xref: /lighttpd1.4/doc/initscripts.txt (revision 9e1acfa6)
1* lighttpd responds to the following signals:
2
3SIGTERM - shut down immediately (terminate existing connections, then exit)
4SIGINT  - shut down gracefully  (serve existing connections, then exit)
5SIGUSR1 - reload gracefully     (serve existing connections, then reload config)
6SIGHUP  - re-open log files     (NOTE: does not reload lighttpd configuration)
7
8(Note: SIGUSR1 behavior is available in lighttpd 1.4.46 and later)
9
10
11* lighttpd graceful restart
12
13https://blog.lighttpd.net/articles/2005/09/02/graceful-restart/
14The current recommended way to reload lighttpd config is to gracefully stop
15and then to restart lighttpd.
16
17With lighttpd 1.4.46 and later, SIGUSR1 is the recommended method to gracefully
18handle configuration reloads and log rotation, though a graceful stop and then
19restart of lighttpd is still required for lighttpd configurations which chroot.
20
21
22* lighttpd initscripts
23
24Depending on the operating system and distribution brand, there are many
25ways to set up lighttpd to run as a daemon when the system starts up, and
26to send signals to lighttpd for start/stop/restart/etc.
27
28Rather than attempting to maintain scripts for an unknown number of distros,
29here are links to a few, which can be used as examples.
30
31Arch:
32https://github.com/archlinux/svntogit-packages/tree/packages/lighttpd/trunk
33
34Debian:
35https://salsa.debian.org/debian/lighttpd
36
37Fedora:
38https://src.fedoraproject.org/rpms/lighttpd/tree/rawhide
39
40Gentoo:
41https://gitweb.gentoo.org/repo/gentoo.git/tree/www-servers/lighttpd/files
42
43openSUSE:
44https://build.opensuse.org/package/show/server:http/lighttpd
45
46sample systemd unit script: doc/systemd/lighttpd.service
47
48Additional, updated information may be found at
49https://redmine.lighttpd.net/projects/lighttpd/wiki/InstallFromSource
50