apache2 server exit error runtimedir

Bug #2093265 reported by thomas platzek
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
apache2 (Ubuntu)
Expired
Undecided
Unassigned

Bug Description

apache2 server exit error runtimedir

sudo systemctl status apache2
[sudo] Passwort für tomate:
● apache2.service - The Apache HTTP Server
   Loaded: loaded (/lib/systemd/system/apache2.service; enabled; vendor preset: enabled)
  Drop-In: /lib/systemd/system/apache2.service.d
           └─apache2-systemd.conf
   Active: failed (Result: exit-code) since Wed 2025-01-08 16:35:57 CET; 37min ago
  Process: 2770 ExecStart=/usr/sbin/apachectl start (code=exited, status=1/FAILURE)

Jan 08 16:35:57 tomate-R530-R730 systemd[1]: Starting The Apache HTTP Server...
Jan 08 16:35:57 tomate-R530-R730 apachectl[2770]: apache2: Syntax error on line 80 of /etc/apache2/apache2.conf: DefaultRuntimeDir takes one argument, Common directory for run-time files (shar
Jan 08 16:35:57 tomate-R530-R730 apachectl[2770]: Action 'start' failed.
Jan 08 16:35:57 tomate-R530-R730 apachectl[2770]: The Apache error log may have more information.
Jan 08 16:35:57 tomate-R530-R730 systemd[1]: apache2.service: Control process exited, code=exited status=1
Jan 08 16:35:57 tomate-R530-R730 systemd[1]: apache2.service: Failed with result 'exit-code'.
Jan 08 16:35:57 tomate-R530-R730 systemd[1]: Failed to start The Apache HTTP Server.

ProblemType: Bug
DistroRelease: Ubuntu 18.04
Package: apache2 2.4.29-1ubuntu4.27
ProcVersionSignature: Ubuntu 4.15.0-213.224-generic 4.15.18
Uname: Linux 4.15.0-213-generic i686
000-default.conf: Error: [Errno 40] Zu viele Ebenen aus symbolischen Links: '/etc/apache2/sites-enabled/000-default.conf'
Apache2ConfdDirListing: False
Apache2Modules:
 Error: command ['pkexec', '/usr/sbin/apachectl', '-D DUMP_MODULES'] failed with exit code 1: apache2: Syntax error on line 80 of /etc/apache2/apache2.conf: DefaultRuntimeDir takes one argument, Common directory for run-time files (shared memory, locks, etc.)
 Action '-D DUMP_MODULES' failed.
 The Apache error log may have more information.
ApportVersion: 2.20.9-0ubuntu7.29
Architecture: i386
CurrentDesktop: XFCE
Date: Wed Jan 8 16:57:36 2025
InstallationDate: Installed on 2024-03-07 (307 days ago)
InstallationMedia: Xubuntu 18.04.1 LTS "Bionic Beaver" - Release i386 (20180725)
SourcePackage: apache2
UpgradeStatus: No upgrade log present (probably fresh install)
error.log:

modified.conffile..etc.apache2.apache2.conf: [modified]
mtime.conffile..etc.apache2.apache2.conf: 2025-01-08T16:29:03.384321
nextcloud.conf: Error: [Errno 40] Zu viele Ebenen aus symbolischen Links: '/etc/apache2/sites-enabled/nextcloud.conf'

Revision history for this message
thomas platzek (tomplatzek48) wrote :
Revision history for this message
Bryce Harrington (bryce) wrote :

Please attach your /etc/apache2/apache2.conf; from the error message you posted it sounds like it has a syntax error.

Changed in apache2 (Ubuntu):
status: New → Incomplete
Revision history for this message
thomas platzek (tomplatzek48) wrote :
Download full text (7.1 KiB)

# This is the main Apache server configuration file. It contains the
# configuration directives that give the server its instructions.
# See http://httpd.apache.org/docs/2.4/ for detailed information about
# the directives and /usr/share/doc/apache2/README.Debian about Debian specific
# hints.
#
#
# Summary of how the Apache 2 configuration works in Debian:
# The Apache 2 web server configuration in Debian is quite different to
# upstream's suggested way to configure the web server. This is because Debian's
# default Apache2 installation attempts to make adding and removing modules,
# virtual hosts, and extra configuration directives as flexible as possible, in
# order to make automating the changes and administering the server as easy as
# possible.

# It is split into several files forming the configuration hierarchy outlined
# below, all located in the /etc/apache2/ directory:
#
# /etc/apache2/
# |-- apache2.conf
# | `-- ports.conf
# |-- mods-enabled
# | |-- *.load
# | `-- *.conf
# |-- conf-enabled
# | `-- *.conf
# `-- sites-enabled
# `-- *.conf
#
#
# * apache2.conf is the main configuration file (this file). It puts the pieces
# together by including all remaining configuration files when starting up the
# web server.
#
# * ports.conf is always included from the main configuration file. It is
# supposed to determine listening ports for incoming connections which can be
# customized anytime.
#
# * Configuration files in the mods-enabled/, conf-enabled/ and sites-enabled/
# directories contain particular configuration snippets which manage modules,
# global configuration fragments, or virtual host configurations,
# respectively.
#
# They are activated by symlinking available configuration files from their
# respective *-available/ counterparts. These should be managed by using our
# helpers a2enmod/a2dismod, a2ensite/a2dissite and a2enconf/a2disconf. See
# their respective man pages for detailed information.
#
# * The binary is called apache2. Due to the use of environment variables, in
# the default configuration, apache2 needs to be started/stopped with
# /etc/init.d/apache2 or apache2ctl. Calling /usr/bin/apache2 directly will not
# work with the default configuration.

# Global configuration
#

#
# ServerRoot: The top of the directory tree under which the server's
# configuration, error, and log files are kept.
#
# NOTE! If you intend to place this on an NFS (or otherwise network)
# mounted filesystem then please read the Mutex documentation (available
# at <URL:http://httpd.apache.org/docs/2.4/mod/core.html#mutex>);
# you will save yourself a lot of trouble.
#
# Do NOT add a slash at the end of the directory path.
#
#ServerRoot "/etc/apache2"

#
# The accept serialization lock file MUST BE STORED ON A LOCAL DISK.
#
#Mutex file:${APACHE_LOCK_DIR} default

#
# The directory where shm and other runtime files will be stored.
#

DefaultRuntimeDir ${APACHE_RUN_DIR} "/var/run/apache2"

#
# PidFile: The file in which the server should record its process
# identification number when it starts.
# This needs to be set in /etc/apache2/envvars
#
PidFile ${APACHE_PID_FILE}

#
# Timeout: The number of seconds before...

Read more...

Revision history for this message
thomas platzek (tomplatzek48) wrote : Re: [Bug 2093265] Re: apache2 server exit error runtimedir

Hi Bryce

thanks for the support. Attached you find the file.

Greetings from Berlin

Am 09.01.25 um 20:54 schrieb Bryce Harrington:
> Please attach your /etc/apache2/apache2.conf; from the error message you
> posted it sounds like it has a syntax error.
>
> ** Changed in: apache2 (Ubuntu)
> Status: New => Incomplete
>

Revision history for this message
John Chittum (jchittum) wrote :

tomplatzek48

thank you for the file. The error reports line 80, which is:

DefaultRuntimeDir ${APACHE_RUN_DIR} "/var/run/apache2"

DefaultRuntimeDir only takes a single argument, and two are present. Delete one, and let us know if that fixes the issue.

Revision history for this message
thomas platzek (tomplatzek48) wrote :

Hi John
I deleted the second argument in line 80. Enclosed you see the new error message
Thomas

Revision history for this message
Launchpad Janitor (janitor) wrote :

[Expired for apache2 (Ubuntu) because there has been no activity for 60 days.]

Changed in apache2 (Ubuntu):
status: Incomplete → Expired
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.