Date: Tue, 08 Jan 2002 06:39:03 +0100 From: Poul-Henning Kamp <phk@critter.freebsd.dk> To: Michael Smith <msmith@freebsd.org> Cc: Dan Moschuk <dan@freebsd.org>, stable@freebsd.org Subject: Re: Hang in md driver Message-ID: <13954.1010468343@critter.freebsd.dk> In-Reply-To: Your message of "Mon, 07 Jan 2002 12:26:30 PST." <200201072026.g07KQUX01267@mass.dis.org>
next in thread | previous in thread | raw e-mail | index | archive | help
malloc(9) should be fixed to report "I can't and I'll probably never be able to" even in the M_WAITOK case. In message <200201072026.g07KQUX01267@mass.dis.org>, Michael Smith writes: > >This doesn't seem to address the problem; md(4) shouldn't hang when it >runs out of memory. > >> >From md(4): >> >> malloc Backing store is allocated using malloc(9). Only one malloc- >> bucket is used, which means that all md devices with malloc >> backing must share the malloc-per-bucket-quota. The exact size >> of this quota varies, in particular with the amount of RAM in >> the system. The exact value can be determined with vmstat(8). >> >> >> In message <20020107141157.A1759@spirit.jaded.net>, Dan Moschuk writes: >> > >> >I can reproduce a hang in the md driver reliably. >> > >> >Setup: >> > >> >dd if=/dev/zero of=image bs=32k count=8k >> >vnconfig -s labels -c vn0 image >> >diskabel -r -w vn0 auto >> >newfs vn0c >> > >> >dd if=image of=/dev/md0 bs=32k count=8k >> >mount /dev/md0c /mnt >> > >> >This works as expected. >> > >> >If I run bonnie against /mnt with a 64M filesize, everything is fine. >> >However, once I up that size to 128M it will hang half way through. >> > >> >Using an mfs partition instead yields no problems. >> > >> >I've tested this against a 4.3 (512M ram) and a 4.4 (1.5GB ram) boxes >> >respectively and both are affected. top says the bonnie process is in the >> >"MD sec" state. >> > >> >Cheers, >> >-Dan >> > >> >> -- >> Poul-Henning Kamp | UNIX since Zilog Zeus 3.20 >> phk@FreeBSD.ORG | TCP/IP since RFC 956 >> FreeBSD committer | BSD since 4.3-tahoe >> Never attribute to malice what can adequately be explained by incompetence. >> >> To Unsubscribe: send mail to majordomo@FreeBSD.org >> with "unsubscribe freebsd-stable" in the body of the message > > > -- Poul-Henning Kamp | UNIX since Zilog Zeus 3.20 phk@FreeBSD.ORG | TCP/IP since RFC 956 FreeBSD committer | BSD since 4.3-tahoe Never attribute to malice what can adequately be explained by incompetence. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-stable" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?13954.1010468343>