Tuesday 28 June 2022

LPI Level 1 102-500 Dumps Questions

LPI Level 1, 102-500 Dumps Questions, LPI Certification, LPI Career, LPI Skills, LPI Jobs, LPI Preparation, LPI Guides, LPI Tutorial and Materials

Recently we updated 102-500 dumps questions for your LPIC-1: Linux Administrator certification. We know that getting LPIC-1: Linux Administrator certification requires you answer both 101-500 and 102-500 exams. Today, we updated 102-500 dumps questions also to ensure that you can complete the LPIC-1 certification.

1. Which command makes the shell variable named VARIABLE visible to subshells?

  • export $VARIABLE
  • export VARIABLE
  • set $VARIABLE
  • set VARIABLEwrong
  • env VARIABLE

2. Which of the following files, when existing, affect the behavior of the Bash shell? (Choose TWO correct answers.)

  • ~/.bashconf
  • ~/.bashrc
  • ~/.bashdefaultswrong
  • ~/.bash_etc
  • ~/.bash_profile

3. Which command allows you to make a shell variable visible to subshells?

  • export $VARIABLE
  • export VARIABLE
  • set $VARIABLE
  • set VARIABLEwrong
  • env VARIABLE

4. What is the purpose of the file /etc/profile?

  • It contains the welcome message that is displayed after login.
  • It contains security profiles defining which users are allowed to log in.
  • It contains environment variables that are set when a user logs in.
  • It contains default application profiles for users that run an application for the first time.

5. Which of the following are requirements in order to run a shell script like a regular command from anywhere in the filesystem? (Choose THREE correct answers.)

  • The user issuing the command must be in the group script.
  • The script file must be found in the $PAT
  • The script file must have the executable permission bit set.
  • The script must begin with a shebang-line (#!) that points to the correct interpreter.wrong
  • The file system on which the script resides must be mounted with the option scripts.

6. Which of the following words is used to restrict the records that are returned from a SELECT query based on a supplied criteria for the values in the records?

  • LIMIT
  • FROM
  • WHERE
  • IF

7. Which of the following configuration files should be modified to set default shell variables for all users?

  • /etc/bashrc
  • /etc/profile
  • ~/.bash_profile
  • /etc/.bashrc

8. Which of the following commands lists all defined variables and functions within Bash?

  • env
  • set
  • env -a
  • echo $ENV

9. When the command echo $$ outputs 12942, what is the meaning of 12942?

  • It is the process ID of the echo command.
  • It is the process ID of the current shell.
  • It is the process ID of the last command executed.
  • It is the process ID of the last command which has been placed in the background.

10. How can the existing environment variable FOOBAR be suppressed for the execution of the script./myscript only?

  • unset -v FOOBAR;./myscript
  • set -a FOOBAR="";./myscript
  • env -u FOOBA
  • /myscript
  • env -i FOOBA
  • /myscript

11. Which of the following words is used to restrict the records that are returned from a SELECT SQL query based on a supplied criteria for the values in the records?

  • CASE
  • FROM
  • WHERE
  • IF

12. Which of the following commands puts the output of the command date into the shell variable mydate?

  • mydate="$(date)"
  • mydate="exec date"
  • mydate="$((date))"
  • mydate="date"
  • mydate="${date}"

13. You are looking into a new script you received from your senior administrator. In the very first line you notice a #! followed by a file path.

This indicates that:

  • The file at that location was used to make the script.
  • This script provides identical functionality as the file at that location.
  • This script will self-extract into a file at that location.
  • The program at that location will be used to process the script.

14. What keyword is missing from this code sample of a shell script?

____ i in *.txt; do

echo $i

done

  • for
  • loop
  • until
  • while

15. Which of the following SQL statements will select the fields name and address from the contacts table?

  • SELECT (name, address) FROM contacts;
  • SELECT (name address) FROM contacts;
  • SELECT name, address FROM contacts;
  • SELECT name address FROM contacts;

16. What output will the following command sequence produce?

echo '1 2 3 4 5 6' | while read a b c; do

echo result: $c $b $a;

done

  • result: 3 4 5 6 2 1
  • result: 1 2 3 4 5 6
  • result: 6 5 4
  • result: 6 5 4 3 2 1
  • result: 3 2 1

17. Which of the following SQL queries counts the number of occurrences for each value of the field order_type in the table orders?

  • SELECT order_type,COUNT(*) FROM orders WHERE order_type=order_type;
  • SELECT order_type,COUNT(*) FROM orders GROUP BY order_type;
  • COUNT(SELECT order_type FROM orders);
  • SELECT COUNT(*) FROM orders ORDER BY order_type;
  • SELECT AUTO_COUNT FROM orders COUNT order_type;

18. What benefit does an alias in bash provide?

  • It provides faster lookups for commands in the system directory.
  • It creates a local copy of a file from another directory.
  • It hides what command you are running from others.
  • It allows a string to be substituted for the first word of a simple command.

19. When the command echo $ outputs 1, which of the following statements is true?

  • It is the process ID of the echo command.
  • It is the process ID of the current shell.
  • It is the exit value of the command executed immediately before echo.
  • It is the exit value of the echo command.

20. What output will the following command produce?

seq 1 5 20

  • 1 6 11 16
  • 1 5 10 15
  • 1 2 3 4
  • 2 3 4 5
  • 5 10 15 20

21. What output will the command seq 10 produce?

  • A continuous stream of numbers increasing in increments of 10 until stopped.
  • The numbers 1 through 10 with one number per line.
  • The numbers 0 through 9 with one number per line.
  • The number 10 to standard output.

22. What is the difference between the commands test -e path and test -f path?

  • They are equivalent options with the same behaviour.
  • The -f option tests for a regular file. The -e option tests for an empty file.
  • Both options check the existence of the path. The -f option also confirms that it is a regular file.
  • The -f option tests for a regular file. The -e option tests for an executable file.

23. After issuing:

function myfunction { echo $1 $2 ; }

in Bash, which output does:

myfunction A B C

Produce?

  • A B
  • A B C
  • A C
  • B C
  • C B A

24. Which of the following is the best way to list all defined shell variables?

  • env
  • set
  • env -a
  • echo $ENV

25. How is a display manager started?

  • It is started by a user using the command startx.
  • It is started like any other system service by the init system.
  • It is started by inetd when a remote hosts connects to the X11 port.
  • It is started automatically when a X11 user logs in to the system console.
Source: dumpsbase.com

Related Posts

0 comments:

Post a Comment