Based on the Linux Master 1 exam syllabusReport an error
ip addr add/ip route add) from persistent (BOOTPROTO/ONBOOT=yes/IPADDR in ifcfg-*, nmcli con).con up after modifying for it to take effect.ip a → ping gw → ping 8.8.8.8 → dig. For port checks, use ss -tuln.DocumentRoot/Listen, named type master + SOA Serial + records (A/MX/CNAME/PTR).range/fixed-address, vsftpd anonymous_enable/chroot_local_user, smb.conf path/writable.root_squash; sshd: PermitRootLogin no.=, spaces inside the brackets of if [ -gt/-eq/-f/-d ], for/while/case (done/done/esac).$(...), $?, while read ... done < file, and sort|uniq -c|sort -rn as patterns.-A/-I/-P/-j, ACCEPT/DROP/REJECT, service iptables save.--permanent then --reload; SELinux: modes and chcon/restorecon.facility.priority (.none/.=); logrotate: rotate N/compress.💡 Pass signal: Lab tasks ask for "the exact command/directive that does this." If the direction, options, and spelling are exact, you are right; if even one is wrong, it is zero points.
🔍 Solving strategy: When you read a question, recall in order ① which area (network/service/script/security), ② temporary or persistent, ③ which file or command. Since three of the four choices are traps with one wrong direction, option, or spelling, the elimination method of finding the error and crossing it out is faster than picking the answer.
ip) / configuration that remains in a file and persists (ifcfg-*, nmcli con).ifcfg-* that decides whether the interface is brought up automatically at boot. If it is not yes, it does not come up.no.done < file : The redirection that attaches input so while read reads the file line by line. It goes after done.--permanent + --reload : The two steps in firewalld of saving permanently and then applying to the current session. Doing only one is half the job..none excludes, .= means only that level, and the default is that level and above.Click a choice to reveal the answer and explanation.
Question 1
Which command combination temporarily assigns the address 192.168.0.50/24 to eth0 and sets the default gateway to 192.168.0.1?
Question 2
In the ifcfg-eth0 file, which combination of directives uses a static IP and makes the interface activate automatically even after a reboot?
Question 3
ping 8.8.8.8 succeeds but ping www.example.com fails. Which file should you check?
Question 4
After editing a BIND zone file, what must you do to propagate the change to the secondary (slave) server?
Question 5
Among the following /etc/exports entries, which is the faulty setting that unintentionally opens rw to all hosts?
Question 6
Which sshd_config setting blocks direct remote login by root on an SSH server?
Question 7
In the following shell script fragments, which line has a syntax error?
Question 8
Which is the correct blank for a script that reads the file users.txt line by line to create user accounts?
while read u; do useradd "$u"; done ____ users.txt
Question 9
Which iptables command allows only incoming TCP connections to port 443 (HTTPS) from outside?
Question 10
How do you allow port 8080/tcp in firewalld so that it persists after reboot and takes effect immediately?
Question 11
"File permissions (rwx) are correct, but the web server cannot access a certain directory. After setenforce 0, access works." What is the most appropriate permanent fix?
Question 12
Which is the correct description of the logrotate settings daily, rotate 7, compress?
I gathered the traps that mock exams catch most often into one table. Reviewing just this table right before the exam is also fine.
| Trap | Answer / Caution |
|---|---|
ip addr vs ip route | Address is addr add, route is route add default via |
| Temporary vs persistent | ip = volatile, ifcfg ONBOOT=yes/nmcli con = persistent |
| Applying nmcli | After modify, you must con up for it to take effect |
| ping IP succeeds, domain fails | DNS (/etc/resolv.conf) problem |
| SOA Serial | Must be increased whenever the zone is edited |
| exports whitespace | No space between client(options) |
| Variable assignment | No spaces around = |
| if condition | Spaces required inside [ and ], numeric -gt/string = |
| Reading a file | while read ... done < file |
| iptables direction | Incoming is INPUT, outgoing is OUTPUT |
| iptables policy change | If remote, allow SSH first |
| Applying firewalld | --permanent then --reload |
| SELinux access denied | Suspect context → restorecon |
| rsyslog | .none = exclude, .= = exactly, .level = and above |
| logrotate | rotate N = number of generations, interval is daily/weekly |
⚠️ Exam-room mindset: Partial credit in lab tasks is stingy. One direction (INPUT/OUTPUT), one space, or one missing
--reloadmakes the whole answer wrong. After writing a command, run it once in your head and double-check "what exactly happens if I execute this?"
We compressed the week into 12 questions. The core of network lab tasks is telling temporary from persistent (ip is volatile, ifcfg ONBOOT=yes/nmcli con is persistent) and layer-by-layer diagnosis (IP works but the domain fails = DNS). Service configuration is a battle of memorizing 1:1 directive mappings (DocumentRoot, SOA Serial, range, PermitRootLogin no, the exports whitespace trap) with exact spelling. For scripts, syntactic rigor (no spaces around =, spaces inside brackets, done < file) is vital, and in security, direction, options, --reload, and context decide pass or fail. Revisit the questions you missed until you can explain in words "what is wrong and why" for each choice. A lab exam is a test of writing exactly what you know.