2017-02-05 38 views
0

我(使用:apt install apache2 --only-upgrade)更新的Apache2我Rapsberry Pi和現在沒有啓動:Apache2的APT升級後未開始

[email protected]:/etc/apache2 # service apache2 start 
Job for apache2.service failed. See 'systemctl status apache2.service' and 'journalctl -xn' for details. 
[email protected]:/etc/apache2 # systemctl status apache2.service 
● apache2.service - The Apache HTTP Server 
    Loaded: loaded (/lib/systemd/system/apache2.service; enabled) 
    Active: failed (Result: resources) since Sun 2017-02-05 16:19:48 CET; 28min ago 

Feb 05 16:47:44 pi systemd[1]: Starting The Apache HTTP Server... 
Feb 05 16:47:44 pi systemd[1]: apache2.service failed to run 'start' task: No such file or directory 
Feb 05 16:47:44 pi systemd[1]: Failed to start The Apache HTTP Server. 

的Apache2的版本:

Server version: Apache/2.4.25 (Raspbian) 
Server built: 2017-01-25T22:59:26 

apache2ctl -t顯示:

Syntax OK 

我試着禁用所有的虛擬主機(只有默認的左),但它didn什麼都不會改變。

的只是apache2輸出:

[Mon Feb 06 01:25:09.079790 2017] [core:warn] [pid 2954] AH00111: Config variable ${APACHE_RUN_DIR} is not defined 
apache2: Syntax error on line 80 of /etc/apache2/apache2.conf: DefaultRuntimeDir must be a valid directory, absolute or relative to ServerRoot 
+0

我使用i-MSCP也發生過同樣的情況。任何修復? –

回答

0

我不得不從14.04升級到Dockerfile後17.04相同的問題。 我的解決辦法是在/var/run 手動添加apache目錄所以修正爲:

mkdir /var/run/apache2 

DefaultRuntimeDir設置爲/var/run/apache2,但該文件夾不見了。

相關問題