• We’re currently investigating an issue related to the forum theme and styling that is impacting page layout and visual formatting. The problem has been identified, and we are actively working on a resolution. There is no impact to user data or functionality, this is strictly a front-end display issue. We’ll post an update once the fix has been deployed. Thanks for your patience while we get this sorted.

Can't edit fstab, it's read only

Red Squirrel

No Lifer
I moved some NFS shares to another raid array and now I need to go around and change it on all my servers/workstations. I hate NFS for that... it should work with share names, not paths and clients should not care where the files are on the server, but that's another story... there does not seem to be anything better than NFS for what it does.

When I try to edit fstab on one of my servers it just says it's read only and refuses to let me edit it. I am root.

On my workstation it's just staying:

umount.nfs: /network/appdev: Stale NFS file handle
umount.nfs: /network/appdev: Stale NFS file handle

When I try to unmount the old one so I can mount the new.

How do I fix these two issues?

Is there an easier way to move files on the NFS server without running into so many issues at all the clients?


Tried all the obvious stuff (which is all I'm finding on Google) such as umount -f and umount -l. For the system that has a read only fstab I tried w! and no go either.
 
Last edited:
Ok managed to get the server working where fstab is read only. I almost ended up having to reinstall it though. I decided to reboot but I got hit with the dreaded ctrl+D bootup error screen due to the invalid fstab entry. Even there it said it was read only. Boot CDs were refusing to even mount the file system. I ended up doing a fsck and there was a whole bunch of errors that it had to fix. To be able to boot again I created a fake nfs share on the nfs server so that the old path is still valid, then was able to boot and then change it. What a pain, all this just because I changed a folder around.

I wonder if I can use symlinks on the server, that way all I have to do is change the symlink and not each client.

I still have to figure out why I can't get the old share to unmount on my workstation though... still getting the NFS handle error and not finding anything useful on Google. I'm kind of scared to reboot in case the system does not come back up.
 
Ended up having to reboot workstation too and it worked.

What a pain though, I should not have to reboot every single machine that uses that mapping just because I change it.
 
How many servers? You could use one server as a master (perhaps the NFS target).

Setup ssh keys from there and mount the clients remotely FROM the NFS server. I have a web cluster I do this with. I basically took the client mount commands out of fstab and run them remotely so I can guarantee the server is running. When NFS starts, there's a delay...then the clients get their commands to connect. I also have scripts to reconnect easily if the connection is broken. It's not difficult to do.
 
How many servers? You could use one server as a master (perhaps the NFS target).

Setup ssh keys from there and mount the clients remotely FROM the NFS server. I have a web cluster I do this with. I basically took the client mount commands out of fstab and run them remotely so I can guarantee the server is running. When NFS starts, there's a delay...then the clients get their commands to connect. I also have scripts to reconnect easily if the connection is broken. It's not difficult to do.

Off the top of my head less than 10, but enough that it's a pain going around to change stuff. For this particular share there was only 2 active clients that use that share but some shares like VM LUNs are disastrous if I try to change. End up having to reboot the ESX server and all.

Never thought of doing the mounting remotely, but not sure if that would solve the issues like "stale NFS handle" and stuff though. Though it would still give a central location to put all the mount commands and parameters.
 
Back
Top