問題1
Which of the following keywords can be used in the file /etc/nsswitch.conf to specify a source for host name lookups? (Choose TWO correct answers.)
Which of the following keywords can be used in the file /etc/nsswitch.conf to specify a source for host name lookups? (Choose TWO correct answers.)
正確答案: B,C
說明:(僅 NewDumps 成員可見)
問題2
Which environment variable should be set in order to change the time zone for the commands run from within the environment variable's scope? (Specify the variable name only.)
Which environment variable should be set in order to change the time zone for the commands run from within the environment variable's scope? (Specify the variable name only.)
正確答案:
TZ
Explanation:
The TZ environment variable is used to change the time zone for the commands run from within the environment variable's scope. It specifies the name of a time zone as defined in the /usr/share/zoneinfo directory or a custom time zone in the POSIX format12. The TZ variable can be set either globally in a shell profile file or locally in a shell session. For example, to set the time zone to America/New_York for the current shell session, one can use the following command:
export TZ=America/New_York
To verify the change, one can use the date command to display the current date and time according to the TZ variable. The TZ variable can also be used to run a single command with a different time zone without affecting the system's time zone. For example, to run the date command with the Asia/Tokyo time zone, one can use the following syntax:
TZ=Asia/Tokyo date
The TZ variable is useful for testing how applications behave in different time zones or for displaying the time in different locations34. Reference:
How to Set or Change the Time Zone in Linux | Linuxize
Linux / UNIX: TZ Environment Variable - nixCraft
Get Current System Time Zone in Linux | Baeldung on Linux
Setting the TZ Environment Variable on Linux | InterSystems Developer
Explanation:
The TZ environment variable is used to change the time zone for the commands run from within the environment variable's scope. It specifies the name of a time zone as defined in the /usr/share/zoneinfo directory or a custom time zone in the POSIX format12. The TZ variable can be set either globally in a shell profile file or locally in a shell session. For example, to set the time zone to America/New_York for the current shell session, one can use the following command:
export TZ=America/New_York
To verify the change, one can use the date command to display the current date and time according to the TZ variable. The TZ variable can also be used to run a single command with a different time zone without affecting the system's time zone. For example, to run the date command with the Asia/Tokyo time zone, one can use the following syntax:
TZ=Asia/Tokyo date
The TZ variable is useful for testing how applications behave in different time zones or for displaying the time in different locations34. Reference:
How to Set or Change the Time Zone in Linux | Linuxize
Linux / UNIX: TZ Environment Variable - nixCraft
Get Current System Time Zone in Linux | Baeldung on Linux
Setting the TZ Environment Variable on Linux | InterSystems Developer
問題3
On a machine running serval X servers. how do programs identify the different instances of theX11 server?
On a machine running serval X servers. how do programs identify the different instances of theX11 server?
正確答案: D
說明:(僅 NewDumps 成員可見)
問題4
Which directory in /etc is used to keep a sample copy of files and directories for when a new user has a home directory created? (Please provide the full path)
Which directory in /etc is used to keep a sample copy of files and directories for when a new user has a home directory created? (Please provide the full path)
正確答案:
etcskeletcskel
Explanation:
The /etc/skel directory is used to keep a sample copy of files and directories for when a new user has a home directory created. The /etc/skel directory contains files and directories that are automatically copied over to a new user's home directory when such user is created by the useradd or adduser command. The /etc/skel directory allows the system administrator to create a standard environment for all new users on the system. For example, the /etc/skel directory may contain a default .bashrc file that sets some aliases and environment variables for the new user, or a default .profile file that executes some commands at login. The /etc/skel directory may also contain subdirectories such as .ssh or .config that store configuration files for various applications or services. The name /etc/skel comes from the word "skeleton", as it provides a basic structure for the new user's home directory. Reference:
[Linux User Administration]
[Linux Directory Structure]
Explanation:
The /etc/skel directory is used to keep a sample copy of files and directories for when a new user has a home directory created. The /etc/skel directory contains files and directories that are automatically copied over to a new user's home directory when such user is created by the useradd or adduser command. The /etc/skel directory allows the system administrator to create a standard environment for all new users on the system. For example, the /etc/skel directory may contain a default .bashrc file that sets some aliases and environment variables for the new user, or a default .profile file that executes some commands at login. The /etc/skel directory may also contain subdirectories such as .ssh or .config that store configuration files for various applications or services. The name /etc/skel comes from the word "skeleton", as it provides a basic structure for the new user's home directory. Reference:
[Linux User Administration]
[Linux Directory Structure]
問題5
What is Irue regarding public and private SSH keys? (Choose TWO correct answers.)
What is Irue regarding public and private SSH keys? (Choose TWO correct answers.)
正確答案: A,B
問題6
Which of the following steps prevents a user from obtaining an interactive login session?
Which of the following steps prevents a user from obtaining an interactive login session?
正確答案: B
說明:(僅 NewDumps 成員可見)
問題7
The system's timezone may be set by linking /etc/localtime to an appropriate file in which directory? (Provide the full path to the directory, without any country information)
The system's timezone may be set by linking /etc/localtime to an appropriate file in which directory? (Provide the full path to the directory, without any country information)
正確答案:
usrsharezoneinfo
Explanation:
The /usr/share/zoneinfo directory contains the binary time zone files that are used by the system to determine the local time for any region. The files are organized in subdirectories by continent, country, or ocean. Some files represent the standard time zones, while others may have historical or political variations. To set the system's timezone, one can create a symbolic link from /etc/localtime to the appropriate file in the /usr/share/zoneinfo directory. For example, to set the timezone to America/New_York, one can use the command sudo ln -sf /usr/share/zoneinfo/America/New_York /etc/localtime. Alternatively, one can use the timedatectl command to set the timezone without creating the link manually. Reference:
How to Set or Change the Time Zone in Linux | Linuxize
4 Ways to Change the Timezone in Linux - wikiHow
Explanation:
The /usr/share/zoneinfo directory contains the binary time zone files that are used by the system to determine the local time for any region. The files are organized in subdirectories by continent, country, or ocean. Some files represent the standard time zones, while others may have historical or political variations. To set the system's timezone, one can create a symbolic link from /etc/localtime to the appropriate file in the /usr/share/zoneinfo directory. For example, to set the timezone to America/New_York, one can use the command sudo ln -sf /usr/share/zoneinfo/America/New_York /etc/localtime. Alternatively, one can use the timedatectl command to set the timezone without creating the link manually. Reference:
How to Set or Change the Time Zone in Linux | Linuxize
4 Ways to Change the Timezone in Linux - wikiHow
問題8
Which of the following files is not read directly by a Bash login shell?
Which of the following files is not read directly by a Bash login shell?
正確答案: A
問題9
Which command is used to set the hostname of the local system? (Specify ONLY the command without any path or parameters.)
Which command is used to set the hostname of the local system? (Specify ONLY the command without any path or parameters.)
正確答案:
hostname
Explanation:
The hostname command is used to set the hostname of the local system. The hostname command can take a single argument, which is the new hostname to be assigned to the system. For example, to set the hostname to linux, one can run:
hostname linux
The hostname command can also be used without any arguments to display the current hostname of the system. For example, to show the current hostname, one can run:
hostname
The hostname command only changes the hostname temporarily, meaning that the original hostname will be restored after a reboot. To change the hostname permanently, one has to edit the configuration files that store the hostname information, such as /etc/hostname, /etc/hosts, /etc/sysconfig/network, etc. The exact files and commands may vary depending on the Linux distribution and the system initialization process. For more details, please refer to the web search results1 or the question answering results2. Reference:
Explanation:
The hostname command is used to set the hostname of the local system. The hostname command can take a single argument, which is the new hostname to be assigned to the system. For example, to set the hostname to linux, one can run:
hostname linux
The hostname command can also be used without any arguments to display the current hostname of the system. For example, to show the current hostname, one can run:
hostname
The hostname command only changes the hostname temporarily, meaning that the original hostname will be restored after a reboot. To change the hostname permanently, one has to edit the configuration files that store the hostname information, such as /etc/hostname, /etc/hosts, /etc/sysconfig/network, etc. The exact files and commands may vary depending on the Linux distribution and the system initialization process. For more details, please refer to the web search results1 or the question answering results2. Reference:
問題10
Which of the following nmcli subcommands exist? (Choose two.)
Which of the following nmcli subcommands exist? (Choose two.)
正確答案: A,D
說明:(僅 NewDumps 成員可見)