readonly /etc/fstab

If you’re trying to save your /etc/fstab and you get:
“fstab” E212: Can’t open file for writing
And you know you can write any other file in “/”, then it’s not a readonly FS.
You need to check the file’s attributes.
[root@myserver etc]# lsattr /etc/fstab
—-i——– /etc/fstab
if it has a “i” then it’s write protected, so change it
[root@myserver etc]# chattr -i /etc/fstab
[root@myserver etc]# lsattr /etc/fstab
————- /etc/fstab
Then you can edit the file
75/433

Leave a Reply

Your email address will not be published. Required fields are marked *