How-To Make the root filesystem read-only

Introduction


There are several reasons why you might want to make your root file system read only. I wanted to have a system on a flash disk, and since flash disks are damaged after repeated read-write circles the read-only root is a very nice solution. Other reasons why you would want to make your root partition read only include:

  • If you want maximum security for your server, and want it to boot from a read only medium (i.e. a CD-ROM)
  • If you want to make your own live-cd
  • To avoid that power loss or system crash damage the root partition.
  • If you want to mount the same nfsroot on several thin clients

The following procedure is what i did to turn my SuSE 10.1 root file system to read-only. It should work on both earlier and later versions but i haven't tested it yet. There could be better/more elegant solutions, if you think that something is missing please fill free to edit this howto.

Acknowledgments

Some of the information on this howto where found here.

→ continue reading

bookmark bookmark bookmark bookmark bookmark bookmark bookmark bookmark bookmark bookmark bookmark bookmark bookmark bookmark bookmark bookmark


Troubleshooting the “device is busy” Error Attempting to umount a Disk

Before attempting to dismount a filesystem, it must be inactive. If "any user" has one of the filesystem's directories as their current directory or has any file within the filesystem open, you will receive an error message, like the one below, when attempting to unmount the filesystem:

  # umount /dev/dsk/c0t2d0s7
  umount: /dev/dsk/c0t2d0s7: device is busy

Well, the

fuser

command to the rescue. The

fuser

command may be used to determine which files or directories within a filesystem are currently in use and to identify the processes and users that are using them.

→ continue reading

bookmark bookmark bookmark bookmark bookmark bookmark bookmark bookmark bookmark bookmark bookmark bookmark bookmark bookmark bookmark bookmark