UNIX/Linux Essentials
File System Worksheet
February 16, 2018

True/False
Indicate whether the statement is true or false.

____	1.	The rmdir command automatically removes a directory and all of its subdirectories and files.

____	2.	When using the chmod command, if there is no character specifying the category of user to affect, only the group category is affected.

____	3.	The SGID allows regular users to execute a binary compiled program and become a member of the group that is attached to the file.

____	4.	After a typical Fedora Linux installation, over 700 different device files are in the /dev directory.

____	5.	In Linux, you must use only one type of filesystem on a system.

____	6.	The more filesystems that are used on a system, the less likely a corrupted filesystem will interfere with normal system operations.

Multiple Choice
Identify the choice that best completes the statement or answers the question.

____	7.	In the FHS, the ____ directory contains the Linux kernel and files used by the boot loader.
a.	/load	c.	/boot	
b.	/bin	d.	/mnt	

____	8.	In the FHS, the ____ directory is the root user’s home directory.
a.	/bin	c.	/boot	
b.	/home	d.	/root	

____	9.	The ____ command takes a list of arguments specifying the absolute or relative pathnames of files to remove.
a.	del	c.	remove	
b.	rm	d.	delete	

____	10.	You can see the contents of a certain variable in memory by using the ____ metacharacter with the echo command.
a.	$	c.	&	
b.	*	d.	#	

____	11.	The ____ section of a filesystem is the section that contains information about the filesystem in general.
a.	inode table	c.	data blocks	
b.	inode	d.	superblock	

____	12.	The chgrp command takes ____ argument(s) at minimum.
a.	one	c.	three	
b.	two	d.	four	

____	13.	The section of an inode that stores permissions is called the ____ of the file.
a.	tail	c.	mode	
b.	head	d.	accessor	

____	14.	If a user has ____ permission for a file, they can open, read, and edit the contents of a file.
a.	write	c.	read	
b.	execute	d.	alter	

____	15.	When using the chmod command for a specific file, the ____ argument would add read permission and remove write permission for the group permissions.
a.	u+r+w	c.	g+r-w	
b.	g-r+w	d.	o+r-w	

____	16.	When using the chmod command, the mode rwx can be represented by the number ____.
a.	0	c.	7	
b.	1	d.	8	

____	17.	Devices that transfer data in a character-by-character fashion are referred to as ____ devices.
a.	text	c.	character	
b.	block	d.	binary	

____	18.	The ____ device file represents the first primary partition on the second IDE hard disk drive (primary slave).
a.	/dev/hdc1	c.	/dev/hda1	
b.	/dev/hdb1	d.	/dev/hdc2	

____	19.	The ____ device file represents the second serial port on the system (COM2).
a.	/dev/ttyS0	c.	/dev/tty1	
b.	/dev/tty2	d.	/dev/ttyS1	

____	20.	The ____ filesystem is used by software programs that write to a CD-RW or DVD-RW drive.
a.	ntfs	c.	ext2	
b.	udf	d.	hpfs	

____	21.	Data is read off of hard disks in concentric circles called ____.
a.	tracks	c.	sectors	
b.	blocks	d.	cylinders	

____	22.	To create partitions after installation, you can use the ____ command.
a.	format	c.	fdisk	
b.	formatdisk	d.	partition	

____	23.	The easiest method for monitoring free space by mounted filesystems is to use the ____ command.
a.	df	c.	dfs	
b.	fs	d.	fd	

____	24.	Errors on a filesystem are often referred to as filesystem ____ and are common on most filesystems.
a.	breaks	c.	degradation	
b.	corruption	d.	failures	

____	25.	To check a filesystem for errors, you can use the ____ command, which can check filesystems of many different types.
a.	fcheck	c.	fscheck	
b.	fsc	d.	fsck	

____	26.	You can edit the quotas for certain users by using the ____ command.
a.	edquota	c.	quota	
b.	editquota	d.	repquota	

Completion
Complete each statement.

	27.	The ____________________ command only searches directories that are listed in a special variable called the PATH variable in the current BASH shell.

	28.	When a user creates a file or directory, that user’s name and ____________________ becomes the owner and group owner of the file, respectively.

	29.	Creating a filesystem on a device is commonly referred to as ____________________.

	30.	Each track on a hard disk is divided into ____________________ of information.

	31.	An extended partition can contain many subpartitions called ____________________.

Short Answer

	32.	How does the execute permission apply to a directory?

	33.	Describe the SUID. Give an example of a command that typically has this permission set.

	34.	What are character devices and block devices? What is the difference between them? What types of devices are represented by block device files?

	35.	What are the three different types of hard drives? Briefly describe each, and list the possible configurations and device files for each type.

	36.	What is filesystem corruption? What factors may lead to filesystem corruption?

	37.	What are hard disk quotas? Why and how are they used? Mention the difference between hard and soft limits, and briefly discuss how quotas can be turned on.
	38. Describe the following:
		PATA

		SATA

		Partition

		Sector

		Cylinder

		Head

		Primary Partition

		Extended Partition

		Logical Partition

		MBR

		EXT2

		EXT3

		EXT4

		Swap

39. Explain the recommended Linux Partition Structure.