Install and Configure SquirrelMail in CentOS 7

Windows Articles

Diskpart is a very useful tool for managing storage in Windows 10.

Hello! Diskpart is an internal tool included in Windows systems that allows you to manage storage units. Indeed, it is possible to manage internal...

How To Install MySQL 8.0 On Ubuntu 20.04

Today we are going to learn that how to Install MySQL 8.0 on Ubuntu 20.04. MySQL is one of the most popular and commonly...

How to Update to MIUI 12 via Fastboot

Greetings friends. The new version of the Android-based operating system MIUI 12 released this year, is still being deployed with some devices missing. On...

How to use modprobe command?

The modprobe command is a Linux administration system created for management, visualization, inclusion and exclusion. From loadable modules to kernel. Also, the Module is...

Install Virtualmin on CentOS 8

Hello, friends. In this post, you will learn how to install Virtualmin on CentOS 8. In addition to that, we will leave it ready...
Muhammad Nabeel
Muhammad Nabeel
Network and System Administrator

SquirrelMail is an opensource webmail package written in PHP. It includes built-in PHP support for the IMAP and SMTP protocols . It has very few requirements and very easy to install and configure.

In this guide you will learn how to install and configure SquirrelMail step by step in Centos 7 and RHEL 7.

Step 1: First of all disable SELINUX using below command

this is not the best choice to disable the firewall because of security purposes, but we are doing this locally. in your case you allow the traffic vie the firewall-cmd rules.

# vi /etc/selinux/config

set SELINUX=disabled

save changes to file and quite

and reboot the server using below command

# reboot

Step 2: Install and Configure Postfix

You must install Epel Repository using below command

# yum install epel-release -y

Now install Postfix

# yum install postfix -y

Now make following changes to posfix file using below command at the end.

# vi /etc/postfix/main.cf
## Enter your hostname
myhostname = osradar.localhost.local

## Enter your domain name
mydomain = osradar.localhost.local

inet_interfaces = all
myorigin = $mydomain

##set your IP range
mynetworks = 192.168.130.138/24, 127.0.0.0/8

## set your mail direcotry
home_mailbox = Maildir/

## Now Go to line no 164 add $domain at the end
mydestination = $myhostname, localhost.$mydomain, localhost, $mydomain

save changes to file and quite

Restart Postfix

# systemctl restart postfix

# systemctl enable postfix

Step 3: Install and Configure Dovecot

# yum install dovecot

# systemctl start dovecot

# systemctl enable dovecot

Now modify below files one by one

make following changes at the end of file /etc/dovecot/dovecot.conf

# vi /etc/dovecot/dovecot.conf

protocols = imap pop3 lmtp

make following changes at the end of file /etc/dovecot/conf.d/10-mail.conf

# vi /etc/dovecot/conf.d/10-mail.conf

mail_location = maildir:~/Maildir

make following changes at the end of file /etc/dovecot/conf.d/10-auth.conf

# vi /etc/dovecot/conf.d/10-auth.conf

disable_plaintext_auth = yes
auth_mechanisms = plain login

make following changes to file /etc/dovecot/conf.d/10-master.conf

# vi /etc/dovecot/conf.d/10-master.conf

unix_listener auth-userdb {
#mode = 0600
user = postfix ## uncomment line 91 and enter postfix
group = postfix ## uncomment line 92 and enter postfix

Now restart Dovecot

# systemctl restart dovecot

# systemctl enable dovecot

Step 4: Install and Configure Squirrelmail

First install and start apache service

# yum install httpd -y

# systemctl start httpd

# systemctl enable httpd

Now install Squirrelmail

# yum install squirrelmail -y

Now go to squirrelmail folder and configure it according to your server

# cd /usr/share/squirrelmail/config/

# ./conf.pl

After changes press S to save settings and press Q to exit.

Now add following lines at the end of httpd.conf file.

Note: If these lines are already added at the end of file SKIP this step.
# vi /etc/httpd/conf/httpd.conf

Alias /webmail /usr/share/squirrelmail
<Directory /usr/share/squirrelmail>
Options Indexes FollowSymLinks
RewriteEngine On
AllowOverride All
DirectoryIndex index.php
Order allow,deny
Allow from all
</Directory>

save changes and quite

then restart Apache and dovecot service

# systemctl restart httpd

# systemctl restart dovecot

Step 5: Create User and Access Webmail

# adduser osradar

# passwd osradar

Finally access Webmail

http://server-ip/webmail

OR

http://yourdomainname/webmail

More articles

3 COMMENTS

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Latest article

Diskpart is a very useful tool for managing storage in Windows 10.

Hello! Diskpart is an internal tool included in Windows systems that allows you to manage storage units. Indeed, it is possible to manage internal...

How To Install MySQL 8.0 On Ubuntu 20.04

Today we are going to learn that how to Install MySQL 8.0 on Ubuntu 20.04. MySQL is one of the most popular and commonly...

How to Update to MIUI 12 via Fastboot

Greetings friends. The new version of the Android-based operating system MIUI 12 released this year, is still being deployed with some devices missing. On...

How to use modprobe command?

The modprobe command is a Linux administration system created for management, visualization, inclusion and exclusion. From loadable modules to kernel. Also, the Module is...

Install Virtualmin on CentOS 8

Hello, friends. In this post, you will learn how to install Virtualmin on CentOS 8. In addition to that, we will leave it ready...
x