Real 010-160 dumps Accurate Questions and Answers with Free and Fast Updates
Real 010-160 Quesions Pass Certification Exams Easily
NEW QUESTION # 77
What are the differences between hard disk drives and solid state disks? (Choose two.)
- A. Solid state disks provide faster access to stored data than hard disks.
- B. Hard disks can fail due to physical damage, while solid state disks cannot fail.
- C. /dev/sdais a hard disk device while /dev/ssdais a solid state disk.
- D. Solid state disks can store many times as much data as hard disk drives.
- E. Hard disks have a motor and moving parts, solid state disks do not.
Answer: A,E
NEW QUESTION # 78
Which of the following commands creates an archive file work.tarfrom the contents of the directory ./
work/?
- A. tar work.tar < ./work/
- B. tar -cf work.tar ./work/
- C. tar --new work.tar ./work/
- D. tar -create work.tgz -content ./work/
- E. tar work > work.tar
Answer: B
NEW QUESTION # 79
Which of the following commands will create an archive file, named backup.tar, containing all the files from the directory /home?
- A. tar -xf /home backup.tar
- B. tar -xf backup.tar /home
- C. tar -cf backup.tar /home
- D. tar -cf /home backup.tar
- E. tar /home backup.tar
Answer: C
NEW QUESTION # 80
Which of the following directories must be mounted with read and write access if it resides on its own dedicated file system?
- A. /lib
- B. /opt
- C. /var
- D. /etc
- E. /usr
Answer: C
Explanation:
The /var directory must be mounted with read and write access if it resides on its own dedicated file system. The reason is that the /var directory contains files and directories that are expected to change in size and content as the normal operation of the system progresses, such as logs, spool files, and temporary files1. Therefore, the /var directory needs to have enough space and permission to accommodate these changes. If the /var directory is mounted as read-only, some system services and applications may fail to start or function properly2.
The other options are not directories that must be mounted with read and write access if they reside on their own dedicated file system. The /opt directory contains optional or third-party software packages that are not part of the default installation1. The /lib directory contains libraries and kernel modules that are essential for the binaries in /bin and /sbin directories1. The /etc directory contains configuration files for the system and applications1. The /usr directory contains user-related programs, libraries, documentation, and data1. These directories are usually mounted as read-only to prevent accidental or malicious modification of their contents3. Reference:
Linux Essentials Exam Objectives, Version 1.6, Topic 102.1, Weight 3
Linux Essentials Certification Guide, Chapter 2, Page 34-35
Linux Filesystem Hierarchy, Chapter 3, Page 17-18
NEW QUESTION # 81
What information is stored in/etc/passwd? (Choose three correct answers.)
- A. The encrypted password
- B. The user's storage space limit
- C. The numerical user ID
- D. The username
- E. The user\s default shell
Answer: C,D,E
Explanation:
Explanation
The /etc/passwd file is a plain text-based database that contains information for all user accounts on the system. It is owned by root and has 644 permissions. The file can only be modified by root or users with sudo privileges and readable by all system users. Each line of the /etc/passwd file contains seven comma-separated fields, representing a user account. The fields are as follows:
* Username: The string you type when you log into the system. Each username must be a unique string on the machine. The maximum length of the username is restricted to 32 characters.
* Password: In older Linux systems, the user's encrypted password was stored in the /etc/passwd file. On most modern systems, this field is set to x, and the user password is stored in the /etc/shadow file.
* User ID (UID): The user identifier is a number assigned to each user by the operating system to refer to a user. It is used by the kernel to check for the user privileges and grant access to system resources. The UID 0 is reserved for the root user and cannot be assigned to any other user.
* Group ID (GID): The user's group identifier number, referring to the user's primary group. When a user creates a file, the file's group is set to this group. Typically, the name of the group is the same as the name of the user. User's secondary groups are listed in the /etc/group file.
* User ID Info (GECOS): This is a comment field. This field contains a list of comma-separated values with the following information: User's full name or the application name, Room number, Work phone number, Home phone number, Other contact information.
* Home directory: The absolute path to the user's home directory. It contains the user's files and configurations. By default, the user home directories are named after the name of the user and created under the /home directory.
* Login shell: The absolute path to the user's login shell. This is the shell that is started when the user logs into the system. On most Linux distributions, the default login shell is Bash.
Therefore, the correct answers are B, C, and E. The user's storage space limit (A) is not stored in the
/etc/passwd file, but in the /etc/quota file. The encrypted password (D) is not stored in the /etc/passwd file, but in the /etc/shadow file. References:
* Linux Essentials Topic 104: The Linux Operating System, section 104.4: Runlevels and Boot Targets.
* Linux Essentials Topic 106: Security and File Permissions, section 106.1: Basic security and identifying user types.
* Linux Essentials Topic 106: Security and File Permissions, section 106.2: Creating users and groups.
* Understanding the /etc/passwd File | Linuxize
* Understanding the /etc/passwd File - GeeksforGeeks
* passwd(5) - Linux manual page - man7.org
* Understanding /etc/passwd file in Linux - DEV Community
NEW QUESTION # 82
A directory contains the following files:
What would be the output of the following shell script?
for file in *.txt
*.txt
- A. b. txt
- B. c.cav
- C. a.txt
- D. a. txt
- E. a b
Answer: A
NEW QUESTION # 83
FILL BLANK
When typing a long command line at the shell, what single character can be used to split a command across multiple lines?
Answer:
Explanation:
\
NEW QUESTION # 84
What is the primary purpose of a firewall in a basic Linux security context?
- A. Manage user authentication
- B. Compress log files
- C. Filter network traffic based on rules
- D. Encrypt data at rest
Answer: C
NEW QUESTION # 85
Which command copies the contents of the directory /etc/, including all sub-directories, to /root/?
- A. cp -R /etc/*.* /root
- B. cp -v /etc/* /root
- C. rcp /etc/* /root
- D. cp -r /etc/* /root
- E. copy /etc /root
Answer: D
Explanation:
The correct command to copy the contents of the directory /etc/, including all sub-directories, to /root/ is cp -r /etc/* /root. This command uses the cp command, which stands for copy, and is used to copy files and directories on Linux and Unix systems. The command also uses the following options and arguments123:
The -r option, which stands for recursive, and tells cp to copy all files and sub-directories of the source directory. Alternatively, the -R option can be used, which has the same effect as -r.
The /etc/* argument, which specifies the source directory and all its contents. The asterisk (*) is a wildcard character that matches any file or directory name. This argument tells cp to copy everything inside the /etc/ directory, but not the directory itself.
The /root argument, which specifies the destination directory. This argument tells cp to copy the source files and sub-directories to the /root/ directory.
The other options are incorrect because they use different commands or syntax that do not copy the contents of the directory /etc/, including all sub-directories, to /root/. For example:
Option A uses the copy command, which is not a valid Linux command. The correct command is cp.
Option C uses the -v option, which stands for verbose, and tells cp to print verbose output. This option does not affect the copying process, but only the output. It also does not include the -r or -R option, which is necessary to copy the sub-directories.
Option D uses the rcp command, which stands for remote copy, and is used to copy files between different hosts on a network. This command is not relevant for copying files on the same host.
Option E uses the -R option, which is correct, but also uses the . argument, which is incorrect. The dot (.) is a special character that matches any single character. This argument tells cp to copy only the files and directories that have a dot in their name, which may exclude some files and directories that do not have a dot.
NEW QUESTION # 86
Given the following directory permissions:
drwxrwxrwt 14 root root 36864 2012-03-02 11:17 /tmp
What does the letter t at the end of drwxrwxrwt indicate?
- A. It means that even though the directory is globally writable only the owner can delete their own files.
- B. It makes the directory accessible for everybody.
- C. It is a temporary bit that prevents launching commands in this directory.
- D. It is the sticky bit that causes all commands in this directory to be launched as root.
- E. It indicates that this directory contains only temporary files that may be deleted.
Answer: A
NEW QUESTION # 87
When typing a long command line at the shell, what can be used to split a command across multiple lines?
Answer:
Explanation:
\
NEW QUESTION # 88
Which of the following programs are web servers? (Choose two.)
- A. Postfix
- B. Dovecot
- C. NGINX
- D. Apache HTTPD
- E. Curl
Answer: C,D
Explanation:
Explanation
NEW QUESTION # 89
Which one of the following statements concerning Linux passwords is true?
- A. All passwords can be decrypted using the system administrator's master password.
- B. Passwords may be at most six characters long.
- C. Passwords are only stored in hashed form.
- D. Passwords may never start with a non-letter.
- E. Users cannot change their password once it has been set.
Answer: C
Explanation:
Explanation
Linux passwords are not stored in plain text, but in a scrambled or encrypted form known as a hash. A hash is a one-way function that transforms a string of characters into a fixed-length value. The same input always produces the same hash, but it is impossible to reverse the process and recover the original input from the hash. This way, the system can verify the user's password without exposing it to anyone who can read the file where the hashes are stored. The file that contains the password hashes is /etc/shadow, which is only readable by the root user or members of the shadow group. The passwd utility is used to change the user's password, which updates the hash in the /etc/shadow file. References: Linux Essentials 1.6 Topic 105: Security and File Permissions, How to Change Account Passwords on Linux, Where is my password stored on Linux?
NEW QUESTION # 90
Which of the following commands extracts the contents of the compressed archive file1.tar.gz?
- A. tar --extract file1.tar.gz
- B. tar -xzf file1.tar.gz
- C. tar -czf file1.tar.gz
- D. detar file1.tar.gz
- E. ztar file1.tar.gz
Answer: B
Explanation:
Explanation
The correct command to extract the contents of the compressed archive file1.tar.gz is tar -xzf file1.tar.gz. This command uses the following options:
* -x means extract files from an archive.
* -z means filter the archive through gzip, which is a compression program that reduces the size of files.
* -f means use the following archive file name, which is file1.tar.gz in this case.
The other commands are incorrect for the following reasons:
* tar -czf file1.tar.gz creates a compressed archive file1.tar.gz from the files specified after the command, not extract it.
* ztar file1.tar.gz is not a valid command, as ztar is not a standard program or option for tar.
* tar --extract file1.tar.gz is missing the -z option to handle the gzip compression, and also the -f option to specify the file name.
* detar file1.tar.gz is not a valid command, as detar is not a standard program or option for tar.
References:
* Linux Essentials - Topic 106: The Linux Operating System, section 106.2 Use single shell commands and one line command sequences to perform basic tasks on the command line.
* LPI Linux Essentials Study Guide: Exam 010 v1.6, 3rd Edition, Chapter 5: Working with Files and Directories, section Compressing and Archiving Files.
NEW QUESTION # 91
Which of the following keys can be pressed to exit less?
- A. l
- B. x
- C. e
- D. q
- E. !
Answer: D
NEW QUESTION # 92
Which command is used to schedule a one-time task to run at a specified future time?
- A. `systemctl`
- B. `cron`
- C. `at`
- D. `nohup`
Answer: C
NEW QUESTION # 93
The current directory contains the following file:
-rwxr-xr-x 1 root root 859688 Feb 7 08:15 test.sh
Given that the file is a valid shell script, how can this script be executed? (Choose two correct answers.)
- A. ./test.sh
- B. ${test.sh}
- C. cmd ./test.sh
- D. bash test.sh
- E. run test.sh
Answer: A,D
Explanation:
Explanation
A shell script is a file that contains a series of commands that can be executed by a shell interpreter. To execute a shell script, there are two main methods:
* Method 1: Specify the path to the script file. This method requires that the script file has the execute permission, which can be granted by using the chmod command. The script file also needs to have a shebang line at the beginning, which indicates which interpreter to use for the script. For example, #!/bin/bash means to use the bash interpreter. To execute the script using this method, you can type the absolute path or the relative path to the script file. If you are in the same directory as the script file, you can use the ./ prefix to indicate the current directory. For example,
./test.sh will execute the test.sh script in the current directory.
* Method 2: Pass the script file as an argument to the interpreter. This method does not require the execute permission or the shebang line for the script file. You can simply use the name of the interpreter followed by the script file name as an argument. For example, bash test.sh will execute the test.sh script using the bash interpreter.
Therefore, the correct answers are D and E. A. run test.sh is incorrect because run is not a valid command in Linux. B. ${test.sh} is incorrect because this syntax is used for variable expansion, not for executing a script. C. cmd ./test.sh is incorrect because cmd is not a valid command in Linux. References:
* Linux Essentials Topic 105: The Power of the Command Line, section 105.3: Basic shell scripting.
* How to Run a Shell Script in Linux [Essentials Explained] - It's FOSS
* How To Execute a Command with a Shell Script in Linux | DigitalOcean
* How To Run the .sh File Shell Script In Linux / UNIX
NEW QUESTION # 94
Which of the following outputs could stem from the command last?
- A. root tty2 Wed May 17 21:11 - 21:11 (00:00)
- B. EXT4-fs (dm-7): mounted filesystem with ordered data mode. Opts: (null)
- C. Last login: Fri Mar 23 10:56:39 2018 from server.example.com
- D. 1 lsB.2 cat text.txt
3 logout
Password for user last changed at Sat Mar 31 16:38:57 EST 2018
Answer: A
NEW QUESTION # 95
What is true about links in a Linux file system?
- A. A symbolic link can point to a file on another file system.
- B. A symbolic link can only point to a file and not to a directory.
- C. When the target of the symbolic link is moved, the link is automatically updated.
- D. A hard link can only point to a directory and never to a file.
- E. Only the root user can create hard links.
Answer: A
Explanation:
Explanation/Reference:
NEW QUESTION # 96
Which of the following can be used to access the command line?
- A. Xargs
- B. Firefox
- C. Terminal
- D. XWindow
- E. BIOS
Answer: C
NEW QUESTION # 97
What is the return value of a shell script after successful execution?
- A. 0
- B. 1
- C. 2
- D. 3
- E. 4
Answer: A
Explanation:
The return value of a shell script after successful execution is 0. This is a convention followed by most UNIX and Linux commands, programs, and utilities. A return value of 0 indicates that the command or script completed successfully, without any errors. A return value of non-zero (1-255) indicates that the command or script failed, and the value can be interpreted as an error code. The return value of a command or script is stored in the special variable $? and can be used to test the outcome of a command or script123. For example, the following script will print a message based on the return value of the ls command:
#!/bin/bash ls if [ $? -eq 0 ]; then echo "ls command executed successfully" else echo "ls command failed" fi
NEW QUESTION # 98
Which of the following commands sorts the output of the commandexport-logs?
- A. export-logs | sort
- B. export-logs & sort
- C. export-logs <> sort
- D. export-logs < sort
- E. export-logs > sort
Answer: A
NEW QUESTION # 99
Which of the following are typical services offered by public cloud providers? (Choose three correct answers.)
- A. Infrastructure as a Service(IaaS)
- B. Software as a Service (SaaS)
- C. Graphics as a Service (GaaS)
- D. Internet as aService(IaaS)
- E. Platform as a Service(PaaS)
Answer: A,B,E
NEW QUESTION # 100
The current directory contains the following file:
-rwxr-xr-x 1 root root 859688 Feb 7 08:15 test.sh
Given that thefile is a valid shell script, how can this script be executed? (Choose two correct answers.)
- A. ./test.sh
- B. ${test.sh}
- C. cmd ./test.sh
- D. bash test.sh
- E. run test.sh
Answer: A,D
NEW QUESTION # 101
Which command displays currently running processes in real time with resource usage?
- A. `top`
- B. `jobs`
- C. `ps aux`
- D. `ls -l /proc`
Answer: A
NEW QUESTION # 102
......
010-160 Dumps are Available for Instant Access: https://actualanswers.pass4surequiz.com/010-160-exam-quiz.html