- Home
- LPI
- LPI Linux Essentials
- 010-160
- 010-160 - Linux Essentials Certificate Exam - version 1.6
LPI 010-160 Linux Essentials Certificate Exam - version 1.6 Exam Practice Test
Linux Essentials Certificate Exam - version 1.6 Questions and Answers
Which of the following commands extracts the contents of the compressed archive file1.tar.gz?
Options:
tar -czf file1.tar.gz
ztar file1.tar.gz
tar -xzf file1.tar.gz
tar --extract file1.tar.gz
detar file1.tar.gz
Answer:
CExplanation:
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.
Which of the following commands adds the directory/new/dir/to thePATHenvironment variable?
Options:
$PATH=/new/dir: $PATH
PATH=/new/dir: PATH
export PATH=/new/dir: PATH
export $PATH=/new/dir: $PATH
export PATH=/new/dir: $PATH
Answer:
CExplanation:
The PATH environment variable is a colon-separated list of directories that the shell searches for commands. To add a new directory to the PATH, you need to append it to the existing value of the variable, using the syntax PATH=new/dir:PATH. However, this only changes the PATH for the current shell session. To make the change permanent, you need to use the export command, which makes the variable available to all child processes of the shell. The export command takes the name of the variable as an argument, without the dollar sign ($). Therefore, the correct command to add /new/dir/ to the PATH and export it is export PATH=/new/dir:PATH. References:
- Linux Essentials - Linux Professional Institute (LPI)
- How to set the path and environment variables in Windows - Computer Hope
What is the UID of the user root?
Options:
1
-1
255
65536
0
Answer:
EExplanation:
The UID of the user root is always 0 on Linux systems. This is because the kernel uses the UID 0 to check for the superuser privileges and grant access to all system resources. The name of the user account with UID 0 is usually root, but it can be changed or have aliases. However, some applications may expect the name root and not work properly with a different name. The UID 0 is reserved for the root user and cannot be assigned to any other user. The UID 0 is stored in the /etc/passwd file along with other user information. 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.
Which operator in a regular expression matches the preceding character either zero or one time?
Options:
?
*
+
%
$
Answer:
AExplanation:
The operator that matches the preceding character either zero or one time in a regular expression is the question mark (?). This operator is also known as the optional quantifier, because it makes the preceding character or group of characters optional. For example, the regular expression colou?r matches both color and colour, because the u is optional. The question mark can also be used to modify other quantifiers, such as * (zero or more), + (one or more), or {m,n} (between m and n times), to make them non-greedy, meaning they will match the shortest possible string instead of the longest. For example, the regular expression .*? matches any character zero or more times, but as few as possible. The question mark is one of the basic regular expression operators covered in the Linux Essentials certification program from the Linux Professional Institute (LPI). References:
- Linux Essentials - Linux Professional Institute (LPI)
- Regular Expressions:Difference between ‘optional occurrence’ and 'zero …
What is true about the su command?
Options:
It is the default shell of the root account.
It can only be used by the user root.
It runs a shell or command as another user.
It changes the name of the main administrator account.
It locks the root account in specific time frames.
Answer:
CExplanation:
The su command stands for substitute user or switch user. It allows you to run a shell or a command as another user, usually the superuser or root. To use the su command, you need to know the password of the target user. For example, if you want to switch to the root user, you can type su - and enter the root password. This will give you a root shell, where you can execute commands with administrative privileges. To exit the root shell, you can type exit or press Ctrl-D. The su command is not the default shell of the root account, nor can it only be used by the root user. It can be used by any user who knows the password of another user. The su command does not change the name of the main administrator account, which is always root on Linux systems. The su command also does not lock the root account in specific time frames, although there are other ways to do that, such as using the pam_time module. References:
- Linux Essentials - Linux Professional Institute (LPI), section 5.1.1
- LPI Linux Essentials Study Guide: Exam 010 v1.6, 3rd Edition, chapter 9, page 219.
Which of the following outputs could stem from the commandlast?
Options:
1 ls
2 cat text.txt
3 logout
Password for user last changed at Sat Mar 31 16:38:57 EST 2018
Last login: Fri Mar 23 10:56:39 2018 from server.example.com
EXT4-fs (dm-7): mounted filesystem with ordered data mode. Opts: (null)
root tty2 Wed May 17 21:11 - 21:11 (00:00)
Answer:
EExplanation:
The last command in Linux is used to display the list of all the users logged in and out since the file /var/log/wtmp was created1. The output of the last command shows the username, the terminal, the IP address, the login time and date, and the duration of the session for each record2. The option E is the only one that matches this format. Theother options are not related to the last command. Option A shows a list of commands executed by a user. Option B shows the password change information for a user. Option C shows the last login information for a user. Option D shows the mount information for a filesystem. References:
- Linux Essentials Version 1.6 Objectives3, Topic 1.4: Command Line Basics, Subtopic: Basic Shell Commands
- Linux last Command Tutorial for Beginners (8 Examples)4
- Linux Essentials Version 1.6 Exam Preparation Guide, Section 1.4: Command Line Basics, Page 16
Which of the following devices represents a hard disk partition?
Options:
/dev/ttyS0
/dev/sata0
/dev/part0
/dev/sda2
/dev/sda/p2
Answer:
DExplanation:
Section: (none)
The correct device name that represents a hard disk partition is /dev/sda2. This device name follows the Linux convention for naming hard disk devices and partitions. According to this convention123:
- The first part of the device name indicates the type of the device. For example, /dev/hd* for IDE drives, /dev/sd* for SCSI, SATA, USB, or eSATA drives, /dev/nvme* for NVMe drives, etc.
- The second part of the device name indicates the order of the device as detected by the system. For example, /dev/sda is the first serial drive, /dev/sdb is the second serial drive, and so on.
- The third part of the device name indicates the number of the partition on the device. For example, /dev/sda1 is the first partition on the first serial drive, /dev/sda2 is the second partition on the first serial drive, and so on.
Therefore, /dev/sda2 means the second partition on the first serial drive, which is a valid hard disk partition. The other options are not valid hard disk partitions, because they do not follow the Linux convention. For example:
- /dev/ttyS0 is a serial port device, not a hard disk device4.
- /dev/sata0 is not a valid device name, because it does not specify the partition number. It should be something like /dev/sata0p1 or /dev/sata0p2, etc.
- /dev/part0 is not a valid device name, because it does not specify the device type or the partition number. It should be something like /dev/sdXp0 or /dev/hdXp0, etc.
- /dev/sda/p2 is not a valid device name, because it uses a slash (/) instead of a number to indicate the partition. It should be something like /dev/sda2 or /dev/sda3, etc.
References: 1: Hard drive/device partition naming convention in Linux - Unix & Linux Stack Exchange 2: Hard drive partition naming convention in Linux - Ask Ubuntu 3: C.4. Device Names in Linux - Debian 4: What is /dev/ttyS0? - Quora
Explanation
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.)
Options:
run test.sh
${test.sh}
cmd ./test.sh
./test.sh
bash test.sh
Answer:
D, EExplanation:
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
Which of the following statements regarding Linux hardware drivers is correct?
Options:
Drivers are regular Linux programs which have to be run by the user who wants to use a device.
Drivers are not used by Linux because the BIOS handles all access to hardware on behalf of Linux.
Drivers are stored on their devices and are copied by the Linux kernel when a new device is attached
Drivers are downloaded from the vendor's driver repository when a new device is attached.
Drivers are either compiled into the Linux kernel or are loaded as kernel modules.
Answer:
EExplanation:
Linux hardware drivers are software components that enable the Linux kernel to communicate with various devices, such as keyboards, mice, printers, scanners, network cards, etc. Drivers are either compiled into the Linux kernel or are loaded as kernel modules. Kernel modules are pieces of code that can be loaded and unloaded into the kernelon demand. They extend the functionality of the kernel without requiring to rebuild or reboot the system. Drivers that are compiled into the kernel are always available, but they increase the size and complexity of the kernel. Drivers that are loaded as kernel modules are only available when needed, but they require a matching version of the kernel and the module. Linux supports a large number of hardware devices, thanks to the efforts of the open source community and some vendors who provide drivers for their products. However, some devices may not have a driver available for Linux, or may require a proprietary driver that is not included in the Linux distribution. In such cases, the user may need to install the driver manually from the vendor’s website or from a third-party repository. References:
- Linux Essentials - Linux Professional Institute (LPI), section 2.2.1
- LPI Linux Essentials Study Guide: Exam 010 v1.6, 3rd Edition, chapter 3, page 67.
Which of the following values could be a process ID on Linux?
Options:
/bin/bash
60b503cd-019e-4300-a7be-922f074ef5ce
/sys/pid/9a14
fff3
21398
Answer:
EExplanation:
A process ID on Linux is a unique integer value that identifies a running process. The process ID can range from 0 to a maximum limit, which is usually 32768 or higher, depending on the system configuration. The process ID of 0 is reserved for the kernel’s idle task, and the process ID of 1 is reserved for the init system, which is the first process launched by the kernel. The process IDs are assigned sequentially to new processes, and are recycled when a process terminates. Therefore, the only valid value for a process ID among the given options is 21398, which is an integer within the possible range. The other values are not valid process IDs because they are either strings, hexadecimal numbers, or file paths, which do not match the format of a process ID on Linux. References:
- Linux Essentials - Linux Professional Institute (LPI)
- How Are Linux PIDs Generated? | Baeldung on Linux
Which package management tool is used in Red Hat-based Linux Systems?
Options:
portage
rpm
apt-get
dpkg
packagectl
Answer:
BExplanation:
RPM stands for RPM Package Manager (formerly known as Red Hat Package Manager), which is a powerful, command-line package management tool developed for the Red Hat operating system. It is now used as a core component in many Linux distributions such as CentOS, Fedora, Oracle Linux, openSUSE and Mageia1. RPM can install, uninstall,and query individual software packages, but it cannot manage dependency resolution like YUM2. YUM is another package management tool that is based on RPM and can handle dependencies automatically. YUM is the primary package management tool for installing, updating, removing, and managing software packages in Red Hat Enterprise Linux2. Therefore, the correct answer is B. rpm, as it is the underlying package management tool used in Red Hat-based Linux systems. References:
- Linux package management with YUM and RPM | Enable Sysadmin
- Chapter 13. Package Management Tool Red Hat Enterprise Linux 5 | Red Hat Customer Portal
- Difference Between YUM and RPM | 2DayGeek
What happens to a file residing outside the home directory when the file owner's account is deleted? (Choose two.)
Options:
During a file system check, the file is moved to /lost +found.
The file is removed from the file system.
The UID of the former owner is shown when listing the file's details.
The user root is set as the new owner of the file.
Ownership and permissions of the file remain unchanged.
Answer:
C, EExplanation:
When a user account is deleted, the files owned by that user are not automatically deleted from the file system, unless they are in the user’s home directory. The files residing outside the home directory will remain unchanged, but they will have an invalid owner. The owner of a file is identified by a numeric user ID (UID), which is mapped to a user name by the /etc/passwd file. When a user is deleted, the corresponding entry in the /etc/passwd file is removed, but the UID of the file is not changed. Therefore, when listing the file’s details, the UID of the former owner is shown instead of the user name. For example, if the user alice with UID 1001 is deleted, and she owns a file named report.txt in the /tmp directory, the output of ls -l /tmp/report.txt will look something like this:
-rw-r–r-- 1 1001 users 1024 Nov 20 14:11 /tmp/report.txt
The user root is not set as the new owner of the file, nor is the file moved to /lost+found or removed from the file system. The /lost+found directory is used to store files that are recovered from a corrupted file system after running the fsck command, not from deleted user accounts. The file system check does not affect the ownership or permissions of the files, unless there is a serious inconsistency that needs to be fixed. References:
- Linux Essentials - Linux Professional Institute (LPI), section 5.2.1
- 5.2 Lesson 1 - Linux Professional Institute Certification Programs, slide 6.
Which of the following programs is a graphical editor for vector graphics?
Options:
Python
NGINX
Samba
Inkscape
MySQL
Answer:
DExplanation:
A vector graphics editor is a software program that allows users to create and edit vector graphics, which are images composed of mathematical curves and shapes. Vector graphics are scalable, meaning they can be resized without losing quality or clarity. Python, NGINX, Samba, and MySQL are not vector graphics editors, but rather other types of software. Python is a programming language, NGINX is a web server, Samba is a file and print server, and MySQL is a database management system. Inkscape is a free and open source vector graphics editor that supports the SVG (Scalable Vector Graphics) format, as well as other formats. Inkscape can be used to create logos, icons, diagrams, illustrations, and other graphics. Inkscape is one of the applications covered in the Linux Essentials certification program from the Linux Professional Institute (LPI). References:
- Linux Essentials - Linux Professional Institute (LPI)
- Draw Freely | Inkscape
What are the differences between hard disk drives and solid state disks? (Choose two correct answers.)
Options:
Hard disks have a motor and moving parts, solid state disks do not.
Hard disks can fail due to physical damage, while solid state disks cannot fail.
Solid state disks can store many times as much data as hard disk drives.
/dev/sdais a hard disk device while/dev/ssdais a solid state disk.
Solid state disks provide faster access to stored data than hard disks.
Answer:
A, EExplanation:
The main difference between hard disk drives (HDDs) and solid state drives (SSDs) is the way they store and access data. HDDs use a spinning disk (platter) and a moving head to read and write data, while SSDs use flash memory chips that have no moving parts. This makes SSDs faster, quieter, and more durable than HDDs, but also more expensive and less spacious. HDDs and SSDs are both I/O devices that can be used to boot the system and store data, but they have different advantages and disadvantages depending on the use case. References:
- Difference between Hard Disk Drive (HDD) and Solid State Drive (SSD)
- Hard Disk Drive (HDD) vs. Solid State Drive (SSD): What’s the Difference?
- How to Check Whether Your Disk Is an SSD or HDD on Linux
Which of the following programs are web servers? (Choose two.)
Options:
Apache HTTPD
Postfix
Curl
Dovecot
NGINX
Answer:
A, EExplanation:
A web server is a program that listens for requests from web browsers and serves web pages, images, or other resources. Apache HTTPD and NGINX are two popular web servers that can run on Linux systems. They can handle multiple protocols, such as HTTP, HTTPS, FTP, and SMTP. Postfix, Curl, and Dovecot are not web servers, but they are related to web or network services. Postfix is a mail transfer agent (MTA) that can send and receive emails. Curl is a command-line tool that can transfer data from or to a web server. Dovecot is a mail delivery agent (MDA) that can store and retrieve emails from a local mailbox. References:
- Linux Essentials - Linux Professional Institute (LPI), section 1.2 Major Open Source Applications
- LPI Linux Essentials 010-160 - Testprep Training Tutorials, section 4.4 Your Computer on the Network
Which statements about the directory /etc/skel are correct? (Choose two.)
Options:
The personal user settings of root are stored in this directory.
The files from the directory are copied to the home directory of the new user when starting the system.
The files from the directory are copied to the home directory of a new user when the account is created.
The directory contains a default set of configuration files used by the useradd command.
The directory contains the global settings for the Linux system.
Answer:
C, DExplanation:
The /etc/skel directory is a skeleton directory that contains the default files and directories that are automatically copied to the home directory of a new user when the account is created by the useradd command12. The purpose of this directory is to provide a consistent and uniform environment for all new users and to save the system administrator’s time and effort in configuring the user settings12. The /etc/skel directory can be customized by adding or removing files and directories as needed, depending on the desired default settings for the new users12.
The other options are incorrect because:
- A. The personal user settings of root are stored in this directory. This is not true, as the personal user settings of root are stored in the /root directory, which is the home directory of the root user3. The /etc/skel directory does not affect the root user’s settings, but only the settings of the new users created by the useradd command12.
- B. The files from the directory are copied to the home directory of the new user when starting the system. This is not true, as the files from the directory are copied to the home directory of the new user when the account is created, not when starting the system12. The copying process only happens once, when the useradd command is executed, and not every time the system is started12.
- E. The directory contains the global settings for the Linux system. This is not true, as the directory contains the default settings for the new users, not the global settings for theLinux system12. The global settings for the Linux system are usually stored in other directories under /etc, such as /etc/default, /etc/sysconfig, /etc/init.d, etc4.
References:
- Understanding the /etc/skel directory in Linux – The Geek Diary
- /etc/skel directory in Linux - techPiezo
- Linux File System Hierarchy - /root directory - LinuxConfig.org
- Linux configuration: Understanding *.d directories in /etc | Enable Sysadmin
Which of the following statements is true about Free Software?
Options:
It is developed by volunteers only.
It may be modified by anyone using it.
It must always be available free of charge.
It only runs on Linux.
It is only distributed as a compiled binary.
Answer:
BExplanation:
The correct statement about Free Software is that it may be modified by anyone using it. This is one of the four essential freedoms of Free Software, which are: the freedom to run the program as you wish, for any purpose; the freedom to study how the program works, and change it so it does your computing as you wish; the freedom to redistribute copies so you can help your neighbor; and the freedom to distribute copies of your modified versions to others1. Access to the source code is a precondition for these freedoms1.
The other statements are false for the following reasons:
- Free Software is not developed by volunteers only. It can be developed by anyone, including individuals, companies, organizations, or communities. Some Free Software developers are paid for their work, while others do it as a hobby or for social benefit1.
- Free Software does not have to be available free of charge. It can be sold or given away for any price. The term “free” refers to the users’ freedom, not the price of the software1. However, Free Software users have the freedom to redistribute copies, so they can obtain the software at no charge from someone who has a copy1.
- Free Software does not only run on Linux. It can run on any operating system that supports it, such as Windows, MacOS, BSD, or Android. Linux is an example of a Free Software operating system, but not the only one1.
- Free Software is not only distributed as a compiled binary. It can also be distributed as source code, or both. In fact, Free Software must provide access to the source code, otherwise the users cannot study or modify the software1.
References:
- What is Free Software? - GNU Project - Free Software Foundation
Which command adds the new usertuxand creates the user’s home directory with default configuration
files?
Options:
defaultuser tux
useradd –m tux
usercreate tux
useradd –o default tux
passwd –a tux
Answer:
BExplanation:
The useradd command in Linux is used to create new user accounts on the system1. The -m option tells the command to create the user’s home directory as /home/username and copy the files from /etc/skel directory to the user’s home directory2. The /etc/skel directory contains the default configuration files for new users3. Therefore, the command useradd -m tux will add the new user tux and create the user’s home directory with default configuration files. The other options are either invalid or do not create the user’s home directory. References:
- Linux Essentials Version 1.6 Objectives, Topic 1.4: Command Line Basics, Subtopic: Basic Shell Commands
- Linux Essentials Version 1.6 Exam Preparation Guide, Section 1.4: Command Line Basics, Page 16
- Linux useradd Command Tutorial for Beginners (15 Examples)
What is true about links in a Linux file system?
Options:
A symbolic link can only point to a file and not to a directory.
A hard link can only point to a directory and never to a file.
When the target of the symbolic link is moved, the link is automatically updated.
A symbolic link can point to a file on another file system.
Only the root user can create hard links.
Answer:
DExplanation:
A symbolic link, also known as a symlink or soft link, is a special type of file that points to another file or directory by its name. A symbolic link can point to a file or directory on the same or different file system, as long as the target is accessible. For example, you can create a symbolic link to a file on a USB drive or a network share, as long as the device is mounted or the connection is established. However, if the target of the symbolic link is moved, renamed, or deleted, the link becomes broken and does not work. To create a symbolic link, you can use the ln command with the -s or --symbolic option, followed by the target name and the link name. For example, ln -s /mnt/usb/file.txt link.txt creates a symbolic link named link.txt that points to the file.txt on the USB drive mounted at /mnt/usb.
The other options are not true about links in a Linux file system. A symbolic link can point to a directory as well as a file. A hard link, which is a direct reference to the same data as another file, can only point to a file and not a directory. A hard link cannot span across different file systems, because it depends on the inode number, which is unique within a file system. When the target of the symbolic link is moved, the link is not automatically updated, but becomes broken. Any user can create hard links, as long as they have the permission to read and write the target file and the link directory.
References:
- Linux Essentials - Linux Professional Institute (LPI)
- Ln Command in Linux (Create Symbolic Links) | Linuxize
What information is stored in/etc/passwd? (Choose three correct answers.)
Options:
The user’s storage space limit
The numerical user ID
The username
The encrypted password
The user\s default shell
Answer:
B, C, EExplanation:
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
What is the preferred source for the installation of new applications in a Linux based operating system?
Options:
The vendor's version management system
A CD-ROM disk
The distribution's package repository
The vendor's website
A retail store
Answer:
CExplanation:
The distribution’s package repository is the preferred source for the installation of new applications in a Linux based operating system. A package repository is a collection of software packages that are maintained by the distribution and can be easily installed, updated, or removed using a package manager. Package repositories offer several advantages, such as:
- They ensure compatibility and stability with the system and other packages.
- They provide security updates and bug fixes for the packages.
- They reduce the risk of malware or corrupted files.
- They simplify the dependency management and configuration of the packages.
The other sources are not preferred because they may not offer these benefits and may cause problems with the system. The vendor’s version management system, the vendor’s website, or a CD-ROM disk may contain packages that are not compatible with the distribution or may conflict with other packages. A retail store may not have the latest or the most suitable packages for the system. References:
- Linux Essentials - Linux Professional Institute (LPI), section 1.3 Installing, Updating and Removing Software Packages
- LPI Linux Essentials Study Guide: Exam 010 v1.6, 3rd Edition, chapter 4 Working on the Command Line, section 4.2 Managing Software
- Table of Contents - Linux Professional Institute Certification Programs, section 1.3 Installing, Updating and Removing Software Packages
Which of the following characters in a shell prompt indicates the shell is running with root privileges?
Options:
!
#
*
&
$
Answer:
BExplanation:
The shell prompt is a symbol or a string of characters that indicates the shell is ready to accept commands. The shell prompt can be customized by the user or by the system administrator. The default shell prompt for a normal user is usually a dollar sign ($), while the default shell prompt for the root user is usually a hash sign (#). The root user is the superuser or the administrator of the system, who has full access and control over all files, commands, and resources. Running commands as root can be dangerous, as it can cause irreversible damage to the system if done incorrectly. Therefore, it is advisable to use sudo or su to run commands as root only when necessary, and to switch back to a normal user as soon as possible. The shell prompt indicates the shell is running with root privileges when it ends with a hash sign (#). References:
- Linux Essentials - Linux Professional Institute (LPI)
- Running a shell command as root - Unix & Linux Stack Exchange
Why are web browser cookies considered dangerous?
Options:
Cookies support identification and tracking of users.
Cookies are always public and accessible to anyone on the internet.
Cookies consume significant amounts of storage and can exhaust disk space.
Cookies store critical data which is lost when a cookie is deleted.
Cookies can contain and execute viruses and malware.
Answer:
AExplanation:
Web browser cookies are small pieces of data that are stored by a website on a user’s browser. They are used to remember information about the user, such as preferences, login details, shopping cart items, etc. Cookies can also be used to identify and track users across different websites, which can have implications for privacy and security. For example, cookies can be used to show targeted ads based on the user’s browsing history, or to collect personal information without the user’s consent. Cookies are not inherently dangerous, but they can pose some risks if they are misused or compromised by malicious actors. References:
- Linux Essentials - Linux Professional Institute (LPI), section 1.4.2
- 1.4 Lesson 1 - Linux Professional Institute Certification Programs, slide 18
Which of the following commands finds all lines in the file operating-systems.txt which contain the term
linux, regardless of the case?
Options:
igrep linux operating-systems.txt
less -i linux operating-systems.txt
grep -i linux operating-systems.txt
cut linux operating-systems.txt
cut [Ll] [Ii] [Nn] [Uu] [Xx] operating-systems.txt
Answer:
CExplanation:
The grep command is used to search for a pattern in a file or input. The -i option makes the search case-insensitive, meaning that it will match both uppercase and lowercase letters. The grep command takes the pattern as the first argument and the file name as the second argument. Therefore, the command grep -i linux operating-systems.txt will find all lines in the file operating-systems.txt which contain the term linux, regardless of the case. References: Linux Essentials - Topic 103: Finding Linux Documentation and Linux Essentials - Topic 104: Command Line Basics
Unlock 010-160 Features
- 010-160 All Real Exam Questions
- 010-160 Exam easy to use and print PDF format
- Download Free 010-160 Demo (Try before Buy)
- Free Frequent Updates
- 100% Passing Guarantee by Activedumpsnet
Questions & Answers PDF Demo
- 010-160 All Real Exam Questions
- 010-160 Exam easy to use and print PDF format
- Download Free 010-160 Demo (Try before Buy)
- Free Frequent Updates
- 100% Passing Guarantee by Activedumpsnet