LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   how to import users in qmail from text file (https://www.linuxquestions.org/questions/linux-software-2/how-to-import-users-in-qmail-from-text-file-512377/)

Braytac 12-20-2006 06:40 PM

how to import users in qmail from text file
 
Hi all
I have been given the task to roll out a linux mail server which i have decided to use Debian and Qmail. I was wondering if there is any way to import bulk users eg: 1000 user accounts, from a text file say from Active Directory. we will be using unchangable passwords which suits the needs fine however apart from creating users through the qmailadmin web page i do not know how to create the accounts+mailboxes, if someone has done this in the past or has any recomendations it would be greatly appreciated.

thanks

fordeck 12-21-2006 12:04 PM

If your system is using regular user accounts (i.e. passwd) then you could use the command "newusers". You can find out more by reading the man pages for "newusers". Here is a link that goes over his version of it. You can find many more by googling with the keywords "batch newusers".

Hope this helps,
Fordeck

Braytac 12-21-2006 03:42 PM

thanks for the suggestion. how would i use system accounts? would this be technically for the default domain? would they show up in qmailadmin? i have used and most likely will do again go by the qmailrocks.org install guide.

fordeck 12-22-2006 08:43 AM

If you're using the qmailrocks guide then you would have choosen to use either Mysql or system accounts. This decision would have been made on the "Part 5 - Vpopmail" portion of the install.

I have done it without mysql, so I probably won't be able to help much with mysql. However it's probably just as easy by doing some sort of a database import.

Regards,
Fordeck

Braytac 12-24-2006 03:29 AM

thanks fordeck. i have only ever used QMR without mysql integration in the past. however I am unaware of how qmail manages individual user accounts, if they are managed via text files? is it dificult to switch from non-mysql to system accounts?

fordeck 12-24-2006 09:43 AM

Quote:

i have only ever used QMR without mysql integration
That is also the way I've done it in the past. So take a look at this link. Also take a look at the man pages for the "newusers" command. That should give you a pretty good understanding of the process. You will undoubtedly need to modify your user text file from exchange to be similar to the /etc/passwd file. Without seeing a sample of this text file I can't advise on how this could be done. But you have an example of the layout by looking at your /etc/passwd file. The /etc/passwd file shows you what the newusers command expects. Linux provides tools like "sed", "awk", "cut" that help automate modifying your exchange text file.


All times are GMT -5. The time now is 11:42 PM.