Unit 6: Network Storage, Boot, Security, and Installation - Practice Quiz

CSE493 — Linux System Administration 60 Questions
0 Correct 0 Wrong 60 Left
0/60

1 Which protocol is commonly used to share directories between Linux systems over a network?

Accessing Network-Attached Storage Easy
A. DHCP
B. SSH
C. DNS
D. NFS

2 Which command displays the NFS exports available from a remote server?

Accessing Network-Attached Storage Easy
A. hostnamectl server
B. firewall-cmd server
C. systemctl list server
D. showmount -e server

3 Which command mounts the NFS export server:/share on /mnt/share?

Mounting Network-Attached Storage with NFS Easy
A. umount -t nfs server:/share /mnt/share
B. mount -t ext4 server:/share /mnt/share
C. exportfs -t nfs server:/share /mnt/share
D. mount -t nfs server:/share /mnt/share

4 Which file is commonly edited to make an NFS mount persistent across reboots?

Mounting Network-Attached Storage with NFS Easy
A. /etc/passwd
B. /etc/resolv.conf
C. /etc/fstab
D. /etc/hosts

5 Which service mounts network file systems automatically when their directories are accessed?

Automounting Network-Attached Storage Easy
A. tuned
B. chronyd
C. sshd
D. autofs

6 Which file is the main configuration map for the autofs service?

Automounting Network-Attached Storage Easy
A. /etc/auto.master
B. /etc/nsswitch.conf
C. /etc/exports
D. /etc/sysctl.conf

7 Which boot loader is commonly used by Red Hat Enterprise Linux?

Controlling the Boot Process Easy
A. GRUB2
B. Anaconda
C. Kickstart
D. Wayland

8 Which command displays the default systemd boot target?

Selecting the Boot Target Easy
A. systemctl get-target
B. systemctl list-default
C. systemctl show-boot
D. systemctl get-default

9 Which systemd target starts a graphical login environment?

Selecting the Boot Target Easy
A. multi-user.target
B. graphical.target
C. emergency.target
D. rescue.target

10 Which parameter can be added to the GRUB kernel command line to interrupt startup for root password recovery?

Resetting the Root Password Easy
A. rd.break
B. fs.check
C. ro.debug
D. net.boot

11 Which command is used to assign a new password to the root account after entering the recovery environment?

Resetting the Root Password Easy
A. whoami
B. passwd
C. useradd
D. userdel

12 Which command checks and repairs a Linux file system?

Repairing File System Issues at Boot Easy
A. lsblk
B. fsck
C. df
D. mount

13 Which firewall management service is commonly used in Red Hat Enterprise Linux?

Managing Server Firewalls Easy
A. firewalld
B. sshd
C. autofs
D. chronyd

14 Which command allows HTTP traffic in the current firewalld configuration?

Managing Server Firewalls Easy
A. firewall-cmd --query-service=http
B. firewall-cmd --add-service=dns
C. firewall-cmd --remove-service=http
D. firewall-cmd --add-service=http

15 Which option makes a firewall-cmd rule remain after a reboot?

Managing Server Firewalls Easy
A. --permanent
B. --reload
C. --runtime
D. --complete

16 Which utility is used to manage SELinux port type assignments?

Controlling SELinux Port Labeling Easy
A. hostnamectl
B. semanage
C. firewall-cmd
D. restorecon

17 What does SELinux do when it operates in enforcing mode?

Managing Network Security Easy
A. Blocks and logs policy violations
B. Allows every network connection
C. Disables all security policies
D. Logs violations without blocking

18 What is the name of the graphical installer used by Red Hat Enterprise Linux?

Installing Red Hat Enterprise Linux Easy
A. GRUB2
B. Kickstart
C. Anaconda
D. Cockpit

19 What is the main purpose of a Kickstart file?

Automating Installation with Kickstart Easy
A. Configure firewall runtime rules
B. Repair damaged file systems
C. Monitor active network connections
D. Automate operating system installation

20 Which graphical tool can be used to create and manage KVM virtual machines?

Installing and Configuring Virtual Machines Easy
A. virt-manager
B. firewall-config
C. nm-connection-editor
D. system-config-printer

21 A Linux administrator needs to identify available NFS exports from a server before mounting one. Which command is most appropriate?

Accessing Network-Attached Storage Medium
A. nfsstat -e nfs-server
B. showmount -e nfs-server
C. exportfs -v nfs-server
D. mount -l nfs-server

22 Which /etc/fstab entry mounts the /projects export from files.example.com on /mnt/projects using NFS at boot?

Mounting Network-Attached Storage with NFS Medium
A. /mnt/projects files.example.com:/projects nfs auto 1 1
B. files.example.com:/projects /mnt/projects nfs defaults 0 0
C. files.example.com:/projects /mnt/projects ext4 defaults 0 0
D. files.example.com:/mnt/projects /projects nfs defaults 0 0

23 An NFS mount fails because the client cannot resolve the server name. Which action should be checked first?

Mounting Network-Attached Storage with NFS Medium
A. Verify DNS or /etc/hosts resolution
B. Change the local file system type
C. Rebuild the server's boot loader
D. Disable the client firewall permanently

24 What is the main advantage of using autofs for an NFS home directory?

Automounting Network-Attached Storage Medium
A. It copies the directory permanently to local storage
B. It replaces the NFS server with a local file system
C. It mounts the directory when accessed and unmounts it when idle
D. It encrypts all files without additional configuration

25 In an indirect autofs map, which location is typically used for a map entry mounting an export under /home/remote?

Automounting Network-Attached Storage Medium
A. /etc/auto.master.d/remote.autofs
B. /var/lib/autofs/remote.mount
C. /etc/fstab.d/remote.nfs
D. /etc/systemd/remote.mount

26 A system boots to a graphical interface, but an administrator wants to start it in a non-graphical troubleshooting mode for one boot. Which GRUB action is appropriate?

Controlling the Boot Process Medium
A. Edit the initrd line and append systemd.target=graphical.target
B. Replace the kernel image with the rescue image
C. Delete the GRUB configuration before rebooting
D. Edit the kernel line and append systemd.unit=multi-user.target

27 Which command permanently configures a system to boot into the graphical target?

Selecting the Boot Target Medium
A. systemctl set-default graphical.target
B. systemctl enable graphical.target
C. grub2-mkconfig --target graphical.target
D. systemctl start graphical.target --permanent

28 An administrator needs a target that starts networking and most system services but does not start a graphical login manager. Which target should be selected?

Selecting the Boot Target Medium
A. graphical.target
B. emergency.target
C. multi-user.target
D. rescue.target

29 After booting into an emergency shell to reset the root password on an SELinux-enabled system, which sequence helps preserve correct file labels?

Resetting the Root Password Medium
A. Delete /etc/shadow, change the password, and disable SELinux
B. Remount / read-only, change the password, and skip relabeling
C. Change the password in /boot, then regenerate the initramfs
D. Remount / read-write, change the password, create /.autorelabel, and reboot

30 Why is rw init=/bin/bash sometimes added to the Linux kernel command line during root password recovery?

Resetting the Root Password Medium
A. It starts a shell with the root file system writable
B. It mounts every available NFS export automatically
C. It replaces the system kernel with a recovery kernel
D. It enables the graphical desktop before authentication

31 A boot process reports errors on an unmounted ext4 file system. Which command is appropriate for checking and repairing it?

Repairing File System Issues at Boot Medium
A. fsck -t ext4 /dev/vdb1
B. xfs_repair -n /dev/vdb1
C. mkfs.ext4 /dev/vdb1
D. mount -o repair /dev/vdb1

32 A server enters emergency mode because an /etc/fstab entry references a disk that is temporarily unavailable. Which option can prevent the missing mount from stopping boot?

Repairing File System Issues at Boot Medium
A. Add the nofail option to the mount entry
B. Change the file system type to auto-fix
C. Add the roothold option to the entry
D. Replace the device with swap

33 A service should accept connections only from the 192.0.2.0/24 network. Which control best enforces this requirement?

Managing Network Security Medium
A. Restrict the service with a firewall source rule
B. Change the server hostname to the subnet name
C. Set the service port to a random unused value
D. Disable logging for rejected connections

34 Which command permanently permits HTTPS traffic in the default firewalld zone and immediately applies the change?

Managing Server Firewalls Medium
A. firewall-cmd --permanent --remove-service=https followed by firewall-cmd --restart
B. firewall-cmd --permanent --add-service=https followed by firewall-cmd --reload
C. firewall-cmd --add-service=https --temporary followed by systemctl restart sshd
D. firewall-cmd --add-port=443/udp --permanent followed by systemctl reload firewalld

35 An administrator added port 8080/tcp to firewalld but remote clients still cannot connect. Which check is most useful next?

Managing Server Firewalls Medium
A. Reinstall the server's network interface driver
B. Change the port protocol from TCP to ICMP
C. Remove all rules from the active firewalld zone
D. Confirm the service is listening on the expected address and port

36 A web service labeled for HTTP is configured to listen on TCP port 8443. Which command adds the correct SELinux port label?

Controlling SELinux Port Labeling Medium
A. semanage port -a -t http_port_t -p tcp 8443
B. restorecon -p tcp -t http_port_t 8443
C. setsebool -a -t http_port_t -p tcp 8443
D. chcon -t http_port_t /etc/services

37 Which command displays the SELinux port types currently associated with TCP ports used by HTTP services?

Controlling SELinux Port Labeling Medium
A. semanage port -l | grep http_port_t
B. ls -Z /var/www | grep http_port_t
C. getsebool -a | grep http_port_t
D. firewall-cmd --list-services | grep http_port_t

38 During a Red Hat Enterprise Linux installation, which partitioning approach gives the installer control over the layout while retaining automatic file system creation?

Installing Red Hat Enterprise Linux Medium
A. Select custom partitioning with LVM and define mount points
B. Select network boot and skip disk configuration
C. Select automatic partitioning and manually edit /etc/fstab
D. Select raw disk mode and format only the swap partition

39 A minimal RHEL server requires remote administration after installation. Which installation choice is most directly relevant?

Installing Red Hat Enterprise Linux Medium
A. Choose a graphical environment and block TCP port 22
B. Install the server environment and enable OpenSSH access
C. Select a local media repository and remove all services
D. Install only the workstation environment and disable networking

40 A Kickstart file must run a command after package installation but before the system reboots. Which section should contain the command?

Automating Installation with Kickstart Medium
A. %packages
B. %addon
C. %post
D. %pre

41 A RHEL client can resolve an NFS server's hostname and ping it, but showmount -e server.example.com times out. The server exports directories through NFSv4 only and its firewall permits the NFS service. Which conclusion best explains the timeout?

Accessing Network-Attached Storage Hard
A. showmount queries the legacy mount service, which an NFSv4-only server may not expose
B. showmount works only when the client has already mounted the NFSv4 root
C. showmount requires write permission on at least one exported directory
D. showmount requires the server hostname to be defined in /etc/hosts

42 A client must mount the NFSv4 export server.example.com:/projects at /mnt/projects during boot. Boot must continue if the server is unavailable, and ordinary local file-system checks must not be attempted. Which /etc/fstab entry is most appropriate?

Mounting Network-Attached Storage with NFS Hard
A. server.example.com:/projects /mnt/projects ext4 defaults,nofail 0 2
B. server.example.com:/projects /mnt/projects nfs4 defaults,fail 1 2
C. server.example.com:/projects /mnt/projects nfs4 defaults,_netdev,nofail 0 0
D. server.example.com:/projects /mnt/projects nfs4 defaults,_netdev 1 1

43 An application writes critical records to an NFS mount. Administrators want interrupted operations to keep retrying after a temporary server outage rather than return potentially unsafe I/O errors to the application. Which mount behavior best satisfies this requirement?

Mounting Network-Attached Storage with NFS Hard
A. Use a hard mount and allow requests to retry until the server responds
B. Use a soft mount and reduce the retry count to avoid blocked processes
C. Use an interruptible soft mount and disable attribute caching
D. Use a synchronous mount and set the retransmission count to zero

44 An autofs indirect map should mount each user's NFS home directory only when /home/<username> is accessed. The server stores homes as /exports/home/<username>. Which map entry correctly uses a wildcard substitution?

Automounting Network-Attached Storage Hard
A. home -fstype=nfs4,rw server.example.com:/exports/home/&
B. * -fstype=nfs4,rw server.example.com:/exports/home/&
C. /* -fstype=nfs4,rw server.example.com:/exports/home/$USER
D. & -fstype=nfs4,rw server.example.com:/exports/home/*

45 After adding /data /etc/auto.data to /etc/auto.master.d/data.autofs, an administrator creates /etc/auto.data with reports -rw server:/exports/reports. Accessing /data/reports still returns "No such file or directory," and no autofs process has reloaded the configuration. What is the most direct corrective action?

Automounting Network-Attached Storage Hard
A. Restart the autofs service so it reads the new master map
B. Run systemctl daemon-reexec so systemd parses the NFS export
C. Restart nfs-server so the client map becomes visible
D. Run mount -a so the kernel reads the new indirect map

46 A system enters emergency mode because a nonessential local data volume listed in /etc/fstab is missing. Administrators want future boots to continue without waiting for that volume, while still mounting it automatically whenever it is available. Which change is most appropriate?

Controlling the Boot Process Hard
A. Set the fifth /etc/fstab field to 1 for the volume
B. Set the sixth /etc/fstab field to 1 for the volume
C. Add noauto to the volume's mount options in /etc/fstab
D. Add nofail to the volume's mount options in /etc/fstab

47 A graphical RHEL server must boot into text-only multi-user mode for one troubleshooting session, then return to its configured graphical default on the next reboot. Which approach meets both requirements?

Selecting the Boot Target Hard
A. Append systemd.default_standard_output=multi-user to the kernel line
B. Append systemd.unit=multi-user.target to the kernel command line once
C. Replace default.target with a permanent link to rescue.target
D. Run systemctl set-default multi-user.target before rebooting once

48 A server currently uses graphical.target by default. An administrator runs systemctl isolate multi-user.target from a graphical session. What is the expected result?

Selecting the Boot Target Hard
A. The current system remains graphical, but the next boot uses multi-user.target
B. The system starts multi-user.target alongside all graphical-only units indefinitely
C. The system permanently changes its default and immediately reboots without graphics
D. The current system switches targets, but the next boot still uses graphical.target

49 A RHEL system is booted with rd.break to reset a forgotten root password on an SELinux-enforcing installation. Which sequence correctly updates the installed system and prepares SELinux labels for the next boot?

Resetting the Root Password Hard
A. chroot /sysroot; mount -o remount,ro /; passwd; restorecon /; reboot
B. mount -o remount,rw /; passwd; touch /sysroot/.autorelabel; exit and reboot
C. mount -o remount,rw /boot; chroot /boot; passwd; setenforce 0; reboot
D. mount -o remount,rw /sysroot; chroot /sysroot; passwd; touch /.autorelabel; exit and reboot

50 Boot stops because an XFS file system on /dev/mapper/vg-data is corrupt. The volume is not the root file system and can be kept unmounted in emergency mode. Which repair procedure is appropriate?

Repairing File System Issues at Boot Hard
A. Mount the volume read-only, then run e2fsck -y /dev/mapper/vg-data
B. Ensure the volume is unmounted, then run xfs_repair /dev/mapper/vg-data
C. Ensure the volume is mounted, then run xfs_growfs /dev/mapper/vg-data
D. Mount the volume read-write, then run fsck.xfs -f /dev/mapper/vg-data

51 A non-root ext4 file system fails its automatic boot check. The administrator has confirmed it is unmounted and wants a forced consistency check that automatically accepts repairs. Which command is appropriate?

Repairing File System Issues at Boot Hard
A. xfs_repair -f -y /dev/mapper/vg-app
B. e2fsck -f -y /dev/mapper/vg-app
C. mount -o remount,repair /dev/mapper/vg-app
D. tune2fs -f -y /dev/mapper/vg-app

52 A host has two NetworkManager connections, both currently active. A firewall zone was assigned by editing only one connection profile with nmcli, but packets continue to use the old zone. What additional action is generally required for the profile change to take effect?

Managing Network Security Hard
A. Reactivate the modified connection so NetworkManager reapplies its zone assignment
B. Flush all nftables tables so NetworkManager can recreate the connection profile
C. Restart sshd so existing sockets inherit the modified connection zone
D. Run semanage port -a so SELinux associates the interface with the zone

53 An administrator runs firewall-cmd --zone=public --add-service=https and confirms that HTTPS works. After reboot, the rule is gone. Which command adds the missing persistent configuration without immediately altering the current runtime state?

Managing Server Firewalls Hard
A. firewall-cmd --runtime-to-permanent --zone=public --add-service=https
B. firewall-cmd --permanent --zone=public --add-service=https
C. firewall-cmd --reload --zone=public --add-service=https
D. firewall-cmd --complete-reload --zone=public --add-service=https

54 A server's public zone is bound to interface ens3, but the source network 192.0.2.0/24 is explicitly assigned to the trusted zone. A packet from 192.0.2.10 arrives through ens3. Which zone handles the packet?

Managing Server Firewalls Hard
A. Both zones, because firewalld combines all rules matching the packet
B. The trusted zone, because an explicit source assignment takes precedence
C. The public zone, because an interface assignment always takes precedence
D. The default zone, because the source and interface assignments conflict

55 A custom web service runs under the confined HTTP server domain and must listen on TCP port 8088. The firewall is already open, but SELinux denies the bind. Port 8088 has no existing SELinux port mapping. Which persistent command is appropriate?

Controlling SELinux Port Labeling Hard
A. setsebool -P httpd_can_network_connect on 8088
B. semanage port -a -t http_port_t -p tcp 8088
C. chcon -t http_port_t /proc/sys/net/ipv4/8088
D. semanage port -m -t http_port_t -p udp 8088

56 An administrator attempts semanage port -a -t http_port_t -p tcp 8443, but the command reports that TCP port 8443 is already defined with another SELinux type. What should the administrator do after verifying that reassignment is appropriate?

Controlling SELinux Port Labeling Hard
A. Use semanage port -d -t http_port_t -p tcp 8443
B. Use setenforce http_port_t:tcp:8443
C. Use semanage port -m -t http_port_t -p tcp 8443
D. Use restorecon -v -t http_port_t tcp/8443

57 A UEFI-based RHEL installation uses GPT, software RAID for most storage, and a separate EFI System Partition. Which design is required for firmware boot support?

Installing Red Hat Enterprise Linux Hard
A. Create a non-RAID EFI System Partition formatted as FAT and mounted at /boot/efi
B. Create an EFI System Partition inside LVM formatted as XFS and mounted at /boot
C. Create a BIOS boot partition formatted as ext4 and mounted at /boot/efi
D. Create the EFI System Partition across RAID 0 formatted as XFS and mounted at /efi

58 During installation, a server must retain data on an existing partition while replacing the operating system. Which storage action best minimizes the risk of destroying the retained data?

Installing Red Hat Enterprise Linux Hard
A. Use custom partitioning, preserve that partition, and reformat only selected OS volumes
B. Use automatic partitioning and trust the installer to infer which partition contains data
C. Delete all existing partitions and restore the retained partition from the installer cache
D. Reinitialize the disk label and recreate the retained partition with identical start sectors

59 A Kickstart %post script must copy a file from the installation environment's /run/install/repo into the installed system. The script needs direct access to both the installer environment and the target mounted at /mnt/sysroot. Which section declaration is most appropriate?

Automating Installation with Kickstart Hard
A. %post --nochroot
B. %pre --nochroot
C. %packages --instLangs=en_US
D. %post --interpreter=/bin/bash

60 A KVM guest must be live-migratable among hosts with different CPU generations. Maximum guest CPU performance is less important than compatibility. Which CPU configuration is the best choice?

Installing and Configuring Virtual Machines Hard
A. Use software emulation with an unrestricted source-host CPU definition
B. Use a common virtual CPU model supported by every migration host
C. Use host passthrough so each guest exposes all source-host CPU features
D. Use host model and permit migration despite missing destination features