Date: Fri, 5 Jun 1998 13:23:26 +0100 (BST) From: Scott Mitchell <scott@dcs.qmw.ac.uk> To: angelsan@bellsouth.net Cc: freebsd-questions@FreeBSD.ORG Subject: Re: Automount the CDROM? Message-ID: <199806051223.NAA20330@hotpoint.dcs.qmw.ac.uk> In-Reply-To: <35746356.60921880@mail.rdu.bellsouth.net> References: <199805131101.MAA03913@hotpoint.dcs.qmw.ac.uk> <35746356.60921880@mail.rdu.bellsouth.net>
next in thread | previous in thread | raw e-mail | index | archive | help
Angel S. Santiago said: >Scott: > >I am intersted...please mail me your map file and any instructions you >deem necessary. > >Thanks in advance. > >A Santiago Hi Angel, Apologies for the delay in replying. My /etc/amd.map looks like this: ----- cut here ----- /defaults type:=host;fs:=${autodir}/${rhost};rhost:=${key} * opts:=rw,grpid,resvport,nfsv2 cdrom type:=program;\ fs:=/mnt/cdrom;\ mount:="/sbin/mount mount /mnt/cdrom";\ unmount:="/sbin/umount umount /mnt/cdrom" floppy type:=program;\ fs:=/mnt/floppy;\ mount:="/sbin/mount mount /mnt/floppy";\ unmount:="/sbin/umount umount /mnt/floppy" msdos type:=program;\ fs:=/mnt/msdos;\ mount:="/sbin/mount_msdos mount_msdos /mnt/msdos";\ unmount:="/sbin/umount umount /mnt/msdos" ----- cut here ----- The cdrom entry (obviously) mounts the CD, floppy and msdos are for UFS and FAT formatted floppies respectively. You will need to have appropriate entries in /etc/fstab for the automounted drives, eg: /dev/wcd0c /mnt/cdrom cd9660 ro 0 0 for the CDROM. You will need to set amd_enable="YES" in /etc/rc.conf and possibly tweak the settings in amd_flags. My automount tree is on /a rather than /net, so both the '/net' and '/host' parts of amd_flags in the default 2.2.6 rc.conf are changed to '/a'. You might also want to make symlinks from /cdrom->/a/cdrom just so the paths look more normal. Note that to unmount the CDROM before it times out you will need to use 'amq -u /mnt/cdrom', since it is really mounted there and not on /cdrom. I hope that all makes sense! Let me know if it works or not. I'll cc: this to -questions in case anyone else finds it useful. Cheers, Scott -- =========================================================================== Scott Mitchell | PGP Key ID |"If I can't have my coffee, I'm just <scott@dcs.qmw.ac.uk> | 0x54B171B9 | like a dried up piece of roast goat" QMW College, London, UK | 0xAA775B8B | -- J. S. Bach. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199806051223.NAA20330>