LPIC-2 Exam 201
Question No: 131 CORRECT TEXT – (Topic 8)
To list the filesystem available from the NFS server ‘castor’, the command”
-e castor” can be used.
Explanation: The showmount is used to display information about NFS filesystems. The
-e option is used to specify an exported filesystem.
Question No: 132 – (Topic 8)
When is the most important time to restore a file from your backup?
On a regular scheduled basis to verify that the data is available.
When the system crashes.
When a user inadvertently loses a file.
When your boss asks to see how restoring a file works.
Explanation: According to ‘best practice’, you should regularly restore files to verify that your backup procedures are working. It’s no good backing up files regularly if you are unable to restore files when needed.
Question No: 133 CORRECT TEXT – (Topic 8)
You routinely compress old log files. You now need to examine a log from two months ago. In order to view its contents without first having to decompress it, use the utility.
Question No: 134 CORRECT TEXT – (Topic 8)
In order to create a file called DirContents containing the contents of the /etc directory you would type .
Answer: ls /etc gt; DirContents
Explanation: Mostly all commands send their output to the screen or take input from the keyboard, but in Linux it is possible to send output to a file or to read input from a file. For example, the ls command sends it’s output to screen; to send the output to a file, you can use the command ls gt; filename. This will send the output of the ls command to filename. In this question, the ls command lists the contents of the /etc directory and sends the list to a file named DirContents.
Question No: 135 – (Topic 8)
On an ext2 filesystem, a running daemon has created a large logfile that is beginning to fill the disk. After deleting the file with an “rm-f” command as root, “df” shows that the space is still in use even though the file is not shown using “ls”. To reclaim this space you must:
Restart the daemon.
Unmount and remount the filesystem.
Recreate the file.
Explanation: Explanation: If you have a daemon which writes a log file and keeps that file open for writing then removing the file will not free up the disk space. The filesystem still sees the program as having a
reference to it. Therefore the filesystem will not free up that disk space. The only way to free the space is to restart the daemon
Question No: 136 CORRECT TEXT – (Topic 8)
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
Explanation: The first thing to consider when planning a backup strategy is what you are going to back up. Then you can think about the amount of data this will be. This will affect your other decisions such as what media to use etc.
Question No: 137 – (Topic 8)
In your present working directory, you have the files.
What is the fewest number of keys you can type to open the file MyTelephoneandAddressBook with vi?
Explanation: Tab completion is where you can type the first few letters of a command or filename then press tab to automatically complete the command or filename. You need to type enough letters so that there is only one command or filename starting with those letters. In this question you could type v then i then space then m then y then tab. This equals six keystrokes. There is only one filename starting with ‘my’ so this file will be opened.
Question No: 138 – (Topic 8)
You have been asked to block network access to an NFS sever. You need to block all access except NFS access. Which of the following actions would you take to achieve this?
Make sure that xinetd is switched off.
Place “ALL: ALL” in /etc/hosts.deny and “NFS: ALL” in /etc/hosts.allow
Add IPChains rules to deny all incoming packets except for portmapper
Place “ALL: ALL” in /etc/hosts.deny and “portmap: ALL” in /etc/hosts.allow
Ensure that the nfs-access.o module is configured into the kernel and use the command “nfs-ctl-allow lt;your IP rangegt;” to provide the required access
Explanation: The hosts.allow file is read before the hosts.deny file. This means that you can block access to ‘all’ in the hosts.deny file, but allow access to specific ports by specific hosts in the hosts.allow file. In this answer, we are blocking all ports to all hosts in the
hosts.deny file. However, we are allowing access to the portmap service for all hosts in the hosts.allow file. (The portmap service is for access to NFS).
Incorrect Answers A:Xinetd must be running.
B:NFS uses the portmapper service. Therefore, you should enter ‘portmap: ALL’ in the hosts.allow file.
C:IPChains is a firewall program. This may work (if you have IPChains running), however using the hosts.allow and hosts.deny files is much simpler.
E:The module and command in this question don’t exist or are incorrectly named.
Question No: 139 – (Topic 8)
You have elected to use the automounter and the autofs script. Your /etc/auto.master file contains the following:
If you change the contents of /etc/auto.project to include a new source path what must be done to access the new path?
Shutdown and restart the local NFS client daemons.
Run fsck on the affected mount point.
Issue the /etc/init.d/autofs reload command.
Add the newly mapped path to /etc/fstab.
Nothing, simply access the newly mapped resource.
Explanation: Autofs uses the automount daemon to manage your mount points by only mounting them dynamically when they are accessed. Autofs consults the master map configuration file /etc/auto.master to determine which mount points are defined. It then starts an automount process with the appropriate parameters for each mount point. Each line in the master map defines a mount point and a separate map file that defines the filesystems to be mounted under this mount point. For example, the /etc/auto.misc file might define mount points in the /misc directory; this relationship would be defined in the
Each entry in auto.master has three fields. The first field is the mount point. The second field is the location of the map file, and the third field is optional. The third field can contain information such as a timeout value. If the source path changes, you can access the new path without changing anything because the mount points are mounted and unmounted dynamically when accessed or closed.
Reference: http://www.redhat.com/docs/manuals/linux/RHL-7.3-Manual/custom-guide/s1- nfs-mount.html
A:As the mount points are mounted and unmounted dynamically, there is no need to restart the NFS daemons.
B:It is not necessary to run fsck (file system checker) on the mount point.
C:As the mount points are mounted and unmounted dynamically, there is no need to restart the autofs daemon.
D:Fstab and autofs are two separate methods for mounting filesystems.
Question No: 140 CORRECT TEXT – (Topic 8)
You want to create a compressed backup of the users home directories. What utility should you use?
Explanation: The tar utility is used to archive multiple files into one ‘tarball’. The -z option
invokes another utility called gzip and instructs it to compress the files before tar archives them.
|Lowest Price Guarantee||Yes||No||No|
|Free VCE Simulator||Yes||No||No|