• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

Question Where is my database stored?

Pleskie

Regular Pleskian
I was expection my database to be stored in /var/lib/mysql

I do see some configuration files in there, but I don't see the mydb.sql file itself.

Where should I be looking?
 
Hi,

There shouldn't be any .sql file inside that directory, your database naming should be something like: /var/lib/mysql/database_name

If you can tell us what exactly are you trying to achieve we may be able to help you further.
 
Hello SBDavid

Thanks for your reply.

I see that folder you are talking about.

What I want is to make a backup from the database file with all of its content.

In PHPMyAdmin I can export the database to mydb.sql.

I thought there would be a file mydb.sql on the server as well. Am I wrong?
 
Hello,

As far as I can recall PHPMyAdmin will let you download the .sql dump to your computer only, there is no option to store it on the server.
 
Really? So nowhere on my server is a file that contains my database contents? :-s
Then where is all this data stored?

So if I understand correctly there is no mydb.sql file anywhere on the server, and the only way to create a back-up is from within Pleks of PHPMyAdmin?
 
You can achieve what you are looking but its within Plesk, not PHPMyAdmin.
Go to the "Databases" section for the Plesk domain in question and click on "Export dump", you will be now able to store it on the server.
 
>> Go to the "Databases" section for the Plesk domain in question and click on "Export dump", you will be now able to store it on the server.

Yes, I have seen that option. PHPMyAdmin also has an export option.

But actually I was hoping there would be a physical file mydb.sql so I could create a symlink to this file in my vhost folder, so I could easily backup my website (files) and db in just a few clicks.

I don't like to have to login to Plesk every time just for downloading my db :-(
 
If the Database is a InnoDB a Copy of the mysql Folder dont work.
Use instead automysqlbackup
On Debian/Ubuntu "apt-get install automysqlbackup"
Automysqlbackups makes automatic Backups daily/weekly/monthly.
 
Thanks for your reply. I did some research on automysqlbackup, but it seems I can't create a specific backup location for a specific database.

What I want is to somehow get the .sql dump (of domain abcxyz.com) into my vhost directory (of domain abcxyz.com).
So when I make a backup of the vhost directory (of domain abcxyz.com) it also includes the database.

Is that somehow possible?
 
Thanks, but is seems quite old and way too complex for what I want.

Maybe Plesk itself will come with a solution one day. For now ... I'm afraid it has to be done manually :-(
 
Old?
Last Update 24 Days ago.... but yea is really old...
to Complex? Upload the Script --> Add Database Login --> Add Cronjob = 5-8 Minutes
 
My mistake ... I saw last update from 2011.

However ... it looks complicated when I look at the screenshots. I just want to make a simple export.
I'll look into this later when I have more time.

If anyone else has tips how to easily back-up a database, please let me know :)
 
What could be easier than using the 1-click database backup of Plesk that @SBDavid suggested in his post???
Yeah, that's easy ... but the only thing is that I have to login every few days to create a back-up. It would have been cool if it was done automatically every day. Well, I'll just have to use this option for now then. Thanks.
 
Have you noticed the backup function in your control panel?
Customer control panel > account > backup websites
You can create a scheduled job that backs up your database and your files to either the local server or an FTP repository, e.g. automatically run a full backup each night or choose to run a full backup every week and incremental backups daily.
 
I think I've seen a back-up option in Plesk Panel somewhere, but I don't recall being able to backup a specific database to a specific location on the server.

Can that be done? Because maybe I missed that option ...
 
Back
Top