Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.debian.user > #197886
| From | john doe <johndoe65534@mail.com> |
|---|---|
| Newsgroups | linux.debian.user |
| Subject | Re: apache not running at boot |
| Date | 2018-07-22 15:20 +0200 |
| Message-ID | <wemrf-1MF-5@gated-at.bofh.it> (permalink) |
| References | (15 earlier) <we0qK-4j7-1@gated-at.bofh.it> <we29c-5qx-3@gated-at.bofh.it> <we7BT-rl-1@gated-at.bofh.it> <wefSN-5Su-5@gated-at.bofh.it> <wem7T-1pL-11@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On 7/22/2018 2:57 PM, Dave wrote: > > > On 07/22/2018 02:14 AM, john doe wrote: >> On 7/21/2018 11:22 PM, Dave wrote: >>> >>> >>> On 07/21/2018 11:38 AM, john doe wrote: >>>> On 7/21/2018 3:46 PM, Dave wrote: >>>>> >>>>> >>>>> On 07/21/2018 08:42 AM, mick crane wrote: >>>>>> On 2018-07-21 13:00, john doe wrote: >>>>>>> On 7/21/2018 11:21 AM, mick crane wrote: >>>>>>>> On 2018-07-21 09:56, mick crane wrote: >>>>>>>>> On 2018-07-21 09:39, john doe wrote: >>>>>>>>> >>>>>>>>>>> my interfaces file is identical and apache starts OK so it is >>>>>>>>>>> probably something else. >>>>>>>>>>> in /lib/systemd/system/apache2.target >>>>>>>>>>> >>>>>>>>>>> do you have the "after" bit >>>>>>>>>>> >>>>>>>>>>> 1 [Unit] >>>>>>>>>>> 2 Description=The Apache HTTP Server >>>>>>>>>>> 3 After=network.target remote-fs.target nss-lookup.target >>>>>>>>>>> >>>>>>>>>> >>>>>>>>>> Or looking if "NetworkManager-wait-online.service" is enabled. >>>>>>>>>> For systemd-networkd that is : >>>>>>>>>> "systemd-networkd-wait-online.service". >>>>>>>>>> >>>>>>>>>> https://www.freedesktop.org/wiki/Software/systemd/NetworkTarget/ >>>>>>>>>> >>>>>>>>>> If your '/etc/network/interfaces' file is empty with the >>>>>>>>>> exception of >>>>>>>>>> the 'lo' interface, your interfaces are probably handled by an >>>>>>>>>> other >>>>>>>>>> "program" and you need to determine which "program" is >>>>>>>>>> responsible for >>>>>>>>>> your interfaces. >>>>>>>>> >>>>>>>>> I'm quite cheerful as everything seems to be working but it >>>>>>>>> wouldn't >>>>>>>>> hurt to find out and may assist OP. >>>>>>> >>>>>>> Appologies for the confusion, I read your answer and think I >>>>>>> could add >>>>>>> to it but was not in anycase directed towards you! :) >>>>>>> >>>>>>> Yes, my comment was for the OP (taking into account other answers he >>>>>>> has sent to the list). >>>>>> >>>>>> looking at links you posted if I was OP I would probably try adding >>>>>> >>>>>> After=network-online.target >>>>>> Wants=network-online.target >>>>>> >>>>>> to /lib/systemd/system/apache2.target >>>>>> >>>>>> and see if apache starts at boot >>>>>> >>>>>> mick >>>>> >>>>> hello - my Deb 9.4 / Apache 2.4 has no file called apache2.target, >>>>> however there is a /lib/systemd/system/apache2.service file:: the >>>>> contents as follows >>>>> Description=The Apache HTTP Server >>>>> After=network.target remote-fs.target nss-lookup.target >>>>> >>>>> [Service] >>>>> Type=forking >>>>> Environment=APACHE_STARTED_BY_SYSTEMD=true >>>>> ExecStart=/usr/sbin/apachectl start >>>>> ExecStop=/usr/sbin/apachectl stop >>>>> ExecReload=/usr/sbin/apachectl graceful >>>>> PrivateTmp=true >>>>> Restart=on-abort >>>>> >>>>> [Install] >>>>> WantedBy=multi-user.target >>>>> root@culser:/lib/systemd/system# >>>>> >>>>> >>>> >>>> Ok -- lets try: >>>> >>>> Undo any changes in '/etc/network/interfaces'. >>>> >>>> As root: >>>> >>>> $ mkdir -p /etc/systemd/apache2.d >>>> $ printf "%s\n%s\n" "After=network-online.target" >>>> "Wants=network-online.target" > /etc/systemd/apache2.d/boot-args.conf >>>> >>>> Then try: >>>> >>>> $ systemctl enable NetworkManager-wait-online >>>> $ systemctl reboot >>>> >>>> If it is not working: >>>> >>>> $ systemctl disable NetworkManager-wait-online.service >>>> $ systemctl enable systemd-networkd-wait-online.service >>>> $ systemctl reboot >>>> >>>> >>>> Note that the lines starting with a '$' are commands and should be >>>> entered on one line. >>>> >>>> https://www.freedesktop.org/wiki/Software/systemd/NetworkTarget/ >>>> https://www.freedesktop.org/software/systemd/man/systemd.unit.html >>>> >>> >>> I tried both those options, apache2 does not start at boot. >>> the contents of /boot-args.conf is as follows: >>> >>> After=network-online.target >>> Wants=network-online.target >>> >>> To check if apache is running after boot i check the >>> /var/run/apache2.pid file is present. it is not present. >>> I also use ps -e | grep apache and nothing is returned. >>> >>> >>> >>> >>> >> >> After a reboot what output do you get: >> >> $ systemctl status apache2 >> > > after boot or reboot the systemctl cmd prints the following: > > ● apache2.service - The Apache HTTP Server > Loaded: loaded (/lib/systemd/system/apache2.service; enabled; vendor > preset: enabled) > Active: failed (Result: exit-code) since Sun 2018-07-22 08:55:17 > EDT; 51s ago > Process: 588 ExecStart=/usr/sbin/apachectl start (code=exited, > status=1/FAILURE) > > Jul 22 08:55:17 culser systemd[1]: Starting The Apache HTTP Server... > Jul 22 08:55:17 culser apachectl[588]: (99)Cannot assign requested > address: AH00072: make_sock: coul > Jul 22 08:55:17 culser apachectl[588]: no listening sockets available, > shutting down > Jul 22 08:55:17 culser apachectl[588]: AH00015: Unable to open logs > Jul 22 08:55:17 culser apachectl[588]: Action 'start' failed. > Jul 22 08:55:17 culser apachectl[588]: The Apache error log may have > more information. > Jul 22 08:55:17 culser systemd[1]: apache2.service: Control process > exited, code=exited status=1 > Jul 22 08:55:17 culser systemd[1]: Failed to start The Apache HTTP Server. > Jul 22 08:55:17 culser systemd[1]: apache2.service: Unit entered failed > state. > Jul 22 08:55:17 culser systemd[1]: apache2.service: Failed with result > 'exit-code'. > > > Is it properly starting if you do?: $ systemctl start apache2 $/usr/sbin/apachectl start If you get any errors it is most likely that the issue lies in Apache's configuration. -- John Doe
Back to linux.debian.user | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Re: apache not running at boot Greg Wooledge <wooledg@eeg.ccf.org> - 2018-07-18 15:40 +0200
Re: apache not running at boot Jonathan Dowland <jmtd@debian.org> - 2018-07-18 16:20 +0200
Re: apache not running at boot Dave <debiantechquestions@gmx.com> - 2018-07-18 22:50 +0200
Re: apache not running at boot Greg Wooledge <wooledg@eeg.ccf.org> - 2018-07-18 23:00 +0200
Re: apache not running at boot Dave <debiantechquestions@gmx.com> - 2018-07-19 03:00 +0200
Re: apache not running at boot mick crane <mick.crane@gmail.com> - 2018-07-19 08:30 +0200
Re: apache not running at boot Joe <joe@jretrading.com> - 2018-07-19 09:00 +0200
Re: apache not running at boot Curt <curty@free.fr> - 2018-07-19 10:30 +0200
Re: apache not running at boot john doe <johndoe65534@mail.com> - 2018-07-19 11:30 +0200
Re: apache not running at boot john doe <johndoe65534@mail.com> - 2018-07-20 10:40 +0200
Re: apache not running at boot Greg Wooledge <wooledg@eeg.ccf.org> - 2018-07-25 14:40 +0200
Re: apache not running at boot Dave <debiantechquestions@gmx.com> - 2018-07-20 01:00 +0200
Re: apache not running at boot Dave <debiantechquestions@gmx.com> - 2018-07-21 06:00 +0200
Re: apache not running at boot メット <mett@pmars.jp> - 2018-07-21 06:50 +0200
Re: apache not running at boot mick crane <mick.crane@gmail.com> - 2018-07-21 09:00 +0200
Re: apache not running at boot john doe <johndoe65534@mail.com> - 2018-07-21 10:40 +0200
Re: apache not running at boot mick crane <mick.crane@gmail.com> - 2018-07-21 11:00 +0200
Re: apache not running at boot mick crane <mick.crane@gmail.com> - 2018-07-21 11:30 +0200
Re: apache not running at boot john doe <johndoe65534@mail.com> - 2018-07-21 14:10 +0200
Re: apache not running at boot mick crane <mick.crane@gmail.com> - 2018-07-21 14:50 +0200
Re: apache not running at boot Dave <debiantechquestions@gmx.com> - 2018-07-21 15:50 +0200
Re: apache not running at boot mick crane <mick.crane@gmail.com> - 2018-07-21 16:10 +0200
Re: apache not running at boot john doe <johndoe65534@mail.com> - 2018-07-21 17:40 +0200
Re: apache not running at boot Dave <debiantechquestions@gmx.com> - 2018-07-21 23:30 +0200
Re: apache not running at boot john doe <johndoe65534@mail.com> - 2018-07-22 08:20 +0200
Re: apache not running at boot Dave <debiantechquestions@gmx.com> - 2018-07-22 15:00 +0200
Re: apache not running at boot john doe <johndoe65534@mail.com> - 2018-07-22 15:20 +0200
Re: apache not running at boot Dave <debiantechquestions@gmx.com> - 2018-07-22 16:10 +0200
Re: apache not running at boot john doe <johndoe65534@mail.com> - 2018-07-22 16:40 +0200
Re: apache not running at boot Dave <debiantechquestions@gmx.com> - 2018-07-22 17:00 +0200
Re: apache not running at boot john doe <johndoe65534@mail.com> - 2018-07-22 17:00 +0200
Re: apache not running at boot Dave <debiantechquestions@gmx.com> - 2018-07-22 17:20 +0200
Re: apache not running at boot mick crane <mick.crane@gmail.com> - 2018-07-22 17:30 +0200
Re: apache not running at boot Cindy-Sue Causey <butterflybytes@gmail.com> - 2018-07-22 19:10 +0200
Re: apache not running at boot Dave <debiantechquestions@gmx.com> - 2018-07-23 00:20 +0200
Re: apache not running at boot mick crane <mick.crane@gmail.com> - 2018-07-23 00:40 +0200
Re: apache not running at boot mick crane <mick.crane@gmail.com> - 2018-07-23 01:00 +0200
Re: apache not running at boot john doe <johndoe65534@mail.com> - 2018-07-23 08:30 +0200
Re: apache not running at boot john doe <johndoe65534@mail.com> - 2018-07-23 13:20 +0200
Re: apache not running at boot mick crane <mick.crane@gmail.com> - 2018-07-23 22:00 +0200
Re: apache not running at boot Joe <joe@jretrading.com> - 2018-07-23 09:50 +0200
Re: apache not running at boot john doe <johndoe65534@mail.com> - 2018-07-23 10:30 +0200
Re: apache not running at boot john doe <johndoe65534@mail.com> - 2018-07-22 17:40 +0200
Re: apache not running at boot john doe <johndoe65534@mail.com> - 2018-07-22 19:00 +0200
Re: apache not running at boot mick crane <mick.crane@gmail.com> - 2018-07-22 20:00 +0200
Re: apache not running at boot Dave <debiantechquestions@gmx.com> - 2018-07-25 15:10 +0200
Re: apache not running at boot john doe <johndoe65534@mail.com> - 2018-07-25 17:00 +0200
Re: apache not running at boot mick crane <mick.crane@gmail.com> - 2018-07-25 19:20 +0200
Re: apache not running at boot john doe <johndoe65534@mail.com> - 2018-07-25 20:00 +0200
Re: apache not running at boot Curt <curty@free.fr> - 2018-07-22 17:40 +0200
Re: apache not running at boot Dave <debiantechquestions@gmx.com> - 2018-07-21 16:00 +0200
Re: apache not running at boot Curt <curty@free.fr> - 2018-07-21 17:50 +0200
Re: apache not running at boot Dave <debiantechquestions@gmx.com> - 2018-07-21 23:10 +0200
csiph-web