Dive into practice questions
Question 1
Which of the following can be used as a secure way to access a remote terminal?
A. TFTP
B. SSH
C. SCP
D. SFTP
Question 2
A user wants to back up some work files from the /opt/work directory to a home directory. Which of the following commands should the user run?
A. mv /opt/work ~
B. cp -R /opt/work ~
C. rm -Rf /opt/work
D. touch ~/work
Question 3
A systems administrator needs to check if the service systemd-resolved.service is running without any errors. Which of the following commands will show this information?
A. systemctl status systemd-resolved.service
B. systemctl enable systemd-resolved.service
C. systemctl mask systemd-resolved.service
D. systemctl show systemd-resolved.service
Question 4
A Linux administrator is troubleshooting an SSHD issue on a server. Users are receiving error messages stating the connection is refused. Which of the following commands should be used to verify whether the service is listening?
A. nslookup
B. route
C. netstat
D. ifconfig
Question 5
A non-privileged user is attempting to use commands that require elevated account permissions, but the commands are not successful. Which of the following most likely needs to be updated?
A. / etc/passwd
B. / etc/shadow
C. /etc/sudoers
D. /etc/bashrc
Question 6
A systems administrator is trying to give read/write access to a file, config.conf, to User1. Based on the output shown:
$ getfacl config.conf # file: config.conf # owner: cloud_user # group: cloud_user user::rw- user:User2:r-- group::rw- mask::rw- other::r--
A. setfacl -b u:User1:r
B. setfacl -x u:User1:User2:rw
C. setfacl -m u:User1:rw
D. setfacl -m g:User1:rw
Question 7
Based on the given command:
find /home/user1 -type f -name "*.txt" -size +100M
Which of the following will the command accomplish?
A. It finds all the files ending with .txt with a size less than 100MB in /home/user1 directory.
B. It finds all the files ending with .txt with a size of 100MB in /home/user1 directory.
C. It finds all the directories with .txt files with a size of 100MB in /home folder.
D. It finds all the files ending with .txt with a size of over 100MB in /home/user1 directory.
Question 8
Users are unable to create new files on the company's FTP server, and an administrator is troubleshooting the issue. The administrator runs the following commands:
# df -h /ftpusers/
Filesystem | Size | Used | Avail | Use% | Mounted on |
/dev/sda4 | 150G | 40G | 109G | 26% | /ftpusers |
# df -i /ftpusers/
Filesystem | Inodes | Iused | Ifree | Iuse% | Mounted on |
/dev/sda4 | 34567 | 34567 | 0 | 100% | /ftpusers |
A. The users do not have the correct permissions to create files on the FTP server.
B. The ftpusers filesystem does not have enough space.
C. The inodes is at full capacity and would affect file creation for users.
D. journalctl --vacuum-time=2
Question 9
A systems administrator is running out of space for journald systemd binary logs in the default location and needs to address the space issue. One of the requirements is to retain the logs for at least two weeks. Which of the following commands should the administrator issue?
A. journalctl --vacuum-size=20M
B. journalctl --vacuum-time=14d
C. journalctl --vacuum-size=200M
D. journalctl --vacuum-time=2
Question 10
An application fails to start after a server is restarted. Which of the following commands would allow this service to start automatically?
A. systemctl reload app.service
B. systemctl restart app.service
C. systemctl enable app.service
D. systemctl start app.service
Answer key
Question 1: B (SSH)
Question 10: C (systemctl enable app.service)