Apache error after ncp-dist-upgrade to Buster

Hi, I was on the standard sytem of NextcloudPi (Raspberry Pi Image). Now, I wanted to upgrade to Buster in order to switch to the Pi4. After the upgrade Appache cannot start. It says:

Jul 24 08:58:23 nextcloudpi systemd[1]: Starting The Apache HTTP Serverā€¦
Jul 24 08:58:23 nextcloudpi apachectl[1697]: AH00526: Syntax error on line 1 of /etc/apache2/conf-enabled/javascript-common.conf:
Jul 24 08:58:23 nextcloudpi apachectl[1697]: Invalid command ā€˜Aliasā€™, perhaps misspelled or defined by a module not included in the server configu
Jul 24 08:58:23 nextcloudpi apachectl[1697]: Action ā€˜startā€™ failed.
Jul 24 08:58:23 nextcloudpi apachectl[1697]: The Apache error log may have more information.
Jul 24 08:58:23 nextcloudpi systemd[1]: apache2.service: Control process exited, code=exited, status=1/FAILURE
Jul 24 08:58:23 nextcloudpi systemd[1]: apache2.service: Failed with result ā€˜exit-codeā€™.
Jul 24 08:58:23 nextcloudpi systemd[1]: Failed to start The Apache HTTP Server.

Thanks for any help.

Is the file /etc/apache2/conf-enabled/javascript-common.conf your configuration file for your cloud? The name is kind of misleading. Check the line containing the Alias. Or post that file here.

1 Like

Hi @eehmke, thanks for the reply. The file /etc/apache2/conf-enabled/javascript-common.conf contains the following:

Alias /javascript/ /usr/share/javascript/

<Directory ā€œ/usr/share/javascript/ā€>
Options FollowSymLinks MultiViews

#Not actually sure if I have another config file. The files in the folder are:
charset.conf localized-error-pages.conf security.conf
http2.conf other-vhosts-access-log.conf serve-cgi-bin.conf
javascript-common.conf php7.3-fpm.conf

First of all, the files in /etc/apache2/conf-enabled are symlinks to the actual files in /etc/apache2/conf-available. You can disable them by command a2disconf and reenable them by a2enconf .
This javascript file is not your cloud config file, so just disable it for now.
You need to find out which is your config file for your nextcloud. None of the names of the other files give any hint.

1 Like

Thank you for helping me out. Disabling the javascript-common.conf did the job :slight_smile:
The cloud is back running.
I do have the Nextcloud conf under /etc/apache2/sites-enabled.

1 Like

Hi eehmke,

Hope you can help me. I got the same problem after executing ncp-dist-upgrade and after disabling javascript-common I could start Apache again. But when i look at the home page I got an ā€œuninterpretedā€ file. So it seems to me the javascript-common file is needed. You have a clou what is wrong with the statement ā€œAlias /javascript/ /usr/share/javascript/ā€? the directory /usr/share/javascript/ contains jquery.
Many thanks in advance.

Problem with the ā€œuninterpretedā€ file was caused by missing PHP. It seems i forgot to run ncp-upgrade before ncp-dist-upgrade. After running ncp-upgrade and rerunning ncp-dist-upgrade with a2disconf javascript-common all seems to be working fine. Problem solved :slight_smile:

1 Like