Need Help: ncp-dist-upgrade broke everything (apache config?)


For quite some time, I was stuck in ncp 1.20.0, and got some notifications saying that the system was updated to 1.20.0 (again). It felt weird to me after the 100th occurence of it. I logged into my Rpi, which tells me that 1.20.0 is outdated and that I should update to 1.20.7.

Well, it did not work. I got a similar message as here : Can't update from ncp 1.20.0 -> 1.20.1. So I followed @OliverV’s instruction (in that thread) to update to Buster.

Then, it started to get complicated for me.

I identified 2 issues in the process:
1/ php7.3 issue :

The following packages have unmet dependencies:
 php7.3-bz2 : Depends: php7.3-common (= 7.3.14-1~deb10u1) but 7.3.14-5+0~20200202.52+debian9~1.gbpa71879 is to be installed
 php7.3-curl : Depends: php7.3-common (= 7.3.14-1~deb10u1) but 7.3.14-5+0~20200202.52+debian9~1.gbpa71879 is to be installed
E: Unable to correct problems, you have held broken packages.
Something went wrong. Fix it and try again
<End of the ncp-dist-upgrade command>

2/ Apache server not starting

Apache log in ncp-dist-upgrade
Setting up apache2 (2.4.38-3+deb10u3) ...
Installing new version of config file /etc/apache2/mods-available/deflate.conf ...
Installing new version of config file /etc/apache2/mods-available/mime.conf ...
Installing new version of config file /etc/logrotate.d/apache2 ...
Job for apache2.service failed because the control process exited with error code.
See "systemctl status apache2.service" and "journalctl -xe" for details.
invoke-rc.d: initscript apache2, action "restart" failed.
â—Ź apache2.service - The Apache HTTP Server
   Loaded: loaded (/lib/systemd/system/apache2.service; enabled; vendor preset: enabled)
   Active: failed (Result: exit-code) since Thu 2020-02-20 20:28:12 UTC; 77ms ago
  Process: 27053 ExecStart=/usr/sbin/apachectl start (code=exited, status=1/FAILURE)

Feb 20 20:28:12 nextcloudpi apachectl[27053]: (98)Address already in use: AH00072: make_sock: could not bind to address [::]:80
Feb 20 20:28:12 nextcloudpi apachectl[27053]: (98)Address already in use: AH00072: make_sock: could not bind to address [::]:443
Feb 20 20:28:12 nextcloudpi apachectl[27053]: (98)Address already in use: AH00072: make_sock: could not bind to address
Feb 20 20:28:12 nextcloudpi apachectl[27053]: no listening sockets available, shutting down
Feb 20 20:28:12 nextcloudpi apachectl[27053]: AH00015: Unable to open logs
Feb 20 20:28:12 nextcloudpi apachectl[27053]: Action 'start' failed.
Feb 20 20:28:12 nextcloudpi apachectl[27053]: The Apache error log may have more information.
Feb 20 20:28:12 nextcloudpi systemd[1]: apache2.service: Control process exited, code=exited, status=1/FAILURE
Feb 20 20:28:12 nextcloudpi systemd[1]: apache2.service: Failed with result 'exit-code'.
Feb 20 20:28:12 nextcloudpi systemd[1]: Failed to start The Apache HTTP Server.

So (I think) I fixed the first problem by doing:
sudo apt-get -f remove php7.3-common
and then re-running sudo ncp-dist-upgrade which reinstall php7.3 correctly (for deb10)

But the issue remains for Apache, with some message giving me hope like

NOTICE: Not enabling PHP 7.3 FPM by default.
NOTICE: To enable PHP 7.3 FPM in Apache2 do:
NOTICE: a2enmod proxy_fcgi setenvif
NOTICE: a2enconf php7.3-fpm
NOTICE: You are seeing this message because you have apache2 package installed.

which I did, but did not work.
I also try systemctl reload apache2 but did not work because apache was not active.

I dig up a bit on internet for why apache could not start with a could not bind to address error, trying to see whether something else was using these http(s) ports. (e.g.

but I couldn’t find a duplicate Listen 80/443 in my conf file:

pi@nextcloudpi:~ $ grep -r Listen /etc/apache2/
/etc/apache2/ports.conf:Listen 80
/etc/apache2/ports.conf:Listen [::]:80
/etc/apache2/ports.conf:	Listen 443
/etc/apache2/ports.conf:        Listen [::]:443
/etc/apache2/ports.conf:	Listen 443
/etc/apache2/ports.conf:        Listen [::]:443
/etc/apache2/sites-available/ncp.conf:Listen 4443

and the 2 Listen 443 are because of <IfModule ssl_module> or <IfModule mod_gnutls.c>. I thought it was not a pb, but maybe it is ?

I was stuck there, not knowing what could I do, so since I saw in the output of the ncp-dist-upgrade a line with :

Setting up dbus (1.10.28-0+deb9u1) ...
A reboot is required to replace the running dbus-daemon.
Please reboot the system when convenient.

I thougt that it might me convenient by now, and in bonus, it might fix the apache issue.
so: sudo reboot
but then I couldn’t connect through ssh to the Rpi (connection timed out), and the Rpi was not detectable by the internet box. I thought maybe this is because it takes some time to replace the dbus stuff or whatever, so I let it like this overnight.
This morning, again, I could not ssh in. So I just unplug it and back in, and now it worked, I could ssh in directly.
But surprise, the HDD was not mounted anymore and not even detected. I unplug the usb cable and put it back but it did not change.
I check the syslog to see what was going on overnight, but 99% of it was:

Feb 21 07:16:41 nextcloudpi bash[1088]: Device "" does not exist.
Feb 21 07:16:44 nextcloudpi bash[1088]: Device "" does not exist.
Feb 21 07:16:48 nextcloudpi bash[1088]: Device "" does not exist.

And I also notice this line (which occured already before the reboot):

Feb 20 19:15:45 nextcloudpi kernel: [    3.615346] usb-storage 1-1.5:1.0: USB Mass Storage device detected
Feb 20 19:15:45 nextcloudpi systemd[1]: Started Monitor /media for mountpoints and create USBdrive* symlinks.
Feb 20 19:15:45 nextcloudpi systemd[1]: Starting Automount USB drives...
Feb 20 19:15:45 nextcloudpi bash[338]: rmdir: failed to remove '/media/USBdrive': Not a directory
Feb 20 19:15:45 nextcloudpi systemd[1]: Started Automount USB drives.

This rmdir kind of scared me.

I tried a sudo ncp-dist-upgrade just in case it would magically fix everything. But it didn’t.

So I thought why not reboot ?
So I did, and now I’m back to having only the apache issue, the HDD is mounted again.

(see next post for output of ncp-report)


Here is the output of the ncp-report:

NextCloudPi diagnostics

Nextcloud is in maintenance mode - no apps have been loaded

NextCloudPi version  v1.20.0
NextCloudPi image    NextCloudPi_10-05-18
distribution         Raspbian GNU/Linux 10 \n \l
automount            yes
USB devices          sda 
datadir              /media/USBdrive/ncdata
data in SD           no
data filesystem      btrfs
data disk usage      658G/932G
rootfs usage         2.9G/15G
swapfile             /var/swap
dbdir                /var/lib/mysql
Nextcloud check      ok
Nextcloud version
HTTPD service        down
PHP service          up
MariaDB service      up
Redis service        up
Postfix service      up
internet check       ok
port check 80        closed
port check 443       closed
IP                   ***REMOVED SENSITIVE VALUE***
gateway              ***REMOVED SENSITIVE VALUE***
interface            eth0
certificates         ***REMOVED SENSITIVE VALUE***
NAT loopback         no
uptime               41min

Nextcloud configuration

Nextcloud is in maintenance mode - no apps have been loaded

    "system": {
        "passwordsalt": "***REMOVED SENSITIVE VALUE***",
        "secret": "***REMOVED SENSITIVE VALUE***",
        "trusted_domains": {
            "0": "localhost",
            "5": "nextcloudpi.local",
            "7": "nextcloudpi",
            "8": "nextcloudpi.lan",
            "1": "",
            "4": "",
            "20": "",
            "21": "",
            "22": "nextcloudpi.local"
        "datadirectory": "***REMOVED SENSITIVE VALUE***",
        "dbtype": "mysql",
        "version": "",
        "overwrite.cli.url": "https:\/\/\/",
        "dbname": "***REMOVED SENSITIVE VALUE***",
        "dbhost": "***REMOVED SENSITIVE VALUE***",
        "dbport": "",
        "dbtableprefix": "oc_",
        "mysql.utf8mb4": true,
        "dbuser": "***REMOVED SENSITIVE VALUE***",
        "dbpassword": "***REMOVED SENSITIVE VALUE***",
        "installed": true,
        "instanceid": "***REMOVED SENSITIVE VALUE***",
        "memcache.local": "\\OC\\Memcache\\Redis",
        "memcache.locking": "\\OC\\Memcache\\Redis",
        "redis": {
            "host": "***REMOVED SENSITIVE VALUE***",
            "port": 0,
            "timeout": 0,
            "password": "***REMOVED SENSITIVE VALUE***"
        "mail_smtpmode": "smtp",
        "mail_from_address": "***REMOVED SENSITIVE VALUE***",
        "mail_domain": "***REMOVED SENSITIVE VALUE***",
        "overwriteprotocol": "https",
        "maintenance": true,
        "logfile": "\/media\/USBdrive\/ncdata\/nextcloud.log",
        "loglevel": "2",
        "log_type": "file",
        "theme": "",
        "mail_sendmailmode": "smtp",
        "mail_smtphost": "***REMOVED SENSITIVE VALUE***",
        "mail_smtpport": "465",
        "mail_smtpsecure": "ssl",
        "mail_smtpauth": 1,
        "mail_smtpauthtype": "LOGIN",
        "mail_smtpname": "***REMOVED SENSITIVE VALUE***",
        "mail_smtppassword": "***REMOVED SENSITIVE VALUE***",
        "twofactor_enforced": "false",
        "twofactor_enforced_groups": [],
        "twofactor_enforced_excluded_groups": [],
        "jpeg_quality": "60",
        "trashbin_retention_obligation": "15, 30"

HTTPd logs

Database logs

2020-02-21  8:34:59 0 [Note] InnoDB: Compressed tables use zlib 1.2.11
2020-02-21  8:34:59 0 [Note] InnoDB: Number of pools: 1
2020-02-21  8:34:59 0 [Note] InnoDB: Using generic crc32 instructions
2020-02-21  8:34:59 0 [Note] InnoDB: Initializing buffer pool, total size = 384M, instances = 1, chunk size = 128M
2020-02-21  8:34:59 0 [Note] InnoDB: Completed initialization of buffer pool
2020-02-21  8:34:59 0 [Note] InnoDB: If the mysqld execution user is authorized, page cleaner thread priority can be changed. See the man page of setpriority().
2020-02-21  8:35:00 0 [Note] InnoDB: 128 out of 128 rollback segments are active.
2020-02-21  8:35:00 0 [Note] InnoDB: Creating shared tablespace for temporary tables
2020-02-21  8:35:00 0 [Note] InnoDB: Setting file './ibtmp1' size to 12 MB. Physically writing the file full; Please wait ...
2020-02-21  8:35:00 0 [Note] InnoDB: File './ibtmp1' size is now 12 MB.
2020-02-21  8:35:00 0 [Note] InnoDB: Waiting for purge to start
2020-02-21  8:35:00 0 [Note] InnoDB: 10.3.22 started; log sequence number 13412234081; transaction id 169367338
2020-02-21  8:35:00 0 [Note] InnoDB: Loading buffer pool(s) from /var/lib/mysql/ib_buffer_pool
2020-02-21  8:35:00 0 [Note] Plugin 'FEEDBACK' is disabled.
2020-02-21  8:35:01 0 [Note] Server socket created on IP: ''.
2020-02-21  8:35:01 0 [Note] Reading of all Master_info entries succeeded
2020-02-21  8:35:01 0 [Note] Added new Master_info '' to hash table
2020-02-21  8:35:01 0 [Note] /usr/sbin/mysqld: ready for connections.
Version: '10.3.22-MariaDB-0+deb10u1'  socket: '/var/run/mysqld/mysqld.sock'  port: 3306  Raspbian 10
2020-02-21  8:35:01 0 [Note] InnoDB: Buffer pool(s) load completed at 200221  8:35:01

Nextcloud logs

{"reqId":"RY8SXlElDVj2cLS8Tq7W","level":3,"time":"2020-02-19T16:47:10+00:00","remoteAddr":"","user":"--","app":"PHP","method":"","url":"--","message":"Error while sending QUERY packet. PID=29787 at \/var\/www\/nextcloud\/3rdparty\/doctrine\/dbal\/lib\/Doctrine\/DBAL\/Driver\/PDOConnection.php#88","userAgent":"--","version":""}
{"reqId":"Xk61UX8AAQEAAEsOGyoAAEka","level":3,"time":"2020-02-20T16:35:40+00:00","remoteAddr":"","user":"Jean","app":"PHP","method":"REPORT","url":"\/remote.php\/dav\/calendars\/Jean\/workics\/","message":"Error while sending QUERY packet. PID=11738 at \/var\/www\/nextcloud\/3rdparty\/doctrine\/dbal\/lib\/Doctrine\/DBAL\/Driver\/PDOStatement.php#117","userAgent":"Mozilla\/5.0 (Macintosh; Intel Mac OS X 10.11; rv:68.0) Gecko\/20100101 Thunderbird\/68.4.2 Lightning\/68.4.2","version":""}
{"reqId":"Xk61UX8AAQEAAEsOGyoAAEka","level":4,"time":"2020-02-20T16:35:40+00:00","remoteAddr":"","user":"Jean","app":"webdav","method":"REPORT","url":"\/remote.php\/dav\/calendars\/Jean\/workics\/","message":{"Exception":"Sabre\\DAV\\Exception\\ServiceUnavailable","Message":"Doctrine\\DBAL\\Exception\\DriverException: An exception occurred while executing 'UPDATE `oc_preferences` SET `configvalue` = ? WHERE (`userid` = ?) AND (`appid` = ?) AND (`configkey` = ?)' with params [1582216540, \"Jean\", \"login\", \"lastLogin\"]:\n\nSQLSTATE[HY000]: General error: 2006 MySQL server has gone away","Code":0,"Trace":[{"file":"\/var\/www\/nextcloud\/3rdparty\/sabre\/dav\/lib\/DAV\/Auth\/Plugin.php","line":201,"function":"check","class":"OCA\\DAV\\Connector\\Sabre\\Auth","type":"->","args":[{"absoluteUrl":"https:\/\/\/remote.php\/dav\/calendars\/Jean\/workics\/","__class__":"Sabre\\HTTP\\Request"},{"__class__":"Sabre\\HTTP\\Response"}]},{"file":"\/var\/www\/nextcloud\/3rdparty\/sabre\/dav\/lib\/DAV\/Auth\/Plugin.php","line":150,"function":"check","class":"Sabre\\DAV\\Auth\\Plugin","type":"->","args":[{"absoluteUrl":"https:\/\/\/remote.php\/dav\/calendars\/Jean\/workics\/","__class__":"Sabre\\HTTP\\Request"},{"__class__":"Sabre\\HTTP\\Response"}]},{"function":"beforeMethod","class":"Sabre\\DAV\\Auth\\Plugin","type":"->","args":[{"absoluteUrl":"https:\/\/\/remote.php\/dav\/calendars\/Jean\/workics\/","__class__":"Sabre\\HTTP\\Request"},{"__class__":"Sabre\\HTTP\\Response"}]},{"file":"\/var\/www\/nextcloud\/3rdparty\/sabre\/event\/lib\/EventEmitterTrait.php","line":105,"function":"call_user_func_array","args":[[{"autoRequireLogin":true,"__class__":"Sabre\\DAV\\Auth\\Plugin"},"beforeMethod"],[{"absoluteUrl":"https:\/\/\/remote.php\/dav\/calendars\/Jean\/workics\/","__class__":"Sabre\\HTTP\\Request"},{"__class__":"Sabre\\HTTP\\Response"}]]},{"file":"\/var\/www\/nextcloud\/3rdparty\/sabre\/dav\/lib\/DAV\/Server.php","line":466,"function":"emit","class":"Sabre\\Event\\EventEmitter","type":"->","args":["beforeMethod",[{"absoluteUrl":"https:\/\/\/remote.php\/dav\/calendars\/Jean\/workics\/","__class__":"Sabre\\HTTP\\Request"},{"__class__":"Sabre\\HTTP\\Response"}]]},{"file":"\/var\/www\/nextcloud\/3rdparty\/sabre\/dav\/lib\/DAV\/Server.php","line":254,"function":"invokeMethod","class":"Sabre\\DAV\\Server","type":"->","args":[{"absoluteUrl":"https:\/\/\/remote.php\/dav\/calendars\/Jean\/workics\/","__class__":"Sabre\\HTTP\\Request"},{"__class__":"Sabre\\HTTP\\Response"}]},{"file":"\/var\/www\/nextcloud\/apps\/dav\/lib\/Server.php","line":317,"function":"exec","class":"Sabre\\DAV\\Server","type":"->","args":[]},{"file":"\/var\/www\/nextcloud\/apps\/dav\/appinfo\/v2\/remote.php","line":35,"function":"exec","class":"OCA\\DAV\\Server","type":"->","args":[]},{"file":"\/var\/www\/nextcloud\/remote.php","line":163,"args":["\/var\/www\/nextcloud\/apps\/dav\/appinfo\/v2\/remote.php"],"function":"require_once"}],"File":"\/var\/www\/nextcloud\/apps\/dav\/lib\/Connector\/Sabre\/Auth.php","Line":162,"CustomMessage":"--"},"userAgent":"Mozilla\/5.0 (Macintosh; Intel Mac OS X 10.11; rv:68.0) Gecko\/20100101 Thunderbird\/68.4.2 Lightning\/68.4.2","version":""}
{"reqId":"Xk61UX8AAQEAAEsOGywAAEkL","level":3,"time":"2020-02-20T16:35:41+00:00","remoteAddr":"","user":"Jean","app":"PHP","method":"REPORT","url":"\/remote.php\/dav\/calendars\/Jean\/jj\/","message":"Error while sending QUERY packet. PID=11740 at \/var\/www\/nextcloud\/3rdparty\/doctrine\/dbal\/lib\/Doctrine\/DBAL\/Driver\/PDOStatement.php#117","userAgent":"Mozilla\/5.0 (Macintosh; Intel Mac OS X 10.11; rv:68.0) Gecko\/20100101 Thunderbird\/68.4.2 Lightning\/68.4.2","version":""}
{"reqId":"Xk61UX8AAQEAAEsOGysAAEkB","level":4,"time":"2020-02-20T16:35:42+00:00","remoteAddr":"","user":"Jean","app":"webdav","method":"REPORT","url":"\/remote.php\/dav\/calendars\/Jean\/persoics\/","message":{"Exception":"Sabre\\DAV\\Exception\\ServiceUnavailable","Message":"Doctrine\\DBAL\\Exception\\DriverException: An exception occurred while executing 'UPDATE `oc_preferences` SET `configvalue` = ? WHERE (`userid` = ?) AND (`appid` = ?) AND (`configkey` = ?)' with params [1582216542, \"Jean\", \"login\", \"lastLogin\"]:\n\nSQLSTATE[HY000]: General error: 2006 MySQL server has gone away","Code":0,"Trace":[{"file":"\/var\/www\/nextcloud\/3rdparty\/sabre\/dav\/lib\/DAV\/Auth\/Plugin.php","line":201,"function":"check","class":"OCA\\DAV\\Connector\\Sabre\\Auth","type":"->","args":[{"absoluteUrl":"https:\/\/\/remote.php\/dav\/calendars\/Jean\/persoics\/","__class__":"Sabre\\HTTP\\Request"},{"__class__":"Sabre\\HTTP\\Response"}]},{"file":"\/var\/www\/nextcloud\/3rdparty\/sabre\/dav\/lib\/DAV\/Auth\/Plugin.php","line":150,"function":"check","class":"Sabre\\DAV\\Auth\\Plugin","type":"->","args":[{"absoluteUrl":"https:\/\/\/remote.php\/dav\/calendars\/Jean\/persoics\/","__class__":"Sabre\\HTTP\\Request"},{"__class__":"Sabre\\HTTP\\Response"}]},{"function":"beforeMethod","class":"Sabre\\DAV\\Auth\\Plugin","type":"->","args":[{"absoluteUrl":"https:\/\/\/remote.php\/dav\/calendars\/Jean\/persoics\/","__class__":"Sabre\\HTTP\\Request"},{"__class__":"Sabre\\HTTP\\Response"}]},{"file":"\/var\/www\/nextcloud\/3rdparty\/sabre\/event\/lib\/EventEmitterTrait.php","line":105,"function":"call_user_func_array","args":[[{"autoRequireLogin":true,"__class__":"Sabre\\DAV\\Auth\\Plugin"},"beforeMethod"],[{"absoluteUrl":"https:\/\/\/remote.php\/dav\/calendars\/Jean\/persoics\/","__class__":"Sabre\\HTTP\\Request"},{"__class__":"Sabre\\HTTP\\Response"}]]},{"file":"\/var\/www\/nextcloud\/3rdparty\/sabre\/dav\/lib\/DAV\/Server.php","line":466,"function":"emit","class":"Sabre\\Event\\EventEmitter","type":"->","args":["beforeMethod",[{"absoluteUrl":"https:\/\/\/remote.php\/dav\/calendars\/Jean\/persoics\/","__class__":"Sabre\\HTTP\\Request"},{"__class__":"Sabre\\HTTP\\Response"}]]},{"file":"\/var\/www\/nextcloud\/3rdparty\/sabre\/dav\/lib\/DAV\/Server.php","line":254,"function":"invokeMethod","class":"Sabre\\DAV\\Server","type":"->","args":[{"absoluteUrl":"https:\/\/\/remote.php\/dav\/calendars\/Jean\/persoics\/","__class__":"Sabre\\HTTP\\Request"},{"__class__":"Sabre\\HTTP\\Response"}]},{"file":"\/var\/www\/nextcloud\/apps\/dav\/lib\/Server.php","line":317,"function":"exec","class":"Sabre\\DAV\\Server","type":"->","args":[]},{"file":"\/var\/www\/nextcloud\/apps\/dav\/appinfo\/v2\/remote.php","line":35,"function":"exec","class":"OCA\\DAV\\Server","type":"->","args":[]},{"file":"\/var\/www\/nextcloud\/remote.php","line":163,"args":["\/var\/www\/nextcloud\/apps\/dav\/appinfo\/v2\/remote.php"],"function":"require_once"}],"File":"\/var\/www\/nextcloud\/apps\/dav\/lib\/Connector\/Sabre\/Auth.php","Line":162,"CustomMessage":"--"},"userAgent":"Mozilla\/5.0 (Macintosh; Intel Mac OS X 10.11; rv:68.0) Gecko\/20100101 Thunderbird\/68.4.2 Lightning\/68.4.2","version":""}
{"reqId":"rXBGwiGvICESGaBTr9I5","level":3,"time":"2020-02-20T17:01:00+00:00","remoteAddr":"","user":"--","app":"PHP","method":"","url":"--","message":"Error while sending QUERY packet. PID=7664 at \/var\/www\/nextcloud\/3rdparty\/doctrine\/dbal\/lib\/Doctrine\/DBAL\/Driver\/PDOConnection.php#88","userAgent":"--","version":""}
{"reqId":"Xk7WnH8AAQEAAErchT4AAJYQ","level":3,"time":"2020-02-20T18:57:53+00:00","remoteAddr":"","user":"--","app":"PHP","method":"GET","url":"\/ocm-provider\/","message":"Error: Class 'OCA\\CloudFederationAPI\\Capabilities' not found at \/var\/www\/nextcloud\/ocm-provider\/index.php#32","userAgent":"Mozilla\/5.0 (Macintosh; Intel Mac OS X 10.11; rv:72.0) Gecko\/20100101 Firefox\/72.0","version":""}
{"reqId":"Xk7bFX8AAQEAAAM8cuMAAAAB","level":3,"time":"2020-02-20T19:16:37+00:00","remoteAddr":"","user":"--","app":"remote","method":"GET","url":"\/status.php","message":{"Exception":"RedisException","Message":"Redis server went away","Code":0,"Trace":[{"file":"\/var\/www\/nextcloud\/lib\/private\/Memcache\/Redis.php","line":54,"function":"get","class":"Redis","type":"->","args":["fc3ec575ec428d9e12a7ceca491b47ca\/core.appinfo\/var\/www\/nextcloud\/apps\/files\/appinfo\/info.xml1576745234"]},{"file":"\/var\/www\/nextcloud\/lib\/private\/App\/InfoParser.php","line":57,"function":"get","class":"OC\\Memcache\\Redis","type":"->","args":["\/var\/www\/nextcloud\/apps\/files\/appinfo\/info.xml1576745234"]},{"file":"\/var\/www\/nextcloud\/lib\/private\/App\/AppManager.php","line":466,"function":"parse","class":"OC\\App\\InfoParser","type":"->","args":["\/var\/www\/nextcloud\/apps\/files\/appinfo\/info.xml"]},{"file":"\/var\/www\/nextcloud\/lib\/private\/legacy\/app.php","line":555,"function":"getAppInfo","class":"OC\\App\\AppManager","type":"->","args":["files",false,null]},{"file":"\/var\/www\/nextcloud\/lib\/private\/AppFramework\/App.php","line":66,"function":"getAppInfo","class":"OC_App","type":"::","args":["files"]},{"file":"\/var\/www\/nextcloud\/lib\/private\/legacy\/app.php","line":240,"function":"buildAppNamespace","class":"OC\\AppFramework\\App","type":"::","args":["files"]},{"file":"\/var\/www\/nextcloud\/lib\/private\/legacy\/app.php","line":120,"function":"registerAutoloading","class":"OC_App","type":"::","args":["files","\/var\/www\/nextcloud\/apps\/files"]},{"file":"\/var\/www\/nextcloud\/lib\/base.php","line":640,"function":"loadApps","class":"OC_App","type":"::","args":[["session"]]},{"file":"\/var\/www\/nextcloud\/lib\/base.php","line":1078,"function":"init","class":"OC","type":"::","args":[]},{"file":"\/var\/www\/nextcloud\/status.php","line":36,"args":["\/var\/www\/nextcloud\/lib\/base.php"],"function":"require_once"}],"File":"\/var\/www\/nextcloud\/lib\/private\/Memcache\/Redis.php","Line":54,"CustomMessage":"--"},"userAgent":"Mozilla\/5.0 (Macintosh) mirall\/2.3.3 (build 84) (Nextcloud)","version":""}

So, any help from NCP wizards or else would be very much appreciated
ping @nachoparker :slight_smile:

(and sorry for that long message)

i once got stuck in a similar issue.

so here’s my workaround that helped me getting onwards…
made a backup… od nc-data
did a ncp-export
backupped even sd-card (meaning a fully external .iso of it) - just in case
wrote newest iso to sd-card.
restored backup (which got me to an nc.version lower than installed with the new .iso)
(can’t remember if i had my ncp restored as well)
and did an upgrade from that to the newest nc… which then worked wonderfully…

i know it’s work and not the direct way… but - again - it worked for me

Thanks for your reply. Could you detail it a bit more?
I’ve made a ncp back up before the upgrade, (without data) do you think I can make something with it?


as for now? yes… restore your backup.

if you still wanna upgrade you could try my way then…

and of course i used and restored my ncp-backup. prior to restoring my nc-backup.

But will ncp-restore actually restore the correct apache config ?

Also, ncp-restore tells me:

“This new installation will cleanup current NextCloud instance, including files and database.”

which sounds odd to me as I don’t want my files to be cleaned up. The backup I have are without data.

How should I proceed ?

no… that would be done by nc-restore

that sounds bad, indeed. but as far as i remember it would just delete internal (database)-links to existing files. and not files itself (as long as you have them on a different hdd).

I think you meant nc-export, right ?

hmm, well, since it won’t restore the apache file, it might not be worth taking the risk ^^

the long version of what i just tried to get through :wink:

ncp export/import won’t restore the apache-file…
apache config should be restored by nextcloud-backup.

I’m lost !

What should I do ? Try the nc-restore ?

So, looking at the nc-restore script, it indeed does not delete the data directory, but instead the nextcloud directory (/var/www/nextcloud)

However, the PHPVER is set to 7.2, whereas mine is 7.3 now (but maybe I should downgrade, is this the pb?) so the script will fail at some point, unless I modify it (is it safe)?

So I unpack manually the backup file, but I couldn’t find any apache conf file (while looking for *conf file).

Are we sure that nc-restore will fix this issue ? I’m afraid to worsen the problem.


well i must admit that i haven’t had any problems regarding my apache-conf… and so i really can’t tell ya.
depending upon your setting in ncp and if you didn’t do any other “tricks” to it… it should be restored by ncp-restore… if i’m thinking about it, twice. since it’s there you adjust your apache-settings.

cant tell you anything about this, i’m afraid. when did you upgrade to php7.3?

See first post, it was during the ncp-dist-upgrade.

Thanks again for your time, I’ll wait for a few other answers

ya… that’s better…

all i could tell you was: my way of handling it worked for me. can’t guarantee for anyone else. :slight_smile: - but i am sure since you seem to have a recent backup of your data (and maybe even a ncp-export) and your user-data on a separate hdd chances are good to get back to a running instance

to be on the safe side ---- do make an iso-copy of your sd-card now. so nothing will be lost if something wont work. you could always go back to that one.

good luck

How do I do that ?

depending on your workstation-OS… so google is your friend…

under windows i used win32 Disk Imager… but read the short manual first

Is there anyone who could help me ?

Some update:

  • I still have the same problem
  • I figure out that my port 80 and 443 were closed (not sure whether it might be the cause of all this, any comment on this would be helpful as well).
  • I notice that my ISP’s box had changes (like IP address change and port redirection removed). I redefined the port redirection, but they remain closed.
  • I tried to set up a basic apache (only enabling de default site 000-default.conf), but it is still not working, even locally.
  • The port seems closed locally (ie. wget returns connection refused).


  • How can I fix this ? I’ve looked over internet without any luck
  • Do you think all this is related ?

Thanks for helping,

(@nachoparker, if you could check all this, it would be nice)


So I finally fix the problem thanks to a friend. We tried make a basic apache site work, and we figured out that it was IPv6 the issue. We don’t really know why as it seemed properly configured on my ISP box.

Anyway the solution was to comment out the Listen [::]:80 and Listen [::]:443 in /etc/apache2/ports.conf.

And now it works, and after rerunning the ncp-dit-upgrade, it worked.

1 Like