<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
{font-family:"Cambria Math";
panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
{font-family:"Trebuchet MS";
panose-1:2 11 6 3 2 2 2 2 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0in;
margin-bottom:.0001pt;
font-size:11.0pt;
font-family:"Calibri",sans-serif;}
span.EmailStyle17
{mso-style-type:personal-compose;
font-family:"Calibri",sans-serif;
color:windowtext;}
.MsoChpDefault
{mso-style-type:export-only;}
@page WordSection1
{size:8.5in 11.0in;
margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
{page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="EN-US" link="#0563C1" vlink="#954F72">
<div class="WordSection1">
<p class="MsoNormal">I'm using a nginx 1.18.0 and 1.16.1 and when i perform a systemctl restart nginx, it does not actually reload the configs. nginx -s reload does not work either. Am i missing a configure flag that allows this to work properly?<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<div style="mso-element:para-border-div;border:none;border-bottom:solid windowtext 1.0pt;padding:0in 0in 1.0pt 0in">
<p class="MsoNormal" style="border:none;padding:0in">Here is my nginx -V<o:p></o:p></p>
<p class="MsoNormal" style="border:none;padding:0in"><o:p> </o:p></p>
</div>
<p class="MsoNormal">built by gcc 5.4.0 20160609 (Ubuntu 5.4.0-6ubuntu1~16.04.12)<o:p></o:p></p>
<p class="MsoNormal">built with OpenSSL 1.1.1g 21 Apr 2020<o:p></o:p></p>
<p class="MsoNormal">TLS SNI support enabled<o:p></o:p></p>
<div style="mso-element:para-border-div;border:none;border-bottom:solid windowtext 1.0pt;padding:0in 0in 1.0pt 0in">
<p class="MsoNormal" style="border:none;padding:0in">configure arguments: --prefix=/usr/local/nginx --modules-path=/usr/lib/nginx/modules --http-client-body-temp-path=/var/cache/nginx/client_temp --http-proxy-temp-path=/var/cache/nginx/proxy_temp --http-fastcgi-temp-path=/var/cache/nginx/fastcgi_temp
--http-uwsgi-temp-path=/var/cache/nginx/uwsgi_temp --http-scgi-temp-path=/var/cache/nginx/scgi_temp --with-threads --with-file-aio --with-http_ssl_module --with-http_v2_module --with-http_stub_status_module --with-http_gunzip_module --with-http_gzip_static_module
--with-http_stub_status_module --with-http_realip_module --with-compat --with-pcre=../pcre-8.44 --with-pcre-jit --with-zlib=../zlib-1.2.11 --with-openssl=../openssl-1.1.1g --with-openssl-opt=no-nextprotoneg --add-module=../ngx_cache_purge-2.3<o:p></o:p></p>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
<div style="mso-element:para-border-div;border:none;border-bottom:solid windowtext 1.0pt;padding:0in 0in 1.0pt 0in">
<p class="MsoNormal" style="border:none;padding:0in">Here is my systemd nginx.service<o:p></o:p></p>
<p class="MsoNormal" style="border:none;padding:0in"><o:p> </o:p></p>
</div>
<p class="MsoNormal">[Unit]<o:p></o:p></p>
<p class="MsoNormal">Description=The NGINX HTTP and reverse proxy server<o:p></o:p></p>
<p class="MsoNormal">After=syslog.target network.target remote-fs.target nss-lookup.target<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">[Service]<o:p></o:p></p>
<p class="MsoNormal">Type=forking<o:p></o:p></p>
<p class="MsoNormal">PIDFile=/usr/local/nginx/logs/nginx.pid<o:p></o:p></p>
<p class="MsoNormal">ExecStartPre=/usr/local/sbin/nginx -t -q -g 'daemon on; master_process on;'<o:p></o:p></p>
<p class="MsoNormal">ExecStart=/usr/local/sbin/nginx -g 'daemon on; master_process on;'<o:p></o:p></p>
<p class="MsoNormal">ExecReload=/usr/local/sbin/nginx -g 'daemon on; master_process on;' -s reload<o:p></o:p></p>
<p class="MsoNormal">ExecStop=/bin/kill -s QUIT $MAINPID<o:p></o:p></p>
<p class="MsoNormal">PrivateTmp=true<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">[Install]<o:p></o:p></p>
<div style="mso-element:para-border-div;border:none;border-bottom:solid windowtext 1.0pt;padding:0in 0in 1.0pt 0in">
<p class="MsoNormal" style="border:none;padding:0in">WantedBy=multi-user.target<o:p></o:p></p>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">I've got a workaround, which i spawn a 2nd process and wait then kill the old, but what is the deal?<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<div style="mso-element:para-border-div;border-top:solid windowtext 1.0pt;border-left:none;border-bottom:solid windowtext 1.0pt;border-right:none;padding:1.0pt 0in 1.0pt 0in">
<p class="MsoNormal" style="border:none;padding:0in">ExecReload=/bin/bash -c "/bin/kill -USR2 $MAINPID && /bin/sleep 5 && /bin/kill -WINCH $MAINPID && /bin/sleep 5 && /bin/kill -QUIT $MAINPID"<o:p></o:p></p>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">I appreciate the help! Thanks.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal"><b><span style="font-family:"Trebuchet MS",sans-serif;color:#9F3400">Zach</span></b><o:p></o:p></p>
</div>
</body>
</html>