Database Conversion

The SQLite database is good for testing, and for ownCloud servers with small single-user workloads that do not use sync clients, but production servers with multiple users should use MariaDB, MySQL, or PostgreSQL. You can use occ to convert from SQLite to one of these other databases.

db
 db:convert-type           Convert the ownCloud database to the newly configured one

You need:

  • Your desired database and its PHP connector installed.

  • The login and password of a database admin user.

  • The database port number, if it is a non-standard port.

This is example converts SQLite to MySQL/MariaDB:

sudo -u www-data php occ db:convert-type mysql oc_dbuser 127.0.0.1 oc_database
For a more detailed explanation see converting database types.