Path: blob/main/xml/en/docs/faq/daemon_master_process_off.xml
1 views
<!--1Copyright (C) Nginx, Inc.2-->34<!DOCTYPE article SYSTEM "../../../../dtd/article.dtd">56<article name="Can I run nginx with “daemon off” or7“master_process off” settings8in a production environment?"9link="/en/docs/faq/daemon_master_process_off.html"10lang="en"11rev="1">1213<section>1415<para>16<initial>Q:</initial>17Can I run nginx with "daemon off" or "master_process off" settings18in a production environment?19</para>2021<para>22 23</para>2425<para>26<initial>A:</initial>27First of all, both "daemon on|off" and "master_process on|off" directives were28intended to be used primarily for nginx code development.29</para>3031<para>32While many people use "daemon off" in production it wasn’t really meant for33that. Since version 1.0.9 it is now quite safe to run nginx in production34with "daemon off", though. Bear in mind that non-stop upgrade is not an35option with "daemon off".36</para>3738<para>39In a development environment, using "master_process off", nginx can run in40the foreground without the master process and can be terminated simply41with ^C (SIGINT). This is somewhat similar to running Apache with42an 'X' command-line option. However you should NEVER run nginx in production43with "master_process off".44</para>4546</section>4748</article>495051