rev. 1.34-1.36 mdconfig.8
rev. 1.52-1.54 mdconfig.c
Make attach the default for -f and assume '-a' and '-t malloc' flags for '-s
<size>' (malloc ramdisk) if not specified.
To mount an image:
MD=`mdconfig -f image`
mount $MD /mnt
To create and mount a RAM disk (gosh, last I used those was on an Atari 1040ST:
256kb just to piss off the 640kb PC loosers)
MD=`mdconfig -s 5mb`
newfs /dev/$MD
mount /dev/$MD /mnt
Et voila! Much easier to remember.
- sys/modules/md/Makefile rev 1.14:
Rename GEOM class kernel module g_md.ko to geom_md.ko for
consistency with the rest. The g_md.ko is now a hardlink of
geom_md.ko for backward compatibility.
- sys/sys/mdioctl.h rev 1.21:
Removed (now unused) #define.
- sys/boot/forth/loader.conf rev 1.102:
Add more GEOM classes to defaults/loader.conf. Add references to
manual pages to those already present.
- sbin/mdconfig/mdconfig.c rev 1.45:
Simplify mdmaybeload() function.
Reviewed by: ru and pjd
Approved by: re (kensmith)
show file name for 'mdconfig -l -u <x>' command.
This allows to preserve API/ABI compatibility with version 0 (that's why
I changed version number back to 0) and will allow to merge this change
to RELENG_5.
MFC after: 5 days
After this change it should be possible to use very big md(4) devices.
- Clean up and simplify the code a bit.
- Use humanize_number(3) to print size of md(4) devices.
- Add 't' suffix which stands for terabyte.
- Make '-S' to really work with all types of devices.
- Other minor changes.
On vnode backed md(4) devices over a certain, currently undetermined
size relative to the buffer cache our "lemming-syncer" can provoke
a buffer starvation which puts the md thread to sleep on wdrain.
This generally tends to grind the entire system to a stop because the
event that is supposed to wake up the thread will not happen until a fair
bit of the piled up I/O requests in the system finish, and since a lot
of those are on a md(4) vnode backed device which is currently waiting
on wdrain until a fair amount of the piled up ... you get the picture.
The cure is to issue all VOP_WRITES on the vnode backing the device
with IO_SYNC.
In addition to more closely emulating a real disk device with a
non-lying write-cache, this makes the writes exempt from rate-limited
(there to avoid starving the buffer cache) and consequently prevents
the deadlock.
Unfortunately performance takes a hit.
Add "async" option to give people who know what they are doing the
old behaviour.
number X, rather than mdX, making it easier to script tests that
use md devices but don't want to make assumptions about any existing
md use (such as in diskless environments).
bypass some extra anti-foot-shooting measures. Currently, its only
effect is to allow detaching a device while it's still open (e.g.,
mounted). This is useful for testing how the system reacts to a disk
suddenly going away, which can happen with some removeable media.
At this point, the force option is only checked on detach, so it
would've been possible to allow the option to be passed with the
MDIOCDETACH operation. This was not done to allow the possibility of
having the force flag influence other tests in the future, which may
not necessarily deal with detaching the device.
Reviewed by: sobomax
Approved by: phk