panic: assertion: cursor->trans->sync_lock_refs > 0 in hammer_recover_cursor

Matthew Dillon dillon at apollo.backplane.com
Thu Oct 22 17:49:03 PDT 2009


:Happened when I started 8 mirror-stream at the same time.
:
:cheers
:   simon

    Yours are easier to track down :-)  Try the patch below.

    Tomokazu's are more difficult.

					-Matt
					Matthew Dillon 
					<dillon at backplane.com>


diff --git a/sys/vfs/hammer/hammer_mirror.c b/sys/vfs/hammer/hammer_mirror.c
index 574b74d..05e12a0 100644
--- a/sys/vfs/hammer/hammer_mirror.c
+++ b/sys/vfs/hammer/hammer_mirror.c
@@ -462,8 +462,10 @@ hammer_ioc_mirror_write(hammer_transaction_t trans, hammer_inode_t ip,
 		 */
 		if (error == EDEADLK) {
 			while (error == EDEADLK) {
+				hammer_sync_lock_sh(trans);
 				hammer_recover_cursor(&cursor);
 				error = hammer_cursor_upgrade(&cursor);
+				hammer_sync_unlock(trans);
 			}
 		} else {
 			if (error == EALREADY)





More information about the Bugs mailing list