Linux Flashcards
You are attempting to copy the contents of one directory, PLAB, to another directory, PIL. You execute the following command
cp PLAB PIL
You are prompted with an error that this is a directory.
You need to copy all files from the PLAB directory to the PIL directory without any error. What should you do?
Use the -r parameter
Which of the following statements are true for the global variable? [Choose all that apply]
Global variables can pass the stored value from the current shell to the sub-shell
PATH and PS are examples of global variables
Which of the following does PKI offer through digital signature?
Non-repudiation
You need to display information about the currently loaded modules in your Linux system. Which of the following command should you use?
lsmod
You perform a vulnerability assessment. In the assessment, you conclude that the edge router is accessible through port 22, making the router insecure. You need to secure this router. What should you do?
Disable SSH
Which of the following information is maintained in the /etc/passwd file? [Choose all that apply]
The user ID number (UID)
Login shell
Encrypted password
User’s group ID number (GID)
Which of the following algorithm can be used to verify an RPM package cryptographically? [Choose all that apply]
MD5
GPG
With the 32-bit Windows operating system installed on a disk formatted with MBR, what is the maximum partition size you can create?
1 TB
You need to view the log messages maintained by rsyslogd. Which of the following files should you review?
rsyslog.conf
Which of the following tool does not work with the deb packages but works with deb archive?
apt
If you are using the tar command with the -czvf option, which of the type of file will you create?
.tgz
You are using CentOS 7. You execute the following command:
SELinux status: enabled
SELinuxfs mount: /sys/fs/selinux
SELinux root directory: /etc/selinux targeted
Loaded policy name: enforcing
Current mode: enforcing
Mode from config file: Policy MLS status: enabled
Policy deny_unknown status: allowed Max kernel policy version: 28
Enforcing
You have just installed DHCP package on your Linux system. You want to configure the system as the DHCP ser,er. You attempt to start the DHCP server wilh lt1e defaull dhcpd.conf rile. Yo, are promplec wilh lrie following error:
Starting ISC DHCP server: dhcpdchccl syslog for diagnostics …. failed!
What could be the possible cause?
Subnet is not defined
You want to view the currently active kernel being used by CentOS. You, however, do not want to make any changes to the currently active kernel. What should you do?
Execute the grub2-editenv list command
Which of the following operating system initially introduced the Common Internet File System (CIFS)?
Windows
To reboot a system, which of the following run level should you use?
6
You start a large download on your Linux system. However, you find tile Web browsing is slow. You want to perform traffic shaping to avoid bandwidth saturation. To do this, you decide to use the wondershaper script. You want to meet the following goals:
- Use low latency for interactive traffic
- Web browsing takes place at reasonable speed along when the downloads and uploads are in progress
- Uploading file does not impact the file downloads or vice versa
With the use of wondershaper script, which of the following goals will be met?
1, 2, and 3
Which of the following are character devices found in the /dev/ directory? [Choose all that apply)
Parallel printer ports
Serial port
The security administrator has discovered several vulnerabilities in an off-the-shelf appl catio but is not sure whether these vulnerabilities are known and published. What should the administrator do to find this out?
Verify with the CVE database
Which of the following can be considered as an overlay network? (Choose all that apply]
Content Delivery Network (CON)
Voice Over IP (VoIP)
Virtual Private Network (VPN)
Peer-to-peer (P2P)
Refer to the exhibit
You have generated the output using the following command:
iotop -oPa
You notice that the number of disk write operations is quite high during the peak traffic hours, and the disk is being overburdened. How should you resolve this issue?
Replace the hard drive in the system
You need to lock out all users except root in a Linux system. Identify the steps that you need to perform:
- Log out all the users
- Create the /etc/nologin
- Modify the /etc/pam.d/login file
1, 2, and 3
You work on a CentOS system as a regular user. You need to start a new process with the nice value of-10. To do this, you execute the following command:
nice 10 ./plab.sh
You are prompted With the following error:
nice: cannot set niceness: Permission denied
What could be the probable cause?
You did not execute the command with the root privileges
You have a new Linux system on which you want to perform the following tasks:
- Initialize the network adapter interface
- Assign an IP address on the interface
- Have the ability to enable or disable the interface
- View the IP address on the interface
- View the MAC address of the interface
- Test the connectivity between two systems
You decide to use the ifconfig command. If you use this command, which of the following tasks should you be able to accomplish?
1,2,3,4,5
Which of the following type of program is dependent on the external shared libraries?
Dynamically linked
You have a Linux server wilh SELinux configured. On your server, you have file and directory permissions, ACLs, and SELinux contexts configured. When you attempt to create a file in one of the directories, you get the access denied error. You verify that you have read, write, and Execute permissions on the directory. How should you narrow down the problem without reducing the security of the system?
Run the audit2why command
You have a directory named plab on which you have applied the Default ACL. You create a subdirectory within the plab directory, and then you create a file. What will be the outcome of these actions?
The subdirectory will have the Default ACL, but the file will access ACL
You want to display the value of a single variable. Which command should you use?
printenv
You attempt to log on to a newly installed Ubuntu system using the root user. You have been told that the root user does not have any password. However, when you attempt to log in, you are prompted with an authentication failure message. You need to install a package but want to use the restrictive administrative privileges. What should you do?
Use the sudo command
You want to use the su command in the same manner as the sudo command. The root account is configured with a password. Which of the following command will help you achieve this?
su -c
You have a dual-boot system with Windows 10 and Ubuntu system. You want to verify if your system is running UEFI. Which of the two methods can help you verify this? (Choose all that apply]
Verify if the /sys/firmware/efi directory exists
Install and then run efibootmgr
In the /etc/sysctl.conf file, which of the following statement should you add to enable IPv6 forwarding?
net.ipv6.conf.all.forwarding=1
Which type of Access Control Entry (ACE) should you use to log access attempts?
System-audit
Which of the following can be defined as the orchestration attributes? [Choose all that apply]
objects tags desired state description name
You want to sort the running service with the time they took to initialize. You want the highest time taken first. Which of the subcommand of systemctl-analyze should be used for this purpose?
Blame