SOLVED - How to reset / reinitialize nextcloud - NC-17

The system is Fedora 29, nextcloud version 17.
Background: Installed nextcloud and was able to complete the configuration and perform initial testing including logging in from local network and syncing files.
However that process was not without errors, such as the database is sqlite instead of mariadb. I would like to reset nextcloud.
How can this be done?
Is there an occ command that will reset the configuration?

  • follow up:
    I have done the following:
    erased the contents of the /data directory
    edited config.php to set installed to false
    touched a file CAN_INSTALL in the config directory and set the ownership to apache:apache
    These resulted in the initialization page from /localhost/nextcloud/index.php - a good start
    However the screen shows the default database as sqlite. config.php has it set as:
    ‘dbtype’ => ‘mariadb’,
    Is there a miss spelling? I this not the correct name?
    (I also tried mysql but that did not work either)
    There is an expansion box on the login screen that brings up the database option screens.
    Now there is a ‘no column with the name “remember”’
    I logged into mysql and dropped the nextcloud database. I then recreated the nextcloud db. With nextcloud set with install false I started the initialize process. This all worked.
    This is closed.

Thanks, Dan

1 Like

if you do this more often try occ maintenance:install …

cd /var/www/nextcloud/
sudo -u www-data php occ maintenance:install --database
"mysql" --database-name "nextcloud"  --database-user "root" --database-pass
"password" --admin-user "admin" --admin-pass "password"

remove …/data, config/config.php and recreate the database before.

Excellent guide! saved my night