Databases

Databases, users, remote access and caches.

Guides

Frequently asked

Which database engines does SrvYard support?

MySQL, MariaDB and PostgreSQL. A server runs MySQL or MariaDB, not both, but PostgreSQL can run beside either. Install an engine from the Services tab if the Databases tab says none is installed. See Create a database and a user.

Can I see a database password again?

Yes, if SrvYard created the user: use Reveal password on the Users tab. If the user was imported, SrvYard has no copy, so reset the password instead and update your .env. See Create a database and a user.

How do I connect my site to its database?

Switch on Connect to database when you create a PHP site and SrvYard writes the settings into the .env, or edit them yourself later. On the same server use 127.0.0.1 as the host. See Connect a site to its database.

How can I reach a database from my own computer?

Use an SSH tunnel, which needs only your own SSH key on the server, and point your database client at the local end. Do not open port 3306 or 5432 to the whole internet. See Remote access, phpMyAdmin and SSH tunnels.

How do I import or export a database?

There is no import or export button. Export by running a backup and downloading the SQL file; the download link is valid for five minutes. Import a dump through an SSH tunnel or over SSH. See Import and export a database.

Should I use Redis or Memcached?

When in doubt, Redis. It can serve cache, sessions and queues in Laravel and can persist data. Memcached is a simpler cache that loses everything on restart. Check the Services tab first, as Redis may already be installed. See Redis, Memcached and cache services.

Does SrvYard install Elasticsearch or Typesense?

No. Meilisearch is the only search engine it installs and manages. Others can be installed by hand over SSH, but SrvYard will not manage them. See Meilisearch and other search services.