Transferring Users

Discussion in 'General' started by dayjahone, Aug 26, 2008.

  1. dayjahone

    dayjahone Member

    I have two servers (mail and web) that I am trying to combine into one. I am following the instructions outlined here for transferring all of the websites, DBs, and admin users from the web server to the new server. Is there a way to transfer the users from the mail server to the new one?

    Thanks.
     
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    Which username prefix do you use?
     
  3. dayjahone

    dayjahone Member

    I use DOMAIN_
     
  4. till

    till Super Moderator Staff Member ISPConfig Developer

    With this username prrefix, the transfer yhould be possible. But you will have to recreate the users in the new machine first in ISPConfig and then copy their home directories (incl. the mail dirs) over to the new server. The passwords for the users can also be copied line by line to the shadow file on the new server, so that they replace the current lines.
     
  5. dayjahone

    dayjahone Member

    Do you mean the "Maildir" directories inside the user's directory?

    Sorry. I didn't understand this line. Where is the shadow file?

    Thanks.
     
  6. falko

    falko Super Moderator Howtoforge Staff

    Yes.

    It's /etc/shadow.
     
  7. dayjahone

    dayjahone Member

    Is there any way to do it if one uses the "webID" prefix and one uses the "domain" prefix? I'm basically just interested in getting the messages from the old server. Thanks.
     
  8. falko

    falko Super Moderator Howtoforge Staff

    I think you're overcomplicating this by using different prefixes.

    What exactly is the step where you're having problems?
     
  9. dayjahone

    dayjahone Member

    I have two old servers that I am trying to move to one new server. One of the old servers uses the DOMAIN_ prefix and the steps are outlined above on how to transfer them to a website with the same DOMAIN_ prefix on the new server. Old server #2 uses the webID_ prefix. I am simply trying to move users from old server #2 to the new server. Because of the different prefixes and different webIDs, the users won't match up on the new server, which uses the domain prefix. Is there a way to simply copy the email messages from one account to another?
     
    Last edited: Sep 20, 2008
  10. dayjahone

    dayjahone Member

    Transferring users from a server that uses DOMAIN_ prefix as outlined above (creating user, copy user folders, paste password in "shadow" file), I tried using webmail and got errors. As it turns out, it varies from one webmail to another:

    Telaen Webmail: seems to work fine.
    Roundcube: "...could not find the page."
    Squirrelmail, I get the following:

    Code:
    ERROR: IMAP server closed the connection.
    Server responded:* BYE [ALERT] Fatal error: Account's mailbox directory is not owned by the correct uid or gid: 
    Any ideas why it might work on one and not the others?
     
    Last edited: Sep 20, 2008
  11. falko

    falko Super Moderator Howtoforge Staff

    I think you can simply copy over the Maildir directory of each user to the new home directory of the user on the new server. Make sure that you adjust the ownerships of the Maildirs on the new server.
     
  12. dayjahone

    dayjahone Member

    Yeah, same thing...It works fine with Telaen webmail, can't find the server with roundCube and gives the same error with Squirrel mail:

    Code:
    (ERROR: IMAP server closed the connection.
    Server responded:* BYE [ALERT] Fatal error: Account's mailbox directory is not owned by the correct uid or gid:
    Does it have anything to do with the fact that the name of the files in Maildir reflect the name of the old server? So, on the old server (server.mydomain.com), there is a file like 123413413134987.11749_0.server and I'm moving it to my new server, server1.mydomain.com.

    Basically all I did was copy the Maildir directory (not the /web directory) and then changed the permissions:
    Code:
    chown -R mydomain.com_user Maildir
     
  13. till

    till Super Moderator Staff Member ISPConfig Developer

    Cou should chown to the user and group, so e.g.

    chown -R mydomain.com_user:web123 Maildir
     
  14. dayjahone

    dayjahone Member

    Till and Falko:

    You guys are amazing human beings. Thanks for all of your help always. If I have any extra cash at the end of the year, I'm throwing it your way.
     
    Last edited: Sep 23, 2008

Share This Page