F5N4 Sample Questions & Answers
Three tasks share the weighting almost equally: cycling the NGINX binary through stop, start, and reload actions, working through common basic use cases, and troubleshooting TLS security settings during an NGINX deployment.
Launch the full F5N4 simulator →Showing 6 of 12 free samples.
- Question 1IntermediateSelect 2
Demonstrate how to stop, start, and reload NGINX binary · Describe how to send signals to the NGINX process
You are writing a custom bash script to manage NGINX via POSIX signals directly, without using the
nginx -swrapper. Which TWO signals will trigger a graceful stop and a configuration reload, respectively? (Select TWO)Show answer & explanation
Correct answers: A, D
Sending a HUP signal to the NGINX master process triggers a configuration reload (equivalent to 'nginx -s reload').
Sending a QUIT signal to the NGINX master process initiates a graceful shutdown (equivalent to 'nginx -s quit').
- Question 2Beginner
Demonstrate how to stop, start, and reload NGINX binary · Describe the difference between a reload and a stop/start
True or False: Executing
nginx -s reloadimmediately terminates all active worker processes and drops in-flight client connections in order to quickly apply the new configuration.Show answer & explanation
Correct answer: B
False. A reload is specifically designed to be graceful. The master process starts new worker processes with the new configuration and sends a message to the old worker processes to shut down gracefully. The old workers stop accepting new connections but will continue to service their existing in-flight connections until they are completed.
- Question 3Advanced
Demonstrate how to stop, start, and reload NGINX binary · Describe how to send signals to the NGINX process
A Senior Linux Engineer is managing a critical NGINX edge proxy. During a routine audit, an automated script mistakenly executed
kill -9against the NGINX master process PID.The master process is now dead, but the NGINX worker processes are still running and actively handling client traffic. The engineer needs to recover the environment so that a new master process can be started with the current configuration, without dropping the traffic currently being handled by the orphaned worker processes.
Which sequence of actions represents the most appropriate troubleshooting step to resolve this specific state?
Show answer & explanation
Correct answer: B
If the master process is killed ungracefully (SIGKILL/-9), the worker processes become orphaned but continue to run and serve traffic. A new master process cannot adopt them, and 'nginx -s' commands will fail because the PID file points to a dead master. The correct recovery is to manually send SIGQUIT to the worker processes (allowing them to finish in-flight requests gracefully) and then start the NGINX service normally.
- Question 4Intermediate
Demonstrate how to stop, start, and reload NGINX binary · Describe how to send signals to the NGINX process
A system administrator has configured a custom log rotation script for NGINX. After the script moves
access.logtoaccess.log.1, they notice that NGINX continues writing new log entries to the renamedaccess.log.1file instead of creating a newaccess.log.Which command must the script execute to instruct NGINX to close the old log files and open new ones?
Show answer & explanation
Correct answer: D
The 'nginx -s reopen' command (or sending the USR1 signal to the master process) instructs NGINX to re-open its log files. Because NGINX keeps the file descriptor open, it will continue writing to the renamed file until it receives this signal. Reloading would also work but is heavier as it spawns new worker processes, whereas reopening just rotates the logs.
- Question 5Beginner
Demonstrate how to stop, start, and reload NGINX binary · Describe how to test a new configuration before applying it
Before applying a new configuration to a production NGINX server, what is the best practice command to ensure there are no syntax errors in the
nginx.conffile?Show answer & explanation
Correct answer: A
The 'nginx -t' command tests the configuration for correct syntax and ensures all referenced files and paths exist and are accessible. It is a critical best practice to run this before executing 'nginx -s reload' to prevent NGINX from failing to apply a broken configuration.
- Question 6Intermediate
Demonstrate how to stop, start, and reload NGINX binary · Describe how to send signals to the NGINX process
An administrator is managing an NGINX container where the
nginxbinary is not in the system path, but they need to reload the configuration gracefully. They know the PID of the master process is 1. Which command will successfully trigger a configuration reload?Show answer & explanation
Correct answer: D
Sending the SIGHUP (HUP) signal to the NGINX master process triggers a graceful configuration reload. This is exactly what 'nginx -s reload' does under the hood. In containerized environments where the master process runs as PID 1, 'kill -HUP 1' is a standard way to reload the config.
Ready for the real thing?
The full F5N4 simulator has every exam-style question, timed mode, and instant scoring.