[PATCH] /etc/rc.d/mdconfig improvements
Garrett Cooper
gcooper at FreeBSD.org
Mon Oct 11 04:20:02 UTC 2010
Hi RC folks,
I was looking at /etc/rc.d/mdconfig* recently, and I thought of
two improvements that could be done to the scripts:
1. It's not overly intuitive from the rc.conf manpage that the
memory disks need to be defined in /etc/fstab, so I added an error to
coach people on what to do
2. There was also a missing guard for around a ${_file} reference
where if I did...
/dev/md0 /scratch cd9660 rw
0 0
/dev/md1 /scratch2 ufs rw 0 0
mdconfig_md0="-f /scratch/disk.img -t vnode"
mdconfig_md1="-t swap -s 1M"
... it would check test for ${_file} twice and fail the second
time. The check is benign in most cases, but for completeness it
should be fixed as shown above.
Could someone please commit the attached patch for me, if no one
objects to the change proposed?
Thanks,
-Garrett
-------------- next part --------------
A non-text attachment was scrubbed...
Name: etc-rc.d-mdconfig-improvements.diff
Type: application/octet-stream
Size: 975 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/freebsd-rc/attachments/20101011/8a2e1551/etc-rc.d-mdconfig-improvements.obj
More information about the freebsd-rc
mailing list