Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!


Click here to return to the 'Dynamic automounting of NFS volumes' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
Dynamic automounting of NFS volumes
Authored by: robleach on Feb 18, '03 03:58:25PM

Hi,

For a while now, I've been wanting to connect my local user account on my machine up with my network user account (NFS) so that I wouldn't be dealing with ownership and permission issues every time I want to edit a file on our public sites (which I do ALL the time). So as a first step, I've been trying to figure out how to automount the remote disk that contains my home directory on the network so that I can create a user with the same uid and home directory location. [My linux system is set up this way.] I first tried adding entries to /etc/fstab, a file I created due to other advice. However, no mount occurred upon restart. So I just tried this procedure you've reccommended, still to no avail.

What I've been doing in the meantime is I added the mount commands to my .login file wrapped in a conditional to check if the mounts pre-exist. However, the mount command didn't always work for some reason and I discovered that mount_nfs provided a retry feature and that seemed to alleviate the problem by setting it to 10. So I know that I *can* mount these locations. I don't understand why none of these automount strategies are working for me. I presume that I can't use the login items strategy because those would be stored in my home directory... Another thing I'm dealing with is the mounts I DO have aren't permanent. They occassionally get lost like for example when the server goes down for a minute and comes back up (a problem my linux system handles fine).

When I tried your procedure, I didn't get any default properties in the window below in NetInfo. Could that be the problem? I would prefer the fstab solution since that's what our sysadmins here are familiar with in terms of other unix systems and they might be able to help if they can figure out the quirks of this sytem. But if I can get any solution that will work, I'll settle.

Any advice would be appreciated.

Thanks,
Rob



[ Reply to This | # ]
Dynamic automounting of NFS volumes
Authored by: artgeek on Feb 19, '03 05:09:12PM

Darwin mounts things weirdly. I think you are on the right track with fstab, though, you just need to load it into NetInfo before it will stick, with ->

niload fstab . < 'your.fstabfile'

Backup NetInfo first!

Sounds like your 'lost' mounts are static, and can't be automounted again when Darwin occasionaly lets the NFS links go -> dynamic mounts should solve this problem. Probably a good idea to just load your NFS info into NetInfo /mounts by hand (NI Manager), and not include that info in the /etc/fstab flat file. As I understand /etc/fstab will cause those mounts to be static, NetInfo uses automounter -> though i'm still learning this stuff. So please test this for your desired results. Please post your findings, too :)

You can name the file you are loading into NetInfo anything you like. Use a '/dev/disk' format with /etc/fstab -> 'LABEL' appears broken (last i checked). This solved getting swap and Users to mount consistantly on a separate internal disk. I'm still working on my NFS too!

good luck.

Check these links for a start:

http://www.macosxhints.com/article.php?story=20021230053007256&query=fstab

http://www.macosxhints.com/article.php?story=20021011053443661

http://www.humbug.org.au/talks/fstab/fstab.html

http://www.opendarwin.org/



[ Reply to This | # ]
Dynamic automounting of NFS volumes
Authored by: artgeek on Feb 21, '03 01:33:06AM

I need to retract my last comment, after my experience last night. Apparently, the only thing that successfully mounts my Users and swap partitions is a custom 'Disks' startupitem. As I was testing my setup, I discovered the rc errors mentioned above, and realized fstab wasn't being read. This startupitem is a holdover from 10.1, but is still working perfectly with Jaguar. Now I get to work out fstab, too. Can't say for sure what part NetInfo is playing now??? I'll post back as I find more.

Sorry for the mis-information :(

The links may still be informative, though. I 'd like to hear what your solution eventually is.

Have a good...

ag



[ Reply to This | # ]
Dynamic automounting of NFS volumes
Authored by: robleach on Jun 30, '03 01:03:14PM

Incidentally, this solved my trouble with doing the mount. I haven't reread my post, but I remember that the procedure recommended here worked once I had my sysadmin do the following on the remote machine... Apparently, the system the remote disk was on needed to "allow" my machine to mount it. Here's the summary my sysadmin gave me for doing that:

To allow a machine to mount remote disks, on the remote system:
Add machine name to /etc/netgroup
root@remote_machine [46] / % ypmake
update netgroup
push netgroup
update netid
push netid
root@remote_machine [47] /var/yp % shareall



[ Reply to This | # ]