LPIC-2 Exam 201
Question No: 201 – (Topic 8)
Which of the following interprets your actions when typing at the command line for the operating system?
Explanation: The quot;shellquot; is another name for the command shell or command interpreter. This is the program that gives you a command prompt, accepts the commands you type there, and basically makes the computer do what you tell it to.
The shell#39;s job is to interpret your commands and run the programs you request. Linux was designed to be a multitasking operating system, which means you can run more than one program at one time. Linux was also designed as a multi-user OS, which means that you can have more than one shell running at the same time. (Each user gets his own shell at login.) As a user, you have access only to the programs you are running, not the ones other users are running (though you can run your own copy of the same program). The programs are kept separate because they are quot;enclosedquot; in a quot;shellquot;.
A:A utility is a program that can be run from the shell.
B:An application is another name for a utility or program.
D:A command is what you enter to run a utility/program/application.
Question No: 202 CORRECT TEXT – (Topic 8)
You are asked to provide access through your FTP server to a network share available from an NT server running on your local network- For this purpose, you will need support in the kernel and to mount the NT share using the smbmount command line utility:
Explanation: Windows NT uses SMB (Server Message Blocks) for network communications. In order to be able to use the smbmount command to mount a Windows NT share, your kernel must have smbfs (server message block file system) support.
Question No: 203 CORRECT TEXT – (Topic 8)
What can you type at a command line to determine which shell you are using?
Answer: echo $SHELL
Explanation: The ‘echo’ command is used to echo a string to standard output. $shell is an environment variable that reflects the current shell in use. Therefore, the ‘echo $shell’ command will display the name and path of the shell you are using.
Question No: 204 – (Topic 8)
Several of your users have been scheduling large at jobs to run during peak load times. How can you prevent anyone from scheduling an at job?
Delete the file /etc/at.deny
Create an empty file called /etc/at.deny
Create two empty files: /etc/at.deny and /etc/at.allow
Create an empty file called /etc/at.allow
Explanation: The /etc/at.allow and the /etc/at.deny files are used to control who is allowed to run the ‘at’ command. If the file /etc/at.allow exists, only usernames mentioned in it are allowed to use the ‘at’ command, and the /etc/at.deny file is ignored.
A:The /etc/at.allow file is read before the /etc/at.deny file. If an /etc/at.allow file exists, any names in that file will be able to use the ‘at’ command’. Deleting the /etc/at.deny file may work, but only if no /etc/at.allow file exists.
B:An empty file called /etc/at.deny is the default on a Linux system and allows anyone to use the ‘at’ command.
C:Creating two empty files: /etc/at.deny and /etc/at.allow would also work because an empty /etc/at.allow file would prevent the use of the ‘at’ command. However, it is unnecessary to create both files.
Question No: 205 – (Topic 8)
Which two utilities can you use to set up a job to run at a specified time?
at and crond
atrun and crontab
at and crontab
atd and crond
Explanation: The ‘at’ command is used to execute commands at a specified time and optional date.
A cron job is a program or script scheduled at a specified time. The ‘crontab’ program is used to create user cron jobs.
Question No: 206 – (Topic 8)
You decide to use the logical volume manager (LVM) to manage four 4GB disk drives. After creating the volume group, how would you create a 10GB logical volume called big- app?
vgcreate -p 10g -n /deb/vg01/big-app
vgcreate -l 2560 /dev/vg01/big-app
mklvm -v 10240 -n /dev/vg01/big-app
lvcreate -v 10240 /dev/vg01/big-app
lvcreate -l 2560 vg01 -n big-app
Explanation: When you create a volume group, it will have a physical extent size of 4MB by default, unless otherwise specified. When you add disks to the volume group, the disk space is divided into chunks equal to the physical extent size (4MB by default). When you create a logical volume with the lvcreate command, the -l option is used to specify the size of the logical drive in ‘logical extents’. The logical extents are the same size as the physical extents. Therefore, to create a 10GB logical drive, you would specify 2560 logical extents (2560 x 4MB = 10GB). Vg01 is the name of the volume group in which to create the logical volume. The -n option allows you to enter a name for the logical volume. In this case ‘big- app’.
A:The vgcreate command is used to create the volume group. B:The vgcreate command is used to create the volume group. C:Mklvm is an invalid command.
D:-v is an incorrect option to create a logical volume.
Question No: 207 – (Topic 8)
Which of the following daemons must be running on an NFS server?
Explanation: If you want to provide NFS service to other hosts, you have to run the rpc.nfsd and rpc.mountd daemons on your machine. As RPC-based programs, they are not managed by inetd, but are started up at boot time and register themselves with the portmapper; therefore, you have to make sure to start them only after rpc.portmap is running.
Portmap provides port information to clients requesting RPC services on the server. Mountd determines which filesystem and devices are available to which machine and users. Nfsd is the daemon on the server that handles client filesystem requests.
Reference: http://www.linuxvalley.it/encyclopedia/ldp/guide/nag2/x-087-2- nfs.daemons.html
B:Nfsiod runs on an NFS client machine to service asynchronous I/O requests to its server. It improves performance but is not required for correct operation.
D:Xinetd is a replacement for inetd, the internet services daemon, and offers improved functionality. However, it is not a requirement to run NFS.
Question No: 208 – (Topic 8)
You previously ran the find command to locate a particular file. You want to run that command again. What would be the quickest way to do this?
->fc -l find lt;entergt;
->history -l find lt;entergt; history n
Retype the command
fc -n find
Explanation: The -l option used with the fc command is used to list the commands saved in the ‘history’. The ‘fc -l find’ command will display all recent commands starting with the word ‘find’. After pressing enter, the list is displayed and you can recall the command by entering the number (n) of the command.
B:The syntax of the ‘history’ command is wrong.
C:Whether it would be quicker to retype the command or not depends on the name of file you were looking for previously. It is unlikely that this is a trick question, so the answer would be to use the fc command.
D:The ‘fc -n find’ command would display the recent ‘find’ commands, but without the command numbers. It would not run the required command.
Question No: 209 CORRECT TEXT – (Topic 8)
You need to view the contents of the tarfile called MyBackup.tar. What command would you use?
Answer: tar tf MyBackup.tar
Answer: tar -tf MyBackup.tar
Explanation: You can list the contents of a ‘tarball’ with the ‘tar tf tarfile’ command. The t option is used to list the files and directories. The f option allows you to specify the name of
the tarball (a tarball is a common name for an archive created with the tar utility) with the f
Question No: 210 – (Topic 8)
How can you determine who has scheduled at jobs?
Explanation: The at -l command is the same as the atq command. It will list the user#39;s pending jobs, unless the user is a privileged user; in which case, everybody#39;s jobs are listed
B:The -q option is used to place the job in a specified queue. It does not display who has scheduled jobs.
C:The -d option is used to delete a specified job. It does not display who has scheduled jobs.
D:This is an invalid command.
|Lowest Price Guarantee||Yes||No||No|
|Free VCE Simulator||Yes||No||No|