On Sat, Jul 06, 2002 at 09:08:39PM +0100, Chris Hedley wrote:
> Hi all,
> 
> If anyone's still looking at the /tmp on md stuff, I've thrown together a
> workaround/solution based on the "mount_md" idea.  Okay, I know that using
> a shell-script for a mount program may be seen as a Bad Thing and I'm not
> sure I want to broadcast my duff shell-programming for all to see, but
> I'll post it if anyone's interested.  What I've done is to create a proto
> file for disklabel to use based on the intended size of the filesystem as
> specified in /etc/fstab which creates a normal multi-partition disc style
> "a" partition which skips the first cylinder, newfses it and mounts the
> result.  Seems to work okay, although since it mucks about with disklabel
> then I'd recommend some caution.
> 
> If it turns out to be useful I'm happy to convert it into a rather more
> robust C equivalent.  This is, of course, based on the assumption that I
> haven't entirely missed the point!  :)

I abused diskless_mount for md filesystems:
[351]cicely5> cat /etc/rc.md
DEV=`mdconfig -a -t swap -s 1400M`
disklabel -r -w ${DEV} auto
newfs /dev/${DEV}c
tunefs -n enable /dev/${DEV}c
mount /dev/${DEV}c /tmp
chmod 1777 /tmp

DEV=`mdconfig -a -t swap -s 800M`
disklabel -r -w ${DEV} auto
newfs /dev/${DEV}c
tunefs -n enable /dev/${DEV}c
mount /dev/${DEV}c /var/run
chmod 755 /var/run

[352]cicely5> grep rc.md /etc/rc.conf
diskless_mount="/etc/rc.md"


It's running fine on i386.
md currently doesn't work on alpha because of 8k pagesize brokenness.

-- 
B.Walter              COSMO-Project         http://www.cosmo-project.de
[EMAIL PROTECTED]         Usergroup           [EMAIL PROTECTED]


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message

Reply via email to