Huge MySQL problems

alphaxs

Verified User
Joined
Sep 12, 2004
Messages
12
Location
Brummen
Hi there, hoping that anyone know an good, or proper solution for this problem:

Today we had an MySQl crash, wherefore it was needed to reinstallate the MySQL deamon.

So in good trust, i did an reinstall of mysql, deleteing the old directory, because i thought in my mind that it whas no problem at all.

I would make an notice on the forum about deleting all the mysql data and then it will be restored by placing back all backups from last night.

But... here it comes:

now all backups are restored, and nog mysql databases are placed back.

So is there any way to restore the mysql databases back from scratch, out of the user or system backups?

Bot are in our possession, but then i shure have to know where to look, because wherever i look, there's nowhere to fin someting that looks like an myswl dump.

Kind regards,

Mark Bevelander
Alpha XS Internet services
 
If your backups are restored, everything should be fine?
A manual restore will take ages depending on the amount of accounts you have.

It would be possible to create a script for it though. The files are located in the backup directory within the tar archive, including configuration files.
 
The user backups (if done from the reseller level) should have MySQL data. The system backup will only have MySQL data if you told it to back it up.
 
Well, the strange thing is.. that when putting a large ammounbt of accounts (selecting them all) the user backups won't be placed back.

When doing it at by ten per time, it works perfectly.

But still, the mysql dbases aren't placed back.

While user backups are placed back.

so the question is, what's wrong with mysql...

Because mysql works perfect.
 
Do the logs have any information as to why DirectAdmin couldn't restore them?
For example, did you setup mysql with the same da_admin username and password that directadmin uses?

What Operating system and version of DirectAdmin are you running. The won't restore over 10 users at a time might be a bug. Do you get any error messages?
 
yes indeed i did setup mysql with the same password, but username looks to me, as not possible, because you uses da_admin as username, against admin.

but the password is the same, is this the problem???

Also i still can't find any .sql dump file in certain user backups.
not all, the most are restored yet, but a few (for about 40 accounts) won't restore any sql. dbase.
 
If some mysql databases are restoring properly then it most likely isn't a problem with the password. In short, you should have a MySQL superuser setup with the same information as stored in /usr/local/directadmin/conf/mysql.conf
You can change the values in that file to use your own user of course, however da_admin is the default.

If the backups don't contain any sql files then the user probably didn't have any databases created. (hopefully)
 
Last edited:
mysql

indeed,

the problem is yet solved, but still there is something i worry about.
Some user backups did not have any sql files in it.
Thath while there are serveral mysql databases on the account itself..

So the strange thing is why those user backups are backupped, but not with sql dump files in it.

Did change the backup config last night, to see if something changed for now, it's about waiting until tonight past twelve, to see if something is changed.

anyway thanx voor the support, in some way it sure helped me a lot, with finding some things, (things i did not think about myself)
 
We've noticed that mysql databases created in the DA control panel are backed up while databases created in phpMyAdmin are not.

Is this your situation?

Jeff
 
Hey Jeff just curious,
What version of DA and phpMyAdmin are you running? DA has been setting permissions such that user accounts can't create databases through anything other than DirectAdmin for me for several months.
 
Lots of systems, lots of different configurations :) .

I do recall that hole being fixed, but I'd bet a lot of folk still have such databases. I know we do.

It pops up when we do inter-server reseller moves.

Jeff
 
What is the bug mentioned here? The same password thing or if the database is created in DA or phpmyadmin? I am developing my own application with mysql and have been using phymyadmin to created the databases and tables. Do I have to create the database with da and then can use phpmyadmin to create the tables and make changes and such, to make sure it is backed up? I had better find out before doing the create for real when the time comes.
 
You used to be able to create databases through phpMyAdmin, since this bypassed DirectAdmin, it wouldn't know of the databases. Because of this you would run into issues where users were creating more databases than they were allowed and backup problems such as Jeff mentioned.

You need to make sure that DirectAdmin recognizes the database on the MySQL Management page.
 
Thanks. I did some testing regarding how all this works and understand. I also know how to get around it with another login (root or da_admin) or direct outside of DA via phpmyadmin via root (which only I have the logins of course), but will do it via my user account in DA to eliminate this issue for myself. Thanks.
 
Hi Tony,

you say you know how to... could you also explain this to us? I haven't had time to test this issue, to see whether it affects me, but if it does I'd sure like to know how to fix it!!

Thanks for your feedback :)

Harro
 
If you have root or da_admin login, you can skip creating the DB as a DA user, you could just either: 1) click phpmyadmin first, and log in as root or da_admin instead of typing in your DA userid and password (since an authentication login screen pops up) and create the database in phpmyadmin with that non-user id, or 2) don't use DA and login via phpmyadmin directly in http as root and create a db. In either case, don't do that or the db won't be tracked in DA. Just create the db first in DA as the user always.
 
ok, thanks!

at first I didn't quite understand your explanation, but after reading your text again I now realise that the first part of your text is what one should NOT do :)

It is clear now :)
 
We're about to move a lot of folk using other control panels, to DA. (We bought some companies.)

Has anyone created a step-by-step How-To to help us go through all the steps of renaming MySQL databases, and getting them up and running on the DA servers?

If so I'd appreciate learning from your mistakes instead of having to create my own :) .

Jeff
 
I haven't found a good way to do that yet. If the other control panel doesn't use the same naming structure as DA (username_dbname) I usually end up restoring the database under a new name that fits DA and then offer to assist the user in searching and updating any configurations that would need to be updated as well.

Quite tedious for any amount of users and frusturating to the client.
I usually work with them one-on-one during the move to make sure everything is working properly (time consuming to say the least).
 
Yes, I know.

I'm considering not renaming them.

Have you tried that?

Has anyone tried that?

What problems does it cause?

Jeff
 
Back
Top