ubuntuusers.de

Apache2 startet nicht mehr

Status: Gelöst | Ubuntu-Version: Xubuntu 20.04 (Focal Fossa)
Antworten |

horald

Anmeldungsdatum:
6. Januar 2011

Beiträge: 240

Wohnort: Köln

Hallo Leute,

leider startet mein Apache2 nicht mehr. Beim Aufruf der Systemabfrage mit

1
systemctl status apache2.service

erhalte ich folgende Meldung:

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
apache2.service - The Apache HTTP Server
     Loaded: loaded (/lib/systemd/system/apache2.service; enabled; vendor preset: enabled)
     Active: failed (Result: exit-code) since Wed 2021-01-13 13:13:14 CET; 27s ago
       Docs: https://httpd.apache.org/docs/2.4/
    Process: 3007 ExecStart=/usr/sbin/apachectl start (code=exited, status=1/FAILURE)

Jan 13 13:13:14 horald-OptiPlex760 systemd[1]: Starting The Apache HTTP Server...
Jan 13 13:13:14 horald-OptiPlex760 apachectl[3025]: apache2: Syntax error on line 146 of /etc/apache2/apache2.conf: Syntax error on line 3 of /etc/apache2/mods-enabled/php7.4.load: Can't loca>
Jan 13 13:13:14 horald-OptiPlex760 apachectl[3007]: Action 'start' failed.
Jan 13 13:13:14 horald-OptiPlex760 apachectl[3007]: The Apache error log may have more information.
Jan 13 13:13:14 horald-OptiPlex760 systemd[1]: apache2.service: Control process exited, code=exited, status=1/FAILURE
Jan 13 13:13:14 horald-OptiPlex760 systemd[1]: apache2.service: Failed with result 'exit-code'.
Jan 13 13:13:14 horald-OptiPlex760 systemd[1]: Failed to start The Apache HTTP Server.

In php7.4.load steht folgendes drin:

1
2
3
# Conflicts: php5
# Depends: mpm_prefork
LoadModule php7_module /usr/lib/apache2/modules/libphp7.4.so

Die Datei "libphp7.4.so" habe ich in das entsprechende Verzeichnis kopiert, ist also vorhanden.

Wenn ich

1
apachectl configtest

eingebe, bekomme ich folgende Meldung:

1
2
apache2: Syntax error on line 146 of /etc/apache2/apache2.conf: Syntax error on line 3 of /etc/apache2/mods-enabled/php7.4.load: Can't locate API module structure `php7_module' in file /usr/lib/apache2/modules/libphp7.4.so: /usr/lib/apache2/modules/libphp7.4.so: undefined symbol: php7_module
Action 'configtest' failed.

Hat einer einen Tipp wie ich den Fehler behebe? Danke.

Viele Grüße

Horst

chr123

Anmeldungsdatum:
19. Juli 2018

Beiträge: 1632

Hast du auch mal in Zeile 146 der /etc/apache2/apache2.conf geschaut?

horald

(Themenstarter)

Anmeldungsdatum:
6. Januar 2011

Beiträge: 240

Wohnort: Köln

Hallo chr123,

danke für die Rückmeldung.

Hast du auch mal in Zeile 146 der /etc/apache2/apache2.conf geschaut?

Klar habe ich da nachgeschaut, aber da ist nur der Include-Aufruf für "php7.4.load" eingebunden.

Viele Grüße

Horst

horald

(Themenstarter)

Anmeldungsdatum:
6. Januar 2011

Beiträge: 240

Wohnort: Köln

Hallo Leute,

ich wollte nur sagen, dass ich es jetzt endlich (selber) gelöst habe. Ich mußte nur folgendes installieren:

1
sudo apt-get install libapache2-mod-php 

Warum es allerdings bisher vorher funktioniert hat, ist mir ein Rätsel...

Viele Grüße

Horst

Antworten |