Set - 2

Question 1 :

What account is created when you install Linux?

Answer :


Whenever you install Linux, only one user account is created. This is the superuser account also known as root.

Question 2 :

What command should you use to check the number of files and disk space used and each user's defined quotas?

Answer :


The repquota command is used to get a report on the status of the quotas you have set including the amount of allocated space and amount of used space.

Question 3 :

In order to run fsck on the root partition, the root partition must be mounted as

Answer :


You cannot run fsck on a partition that is mounted as read-write.

Question 4 :

In order to improve your system's security you decide to implement shadow passwords. What command should you use?

Answer :


The pwconv command creates the file /etc/shadow and changes all passwords to 'x' in the /etc/passwd file.

Question 5 :

Bob Armstrong, who has a username of boba, calls to tell you he forgot his password. What command should you use to reset his command?

Answer :

passwd boba 

The passwd command is used to change your password. If you do not specify a username, your password will be changed.

Question 6 :

The top utility can be used to change the priority of a running process? Another utility that can also be used to change priority is ___________?

Answer :


Both the top and nice utilities provide the capability to change the priority of a running process.

Question 7 :

What command should you type to see all the files with an extension of 'mem' listed in reverse alphabetical order in the /home/ben/memos directory.

Answer :

ls -r /home/ben/memos/*.mem 

The -c option used with ls results in the files being listed in chronological order. You can use wildcards with the ls command to specify a pattern of filenames.

Question 8 :

What file defines the levels of messages written to system log files?

Answer :


To determine the various levels of messages that are defined on your system, examine the kernel.h file.

Question 9 :

What command is used to remove the password assigned to a group?

Answer :

gpasswd -r 

The gpasswd command is used to change the password assigned to a group. Use the -r option to remove the password from the group.

Question 10 :

What command would you type to use the cpio to create a backup called backup.cpio of all the users' home directories?

Answer :

find /home | cpio -o > backup.cpio 

The find command is used to create a list of the files and directories contained in home. This list is then piped to the cpio utility as a list of files to include and the output is saved to a file called backup.cpio.

Question 11 :

What can you type at a command line to determine which shell you are using?

Answer :

echo $SHELL 

The name and path to the shell you are using is saved to the SHELL environment variable. You can then use the echo command to print out the value of any variable by preceding the variable's name with $. Therefore, typing echo $SHELL will display the name of your shell.

Question 12 :

What type of local file server can you use to provide the distribution installation materials to the new machine during a network installation?

A). Inetd
Answer : Option E

Explanation :

You can use an NFS server to provide the distribution installation materials to the machine on which you are performing the installation. Answers a, b, c, and d are all valid items but none of them are file servers. Inetd is the superdaemon which controls all intermittently used network services. The FSSTND is the Linux File System Standard. DNS provides domain name resolution, and NNTP is the transfer protocol for usenet news.

Question 13 :

If you type the command cat dog & > cat what would you see on your display? Choose one:

A). Any error messages only.
B). The contents of the file dog.
C). The contents of the file dog and any error messages.
D). Nothing as all output is saved to the file cat.
Answer : Option D

Explanation :

When you use & > for redirection, it redirects both the standard output and standard error. The output would be saved to the file cat.

Question 14 :

When you create a new partition, you need to designate its size by defining the starting and ending _____________.

Answer :


When creating a new partition you must first specify its starting cylinder. You can then either specify its size or the ending cylinder.

Question 15 :

What key combination can you press to suspend a running job and place it in the background?

Answer :


Using ctrl-z will suspend a job and put it in the background.

Question 16 :

The easiest, most basic form of backing up a file is to _____ it to another location.

Answer :


The easiest most basic form of backing up a file is to make a copy of that file to another location such as a floppy disk.

Question 17 :

In order to prevent a user from logging in, you can add a(n) ________at the beginning of the password field.

Answer :


If you add an asterick at the beginning of the password field in the /etc/passwd file, that user will not be able to log in.

Question 18 :

When planning your backup strategy you need to consider how often you will perform a backup, how much time the backup takes and what media you will use. What other factor must you consider when planning your backup strategy? _________ 

Answer :

what to backup 
Choosing which files to backup is the first step in planning your backup strategy.

Question 19 :

What utility can you use to automate rotation of logs?

Answer :

The logrotate command can be used to automate the rotation of various logs.

Question 20 :

In order to display the last five commands you have entered using the history command, you would type ___________ .

Answer :

history 5 
The history command displays the commands you have previously entered.
By passing it an argument of 5, only the last five commands will be displayed.