====== Creating Required Users and Groups ====== This page is supplemental to main article: [[howtos:network_services:postfix_dovecot_mysql|Creating a Virtual Mail Server with Postfix, Dovecot and MySQL]] You will need to create a few special users and groups to be able to build and/or run your mail server components. We will use the SBo assigned uid and gid for each user and group. To prepare to build or install postfix, execute the following commands on the target machine: groupadd -g 200 postfix useradd -u 200 -d /dev/null -s /bin/false -g postfix postfix groupadd -g 201 postdrop To prepare to build or install dovecot, execute the following commands on the target machine: groupadd -g 202 dovecot useradd -d /dev/null -s /bin/false -u 202 -g 202 dovecot groupadd -g 248 dovenull useradd -d /dev/null -s /bin/false -u 248 -g 248 dovenull Additionally, we must create a user, group and target directory for the virtual mail functions. There is no recommended uid/gid for these but a common choice for both is 5000. You may wish to change these to suit your own environment. Execute the following commands on the install machine (these are not necessary when building): groupadd -g 5000 vmail useradd -d /var/vmail -s /bin/false -u 5000 -g 5000 vmail mkdir -p /var/vmail/vhosts chown -R vmail:vmail /var/vmail To test whether these users or groups already exist on a machine, substitute the user or group names into the respective commands: cat /etc/passwd |grep ^postfix cat /etc/group |grep ^postdrop If the corresponding name exists it will be shown, otherwise you will see only an empty prompt in response. For troubleshooting you should verify that each user and group is defined on your machine as shown here. [[howtos:network_services:postfix_dovecot_mysql|Return to main article page]] ====== Sources ====== * Originally written by [[wiki:user:astrogeek | astrogeek]] {{tag>howtos email postfix dovecot}}