Skip to main content

Explain memory and virtual file system in Linux.

22.Explain memory and virtual file system in Linux.
Ans.
1. These file systems do not exist on disk in the same way that traditional file systems do, they either exists entirely in the system memory or they are virtual because they are an interface to system devices.

2. cramfs:
cramfs is designed to cram a file System onto a small flash memory device, so it is small, simple and able to compress things well.
The largest file size is 16MB and the largest file system size is 256MB since cramfs is so compressed, it isn’t instantly updateable.

3. tmpfs:
tmpfs is structured around the idea that whatever is put in the /tmp file system is accessed again shortly, tmpfs solely in memory, so what you put in /tmp doesn’t persist between reboots.

4. ramfs:
ramfs is basically cramfs without the compression.

5. romfs:
This is a read only file system that is mostly used for initial ramdisks of installation disks.
It was designed to take up very little space, so you could fit a kernel and some useful code into a small disk.

6. proc:
proc is a virtual file system that acts as an interface to the kernel’s internal data structures.
Proc can be used to get detailed information about a system’s hardware and to change kernel parameters at runtime.

7. /dev/pts:
It is a lightweight version if devfs, instead of having all the device files supported in the virtual file system, it provides support for only virtual pseudoterminal device files.

8. devfs:
The device file system (devfs) is another way to access “real” character and block special devices on your root file system, devfs enables device drivers to register devices by name.

9. sysfs:

Sysfs is a virtual file system that acts as an interface to the kernel’s internal data structures information is stored in the /sys directory and can be used to get details about a system’s hardware and to change kernel parameters at runtime.


Comments

Popular posts from this blog

Explain the backing up and restoring files in Linux.

9.Explain the backing up and restoring files in Linux. Ans. 1. Backing-up and restoring files is done only by system administrator. 2. Because of built-in features, Linux doesn’t allow users to back-up their own files to removable disks. 3. It’s not enough to know that performing backup is your job, you need to formulate a strategy to making sure your system is not vulnerable to sudden disastrous disruptions. 4. If you have a high capacity tape drive and several good set of restore disks you can take backup every few days. 5. If you are managing a system with scores of users, you might find it more sensible to back up accounts and system configurations. 6. Only you can decide ‘what’ to backup, you need to decide ‘how frequently’ to perform backups, whether to maintain series of incremental backup. 7. You should maintain perfect backups without ever needing to restore to them, this means encouraging users to keep multiple copies of their important files in their ho...

Explain the file systems supported by Linux.

21.Explain the file systems supported by Linux. Ans. 1. Linux can read/write to several file system that originated with other operating system much different from Linux. 2. One reason that Linux supports so many file systems is the design of its virtual file system (VFS) layer, its provides a fairly universal forms of file support, file systems supported by Linux are as follows: 3. ext3: • Ext3 stands for third extended file system. • Starting from Linux Kernel 2.4.15 ext3 was available. • The main benefit of ext3 is that it allows journaling. • Journaling has a dedicated area in the file system, where all the changes are tracked. • When the system crashes, the possibility of file system corruption is less because of journaling. (If no journaling, then fsck command (file system consistency check) is used to check for the corrupted file and to repair that file). • ext3 keeps a record of uncommitted file transactions and applies only those transactions when the sy...

Explain the rc script and how they can be managed by manually.

18.Explain the rc script and how they can be managed by manually. Ans. 1. ‘rc’ scripts are stored in ‘/etc/rc.d’ directory, rc scripts are used to stop and start services for runlevels. 2. In ‘/etc/rc.d’ directory we have some additional directories rc0.d, rc1.d, rc2.d, rc3.d, rc4.d, rc5.d and rc6.d, the numbers in directory name corresponds to the runlevel and contains the scripts for runlevels. 3. For example let’s take runlevel 5, init program looks in the ‘/etc/rc.d/rc5.d/’ directory for the processes to start and stop. 4. All the scripts in the rc5.d directory are symbolic like to the actual scripts that are located in the ‘/etc/rc.d/init.d/’ directory. The use of symbolic link means that the runlevel can be modified by adding or removing symlinks or changing the order the script run. 5. rc scripts contains symbolic links which can be modified to change the runlevels. 6. Symbolic links begins with a ‘k’ and a number or an ‘s’ and a number. Example: S25netfs -...