What is true regarding the statement beginning with #! that is found in the first line of script? (Choose two.)
Correct Answer: B,E
Question 97
Which crontab entry could be used to set the system time at regular intervals?
Correct Answer: B
The crontab entry that could be used to set the system time at regular intervals is the one that uses the ntpdate command to synchronize the system clock with a Network Time Protocol (NTP) server. The ntpdate command takes one or more NTP server names or IP addresses as arguments and adjusts the system clock accordingly12. The crontab entry B specifies that the ntpdate command should be executed at the first minute of the zeroth hour (i.e., 00:01) of every day of every month of every weekday, using the NTP server ntp1.digex.net34. This will ensure that the system time is updated daily with a reliable source. The other crontab entries are either invalid or ineffective for setting the system time at regular intervals. The date command can be used to display or set the system date and time, but it requires a specific format for the argument, not an NTP server name5. The runcron and settime commands are not standard Linux commands and their functionality is unknown. The $d, $t, and $24 variables are also undefined and meaningless in this context. References: 1: Linux At, Batch, Atq, Atrm Command Help and Examples - Computer Hope 2: How to set a cron job to run at a exact time? - Stack Overflow 3: 107.2 Lesson 1 - Linux Professional Institute Certification Programs 4: How to setup a crontab to execute at specific time - Stack Overflow 5: Writing a specific format of time in a text file every minute using ... - Ask Ubuntu
Question 98
Which of the following steps prevents a user from obtaining an interactive login session?
Correct Answer: A
Question 99
Which file contains the date of the last change of a user's password?
Correct Answer: D
The /etc/shadow file contains the encrypted passwords and other information for each user account on a Linux system. The third field in each line of this file is the date of the last password change, expressed as the number of days since Jan 1, 1970. This information is used by the system to determine when a user must change their password, based on the password aging policy. The /etc/shadow file can be viewed and modified by the root user or by using the chagecommand123. The other files listed in the options do not store the date of the last password change. The /etc/gshadow file contains the encrypted passwords for group accounts4. The /etc/passwd file contains the basic information for each user account, such as the user name, user ID, group ID, home directory, login shell, etc., but not the password5. The /etc/pwdlog file does not exist by default on most Linux systems, and it is not related to the password change date. The /var/log/shadow file also does not exist by default on most Linux systems, and it is not related to the password change date. References: https://www.redhat.com/sysadmin/password-changes-chage-command https://www.golinuxcloud.com/check-last-password-change-expiration-linux/
Question 100
Which of the following programs can be used to determine the routing path to a given destination?
Correct Answer: E
The traceroute program can be used to determine the routing path to a given destination by sending packets with incrementing TTL values and recording the source of the ICMP time exceeded messages. This way, it can show the intermediate hops and the round-trip times for each packet. The other programs have different purposes: dig is used to query DNS servers, netstat is used to display network connections and statistics, ping is used to test the reachability of a host by sending ICMP echo requests and measuring the response time, and route is used to manipulate the routing table. References: * LPI 102-500 Exam Objectives, Topic 110: Network Fundamentals, Weight: 4, 110.3 Basic network troubleshooting * LPI 102-500 Study Guide, Chapter 10: Network Fundamentals, Section 10.3: Basic Network Troubleshooting, Page 125-126