L5 Linux Filesystem Administration

¡Supera tus tareas y exámenes ahora con Quizwiz!

The _____ command views the size of a directory and contents in Kilobytes.

du (directory usage)

T/F. Floppy disks must be prepared before use and formatted with a filesystem.

True

The_____ with the t option allows the system administrator to specify the filesystem type.

-t command

L5 Study Guide Questions - Linux Filesystem Administration (Page 14)

...

When the Linux system is first turned on, a filesystem present on the hard drive is mounted to the / directory. This is referred to as the __________________________ filesystem and contains most of the operating system files.

...

mkfs /dev/fd0

...

The_____ contains a device file for each device on your computer.

/dev directory

To make identification of the CD/DVD drive(s) easier, Fedora Linux includes symbolic links within the /dev directory. State them.

/dev/cdrom - symbolic link to first CD-ROM drive /dev/cdrw - symbolic link to first CD-RW drive /dev/dvd - symbolic link to first DVD-ROM drive /dev/dvdrw - symbolic link to first DVD-RW drive

Quotas are typically enabled at boot time if there are entries in _____ file.

/etc/fstab

The_____ file is used to mount devices at boot time and it is also consulted when users do not specify enough arguments with the mount command.

/etc/fstab (filesystem table)

The _____ directory contains most utilities and installed programs on a Linux system and should have enough room for future software installations.

/usr

The _____ directory grows in size continuously as it stores log files. Old log files should be removed periodically to leave room for new ones.

/var

There are six fields in the etc/fstab file. State these fields.

<device to mount> <mount point> <type> <mount options> <dump#> and <fsck#>

_____ are unusable areas of a disk that cannot hold a magnetic charge.

Bad Blocks

2. After a partition on a hard disk drive is formatted with a filesystem, all partitions on that hard disk drive must use the same filesystem. True or False?

False

9. Character devices typically transfer data more quickly than block devices. True or False?

False

The SATA and SCSI hard drives must be configured in one of several ways. State them.

First SATA or SCSI hard drive (/dev/sda) Second SATA or SCSI hard drive (/dev/sdb) Third SATA or SCSI hard drive (/dev/sdc) And so on

Most current Linux systems have a SATA hard drive configuration. It must be configured as one of several ways. State them.

First SATA/SCSI drive (/dev/sda, /dev/scd0, /dev/sr0, and /dev/sg0) Second SATA/SCSI drive (/dev/sdb, /dev/scd1, /dev/sr1, and /dev/sg1) Third SATA/SCSI drive (/dev/sdc, /dev/scd2, /dev/sr2, and /dev/sg2) And so on

_____ a drive is creating a filesystem on the device.

Formatting

Large hard drives (> 2 TB) use a _____ in place of the MBR to allow for the additional addressing of sectors.

GUID Partition Table (GPT)

_____ are the limits on the number of files or total disk storage space on a hard disk drive that are available to the user. It will restrict the number of files/directories or total disk space usage for each user. It can be applied to both users and groups of users.

Hard Disk Quotas

_____ are rigid quotas and prevent the user from exceeding these hard disk limits.

Hard Limits

_____ is used to create volumes. These volumes can contain filesystems and can be mounted to directories. They are more flexible than standard partitions because they allow use of free space across multiple hard disks. They have error correction abilities.

Logical Volume Manager (LVM)

_____ are the usable volumes that are created by the LVM from the available storage space within a VG. LVs contain a filesystem and are mounted to a directory in the Linux filesystem hierarchy. In addition, LVs can be resized easily by the LVM to use more or less storage space.

Logical Volumes (LVs)

The _____ of a device file points to the device driver for the device in the Linux kernel. It may be shared, i.e., two hard drives.

Major Number

The partition definitions are stored in the first readable sector of the hard disk, known as _____.

Master Boot Record (MBR) or Master Boot Block (MBB)

The _____ of a device file indicates the particular device itself, i.e., the first floppy drive, etc.

Minor Number

A _____ is a directory to which a device is attached.

Mount Point

_____ refers to the process of making a device accessible to users via the logical directory tree.

Mounting a drive

A _____ is a physical division of a hard drive.

Partition

State some good practices on why it is good to use more than two partitions.

Partitions segregate different types of data. Partitions allow for the use of multiple filesystem types on one hard drive. Partitions reduce the chance that filesystem corruption will render a system unusable. Partitions speeds up access to stored data and keeps filesystems as small as possible.

_____are unused partitions on hard disks that the LVM can use to store information.

Physical Volumes (PVs)

The LVM consists of several different components. State them.

Physical volumes (PVs) A volume group (VG), and Logical volumes (LVs)

The standard PATA hard drive configuration must be configured in one of several ways. State them.

Primary master (/dev/hda) Primary slave (/dev/hdb) Secondary master (/dev/hdc) Secondary slave (/dev/hdd)

_____ allow the user to extend the hard disk quota limits for a certain period of time (usually seven days by default).

Soft Limits

State the two types of hard disk quotas.

Soft limits Hard limits

_____ is the process of writing data stored in RAM to the hard disk.

Syncing

T/F. Frequently used filesystems should be checked regularly for errors since they are more prone to corruption.

True

mkfs -t ext2 /dev/fd0

The default filesystem of the mkfs command is the ext2 filesystem.

T/F. If a device file is corrupted, it will be listed as a regular file.

True

When using the ls -l command to view device files, a portion of the listing is replaced by two numbers. State them.

The major number & The minor number

tune2fs -i 0 /dev/vg2USB/data

This command changes the interval between filesystem checks to 0 seconds which in effect disables the filesystem checks.

cat /etc/mtab

This command displays the mount information in the /etc/mtab file.

cat /etc/fstab

This command displays the mounted devices at boot time.

fuser -u /media/floppy

This command is used to check if any user is using the /media/floppy directory.

mount /dev/fd0

This command looks up the missing information in the /etc/fstab file.

mount /media/floppy

This command looks up the missing information in the /etc/fstab file.

mknod /dev/fd0 b 2 0

This command re-created the device driver for the first floppy disk based the file type, the major and minor numbers.

T/F. Files that cannot be repaired are placed in the lost+found directory and the file is renamed as its inode number. These files in the lost+found directory are usually deleted.

True

16. The lvextend command can be used to add additional unused space within a volume group to an existing logical volume. True or False?

True

T/F. A filesystem with several small files might use up all of the inodes in the inode table and prevent new files from being created on the filesystem.

True

T/F. After a floppy disk has been formatted with a filesystem, it must be mounted on the directory tree before it can be used.

True

T/F. All device files consist of inodes and no data blocks thus the files are small. The entire /dev directory can fit on a floppy disk.

True

T/F. Although swap partitions do not contain a filesystem, you must still be prepared to swap partitions and activate them for use on the Linux system.

True

T/F. Any existing directory can be a mount point. The existing files are just covered up in the directory.

True

T/F. As the disk size increases, organization on the disk becomes more difficult and chance of error increases.

True

T/F. Block devices transfer chunks or blocks of data at a time using physical memory to buffer the transfer. It is a method for fast data transfer via floppy disks, CD-ROMs, DVDs, USB flash drives and hard disks.

True

T/F. CDs/DVDs cannot be ejected until properly unmounted because the drive is locked.

True

T/F. Character devices transfer data to and from the device in the system character-by-character. Tape drives are an example of this method of data transfer.

True

T/F. Conversely, more filesystems typically results in less hard disk space per filesystem and might result in system errors if certain filesystems fill up with data.

True

T/F. Each partition in a Linux system can have its own unique filesystem.

True

T/F. Edit the /etc/fstab file to ensure that LVs are automatically mounted at system startup.

True

T/F. Edit the /etc/fstab file to ensure that new swap partition is activated as virtual memory.

True

T/F. Every filesystem has an inode table that contains the inodes for the files and directories on the filesystem. This inode table is made during filesystem creation and is usually proportional to the size of the filesystem. Each file and directory uses one inode.

True

T/F. If an operating system finds a bad block, it puts a reference to that bad block in the bad blocks table on the filesystem. Any entries in the bad block table are not used for future disk storage.

True

T/F. If the filesystem type of the fsck command is not specified, the filesystem is detected automatically.

True

T/F. If the free space on / filesystem falls below 10%, the system might suffer from poorer performance or cease to operate.

True

T/F. If there are several users on a system, there must be enough hard disk space to support the files that each user is expected to store on the hard disk.

True

T/F. In a GUI environment, the CD or DVD is automatically mounted to a directory underneath the /media directory. It is named for the label on the CD or DVD. The system places a shortcut on the desktop.

True

T/F. It is good form to always reboot your machine after running fdisk to ensure proper reloading of the partition table into memory.

True

T/F. Most older Linux systems have a standard PATA hard drive configuration.

True

T/F. Most removable storage devices emulate the SCSI protocol in the firmware of the device itself. Therefore, USB devices can usually be configured as SATA or SCSI hard drives, i.e., /dev/sda, /dev/sdb, /dev/sdc & /dev/sdd.

True

T/F. SATA and SCSI hard disks are well-suited to Linux servers. They have faster access speeds and multiple hard drives can be attached to a controller. SATA and SCSI hard disks are associated with different device files.

True

T/F. The / directory should always contain a great deal of free space to be used as working space for the operating system.

True

T/F. The LVM has error correction abilities that minimize the chance that data will be corrupted or lost.

True

T/F. The administrator should check the mounted filesystems periodically. The filesystems should be checked for errors, disk space usage and inode usage.

True

T/F. The device driver for the first floppy drive is stored in the /dev/fd0 directory.

True

T/F. The device file type (block or character), major number (device driver) and the minor number (specific device) make up the unique characteristics of each device file.

True

T/F. The df commands only views mounted filesystems.

True

T/F. The e2fsck command can be used to check the ext2, ext3 and ext4 filesystems. These commands accept more options and can be used to check a filesystem more thoroughly than fsck.

True

T/F. The iso9660 filesystem can be used to create image files, called ISO images that contain other files. It can be mounted as a loopback device using the mount command.

True

T/F. The pvscan, vgscan, and lvscan commands display information about PVs, VGs, and LVs, respectively.

True

T/F. These errors in the filesystem structure prevent the retrieval of data and commonly occur due to improper system shutdown.

True

T/F. These removable devices are automatically mounted to a new directory under the /media directory named for the label on the device.

True

T/F. To automatically repair any corruption, use the -a or -y option with the fsck command to automatically repair the filesystem corruption.

True

T/F. To configure the LVM, you must first create one or more PVs that reference an unused partition on a hard disk in your computer.

True

T/F. To mount a device on the directory tree, you must use the mount command with options and arguments to specify the filesystem type, the device to mount and the directory on which to mount the device (mount point).

True

T/F. To mount or unmount floppies, one must ensure that no user is currently using the mount point directory.

True

T/F. To see a list of devices that are currently used on the system and the major numbers, use the cat /proc/devices command.

True

T/F. Use the ls -l /dev/fd0 command to determine whether it uses a block or a character method of data transfer. brw-rw---- indicates that the fd0 is a block device file.

True

T/F. With no options or arguments, the mount command lists currently mounted filesystems.

True

T/F. To access and store files on the floppy device, you can now treat the /media/floppy directory as the root of the floppy disk.

True cd /media/floppy

T/F. The du -s command will summarize the output. The -h option should also be used.

True du -hs /usr

T/F. Using the -c option to the e2fsck command, the user checks for bad blocks and adds them to a bad block table on the filesystem so they are not used in the future.

True e2fsck -c /dev/vg2USB/data

T/F. The filesystem must be unmounted and the -f option should be used to perform a full disk check.

True fsck -f -t ext4 /dev/vg2USB/data

T/F. Editing the /etc/fstab file allows the system to mount new filesystems automatically at boot time.

True gedit /etc/fstab

T/F. You can work with the VGs as you would work with any other hard disk partition device file.

True mke2fs -t ext4 /dev/vg2USB/data mke2fs -t ext4 /dev/vg2USB/moredata

T/F. After rebooting the computer, the partition must be formatted, then mounted and unmounted.

True mkfs -t ext4 /dev/sdb1

T/F. The mkisofs command is used to create an ISO image from a directory of files. The following commands make a file called nick.iso from the files on the desktop of the root user that are in the Stuff from Nick directory with Joliet(-J) and Rock Ridge (-R) support.

True mkisofs -RJ -o nick.iso /root/Desktop/'Stuff from Nick' mount -o loop -t iso9660 nick.iso /media/loop

T/F. CDs typically use the iso9660 filesystem type and are not writable. They should be mounted with the -r (read-only) option.

True mount -r -t iso9660 /dev/cdrom /media/cdrom

T/F. It is easy to work with removable storage devices using a GUI interface. If you want to use commands, you must know the device file and mount point directory for each device.

True umount /dev/sdb1 mke2fs -t ext4 /dev/sdb1 mkdir /media/'Flash Drive' mount -t ext4 /dev/sdb1 /media/'Flash Drive'

T/F. A floppy disk should be unmounted before it is ejected.

True umount /media/floppy

A _____ is a partition with its own filesystem.

Volume

A _____ contains one or more PVs. It represents the pool of hard disk storage space that is available to the LVM for creating logical volumes. Additional PVs can easily be added to a VG after creation.

Volume Group (VG)

17. You plug a USB flash memory drive into a system that has two SATA hard disks. What will the partition on this USB flash memory drive be recognized as to the Linux system? a. /dev/sda1 b. /dev/sda2 c. /dev/sdb1 d. /dev/sdc1

a. /dev/sda1

11. What does the command dumpe2fs -h do? a. backs up an ext2 filesystem b. displays the number of inodes used and available in an ext2 filesystem c. dumps an ext2 filesystem d. is not a valid command

b. displays the number of inodes used and available in an ext2 filesystem

14. A device file _______________________. (Choose all that apply.) a. has no inode section b. has no data section c. has no size d. displays a major and minor number in place of a file size e. has a fixed size of 300 kilobytes

b. has no data section d. displays a major and minor number in place of a file size

18. Which command mounts all existing filesystems in /etc/fstab? a. mount -f b. mount -a c. mount /etc/fstab d. mount /etc/mtab

b. mount -a

19. A user runs the fsck command with the -a option on a filesystem that is showing signs of corruption. How would that user locate any files the system was unable to repair? a. Look in the root of the filesystem. b. The system prompts the user for a target location when it comes across a file it cannot repair. c. Mount the filesystem and check the lost+found directory underneath the mount point. d. View the contents of the directory /lost+found.

c. Mount the filesystem and check the lost+found directory underneath the mount point.

13. Which of the following statements are true? (Choose all that apply.) a. Quotas can only limit user space. b. Quotas can only limit the number of files a user can own. c. Quotas can limit both user space and the number of files a user can own. d. Hard limits can never be exceeded. e. Hard limits allow a user to exceed them for a certain period of time. f. Soft limits can never be exceeded. g. Soft limits allow a user to exceed them for a certain period of time. h. Either a hard limit or a soft limit can be set, but not both concurrently.

c. Quotas can limit both user space and the number of files a user can own d. Hard limits can never be exceeded. g. Soft limits allow a user to exceed them for a certain period of time.

12. The first floppy drive on the system is not responding. You enter the file /dev/fd0 command and receive the following output. What is the problem? [BEGIN CODE] [root@server1 root]# file /dev/fd0 /dev/fd0: ASCII text [root@server1 root]# [END CODE] a. The floppy drive cable has come loose. b. There is no floppy disk in the drive. c. The device file has become corrupt. d. The floppy drive is seen as a character device.

c. The device file has become corrupt.

6. A user mounts a device to a mount point directory and realizes afterward there are files previously found within the mount point directory that are needed. What should this user do? a. Nothing; the files are lost and cannot ever be accessed. b. Nothing; the files could not have been there as you can only mount to empty directories. c. Unmount the device from the directory. d. Run the fsck command to recover the file. e. Look in the lost+found directory for the file

c. Unmount the device from the directory.

8. What must you do to successfully run the fsck command on a filesystem? a. Run the fsck command with the -u option to automatically unmount the filesystem first. b. Choose yes when warned that running fsck on a mounted filesystem can cause damage. c. Unmount the filesystem. d. Ensure that the filesystem is mounted.

c. Unmount the filesystem.

4. Jim has just purchased two new SCSI hard disk drives and a controller card for them. He properly installs the hardware in his machine. Before he can use them for data storage and retrieval, what must he do? (Choose all that apply.) a. Mount the two hard drives so they are accessible by the operating system. b. Mount a filesystem to each of the hard disk drives. c. Use the fdisk command to create one or more partitions on each of the hard disk drives. d. Use the vi editor to edit /etc/mtab and create an entry for the controller card and the hard disk drives. e. Mount any partitions created on the two hard drives such that they are accessible by the operating system. f. Format any partitions created with a valid filesystem recognized by Linux.

c. Use the fdisk command to create one or more partitions on each of the hard disk drives. e. Mount any partitions created on the two hard drives such that they are accessible by the operating system. f. Format any partitions created with a valid filesystem recognized by Linux.

3. You want to see the filesystems that are presently in use on the system. What command could you use? a. cat /etc/fstab b. ls -l /etc/fstab c. cat /etc/mtab d. ls -l /etc/fstab

c. cat /etc/mtab

20. Which command is used to format a partition on a hard disk drive with the ext4 filesystem? a. format_ext4 device b. ext4mkfs device c. e2mkfs -t ext4 device d. makeext4FS device

c. e2mkfs -t ext4 device

There are two methods for transferring data to and from a device. State them.

character block

Filesystems themselves can accumulate errors over time and these errors are often referred to as filesystem _____ and are common on most filesystems.

corruption

Several prompts are displayed for the user to accept the fdisk commands. State them.

d (delete a partition) m (print this menu) n (add a new partition) p (print the partition table) q (quit without saving changes) w (write table to disk)

15. Which of the following statements regarding LVM structure is correct? a. PVs are collections of VGs b. LVs are created from the free space available within PVs c. VGs are comprised of one or more PVs d. PVs use the space within LVs to create VGs

d. PVs use the space within LVs to create VGs

7. Which command is used to display the amount of free space that exists on a filesystem? a. fsck b. quota c. du d. df

d. df

10. What does the du /var command do? a. shows the users connected to the /var directory b. shows the size of all directories within the /var directory c. dumps the /var directory d. displays the amount of free space in the /var directory

d. displays the amount of free space in the /var directory

The _____ command monitors the free space used by mounted filesystems. This command with the -h option is more user friendly or at least humanly-readable.

df (disk free space) df -h

The _____ command views the total number of inodes and free inodes for an ext2, ext3 or ext4 filesystem. The -h option should be used.

dumpe2fs dumpe2fs -h /dev/sdb1

The _____ command can be used to edit certain user quotas.

edquota

The _____ is the second extended filesystem which is the traditional filesystem used in Linux. It supports access control lists (individual user permissions).

ext2 filesystem

mount -t ext2 /dev/fd0 /media/floppy

ext2 is the filesystem type /dev/fd0 is the device /media/floppy is the mount point

The _____ is the third extended filesystem which is a variation on ext2 that allows for journaling and thus, has a faster startup and recovery time.

ext3 filesystem

The _____ is the fourth extended filesystem which is a variation on ext3 that has larger filesystem support and speed enhancements.

ext4 filesystem

The_____ creates partitions after installation. The user needs to specify the hard disk partition as an argument.

fdisk command fdisk /dev/sdb

The _____ is an organization imposed on the physical storage media that is used to manage the storage and retrieval of data.

filesystem

The _____ command checks a filesystem for errors.

fsck (filesystem check)

The _____, with the -u option, lists all of the users using a directory.

fuser command

The _____is the CD-ROM filesystem which is a filesystem that originated from the International Standards Organization recommendation 9660 and is used to access data stored on CDs and DVDs.

iso9660 filesystem

When an ext2 filesystem is created on a disk device, one directory called_____ is created by default.

lost+found

Use the_____ to determine which of these configurations is used for the CD-ROM.

ls -l /dev/cdrom

The ______ command is used to create LVs from available space in a VG.

lvcreate lvcreate -L 600MB -n data vg2USB lvcreate -L 128MB -n moredata vg2USB

The _____ command is used to display information about each LV.

lvdisplay

The_____ command is used to increase the size of an LV, e.g., to use space extended onto an existing VG.

lvextend

The _____ command is used to format a disk device with a filesystem.

mkfs (make filesystem)

The _____ can be used to re-create a corrupted device file or recreate a deleted file. The command must have the file type, the major and minor numbers.

mknod command

Use the _____ command to prepare the swap partition.

mkswap mkswap /dev/sdb1

The _____filesystems that are used, the _____ likely a corrupted filesystem will interfere with normal system operations.

more, less

The _____ is used to mount devices to mount point directories.

mount command

The _____ with no options or arguments displays a list of currently mounted filesystems in the /etc/mtab file.

mount command

The _____ is a filesystem used by DOS and Windows computers that supports long file names.

msdos filesystem

To create a PV partition, use the _____ command.

pvcreate pvcreate /dev/sdb pvcreate /dev/sdc

The _____ command is used to display detailed information about each PV.

pvdisplay

The _____ command allows regular users to view their own quotas and current usage.

quota

After boot time, the _____ commands toggle the quotas on and off, respectively.

quotaon and quotaoff

The _____ command gathers a report for quotas by user on the filesystem.

repquota

Use the _____ command to deactivate the swap partition.

swapoff

Use the _____ command to activate the swap partition.

swapon swapon /dev/sdb1

State the two required partitions (at a minimum) for a Linux system.

the root partition the swap partition for virtual memory

The_____ command can be used to change or "tune" filesystem parameters after a filesystem has been created.

tune2fs

The_____ is the Universal Disk filesystem which is a filesystem used by software programs that write to a CD-R, CD-RW or DVD writable disks.

udf filesystem

The _____ is used to unmount devices from mount point directories.

umount command

The _____command is used to create a VG that uses the space in PVs. The arguments are name of the VG and PVs to be used.

vgcreate vgcreate vg2USB /dev/sdb /dev/sdc

The _____ command is used to display detailed information about each VG.

vgdisplay

The _____ command is used to add a new PV to an existing VG.

vgextend


Conjuntos de estudio relacionados

BIO 320: TRASNPORT ACROSS MEMBRANES

View Set

Topic 4 - Doctrine of Anticipation

View Set

Lesson 5 Marketing Quiz - Marketing Research

View Set

Mental Health Chapter 25 Practice Questions

View Set

HR management: Employee benefits

View Set

chapter 2 inquizitives texas government

View Set

Week 9 - iClicker & TPCS Questions

View Set