hey Mikkel,
Tsja, je moet er even goed voor zitten, zijn uitleg is soms een beetje apart qua volgorde.
Maar het is een handig en mooi principe, dus zonde van het geklik op links of elke keer mount -a doen, vind ik.
Uiteraard je eigen keuze, maar ik probeer het toch nog eens:
Om te beginnen, je zegt dat de gedeelde map
op de andere pc leeg was: autofs is voor je client (dus de pc waarop je gaat mounten), niet voor de server!
/etc/auto.ubuntumini bestaat ook niet, hij maakt 'm aan en kiest zelf de naam (kopie van auto.misc).
/etc/auto.ubuntumini is where we keep another file listing our NFS mounts. It can be any file name in any directory actually. But the default is /etc/auto.misc which I leave for later examination. We're going to create this /etc/auto.ubuntumini file in a moment. What matters is that the file matches this entry in /etc/auto.master.
Ik heb 'm zelf anders genoemd en een kopie gemaakt van auto.misc: /etc/auto.nfs:
#
# $Id: auto.misc,v 1.2 2003/09/29 08:22:35 raven Exp $
#
# This is an automounter map and it has the following format
# key [ -mount-options-separated-by-comma ] location
# Details may be found in the autofs(5) manpage
#cd -fstype=iso9660,ro,nosuid,nodev :/dev/cdrom
# the following entries are samples to pique your imagination
#linux -ro,soft,intr ftp.example.org:/pub/linux
#boot -fstype=ext2 :/dev/hda1
#floppy -fstype=auto :/dev/fd0
#floppy -fstype=ext2 :/dev/fd0
#e2floppy -fstype=ext2 :/dev/fd0
#jaz -fstype=ext2 :/dev/sdc1
#removable -fstype=ext2 :/dev/hdd
nfs -fstype=nfs,rw,hard,intr 192.168.2.9:/srv/nfs
De laatste regel is van mij: nfs protocol, ip adres van de server en de nfs export.
Een verwijzing naar die /etc/auto.nfs staat dan weer in /etc/auto.master:
#
# $Id: auto.master,v 1.4 2005/01/04 14:36:54 raven Exp $
#
# Sample auto.master file
# This is an automounter map and it has the following format
# key [ -mount-options-separated-by-comma ] location
# For details of the format look at autofs(5).
#/misc /etc/auto.misc --timeout=60
#/smb /etc/auto.smb
#/misc /etc/auto.misc
#/net /etc/auto.net
/mnt/nfsShare /etc/auto.nfs --timeout=300 --ghost
Ofwel: mount op je client in /mnt/nfsShare de configuratie zoals 'ie in /etc/auto.nfs staat.
Een belangrijke tip van JRicard:
One element of note. BOTH the AUTO.MASTER and AUTO.UBUNTUMINI files require a blank line with line feed after the last entry. Just an anomaly as to the way the software reads lines until it reaches an end of file. But don't forget them.
Tot slot, als je beide bestanden netjes opgeslagen hebt:
sudo /etc/init.d/autofs restart
en de boel moet in /mnt/nfsShare zichtbaar zijn. (NB: de map nfsShare onder /mnt moet je wel zelf aanmaken vóórdat je er een fs in mount)
Da's alles.