Trouble transferring documents from old NextCloud to new NextCloud installation

Support intro

Sorry to hear you’re facing problems :slightly_frowning_face:

help.nextcloud.com is for home/non-enterprise users. If you’re running a business, paid support can be accessed via portal.nextcloud.com where we can ensure your business keeps running smoothly.

In order to help you as quickly as possible, before clicking Create Topic please provide as much of the below as you can. Feel free to use a pastebin service for logs, otherwise either indent short log examples with four spaces:

example

Or for longer, use three backticks above and below the code snippet:

longer
example
here

Some or all of the below information will be requested if it isn’t supplied; for fastest response please provide as much as you can :heart:

Nextcloud version (eg, 18.0.2): NextCloudPi v1.18
Operating system and version (eg, Ubuntu 20.04): Raspbian Buster, Feb 2020. Linux raspberrypi 4.19.97+ #1294 Thu Jan 30 13:10:54 GMT 2020 armv6l GNU/Linux
Apache or nginx version (eg, Apache 2.4.25): Server version: Apache/2.4.38 (Raspbian)
PHP version (eg, 7.1): PHP 7.3.14-1~deb10u1 (cli) (built: Feb 16 2020 15:07:23) ( NTS )

The issue you are facing:
I have two Raspberry Pis. An old version of NextCloudPi is installed on one Pi (v 0.54.7) and I have installed v1.18 on another Pi. I want to transfer my documents from the old installation to the new. I’m not able to make the documents appear in the NextCloudPi Web Interface despite dragging the files…
FROM /media/myCloudDrive/ncdata/ncp on the “old” installation
TO /media/myCloudDrive/ncdata/ncp on the “new” installation.
AND running nc-scan and nc-fix-permissions and chmod www-data recursively.
Furthermore, when I start the NextCloudPi Web Interface to my documents I find that the whole Chrome becomes unresponsive and I can’t click into open tabs or open new ones or close individual ones. I can only close down the whole browser.

Is this the first time you’ve seen this error? (Y/N): Yes

Steps to replicate it:

  1. Drag all the files and folders in --> /media/myCloudDrive/ncdata/ncp from “old” NextCloudPi installation in to the same folder on a new installation.

This is what I tried:
On the new Installation…
# chown -R www-data:www-data /media/myCloudDrive/ncdata/ncp
Fixed the file permissions using the terminal user interface (TUI) utility
Ran nc-scan to make the files appear in the NextCloudPi WebIf. (but they don’t!)
systemctl restart apache2

The output of your Nextcloud log in Admin > Logging:

PASTE HERE

The output of your config.php file in /path/to/nextcloud (make sure you remove any identifiable information!):

<?php
$CONFIG = array (
  'passwordsalt' => 'Q/hH6D7ZvTtguiap1',
  'secret' => 'agTnXOHp6cKRd4HWZq4/lqh/pVJ/',
  'trusted_domains' => 
  array (
    0 => 'localhost',
    11 => 'xx.xx.xxx.xxx',
    1 => '192.168.1.1',
    5 => 'nextcloudpi.local',
    7 => 'nextcloudpi',
    8 => 'nextcloudpi.lan',
  ),
  'datadirectory' => '/media/myCloudDrive/ncdata',
  'dbtype' => 'mysql',
  'version' => '18.0.4.2',
  'overwrite.cli.url' => 'http://localhost',
  'dbname' => 'nextcloud',
  'dbhost' => 'localhost',
  'dbport' => '',
  'dbtableprefix' => 'oc_',
  'mysql.utf8mb4' => true,
  'dbuser' => 'ncadmin',
  'dbpassword' => 'bVAJEB7NJEd22i+dK/FOTyns2',
  'installed' => true,
  'instanceid' => 'ockiulq2s5kd',
  'memcache.local' => '\\OC\\Memcache\\Redis',
  'memcache.locking' => '\\OC\\Memcache\\Redis',
  'redis' => 
  array (
    'host' => '/var/run/redis/redis.sock',
    'port' => 0,
    'timeout' => 0.0,
    'password' => '+PY19/x2fkmB94pn9lcsob+',
  ),
  'tempdirectory' => '/media/myCloudDrive/ncdata/tmp',
  'mail_smtpmode' => 'sendmail',
  'mail_smtpauthtype' => 'LOGIN',
  'mail_from_address' => 'admin',
  'mail_domain' => 'ownyourbits.com',
  'preview_max_x' => '2048',
  'preview_max_y' => '2048',
  'jpeg_quality' => '60',
  'overwriteprotocol' => 'https',
  'maintenance' => false,
  'logfile' => '/media/myCloudDrive/ncdata/nextcloud.log',
);

The output of your Apache/nginx/system log in /var/log/____:

[Thu May 14 22:47:37.732952 2020] [ssl:warn] [pid 18377:tid 3069566688] AH01909: localhost:443:0 server certificate does NOT include an ID which matches the server name
[Thu May 14 22:47:37.736250 2020] [ssl:error] [pid 18377:tid 3069566688] AH02217: ssl_stapling_init_cert: can't retrieve issuer certificate! [subject: CN=raspberrypi / issuer: CN=raspberrypi / serial: 35F6DD2BC76BEEE3EE9BB3B3194F5A3C95651172 / notbefore: May 14 21:30:49 2020 GMT / notafter: May 12 21:30:49 2030 GMT]
[Thu May 14 22:47:37.736771 2020] [ssl:error] [pid 18377:tid 3069566688] AH02604: Unable to configure certificate localhost:443:0 for stapling
[Thu May 14 22:47:37.931258 2020] [ssl:warn] [pid 18378:tid 3069566688] AH01909: localhost:443:0 server certificate does NOT include an ID which matches the server name
[Thu May 14 22:47:37.933327 2020] [ssl:error] [pid 18378:tid 3069566688] AH02217: ssl_stapling_init_cert: can't retrieve issuer certificate! [subject: CN=raspberrypi / issuer: CN=raspberrypi / serial: 35F6DD2BC76BEEE3EE9BB3B3194F5A3C95651172 / notbefore: May 14 21:30:49 2020 GMT / notafter: May 12 21:30:49 2030 GMT]
[Thu May 14 22:47:37.933538 2020] [ssl:error] [pid 18378:tid 3069566688] AH02604: Unable to configure certificate localhost:443:0 for stapling
[Fri May 15 01:11:14.343445 2020] [ssl:warn] [pid 18378:tid 3069566688] AH01909: localhost:443:0 server certificate does NOT include an ID which matches the server name
[Fri May 15 01:11:14.348220 2020] [ssl:error] [pid 18378:tid 3069566688] AH02217: ssl_stapling_init_cert: can't retrieve issuer certificate! [subject: CN=raspberrypi / issuer: CN=raspberrypi / serial: 35F6DD2BC76BEEE3EE9BB3B3194F5A3C95651172 / notbefore: May 14 21:30:49 2020 GMT / notafter: May 12 21:30:49 2030 GMT]
[Fri May 15 01:11:14.348492 2020] [ssl:error] [pid 18378:tid 3069566688] AH02604: Unable to configure certificate localhost:443:0 for stapling
[Fri May 15 01:41:53.696143 2020] [ssl:warn] [pid 18378:tid 3069566688] AH01909: localhost:443:0 server certificate does NOT include an ID which matches the server name
[Fri May 15 01:41:53.707908 2020] [ssl:error] [pid 18378:tid 3069566688] AH02217: ssl_stapling_init_cert: can't retrieve issuer certificate! [subject: CN=raspberrypi / issuer: CN=raspberrypi / serial: 35F6DD2BC76BEEE3EE9BB3B3194F5A3C95651172 / notbefore: May 14 21:30:49 2020 GMT / notafter: May 12 21:30:49 2030 GMT]
[Fri May 15 01:41:53.708186 2020] [ssl:error] [pid 18378:tid 3069566688] AH02604: Unable to configure certificate localhost:443:0 for stapling
[Fri May 15 02:57:01.590307 2020] [proxy_fcgi:error] [pid 4481:tid 2856264736] [client 192.168.1.101:51761] AH01067: Failed to read FastCGI header
[Fri May 15 02:57:01.592670 2020] [proxy_fcgi:error] [pid 4481:tid 2856264736] (104)Connection reset by peer: [client 192.168.1.101:51761] AH01075: Error dispatching request to : 
[Fri May 15 02:57:07.288490 2020] [proxy:error] [pid 4402:tid 2763854880] (2)No such file or directory: AH02454: FCGI: attempt to connect to Unix domain socket /run/php/php7.3-fpm.sock (*) failed
[Fri May 15 02:57:07.289660 2020] [proxy_fcgi:error] [pid 4402:tid 2763854880] [client 192.168.1.101:51763] AH01079: failed to make connection to backend: httpd-UDS
[Fri May 15 02:57:08.913742 2020] [proxy:error] [pid 4402:tid 2763854880] (2)No such file or directory: AH02454: FCGI: attempt to connect to Unix domain socket /run/php/php7.3-fpm.sock (*) failed
[Fri May 15 02:57:08.914176 2020] [proxy_fcgi:error] [pid 4402:tid 2763854880] [client 192.168.1.101:51763] AH01079: failed to make connection to backend: httpd-UDS
[Fri May 15 02:57:09.042960 2020] [proxy:error] [pid 4402:tid 2755453984] (2)No such file or directory: AH02454: FCGI: attempt to connect to Unix domain socket /run/php/php7.3-fpm.sock (*) failed
[Fri May 15 02:57:09.043345 2020] [proxy_fcgi:error] [pid 4402:tid 2755453984] [client 192.168.1.101:51763] AH01079: failed to make connection to backend: httpd-UDS
[Fri May 15 02:58:16.338126 2020] [ssl:warn] [pid 357:tid 3070185184] AH01909: localhost:443:0 server certificate does NOT include an ID which matches the server name
[Fri May 15 02:58:16.415494 2020] [ssl:error] [pid 357:tid 3070185184] AH02217: ssl_stapling_init_cert: can't retrieve issuer certificate! [subject: CN=raspberrypi / issuer: CN=raspberrypi / serial: 35F6DD2BC76BEEE3EE9BB3B3194F5A3C95651172 / notbefore: May 14 21:30:49 2020 GMT / notafter: May 12 21:30:49 2030 GMT]
[Fri May 15 02:58:16.415807 2020] [ssl:error] [pid 357:tid 3070185184] AH02604: Unable to configure certificate localhost:443:0 for stapling
[Fri May 15 02:58:17.911296 2020] [ssl:warn] [pid 611:tid 3070185184] AH01909: localhost:443:0 server certificate does NOT include an ID which matches the server name
[Fri May 15 02:58:17.954021 2020] [ssl:error] [pid 611:tid 3070185184] AH02217: ssl_stapling_init_cert: can't retrieve issuer certificate! [subject: CN=raspberrypi / issuer: CN=raspberrypi / serial: 35F6DD2BC76BEEE3EE9BB3B3194F5A3C95651172 / notbefore: May 14 21:30:49 2020 GMT / notafter: May 12 21:30:49 2030 GMT]
[Fri May 15 02:58:17.954333 2020] [ssl:error] [pid 611:tid 3070185184] AH02604: Unable to configure certificate localhost:443:0 for stapling

I figured out what the problem was…

Regarding my browser freezing up, I’m not sure why that was happening but after rebooting my PC and Raspberry Pi it wasn’t a problem anymore.

The issue with nc-scan was I think because it’s not very well explained how to use it. A NOOB would easily be confused.

Here is how I got nc-scan to work:
1.A Using a Samba share accessed from Windows I selected all files and folders in /media/myCloudDrive/ncdata/ncp on my “old” NextcloudPi installation and dragged them into /media/myCloudDrive/ncdata/ncp on the “new” NextcloudPi installation.
1.B Another option here is to use rsync to do the copy over which can be set to preserve timestamps (as well and ownership and permissions) in case the copy over ends up resetting them to new timestamps and you don’t want that to happen.
2. Fixed the file ownerships (this would not be at all obvious for a NOOB)
# chown -R www-data:www-data /media/myCloudDrive/ncdata/ncp
3. I then ran # ncp-config to start the Terminal User Interface (TUI) to fix the file permissions
# ncp-config --- Tools --- nc-fix-permissions
4. I then ran nc-scan from the TUI
# ncp-config --- Tools --- nc-scan
In here I was making a mistake of setting the Path1 to /media/myCloudDrive/ncdata/ncp but this wasn’t finding any newly copied over files… instead with Path1 simply as below it found them

  • It might have been fine to just leave the paths blank.
  • I don’t know what “NONEXTERNAL” means… could it be re-phrased in a future update?
  • Could one or two sentences be added to this TUI screen to explain more clearly to NOOBs how to use it? A few bullet points underneath the first line… “Enter configuration for nc-san”. There is plenty of space there and NOOBs appreciate having things spelt out !

Cheers,

Flex