Disappearing virtual users!!! nooooooo

motobrandt

Verified User
Joined
Jan 8, 2004
Messages
217
OK... in a nutshell first, I added 47 email users to a site that already had 5 on it. Everything looked fine. When I looked again 2 hours later all of the users that I just added were gone!

I have already moved about 150 sites to this server from my other servers with no problems well atleast not like this.

Here is the long story. The website was hosted on one server. The mail on another. The plan was to combine them onto the new DA server. I have a script that moves the users over and one that does their passwords. And one that does the mail spool. (All of this is moving from a Cobalt Raq4 to DA running on FreeBSD 4.8) So I first did the move from the web server. Great everything went fine except for the cgi-mailing list DADA but that's for another post. That is where the first 5 users came from. Then I used the same scripts to move the users and passwords from the mail server (again a Cobalt Raq4). Right after I did it I went to the interface to check and see if they made the move properly and sure enough they did.
Then a few minutes later I looked again and they were gone! I tried the script again and it failed, like it should when the users are already on the destination server. Then today I decided to enter all of the users manually through Direct Admin. Everything went fine again. And again a couple of hours later all of the new names were gone.

HELP!!!??? WTF???

It appears that I can't add more users or something. All of the fields for the reseller and the User are set to unlimited.
 
Hello,

The only time DA touches that file is when users are added or removed... There is no active checker at all for that file so I'm clueless as to why the file would magically empty itself. (First time I've heard of it happening). If you weren't adding/removing any users to it at that time.. it's unlikely to be DA.. probably unrelated, but check the /etc/virtual/domain.com_off just in case the domain got suspended..

John
 
hmmmm

Nope, not suspended. Can I just delete the passwd file? And re-enter the users? Or do I need to empty the file and leave it there?
 
Hello,

You *should* be able to do whatever you want to it without worry.. it might be a good idea to figure out why the file is being dumped. (the file has to exist before DA will add users to it).

Also maybe double check the permissions you were using.

John
 
I'll try

Ok I'll empty the file so that it will be there for DA to use. No permissions were altered as the script that I used to add users was just using the API commands.
 
of course!

Well the issue here was the script to migrate the passwords from the shadow file. Moving users with a script was successful. Creating users in the interface was successful. But when I ran the password script the new users dissapeared. In case any one is wondering or you Roark :) the problem was this.
The password script first looked at /etc/virttual/domain.com/passwd.bak if there is no backup of the passwd file it created one. Then the script looks at the users in passwd.bak and compares it the imported shadow file. Then adds the info to the new passwd file (username and encrypted password). The issue was this. Since this site came from two different servers the users from the first server made it and the passwords worked. But then those users populated passwd.bak. So when ever the password script ran it looked to see if passwd.bak existed and if it did it used those users to populate passwd. Effectively erasing the users that had just been added. The fix? rm passwd.bak

Ahhhggg. I'll have to fix that script to just make the new passwd.bak whether it already exists or not.

If anyone is migrating from a Cobalt Raq4 to DA these scripts are available and work quite well. I just found the only bug. I think ;)
 
Back
Top