DA internals with mysql ...

GlennH

Verified User
Joined
Jul 10, 2004
Messages
49
hello all,
What ever happened happend to my server and Im haggling it back together,

I managed to copy the mysql db's from the old drive to the new DA server and place them in /var/lib/mysql and then
chown -R mysql:mysql user_db
now the new DA can see the db and size, however DA shows -1 users. I add a user through DA and now it shows 0 users.

A DB created through DA will normaly show 1 user

So, who am I missing as a user ?
DA itself ?

If so how whats the best approch to adding them to keep it al nice ?

Glenn
 
If you copied all the files and directories from /var/lib/mysql then all the users should still be intact with their old permissions, as well as all their data.
 
Nevermind,

The missing user was the da user who created the domain that created (or was supposed to create) the db.

launced phpmyadmin as root, added the user to the db...

nice when it works !

One question, when I copied the dbs over how did da know to add it self to the list of users ?

does da see any new dbs and add it self ? if so why wouldnt da add the user in the db name ?

For example
userx_database moved to the /var/lib/mysql folder when da reloads and adds itself why cant it add userx if exists also ?


Glenn
 
As I said, if you copied the whole directory structure of /var/lib/mysql, then you should not have to do anything, all the users and databases should be intact. If you wiped out the mysql database, then I can see you having to restore users. DA does not know how to add itself to MySQL, it only knows about the da_admin user. That is the account that DA uses to add all the other users with.

I could be wrong, but I don't believe DA adds itself to any user database, as a matter of fact, I'm not sure where you are getting the user numbers, if it is from the statistics page of DA, that number has nothing to do with MySQL, that is taken from the data in the /usr/local/directadmin/data/users directory. There should be a directory for each user there including DA.
 
toml,
Sorry I didnt see your post,
The only files I copied were the dbs themselves.

I didnt want to bite off more then I could chew....


Glenn
 
You should not have any problems copying the whole directory and subdirectories. Otherwise you will have to figure out the passwords for all the users as well as setting up the permissions for each user. Much easier to just copy everything.
 
Back
Top