Lpi 101-500 LPI Linux Administrator – 101 (LPIC-1 101) Online Training
Lpi 101-500 Online Training
The questions for 101-500 were last updated at Jul 17,2025.
- Exam Code: 101-500
- Exam Name: LPI Linux Administrator - 101 (LPIC-1 101)
- Certification Provider: Lpi
- Latest update: Jul 17,2025
Which of the following commands will send output from the program myapp to both standard output (stdout) and the file file1.log?
- A . cat < myapp | cat > file1.log
- B . myapp 0>&1 | cat > file1.log
- C . myapp | cat > file1.log
- D . myapp | tee file1.log
- E . tee myapp file1.log
Which of the following shell redirections will write standard output and standard error output to a file named filename?
- A . 2>&1 >filename
- B . >filename 2>&1
- C . 1>&2>filename
- D . >>filename
- E . 1&2>filename
Which of the following sequences in the vi editor saves the opened document and exits the editor? (Choose TWO Answer s.)
- A . Ctrl XX
- B . Ctrl :W
- C . Esc zz
- D . Esc :wq
- E . Esc ZZ
Which of the following commands can be used to determine how long the system has been running? (Choose TWO Answer s.)
- A . uptime
- B . up
- C . top
- D . uname -u
- E . time Cup
Which of the following commands will reduce all consecutive spaces down to a single space?
- A . tr ‘s’ ‘ ‘ < a.txt > b.txt
- B . tr -c ‘ ‘ < a.txt > b.txt
- C . tr -d ‘ ‘ < a.txt > b.txt
- D . tr -r ‘ ‘ ‘
‘ < a.txt > b.txt - E . tr -s ‘ ‘< a.txt > b.txt
From a Bash shell, which of the following commands directly executes the instruction from the file /usr/local/bin/runme.sh without starting a subshell? (Please select TWO answers.)
- A . source /usr/local/bin/runme.sh
- B . . /usr/local/bin/runme.sh
- C . /bin/bash /usr/local/bin/runme.sh
- D . /usr/local/bin/runme.sh
- E . run /usr/local/bin/runme.sh
Which of the following commands prints a list of usernames (first column) and their primary group (fourth column) from the /etc/passwd file?
- A . fmt -f 1,4 /etc/passwd
- B . split -c 1,4 /etc/passwd
- C . cut -d : -f 1,4 /etc/passwd
- D . paste -f 1,4 /etc/passwd
When running the command
sed -e "s/a/b/" /tmp/file >/tmp/file
While /tmp/file contains data, why is /tmp/file empty afterwards?
- A . The file order is incorrect. The destination file must be mentioned before the command to ensure redirection.
- B . The command sed did not match anything in that file therefore the output is empty.
- C . When the shell establishes the redirection it overwrites the target file before the redirected command starts and opens itfor reading.
- D . Redirection for shell commands do not work using the > character. It only works using the | character instead.
Which of the following explanations are valid reasons to run a command in the background of your shell?
- A . The command does not need to execute immediately.
- B . The command has to run immediately but the user needs to log out.
- C . The system is being shut down and the command needs to restart execution immediately after the reboot.
- D . The command can run at a lower priority than normal commands run on the command line.
Which grep command will print only the lines that do not end with a / in the file foo?
- A . grep’/$’ foo
- B . grep ‘/#’ foo
- C . grep -v ‘/$’ foo
- D . grep -v ‘/#’ foo
Error in this question:Which of the following apt-get commands will install the newest versions of all currently installed packages without removing any packages or installing new packages that are not already installed?
The correct answer is B. upgrade, not C. dist-upgrade.
Error
in this question :
What is the first program that is usually started, at boot time, by the Linux kernel when using SysV init?
Hide Solution
Correct Answer: C
Are you sure this is the correct annswer?
i think it is B
When a Linux system using SysV init boots up, the kernel loads and then executes the program located at /sbin/init, so the correct answer is B. /sbin/init