Results 1 to 8 of 8

Thread: Apache2 and sysvinit vs systemd

  1. #1

    Default Apache2 and sysvinit vs systemd

    I am unfamiliar with sysvinit and systemd but after upgrading to 12.1 I find that apache no longer starts. The workaround is apparently install sysvinit-init, which yast tells me requires deinstallation of systemd-sysvinit. Is that safe? Won't that break new stuff that was installed with 12.1?

  2. #2
    Join Date
    Jun 2008
    Location
    UTC+10
    Posts
    9,686
    Blog Entries
    4

    Default Re: Apache2 and sysvinit vs systemd

    You don't need to do that. I don't have sysvinit-init installed and I can boot using sysv. Just add init=/sbin/sysvinit to your boot parameters either temporarily at GRUB or permanently by editing /boot/grub/menu.lst.

    However I recall that I did not have problems with systemd and Apache, but I can't be sure because I switched to sysv, because of other issues. Make sure you have the latest updates, there was a new systemd package recently.

  3. #3

    Default Re: Apache2 and sysvinit vs systemd

    Thanks for your reply. I don't know what this does, but I added init=/sbin/sysvinit to menu.lst and rebooted. Now I get:

    Code:
    > sudo /etc/init.d/apache2 start
    Starting httpd2 (prefork) Inconsistency detected by ld.so: dl-open.c: 596: _dl_open: Assertion `_dl_debug_initialize (0, args.nsid)->r_state == RT_CONSISTENT' failed!
    
    The command line was:
    /usr/sbin/httpd2-prefork -f /etc/apache2/httpd.conf
                                                                                    failed
    It looks like the sysvinit parameter worked, but there's something else wrong? On preliminary research I can't find anything about this new error...I rarely see assertions fail straight out of C code from a script launch. Either way, pre-12.1, apache launched correctly, but I don't know if this new error has anything to do with systemd or not.

  4. #4
    Join Date
    Jun 2008
    Location
    UTC+10
    Posts
    9,686
    Blog Entries
    4

    Default Re: Apache2 and sysvinit vs systemd

    My 12.1 Apache runs fine under sysv (and I think it did under systemd). Knowing how services work under Linux, I seriously doubt if the service manager has anything to do with this error. It feels more like you have missing Apache components or corrupted files. I would suggest reinstalling the entire LAMP pattern, then applying all updates, just in case there was a problem with the Apache released on the master media. Actually if you haven't applied all updates yet, you should try this first, since it's easy to do.

    You might also try disabling apparmor, that caused problems with a couple of other services I run.

  5. #5

    Default Re: Apache2 and sysvinit vs systemd

    Fixed it! It was indeed a problem with Apache configuration, apparently caused by upgrading from 11.4 to 12.1. If anyone knows the best place to report this, please let me know.

    When I went to uninstall PHP5 I found it was mysteriously not present. I reinstalled it and got the same error but noticed that PHP5 requires Apache2 prefork (IIRC) and my software manager showed several versions of Apache2 installed, not just prefork (the others being event, and threaded, or something along those lines). I uninstalled all of them and reinstalled PHP5, letting the package manager resolve the apache dependencies, and it worked. My httpd configs are totally borked now tho :/

    [Edit for future reference: my configs were borked because reinstalling apache overwrote apache settings files. In my case the relevant files turned out to be /etc/apache2/listen.conf, and the package manager was nice enough to save the old copy in /etc/apache2/listen.conf.rpmsave, so I was able to easily reinstate my server config.]

    Thanks for your help guys.

  6. #6
    Join Date
    Jun 2008
    Location
    Wales, MA
    Posts
    486

    Default Re: Apache2 and sysvinit vs systemd

    I had many services that were not starting properly under systemd. I didn't look into why. how, or anything else. I simply installed sysvinit, it removed systemd and all has been working flawlessly for me.

    mythbackend, mysql, apache..................would not start under systemd, they all work perfectly under sysvinit

  7. #7
    Join Date
    Feb 2009
    Location
    Spain
    Posts
    25,547

    Default Re: Apache2 and sysvinit vs systemd

    On 2012-01-11 11:36, sp3wn wrote:
    > Fixed it! It was indeed a problem with Apache configuration, apparently
    > caused by upgrading from 11.4 to 12.1. If anyone knows the best place
    > to report this, please let me know.


    Did you revise the configuration files .rpmnew and .rpmsave after the
    upgrade? There is a long list in "/var/adm/rpmconfigcheck" of files you
    have to manually review after upgrading.

    If you did this properly, and still you had a bug, then the place to report
    is Bugzilla, obviously.

    --
    Cheers / Saludos,

    Carlos E. R.
    (from 11.4 x86_64 "Celadon" at Telcontar)

  8. #8

    Default Re: Apache2 and sysvinit vs systemd

    Quote Originally Posted by brucecadieux View Post
    I had many services that were not starting properly under systemd. I didn't look into why. how, or anything else. I simply installed sysvinit, it removed systemd and all has been working flawlessly for me.

    mythbackend, mysql, apache..................would not start under systemd, they all work perfectly under sysvinit
    Thanks to HowToForge I found an idea to start Apache and Postfix under systemd:
    Code:
    systemctl enable apache2
    systemctl enable postfix
    These commands (run once) create some links that seem to be necessary for perfect starting these services.

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •