Date: Sat, 30 Nov 2002 13:42:53 +0100 (CET) From: Michal Mertl <mime@traveller.cz> To: current@freebsd.org Subject: system locks with vnode backed md(4) Message-ID: <Pine.BSF.4.41.0211301330040.60923-100000@prg.traveller.cz>
next in thread | raw e-mail | index | archive | help
Recently there was a discussion about jails on some freebsd list. Someone recommended vnconfig(8)ed file-backed disk for jail file systems. Terry wrote there are problems with it. I liked the idea and played with mdconfig(8)ed devices on current. Terry was right - I can easily make the system deadlock. I really like the idea of jails in vnode-backed filesystems - it performs really well (with small files at least) and it's a pity it can't really be used. I also assume one may encounter the same dadlock using vnode backed swap which is recommended all over the place. I tried to measure performance a bit ('time tar xzf ports.tgz' and 'time rm -rf ports' on real filesystem and it vnode backed one). I got the system to lock-up. I am able to get to DDB so I'm posting 'ps' output here. To recreate the problem use something like this (but for first dadlock I wasn't stressing the system that much - I just used it): mdconfig -a -t vnode -f /some/path/file -s 500m newfs -U /dev/md0 mount /dev/md0 /some/mount/point cd /some/mount/point while (1) tar xzf /path/to/ports.tgz rm -rf ports end DDB 'ps' output when the system is deadlocked (sorry for the line-wrap): pid proc addr uid ppid pgrp flag stat wmesg wchan cmd 537 c403a000 e1722000 1001 533 537 8000012 norm[SLPQ newbuf c03ede10][SLP] tcsh 533 c403a1d8 e1723000 1001 532 533 0004002 norm[SLPQ ppwait c403a1d8][SLP] tcsh 532 c403a3b0 e1724000 1001 529 359 0000100 norm[CVQ select c039cbe4][SLP] sshd 529 c403c000 e1760000 0 359 359 0000100 norm[SLPQ sbwait c3f00764][SLP] sshd 528 c403a588 e1725000 0 527 527 0006002 norm[SLPQ newbuf c03ede10][SLP] gzip 527 c3e4a760 e04e0000 0 454 527 0004002 norm[SLPQ getblk ce4140f4][SLP] tar 526 c403c3b0 e1762000 1001 521 526 0004002 norm[SLPQ newbuf c03ede10][SLP] find 521 c403c1d8 e1761000 1001 520 521 2004002 norm[SLPQ pause e1761000][SLP] tcsh 520 c3f3d760 e1701000 1001 517 359 0000100 norm[CVQ select c039cbe4][SLP] sshd 517 c403ace8 e175f000 0 359 359 0000100 norm[SLPQ sbwait c3f00b64][SLP] sshd 507 c403a938 e175d000 0 0 0 0000204 norm[SLPQ newbuf c03ede10][SLP] md0 454 c3f3d3b0 e16ff000 0 453 454 2004002 norm[SLPQ pause e16ff000][SLP] csh 453 c3f3d000 e16fd000 1001 446 453 0004102 norm[SLPQ wait c3f3d000][SLP] su 446 c3e4ab10 e04e2000 1001 445 446 2004002 norm[SLPQ pause e04e2000][SLP] tcsh 445 c3f3db10 e1703000 1001 442 359 0000100 norm[CVQ select c039cbe4][SLP] sshd 442 c3f3d938 e1702000 0 359 359 0000100 norm[SLPQ sbwait c3f00264][SLP] sshd 440 c3f3d1d8 e16fe000 0 1 440 0004002 norm[SLPQ ttyin c3fbb410][SLP] getty 439 c3e4d3b0 e051c000 0 1 439 0004002 norm[SLPQ ttyin c3fbb810][SLP] getty 438 c3e4d588 e051d000 0 1 438 0004002 norm[SLPQ ttyin c3fbbc10][SLP] getty 437 c3e4d760 e051e000 0 1 437 0004002 norm[SLPQ ttyin c3f39010][SLP] getty 436 c3e4d938 e051f000 0 1 436 0004002 norm[SLPQ ttyin c3f38810][SLP] getty 435 c3e4db10 e0520000 0 1 435 0004002 norm[SLPQ ttyin c3ef9c10][SLP] getty 434 c3e4dce8 e0521000 0 1 434 0004002 norm[SLPQ ttyin c3f38410][SLP] getty 432 c3d27ce8 e04d3000 0 1 432 0004002 norm[SLPQ ttyin c1201010][SLP] getty 424 c3f3d588 e1700000 0 1 424 0000000 norm[SLPQ nanslp c03c8e34][SLP] cron 359 c3e4a1d8 e04dd000 0 1 359 0000100 norm[CVQ select c039cbe4][SLP] sshd 209 c3e4a000 e04dc000 0 1 209 0000000 norm[CVQ select c039cbe4][SLP] syslogd 33 c3e4ace8 e04e3000 0 0 0 0000204 norm[SLPQ vlruwt c3e4ace8][SLP] vnlru 9 c3e4d000 e051a000 0 0 0 0000204 norm[SLPQ newbuf c03ede10][SLP] syncer 8 c3e4d1d8 e051b000 0 0 0 0000204 norm[SLPQ newbuf c03ede10][SLP] bufdaemon 7 c3cc0588 d781b000 0 0 0 000020c norm[SLPQ pgzero c03ef2a4][SLP] pagezero 6 c3cc0760 d7852000 0 0 0 0000204 norm[SLPQ psleep c03ef2bc][SLP] vmdaemon 5 c3cc0938 d7853000 0 0 0 0000204 norm[SLPQ psleep c03a9718][SLP] pagedaemon 32 c3cc0b10 d7854000 0 0 0 0000204 new [IWAIT] irq8: rtc 31 c3cc0ce8 d7855000 0 0 0 0000204 new [IWAIT] irq0: clk 30 c3d27000 e04cc000 0 0 0 0000204 new [IWAIT] irq4: sio0 29 c3d271d8 e04cd000 0 0 0 0000204 norm[IWAIT] swi0: tty:sio 28 c3d273b0 e04ce000 0 0 0 0000204 norm[CPU 0] irq1: atkbd0 27 c3d27588 e04cf000 0 0 0 0000204 new [IWAIT] irq15: ata1 26 c3d27760 e04d0000 0 0 0 0000204 norm[IWAIT] irq14: ata0 25 c3d27938 e04d1000 0 0 0 0000204 new [IWAIT] irq5: pcm0 24 c120e1d8 d6640000 0 0 0 0000204 norm[IWAIT] irq10: rl0 bktr3+++ 23 c120e3b0 d6641000 0 0 0 0000204 new [IWAIT] irq6: bktr2 bktr5++ 22 c120e588 d6642000 0 0 0 0000204 new [IWAIT] irq7: bktr1 bktr4++ 21 c120e760 d6643000 0 0 0 0000204 new [IWAIT] irq11: bktr0 bktr7* 20 c120e938 d6644000 0 0 0 0000204 new [IWAIT] irq13: 19 c120eb10 d6645000 0 0 0 0000204 new [IWAIT] swi5: acpitaskq 18 c120ece8 d6646000 0 0 0 0000204 new [IWAIT] swi3: cambio 17 c3cc0000 d7818000 0 0 0 0000204 new [IWAIT] swi2: camnet 16 c3cc01d8 d7819000 0 0 0 0000204 new [IWAIT] swi5: task queue 15 c3cc03b0 d781a000 0 0 0 0000204 norm[SLPQ sleep c03b5040][SLP] random 4 c1207000 d65cb000 0 0 0 0000204 norm[SLPQ g_down c03934b0][SLP] g_down 3 c12071d8 d6638000 0 0 0 0000204 norm[SLPQ g_up c03934ac][SLP] g_up 2 c12073b0 d6639000 0 0 0 0000204 norm[SLPQ g_events c03934a4][SLP] g_event 14 c1207588 d663a000 0 0 0 0000204 new [IWAIT] swi4: vm 13 c1207760 d663b000 0 0 0 000020c norm[RUNQ] swi6: tty:sio clock 12 c1207938 d663c000 0 0 0 0000204 norm[IWAIT] swi1: net 11 c1207b10 d663d000 0 0 0 000020c norm[Can run] idle 1 c1207ce8 d663e000 0 0 1 0004200 norm[SLPQ wait c1207ce8][SLP] init 10 c120e000 d663f000 0 0 0 0000204 norm[CVQ ktrace c03c50c4][SLP] ktrace 0 c0394720 c04ff000 0 0 0 0000200 norm[SLPQ sched c0394720][SLP] swapper -- Michal Mertl mime@traveller.cz To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.4.41.0211301330040.60923-100000>