[SOLVED] Configure Postfix & Dovecot to NOT use system users.
Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
sudo groupadd -g 5000 vmail
To create a virtual mailbox owner:
sudo useradd -m -u 5000 -g 5000 -s /bin/bash vmail ##### YOU forgot to execute this
Edit main.cf
sudo vi /etc/postfix/main.cf
Set up Postfix to use virtual mailboxes
Add the following code segment to main.cf
virtual_mailbox_domains = /etc/postfix/vhosts
virtual_mailbox_base = /home/vmail
virtual_mailbox_maps = hash:/etc/postfix/vmaps
virtual_minimum_uid = 1000
virtual_uid_maps = static:5000
virtual_gid_maps = static:5000
I have tried to run the missing command and got the following:
root@server.aevtech.com [~]: sudo useradd -m -u 5000 -g 5000 -s /bin/bash vmail
useradd: group '5000' does not exist root@server.aevtech.com [~]: groupadd 5000
groupadd: group '5000' already exists
I checked everything else and that was done and good to go. But, how come it is telling me the group is not there in one error and it tells me it is in another?
Last edited by FortressMvelez; 08-27-2013 at 12:15 PM.
root@server.aevtech.com [~]: sudo useradd -m -u 5000 -g 5000 -s /bin/bash vmail
useradd: group '5000' does not exist root@server.aevtech.com [~]: groupadd 5000
groupadd: group '5000' already exists
The above is wrong execution.
Now try to understand what the command is doing:
Code:
sudo groupadd -g 5000 vmail # add a group with gid 5000 and name vmail
sudo useradd -m -u 5000 -g 5000 -s /bin/bash vmail #Add a user with uid 5000 gid 5000, a default home directory and name vmail.
See above and compare what mistake you were doing since the start on this procedure.
Go ahead delete the existing group you created incorrectly and create again with above commands.
For now i dont know much about roundcube, so its better to mark this thread as SOLVED and open a new thread to figure out how to assign password to these email addresses and access them in Roundcube.. someone should have info on that.
meanwhile i will try configuring roundcube on my test machine and will do some R&D on your requirement.
Yeah i thought you have already set it up for dovecot as the link i shared has the info of setting the users and password using dovecot too and the same can be used in Roundcube ...after what i have searched so far about roundcube.
So follow the documentation again for dovecot and you are all set to go to use it for roundcube.
@descendant_command: Thanks for the hint
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.