Missing Mail?

15 posts / 0 new
Last post
#1 Fri, 06/02/2006 - 22:14
AdamHolt

Missing Mail?

Im not sure what I've done, but I used to use everydns.net for my DNS information and mail use to be delivered fine.

Now I switched over all the sites hosted to use dnsexit.com because they have a simple perl script that runs as a daemon on the server and updates the dynamic ip address assigned to us (of course the IP address has only changed once in 8 months thankfully)

But now when I attempt to send mail to a couple different email address's that are on the server, it never gets delivered.

Im hoping someone else here might be using dnsexit.com and can instruct me as to what Im doing wrong.

For the MX record in dnsexit wizard Im inputing the domain names like mydomain.com priority 5

Is there anything I can do to check if it's actually a server problem and not a record problem?

Sat, 06/03/2006 - 02:44
Joe
Joe's picture

Hey Adam,

You can send a message from the command line of the server itself, to a username (rather than an email address) on the system. For example, if I were testing my mailbox on virtualmin.com I would do the following:

echo "Tested" | mail -s "Testing" joe

This doesn't test for outside accessibility of your mail system, but will prove that mail delivery is working locally.

But, really, the first place to go when you're running into mail problems is the maillog (in /var/log/maillog on most Linux systems). Watch it with "tail -f /var/log/maillog" and then try to send an email to one of your accounts. If you see nothing at all logged, it's probably DNS troubles, if you do see something it'll probably give you a good clue about what is actually going wrong.

The "host" command is a good tool for debugging DNS troubles, if it does turn out to be the source of your woes. The simplest test case would go:

[[joe@delilah ~]]$ host -t mx virtualmin.com
virtualmin.com mail is handled by 5 mail.virtualmin.com.
[[joe@delilah ~]]$ host mail.virtualmin.com.
mail.virtualmin.com has address 70.86.4.226

Holler if you get something you aren't sure what to do about in any case. We can probably help.

--

Check out the forum guidelines!

Thu, 06/08/2006 - 12:30
AdamHolt

Hi,
Okay, I tried the host commands and they appear correct,
I tried host -t mx brainboxdesigns.com and it returns
brainboxdesigns.com mail is handled by 5 brainboxdesigns.com.

I tried host brainboxdesigns.com and I get
brainboxdesigns.com has address 74.62.4.231 (which is the correct current IP address I have.

When using the tail command to view the mail log I and sending a message use echo "test" | mail -s brainboxdesigns I get the following in the mail log

Jun 8 08:24:34 www postfix/qmgr[[29475]]: 91D295FC68: from=[[ me @ www.xxxxxxxxxxxx.com]], size=448, nrcpt=1 (queue active)
Jun 8 08:24:34 www postfix/local[[13559]]: 91D295FC68: to=[[ brainboxdesigns @ www.thriftyserve.com]], orig_to=[[brainboxdesigns]], relay=local, delay=0, status=sent (delivered to command: /usr/bin/procmail -o -a -d)
Jun 8 08:24:34 www postfix/qmgr[[29475]]: 91D295FC68: removed

I do receive this email when I send it from the command line.

But anything I send from my windows box to the server does not get received.

Where should I check next?

Thanks,

Thu, 06/08/2006 - 14:54
Joe
Joe's picture

Hey Adam,

Next up is to run the same tail command while sending mail from your usual mail client. We've gotta find out where the email is ending up. If nothing shows up in the log, I'd probably suspect a firewall getting in the way. If an error shows up, we'll be able to figure out what to do based on what the error is.

--

Check out the forum guidelines!

Fri, 06/09/2006 - 01:15
AdamHolt

Okay, I think you've given me something to look at.

I recently had to reload the firmware on the router. Perhaps I didnt setup the port again for mail to get directed to the server.

Is port 25 the only port I need to route to the servers IP address for the mail to function properly?

Thanks for your time and effort.

Tue, 04/17/2007 - 02:36
daviddavid

hey, i am having some issues with mail as well...i suspect i havent set it up though.

i did the tail and mail from command i get
Apr 17 00:24:25 ip-99-99-99-99 postfix/cleanup[[7982]]: 9AC617700CB: message-id=<20070417072425.9AC617700CB@xx-xx-xx-xx-xx.ip.secureserver.net>
Apr 17 00:24:25 ip-99-99-99-99 postfix/nqmgr[[30503]]: 9AC617700CB: from=<root@xx-xx-xx-xx.ip.secureserver.net>, size=398, nrcpt=1 (queue active)
Apr 17 00:24:25 ip-99-99-99-99 postfix/lmtp[[7996]]: 9AC617700CB: to=<midnightprophet@xx-xx-xx-xx.secureserver.net>, orig_to=<midnightprophet>, relay=none, delay=0, status=deferred (connect to /var/lib/imap/socket/lmtp[[/var/lib/imap/socket/lmtp]]: No such file or directory)

i imagine i should stop there, but i go on!

host -t mx domain.com
domain.com mail is handled by 0 mail.domain.com.

host mail.domain.com
mail.domain.com is an alias for mail.domain.com.
mail.domain.com is an alias for mail.domain.com.
mail.domain.com is an alias for mail.domain.com.

just installed virtualmin pro onto FC4, i have a domain as you see above and it was hosted at godaddy, i went and changed the records at go daddy to point to my new godaddy server, ie:
email email.secureserver.net
mail pop.secureserver.net
pop pop.secureserver.net
smtp smtp.secureserver.net
webmail webmail.secureserver.net
e email.secureserver.net

changed all the above to mail.domain.com, im sure once i have a clue i will change them to the correct addresses, like pop

but for now, still trying to figure out which way is up and which is down, still searching the forums, but if anyone has a quick tip of where to look, let me know

Tue, 04/17/2007 - 02:39
daviddavid

crap, can you edit this post and take out the IPs? i dont see an edit feature

Tue, 04/17/2007 - 03:23
daviddavid

SpamAssassin and Procmail are installed. However, your mail server does not appear to be configured to deliver using Procmail.

i am reading the manuals now to see whay i need to do, but thought i would add this, this is what happens when i do config check

Tue, 04/17/2007 - 03:50 (Reply to #8)
Joe
Joe's picture

Hey David,

<i>SpamAssassin and Procmail are installed. However, your mail server does not appear to be configured to deliver using Procmail.</i>

Looks like something screwed up a bit during installation (we've had a bug in the Postfix setup for a few days--it's fixed in the updates I'm rolling out tonight). There's a script that'll run through all of the default configuration steps and correct that here:

http://software.virtualmin.com/lib/virtualmin-base-standalone.pl

--

Check out the forum guidelines!

Tue, 04/17/2007 - 03:45
daviddavid

and in case anyone reads this, i wanted to keep it all under one thread.

i have a domain, its hosted and works just fine. its at godaddy, can i just forward the email mx records to my virtualmin install so i can do all the email stuff on my server?
so :
mydomain.com keep.old.address
mail.mydomain.com go.to.my.new.address

could i do that?

sorry i am such a newb, you should make me pay extree!

Tue, 04/17/2007 - 03:56 (Reply to #10)
Joe
Joe's picture

<i>i have a domain, its hosted and works just fine. its at godaddy, can i just forward the email mx records to my virtualmin install so i can do all the email stuff on my server?
so :
mydomain.com keep.old.address
mail.mydomain.com go.to.my.new.address

could i do that?</i>

I'm not sure what you're asking exactly. You can, of course, set an MX record to point to any server you want, and as long as that server is configured to accept mail for that domain, it'll be delivered.

Note than an MX record points to a name (not an IP), so you'll need to use the name of your new server. So, if I wanted mail from my personal website obsceneart.com to end up in my Virtualmin mailbox, I could switch the MX record to point to mail.virtualmin.com instead of mail.obsceneart.com. No problem there. You then have to make sure Postfix is accepting mail for the domain...there are many ways to do that. If you plan to eventually move the website over, too, you should create the domain in Virtualmin (the website will just be unused since DNS won't point to it yet) and create the right mailbox.

If you don't plan to host the domain on the Virtualmin server, you'll just need to add the domain to the mydestination directive and add one or more users that match your mailboxes from that domain (or forwarding rules to point to existing users). Lots of possibilities here, but the easiest is probably just to pretend like Virtualmin is doing everything but only use the mail feature.

--

Check out the forum guidelines!

Tue, 04/17/2007 - 05:36
daviddavid

thanks for the info, i ran it and here is output, i dont need feedback, just thought you might like to see it

Setting Webmin theme
Setting Usermin theme
Configuring Postfix
Enabling Postfix and disabling Sendmail
Configuring Dovecot for POP3 and IMAP
Enabling Dovecot POP3 and IMAP servers
Enabling ProFTPd
Starting proftpd: [[ OK ]]
Enabling SMTP Authentication
Starting saslauthd: saslauthd[[4442]] :detach_tty : Cannot start saslauthd
saslauthd[[4442]] :detach_tty : Another instance of saslauthd is currently running
[[FAILED]]
Configuring Virtualmin
Configuring Procmail
Configuring Webalizer
Updating /etc/shells
Enabling MySQL and PostgreSQL
Enabling Apache
Configuring and enabling BIND
Enabling status monitoring
Enabling quotas on filesystem for /home
Configuring firewall rules
Allowing traffic on TCP port: ssh
Allowing traffic on TCP port: smtp
Allowing traffic on TCP port: domain
Allowing traffic on TCP port: ftp
Allowing traffic on TCP port: ftp-data
Allowing traffic on TCP port: pop3
Allowing traffic on TCP port: pop3s
Allowing traffic on TCP port: imap
Allowing traffic on TCP port: imaps
Allowing traffic on TCP port: http
Allowing traffic on TCP port: 10000
Allowing traffic on TCP port: 20000
Allowing traffic on UDP port: domain

Tue, 04/17/2007 - 07:47
daviddavid

sumabutch

im reading your book Joe, thinking that will help..this forum needs to be organized a bit more so i can just look in Postfix section! ;)

Apr 17 05:32:40 ip-208-109-107-1 postfix/nqmgr[[1953]]: B42C07700C9: from=&lt;root@ip-208-109-107-1.ip.secureserver.net&gt;, size=398, nrcpt=1 (queue active)
Apr 17 05:32:40 ip-208-109-107-1 postfix/lmtp[[6911]]: B42C07700C9: to=&lt;midnightprophet@ip-208-109-107-1.ip.secureserver.net&gt;, orig_to=&lt;midnightprophet&gt;, relay=none, delay=19743, status=deferred (connect to /var/lib/imap/socket/lmtp[[/var/lib/imap/socket/lmtp]]: No such file or directory)

i tried to manually create the lmtp file and give it permissions, it said something else then, access denied or something similar. i am pretty sure postfix was supposed to setup automatically? if not, then i will just contiune to read that portion of your book, if so, anything i can do to get it to work? i am using shorewall instead of iptables, its all locked down, but i get the above error when trying to send enternally. how the hell 2 people support all these issues is beyond me, do you sleep?
FC4 i ran yum update and got the new update i guess you were talkin about, i had to reboot server to get access to virtualmin again (firewall issue?)

Tue, 04/17/2007 - 08:23
daviddavid

from webmin module postfix/local delievery

i removed lmtp:unix:/var/lib/imap/socket/lmtp from the Optional actual transport to use. not sure if that is a good fix or not though, but it does allow me to send internally now from command line

Tue, 04/17/2007 - 10:11 (Reply to #14)
Joe
Joe's picture

Hey David,

<i>i removed lmtp:unix:/var/lib/imap/socket/lmtp from the Optional actual transport to use. not sure if that is a good fix or not though, but it does allow me to send internally now from command line</i>

Yeah, this is probably the right thing to do. I have no clue where that directive came from. We don't add it, and it's not part of the default configuration on my Debian test system. There are some quirks about the Debian postfix package, but this isn't one that I've seen.

--

Check out the forum guidelines!

Topic locked