Workaround of race condition between systemd and nginx.
Gena Makhomed
gmm at csdoc.com
Wed Dec 30 13:45:48 UTC 2015
# HG changeset patch
# User Gena Makhomed <gmm at csdoc.com>
# Date 1451482795 18000
# Wed Dec 30 08:39:55 2015 -0500
# Node ID a340d271b3ffa51c0396a5afc5270cb02b701204
# Parent 1073d7e4e430ddb53b603d151e1a403d10aa420b
Workaround of race condition between systemd and nginx.
Just replace network.target with network-online.target in systemd unit
files.
More details:
http://www.freedesktop.org/wiki/Software/systemd/NetworkTarget/
diff -r 1073d7e4e430 -r a340d271b3ff rpm/SOURCES/nginx-debug.service
--- a/rpm/SOURCES/nginx-debug.service Wed Dec 09 18:31:08 2015 +0300
+++ b/rpm/SOURCES/nginx-debug.service Wed Dec 30 08:39:55 2015 -0500
@@ -1,7 +1,7 @@
[Unit]
Description=nginx - high performance web server
Documentation=http://nginx.org/en/docs/
-After=network.target remote-fs.target nss-lookup.target
+After=network-online.target remote-fs.target nss-lookup.target
[Service]
Type=forking
diff -r 1073d7e4e430 -r a340d271b3ff rpm/SOURCES/nginx.service
--- a/rpm/SOURCES/nginx.service Wed Dec 09 18:31:08 2015 +0300
+++ b/rpm/SOURCES/nginx.service Wed Dec 30 08:39:55 2015 -0500
@@ -1,7 +1,7 @@
[Unit]
Description=nginx - high performance web server
Documentation=http://nginx.org/en/docs/
-After=network.target remote-fs.target nss-lookup.target
+After=network-online.target remote-fs.target nss-lookup.target
[Service]
Type=forking
-------------- next part --------------
# HG changeset patch
# User Gena Makhomed <gmm at csdoc.com>
# Date 1451482795 18000
# Wed Dec 30 08:39:55 2015 -0500
# Node ID a340d271b3ffa51c0396a5afc5270cb02b701204
# Parent 1073d7e4e430ddb53b603d151e1a403d10aa420b
Workaround of race condition between systemd and nginx.
Just replace network.target with network-online.target in systemd unit files.
More details: http://www.freedesktop.org/wiki/Software/systemd/NetworkTarget/
diff -r 1073d7e4e430 -r a340d271b3ff rpm/SOURCES/nginx-debug.service
--- a/rpm/SOURCES/nginx-debug.service Wed Dec 09 18:31:08 2015 +0300
+++ b/rpm/SOURCES/nginx-debug.service Wed Dec 30 08:39:55 2015 -0500
@@ -1,7 +1,7 @@
[Unit]
Description=nginx - high performance web server
Documentation=http://nginx.org/en/docs/
-After=network.target remote-fs.target nss-lookup.target
+After=network-online.target remote-fs.target nss-lookup.target
[Service]
Type=forking
diff -r 1073d7e4e430 -r a340d271b3ff rpm/SOURCES/nginx.service
--- a/rpm/SOURCES/nginx.service Wed Dec 09 18:31:08 2015 +0300
+++ b/rpm/SOURCES/nginx.service Wed Dec 30 08:39:55 2015 -0500
@@ -1,7 +1,7 @@
[Unit]
Description=nginx - high performance web server
Documentation=http://nginx.org/en/docs/
-After=network.target remote-fs.target nss-lookup.target
+After=network-online.target remote-fs.target nss-lookup.target
[Service]
Type=forking
More information about the nginx-devel
mailing list