Open jmgomez-IAA opened 4 years ago
Listar todos los moudlos php instalados en el sistema:
#]$ php -m
Esta solucion funciona:
- sudo -u www-data php /path/to/nextcloud/occ maintenance:mode --on
- mkdir -p /new/path/to/data
- cp -a /path/to/data/. /new/path/to/data
- chown -R www-data:www-data /new/path/to/data
- nano /path/to/nextcloud/config/config.php 'datadirectory' => '/new/path/to/data',
- mysqldump -u
-p > /path/to/dbdump/dump.sql - Adjust "oc_storages"database table to reflect the new data folder location: mysql -u
-p //enter mysql root password, then within mysql console: use ; update oc_storages set id='local::/new/path/to/data/' where id='local::/path/to/data/'; //take care about backslash at the end of path!! quit; - sudo -u www-data php /path/to/nextcloud/occ maintenance:mode --off
Deespues borar el directorio antigüo. rm -R /path/to/data //old location!!
[jmgomez@greencloud cloud-data-backup]$ sudo psql -d nextcloud -U nextcloud -W Password: psql (12.2) Type "help" for help.
nextcloud=> \l List of databases Name | Owner | Encoding | Collate | Ctype | Access privileges -----------+-----------+-----------+---------+-------+------------------------- nexcloud | nextcloud | SQL_ASCII | C | C | nextcloud | nextcloud | SQL_ASCII | C | C | nextcloud=CTc/nextcloud postgres | postgres | SQL_ASCII | C | C | template0 | postgres | SQL_ASCII | C | C | =c/postgres + | | | | | postgres=CTc/postgres template1 | postgres | SQL_ASCII | C | C | =c/postgres + | | | | | postgres=CTc/postgres (5 rows)
nextcloud=> SELECT nextcloud; ERROR: column "nextcloud" does not exist LINE 1: SELECT nextcloud; ^ nextcloud=> SELECT nextcloud nextcloud-> UPDATE oc_storages set id="local::/var/cloud-data" where id='local::/usr/share/webapps/nextcloud/data" nextcloud'> select * from oc_storages nextcloud'> \d oc_storages nextcloud'> quit Use control-D to quit.
https://help.nextcloud.com/t/howto-change-move-data-directory-after-installation/17170
sudo -u http php /usr/share/webapps/nextcloud/occ files:scan --all
sudo -u www-data php /usr/share/webapps/nextcloud/occ maintenance:mode --off
Nextcloud
Introduccion
Usar nextcloud para syncronizar el movil.
Instalación de Nextcloud
https://linuxize.com/post/how-to-install-and-configure-nextcloud-on-centos-7/