TUTORIAL Gotcha-Free PBX: SMTP Mail Relay with Incredible PBX and Fax for Asterisk-GUI (RasPi 2 Edition)

synack

Guru
Joined
Dec 31, 2013
Messages
227
Reaction score
56
Feb 22 13:59:12 incrediblepi2 sm-mta[4422]: gethostbyaddr(10.10.220.182) failed: 4

That just means DNS was not able to perform a reverse lookup. That shouldn't be preventing you from mailing.
You can fix it at any rate by adding an entry in your /etc/hosts file. eg:
echo '10.10.220.182 incrediblepi2.test.local incrediblepi2' >> /etc/hosts

localhost is actually 127.x.x.x/8 and you can reference it by any IP address in that range. Why the Internet gods chose to do that? I have no idea at all. Seems like a waste of 16 million addresses to me.

With the information you provided, i'm not entirely sure why your e-mail isn't flowing.
If you want to PM me more details I can look into it further.
 

dandy_don

Member
Joined
Sep 27, 2010
Messages
173
Reaction score
11
Synack,

I REALLY appreciate your help. I did as you suggested but these messages still are not making it through. They are no longer stacking up in the mail cue but I don't know where/if they might be going. Can I be the only one having these problems?

I think I'll start from scratch again and see if there is any different outcome.

Thanks,
Don
 

dandy_don

Member
Joined
Sep 27, 2010
Messages
173
Reaction score
11
Synack,

I gave up trying to make sendmail work so I rebuilt the system (yet again) but this time I installed faxing so that postfix would be installed, hoping that this would fix the sending of voice mail messages to e-mail. It still did not fix it?!?!?

I can use telnet, etc., and was able to send a test message from the command line but voice mail messages NEVER get sent/received.
Do you have any other ideas I might try?

I just don't get it... It shouldn't be that difficult to make this work but I've tried all the suggestions thus far and followed all of the instructions (I think), but to no avail. The only other thing which I'm starting to question is if any of the coding is dependent upon being on a 192.168 network. My networks are all 10.10. Not sure why that would make a difference but it just doesn't work.:banghead:

Any help is greatly appreciated.
 

synack

Guru
Joined
Dec 31, 2013
Messages
227
Reaction score
56
OK lets start from the top:
fix the hosts file. the one you posted earlier in the thread has a problem. host entries should always be:
ADDRESS NAME NAME NAME etc...

I see the last entry as:
NAME ADDRESS NAME NAME etc.

make sure for your first 127.0.0.1 it is:
127.0.0.1 HOSTNAME.DOMAIN.TLD HOSTNAME localhost localhost.localdomain localhost4 localhost4.localdomain4
where hostname.domain.tld matches your fully qualified "hostname" and hostname on it's own is without the domain part.
The order above is important.
Unless you are using ipv6 remove or comment out the rest of the chuff for now. You can probably get away with just the one line above.
Code:
Hint, both these commands below should match:
hostname
hostname -f

Next, make sure your resolv.conf is correct.
/etc/resolv.conf should contain at minimum:
Code:
search DOMAIN.TLD
nameserver dns1IP

Next you need to decide if your server is going to mail directly, or if you will use a smarthost/relay to deliver for you. The biggest driving factor is what your ISP will allow. In effort to prevent compromised home computers from becoming spam servers, many ISPs block outbound smtp on port 25 to the world except to their provided SMTP server (which usually requires authentication)

Mailing directly will require some sort of valid source (from) e-mail address that the receiving mail server can verify. Many anti-spam routines will dump e-mail to the floor if the "sender" server of XYZ.com does not match the SPF record of valid senders.
eg: if you send from your server using address: [email protected], the receiving server will check the SPF DNS record for here.com to see if your IP/host is in the list of valid senders.

This check will happen also with a smart-relay, so you will likely need to use a from email address with no or at least a loose SPF record.
If you are using an smarthost, you will likely have an email with that ISP you can use that is properly configured to send.

Gone are the days of "blind trust" with e-mail.

Once that decision is made, then the sendmail.cf file needs configuring.
(this was basically my purpose for asking you to send me the details via PM. without knowing to: from: and smarthosts it was getting difficult to troubleshoot generically)
 

dandy_don

Member
Joined
Sep 27, 2010
Messages
173
Reaction score
11
Synack,

Thanks for the response. This is "new" build using the same Raspberry Pi Model 2 hardware.
This is the contents of the /etc/hosts file:

127.0.0.1 localhost
::1 pbx.local localhost ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters

This is the contents of /etc/resolv.conf:
domain woh.rr.com
search woh.rr.com
nameserver 10.10.220.4

My router/firewall is 10.10.220.4. My ISP is Time Warner cable.
Since I installed Advantfax, it installed Postfix. The status now shows Postfix UP.

I am open to suggestion regarding the method of sending the e-mail.
I'll now check and reply to any PM from you.

Thanks again for your help!
Don
 

ostridge

Guru
Joined
Jan 22, 2015
Messages
1,618
Reaction score
517
for what its worth:
After "ff02::3 ip6-allrouters" - mine has
ff02::3 ip6-allhosts
I thought the fqdn hostname was got from here (hosts) so as not to get root@(none) /etc# ?
 

Members online

No members online now.

Forum statistics

Threads
25,782
Messages
167,509
Members
19,202
Latest member
pbxnewguy
Get 3CX - Absolutely Free!

Link up your team and customers Phone System Live Chat Video Conferencing

Hosted or Self-managed. Up to 10 users free forever. No credit card. Try risk free.

3CX
A 3CX Account with that email already exists. You will be redirected to the Customer Portal to sign in or reset your password if you've forgotten it.
Top