Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 479658 - www-servers/apache fails to start with systemd: mod_ssl invalid mutex directory
Summary: www-servers/apache fails to start with systemd: mod_ssl invalid mutex directory
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Server (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Patrick Lauer
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-08-03 18:48 UTC by Mark R. Pariente
Modified: 2013-08-04 17:54 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Mark R. Pariente 2013-08-03 18:48:41 UTC
I have:

www-servers/apache 2.4.6-r2
sys-apps/systemd-206-r1

Trying to start apache2.service results in:

Aug 02 17:50:28 siegeengine systemd[1]: Starting The Apache HTTP Server...
Aug 02 17:50:28 siegeengine systemd[1]: Started The Apache HTTP Server.
Aug 02 17:50:29 siegeengine apache2[616]: AH00526: Syntax error on line 60 of /etc/apache2/modules.d/40_mod_ssl.conf:
Aug 02 17:50:29 siegeengine apache2[616]: Invalid Mutex directory in argument file:/run/apache_ssl_mutex
Aug 02 17:50:29 siegeengine systemd[1]: apache2.service: main process exited, code=exited, status=1/FAILURE
Aug 02 17:50:29 siegeengine apache2[636]: AH00526: Syntax error on line 60 of /etc/apache2/modules.d/40_mod_ssl.conf:
Aug 02 17:50:29 siegeengine apache2[636]: Invalid Mutex directory in argument file:/run/apache_ssl_mutex
Aug 02 17:50:29 siegeengine systemd[1]: apache2.service: control process exited, code=exited status=1
Aug 02 17:50:29 siegeengine systemd[1]: Unit apache2.service entered failed state.

The specified line in mod_ssl.conf looks like:

## Semaphore:
# Configure the path to the mutual exclusion semaphore the SSL engine uses
# internally for inter-process synchronization.
Mutex file:/run/apache_ssl_mutex ssl-cache
</IfDefine>

Manually creating the directory with 'mkdir /run/apache_ssl_mutex' allows apache2.service to start properly.

It looks like the openrc init script has the following:

checkconfig() {
        checkpath --directory /run/apache_ssl_mutex
        checkconfd || return 1

        ${APACHE2} ${APACHE2_OPTS} -t 1>/dev/null 2>&1

which would create this directory before trying to start apache. Looks like the systemd unit needs to do this as well?

Reproducible: Always




Portage 2.2.0_alpha192 (default/linux/amd64/13.0/desktop/gnome, gcc-4.7.3, glibc-2.17, 3.9.11-gentoo-r1 x86_64)
=================================================================
System uname: Linux-3.9.11-gentoo-r1-x86_64-Intel-R-_Core-TM-_i7_CPU_950_@_3.07GHz-with-gentoo-2.2
KiB Mem:    12281300 total,   8905840 free
KiB Swap:   16787888 total,  16787888 free
Timestamp of tree: Sat, 03 Aug 2013 17:00:02 +0000
ld GNU ld (GNU Binutils) 2.23.1
app-shells/bash:          4.2_p45
dev-java/java-config:     2.2.0::java-overlay
dev-lang/python:          2.7.5-r1, 3.2.5-r1, 3.3.2-r1
dev-util/cmake:           2.8.11.1
dev-util/pkgconfig:       0.28
sys-apps/baselayout:      2.2
sys-apps/openrc:          0.11.8
sys-apps/sandbox:         2.6-r1
sys-devel/autoconf:       2.13, 2.69
sys-devel/automake:       1.10.3, 1.11.6, 1.13.4, 1.14
sys-devel/binutils:       2.23.1
sys-devel/gcc:            4.7.3
sys-devel/gcc-config:     1.8
sys-devel/libtool:        2.4.2
sys-devel/make:           3.82-r4
sys-kernel/linux-headers: 3.9 (virtual/os-headers)
sys-libs/glibc:           2.17
Repositories: gentoo vmware mrpdaemon systemd multimedia steam-overlay java megacoffee sunrise Mark-s-local-portage-overlay
ACCEPT_KEYWORDS="amd64 ~amd64"
ACCEPT_LICENSE="*"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=native -O3 -pipe -fomit-frame-pointer"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/gnupg/qualified.txt /usr/share/maven-bin-3.1/conf"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-march=native -O3 -pipe -fomit-frame-pointer"
DISTDIR="/usr/portage/distfiles"
EMERGE_DEFAULT_OPTS="--autounmask=n"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-logs config-protect-if-modified distlocks ebuild-locks fixlafiles merge-sync news parallel-fetch preserve-libs protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync"
FFLAGS="-O2 -pipe"
GENTOO_MIRRORS="http://mirror.usu.edu/mirrors/gentoo/ http://gentoo.llarian.net/ http://gentoo.mirrors.easynews.com/linux/gentoo/ http://gentoo.gossamerhost.com http://gentoo.mirrors.hoobly.com/"
LANG="en_US.utf8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
MAKEOPTS="-j9 -l9"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/var/lib/layman/vmware /var/lib/layman/mrpdaemon /var/lib/layman/systemd /var/lib/layman/multimedia /var/lib/layman/steam /var/lib/layman/java /var/lib/layman/megacoffee /var/lib/layman/sunrise /usr/local/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="X a52 aac acl acpi alsa amd64 artworkextra avahi bash-completion berkdb bluray branding bzip2 cairo cdda cdr cleartype cli clutter colord cracklib crypt cscope cups cxx dbus devhelp device-mapper dri dts dv dvd dvdr eds emboss encode evo exif faac fam ffmpeg firefox flac fortran fuse gdbm gdu geoloc gif git glade glitz gnome gnome-keyring gnome-online-accounts gnutls gphoto2 gpm gstreamer gtk gtk2 gtk3 hostip iconv id3tag introspection ipv6 jabber jpeg lame lcms libnotify libsecret mad map mmx mmxext mng modules mp3 mp4 mpeg msn mudflap multilib nautilus ncurses networkmanager nls nptl ogg opengl openmp pam pango pcre pdf png policykit ppds pulseaudio python qt3support qt4 quicktime readline rtmp sdl session socialweb spell sse sse2 sse3 ssl ssse3 startup-notification svg systemd tcpd theora threads tiff tracker truetype udev udisks unicode upower usb v4l v4l2 vala vdpau vim-syntax vorbis vpx wav win32codecs wxwidgets x264 xcb xcomposite xml xv xvid xvmc zlib" ABI_X86="64" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias access_compat" CALLIGRA_FEATURES="kexi words flow plan sheets stage tables krita karbon braindump author" CAMERAS="*" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ubx" INPUT_DEVICES="keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LINGUAS="en" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php5-4" PYTHON_SINGLE_TARGET="python2_7" PYTHON_TARGETS="python2_7 python3_2" RUBY_TARGETS="ruby19 ruby18 ruby20" USERLAND="GNU" VIDEO_CARDS="nvidia" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  CPPFLAGS, CTARGET, INSTALL_MASK, LC_ALL, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, USE_PYTHON
Comment 1 Mike Gilbert gentoo-dev 2013-08-04 17:54:16 UTC
+  04 Aug 2013; Mike Gilbert <floppym@gentoo.org> files/apache.conf:
+  Create /run/apache_ssl_mutex directory via tmpfiles.d, bug 479658.

No revbump; I figure the number of people using apache with systemd is fairly small, so I don't want to force a rebuild on everyone.