Operations 10 min read

Test Your Linux Mastery: 30‑Question Quiz for Sysadmins

This article presents a 30‑question Linux quiz—including multiple‑choice, true/false, and short‑answer sections—designed to let operations professionals assess their command‑line knowledge within a 45‑minute timeframe, with clear rules and honest‑answer guidelines.

MaGe Linux Operations
MaGe Linux Operations
MaGe Linux Operations
Test Your Linux Mastery: 30‑Question Quiz for Sysadmins

“Strive to make days more relaxed, joyful, and elegant.” — Ma Ge

Operations personnel need solid Linux skills to lead a more relaxed, joyful, and elegant life.

Having learned the basics of Linux, we now assess our level with a test.

Test Rules

This test has no score; it aims to let participants evaluate their knowledge. It contains 30 questions to be answered in 45 minutes.

Answers can be submitted via the article bottom, WeChat public account, 51CTO blog, etc.

Please answer honestly without searching for solutions.

Multiple‑Choice Questions (multiple answers possible)

1、In regular expressions, which character class denotes non‑space characters?
 a. [:graph:]
 b. [:digit:]
 c. [:space:]
 d. [:alpha:]

2、Which statement about bash variables is correct?
 a. Can be set in /etc/profile for all users permanently
 b. Adding to ~/.bash_profile affects a single user temporarily
 c. Using export defines it for the current shell permanently
 d. All of the above are incorrect

3、After logging into Linux, the shell reads startup files in which order?
 a. /etc/profile → ~/.bash_profile → ~/.profile → ~/.bash_login
 b. /etc/profile → ~/.bash_profile → ~/.bash_login → ~/.profile
 c. ~/.bash_profile → /etc/profile → ~/.profile → ~/.bash_login
 d. ~/.bash_login → ~/.profile → ~/.bash_profile → /etc/profile

4、Command to create nested directories?
 a. mkdir -p
 b. mkdir -v
 c. mkdir -m
 d. mkdir -Z

5、Which command can view attributes of a file that even root cannot modify directly?
 a. ls -lh
 b. file
 c. stat
 d. lsattr

6、Which alias definition is correct?
 a. LS='ls -lh'
 b. set cnet 'cd /etc/sysconfig/network-scripts/ifcfg-eth0'
 c. alias die='rm -fr'
 d. unalias die='rm -fr'

7、Common text‑editing tools?
 a. nano
 b. cat
 c. cut
 d. vim

8,Which find option selects socket files?
 a. d
 b. l
 c. p
 d. s

9、If a file has permissions -rw-r--r-- and chmod g+s is applied, what will be displayed?
 a. -rw-r-Sr--
 b. -rw-r-sr--
 c. -rw-r--r--
 d. -rw-r-xr--

10、When using fdisk, which type code represents an LVM partition?
 a. l
 b. lvm
 c. 9e
 d. 8e

11、Command to archive a directory without compression?
 a. tar -cvf
 b. tar -zcvf
 c. tar -jvf
 d. tar -jcvf

12、Which positional parameter represents the script itself?
 a. $0
 b. $1
 c. $#
 d. $@

13、Four‑layer load balancing and seven‑layer load balancing correspond to which OSI layers?
 a. Transport, Presentation
 b. Network, Application
 c. Transport, Application
 d. Network, Presentation

14、Two processes have PIDs 110 and 119; to ensure 119 always gets CPU priority over 110, what should be done?
 a. nice -5 119
 b. renice -5 119
 c. nice -5 110
 d. renice -5 110

15、How to add a crontab task for user magedu non‑interactively?
 a. Write to /var/spool/cron/root
 b. Write to /var/spool/cron/magedu
 c. Write to /var/spool/root/cron
 d. Write to /var/spool/magedu/cron

16、Command to start network service on CentOS 7?
 a. service network start
 b. /etc/init.d/network start
 c. systemctl start network.service
 d. /etc/init.d/rc.d/init.d start

17、During kernel self‑initialization, which task is performed?
 a. Detect all recognizable hardware
 b. Mount the real root filesystem read‑only
 c. Search boot devices sequentially, using the first with a bootloader
 d. Launch the first user‑space program: /sbin/init

18、Which statement about Linux runlevels on CentOS 6 is incorrect?
 a. 4 – maintenance mode, multi‑user, network enabled, no NFS
 b. 1 – maintenance mode, single‑user, root login without authentication
 c. 3 – normal, full multi‑user text mode
 d. 5 – normal, full multi‑user graphical mode

19、Which command correctly prints the line containing the root user in /etc/passwd?
 a. awk '{if($1=/root/) print }' /etc/passwd
 b. awk -F: '{if($1==/root/) print }' /etc/passwd
 c. awk -F: '{if($1=/root/) print }' /etc/passwd
 d. awk -F: '{if($1~/root/) print }' /etc/passwd

20、Which is NOT a function of /etc/rc.d/rc.sysinit?
 a. Set hostname from configuration
 b. Configure server IP address
 c. Print welcome text
 d. Activate LVM and RAID devices

True/False Questions (analyze why each is right or wrong if interested)

1. In symmetric encryption, encryption and decryption use the same key; main algorithms include md5, sha1.
2. After implementing RAID 1 with two disks, overall write performance degrades.
3. RAID 5 requires at least three disks.
4. keepalived is implemented based on the VRRP protocol.
5. Process A starts with a maximum of 1024 open file descriptors; after raising the system limit to 65535, a child process of A will still have a limit of 1024.

Short‑Answer Questions

1. Find ordinary files or directories in the current directory that have not changed in the last 10 days and are larger than 4 KB.
2. Use the ss command to list connections in the TIME_WAIT state.
3. Briefly describe the boot process of CentOS 6.
4. What is the difference between yum update and yum upgrade?
5. Schedule the script /data/get_username.sh to run at 01:05 every Tuesday and write its output to /tmp/get_username.log.
Original Source

Signed-in readers can open the original source through BestHub's protected redirect.

Sign in to view source
Republication Notice

This article has been distilled and summarized from source material, then republished for learning and reference. If you believe it infringes your rights, please contactadmin@besthub.devand we will review it promptly.

Linuxcommand-lineQuiz
MaGe Linux Operations
Written by

MaGe Linux Operations

Founded in 2009, MaGe Education is a top Chinese high‑end IT training brand. Its graduates earn 12K+ RMB salaries, and the school has trained tens of thousands of students. It offers high‑pay courses in Linux cloud operations, Python full‑stack, automation, data analysis, AI, and Go high‑concurrency architecture. Thanks to quality courses and a solid reputation, it has talent partnerships with numerous internet firms.

0 followers
Reader feedback

How this landed with the community

Sign in to like

Rate this article

Was this worth your time?

Sign in to rate
Discussion

0 Comments

Thoughtful readers leave field notes, pushback, and hard-won operational detail here.