EMail server setup: FC6+Postfix+Dovecot+Squirrelmail
Linux - NetworkingThis forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.
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.
EMail server setup: FC6+Postfix+Dovecot+Squirrelmail
I'm setting up a server for a small home network to bring mail and web hosting in house, but have gotten stuck part of the way. I have dovecot and postfix installed and running. I have already set up a local DNS server and it seems to be working okay:
If I send mail from the command line as root, it shows up in root's mailbox just fine:
Quote:
# echo "test of a test" | mail -s "a test" root
# cat /root/Mailbox
From root@mydomain.org Sat Jul 28 14:47:54 2007
Return-Path: <root@mydomain.org>
X-Original-To: root
Delivered-To: root@mydomain.org
Received: by mail.mydomain.org (Postfix, from userid 0)
id 2490CC404F5; Sat, 28 Jul 2007 14:47:54 -0600 (MDT)
To: root@mydomain.org
Subject: a test
Message-Id: <20070728204754.2490CC404F5@mail.mydomain.org>
Date: Sat, 28 Jul 2007 14:47:54 -0600 (MDT)
From: root@mydomain.org (root)
test of a test
When I log into the squirrelmail though, the INBOX is empty. This seems wrong. This same behavior also occurs for a non-root account (richard@mydomain.org).
When I send mail from the command line from a non-root account, all seems okay and the message is received fine (note that otherdomain.com is completely external to mydomain.org):
Notice that the sender address has "localhost" embedded in it address. In fact, the 3rd line above (for "postfix/pickup") refers to richard@localhost.
This led me to check on my host designations. I'm still new at networking details, so I may have made some mistakes here. Note that this server is my firewall and gateway for the rest of the network and so has two NICS: ethOUT (IP=yyy.yyy.110.54) and ethLOCAL (IP=192.168.xxx.115). As part of my testing, I lowered the firewall briefly to verify that it wasn't a factor. Finally, hosting of mydomain.org is actually currently elsewhere as I'm trying to set up to bring it in before I switch the public dns records: nonetheless, given the symptoms so far, I doubt that would be a contributing issue.
Quote:
# uname -a
Linux poppa.mydomain.org 2.6.20-1.2962.fc6 #1 SMP Tue Jun 19 18:24:12 EDT 2007 i686 i686 i386 GNU/Linux
# uname -n
poppa.mydomain.org
# hostname
poppa.mydomain.org
# hostname -a
So my questions:
1) why isn't Squirrelmail seeing the email in the user mailboxes?
2) why does sending through Squirrelmail embed localhost in the sender address?
Some ancillary questions:
3) is there anything that looks out of whack on my hostname setup?
4) if I don't do a # setsebool httpd_can_network_connect = 1, squirrelmail fails. I can make this permanent, but is that the right thing to do or is there a preferred way to more directly target Squirrelmail as an allowed script engine?
Sorry for all the quoted detail, but I'm at loss as to what is the likely culprit. Thanks for reading this far....
I have tried to set up KMail to read from both the root and non-root accounts through both imap and pop3. The imap won't connect, so that seems related to some security setting, but the pop3 connects but comes back empty. The pop3 behavior leads me to believe that there is a mismatch between where postfix sends the email and where dovecot expects to find it.
I don't know where to look for this discrepancy and it isn't obvious from the configuration files. If I can resolve the pop3 issue, it might simplify the imap issue.
Any advice? Is there a way to confirm my hypothesis on the mailbox mismatch?
Distribution: Linux Redhat 9.0, Fedora Core 2,Debian 3.0, Win 2K, Win95, Win98, WinXp Pro
Posts: 344
Rep:
You will have to set up someone in your sendmail's access file to send root's mail to. It won't allow "root" to log in and retrieve mail from that account. If you look in etc/mail for the access file, enter in someone (a valid user) to recieve root's mail, it should work just fine. Try that and repost.
It might have been obscured with all my description, but the issue with squirrelmail happens even with non-root accounts. The mailbox for a non-root account, richard@mydomain.org, accessed via POP3 comes up empty even though mail is sitting in /home/richard/Mailbox.
Quote:
You will have to set up someone in your sendmail's access file to send root's mail to.
I'm running Postfix instead of sendmail. I found /etc/postfix/access but that doesn't seem to be what you're suggesting.
Test it: Open your favorite browser and go to http://your.hostname.com/webmail and log in with the NON-ROOT user and password. If everything worked out well, you should have a new mail in your inbox.
My server is now online and receiving mail from the Internet fine. Incidentally, I'm only the using DNS setup internally, my domain name provider is handling my public DNS records, so that part of my setup in my original post is not really relevant.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.