LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Server (https://www.linuxquestions.org/questions/linux-server-73/)
-   -   How can I solve the problem of "IPs with missing PTR records." to send email through postfix with port 25 from local pc? (https://www.linuxquestions.org/questions/linux-server-73/how-can-i-solve-the-problem-of-ips-with-missing-ptr-records-to-send-email-through-postfix-with-port-25-from-local-pc-4175736093/)

cola 04-16-2024 11:21 AM

How can I solve the problem of "IPs with missing PTR records." to send email through postfix with port 25 from local pc?
 
Error:
Code:

AAB0360FEF: to=<abcd@gmail.com>, relay=gmail-smtp-in.l.google.com[64.233.170.27]:25, delay=2.9, delays=0.02/0.02/2/0.84, dsn=5.7.25, status=bounced
(host gmail-smtp-in.l.google.com[64.233.170.27] said: 550-5.7.25 [a.b.c.d] The IP address sending this message does not have a PTR 550-5.7.25 record
setup, or the corresponding forward DNS entry does not point 550-5.7.25 to the sending IP. As a policy, Gmail does not accept messages from 550-5.7.25
IPs with missing PTR records. For more information, go to 550-5.7.25  https://support.google.com/mail/answer/81126#ip-practices  550-5.7.25 To learn
more about Gmail's sender policy, go to 550 5.7.25  https://support.google.com/mail/answer/81126. w2-20020a17090aaf8200b002a78140f747si5962065pjq.62
- gsmtp (in reply to end of DATA command))

Here, a.b.c.d is the public ip address. It is dynamic ip address. I think, it is the router's public ip address. Local pc has ip address like 192.168.1.103.

I am trying to send email to gmail through postfix with port 25 from local pc or localhost. I have installed postfix, opendkim and configured these. /etc/hostname has "mydomain.com". So the sender is user1@mydomain.com.

I have followed this website: https://netcorecloud.com/tutorials/c...ostfix-ubuntu/

How can I solve the problem of "IPs with missing PTR records." to send email through postfix with port 25 from local pc? Where will I write PTR record? How can I write PTR record?

scasey 04-16-2024 04:10 PM

This is the "whole other subject" I spoke of in your other post. There is much involved in hosting an email server.
PTR records are DNS entries. Gmail probably wants to see an rDNS record for your IP. What does
Code:

dig -x (your IP)
return?

You’ll also need TXT DNS entries for your domain for SPF and DKIM.. Those entries will be in the authoritative name servers for your domain. Typically, those are provided by your domain registrar.

It’s also unlikely that email coming from a dynamic IP address will be accepted by gmail or Oath (AOL/Yahoo) or any server using an RBL that identifies dynamic IPs.

TenTenths 04-17-2024 04:45 AM

Quote:

Originally Posted by scasey (Post 6496435)
It’s also unlikely that email coming from a dynamic IP address will be accepted by gmail or Oath (AOL/Yahoo) or any server using an RBL that identifies dynamic IPs.

I've found that https://mxtoolbox.com/blacklists.aspx is not bad for checking if an IP is on a bunch of blacklists.

cola 04-17-2024 11:16 AM

I have got: "We notice you are on a blacklist.". Listed 5 times with 2 timeouts. Blacklist for BARRACUDA, SORBS SPAM, Spamhaus ZEN, UCEPROTECTL2, UCEPROTECTL3. Timeout: MADAVI, NoSolicitado. Can it be a problem?

TenTenths 04-17-2024 11:26 AM

Quote:

Originally Posted by cola (Post 6496666)
I have got: "We notice you are on a blacklist.". Listed 5 times with 2 timeouts. Blacklist for BARRACUDA, SORBS SPAM, Spamhaus ZEN, UCEPROTECTL2, UCEPROTECTL3. Timeout: MADAVI, NoSolicitado. Can it be a problem?

Yes, you may have problems getting any e-mail delivered.

cola 04-17-2024 11:35 PM

Quote:

Originally Posted by scasey (Post 6496435)
This is the "whole other subject" I spoke of in your other post. There is much involved in hosting an email server.
PTR records are DNS entries. Gmail probably wants to see an rDNS record for your IP. What does
Code:

dig -x (your IP)
return?

You’ll also need TXT DNS entries for your domain for SPF and DKIM.. Those entries will be in the authoritative name servers for your domain. Typically, those are provided by your domain registrar.

It’s also unlikely that email coming from a dynamic IP address will be accepted by gmail or Oath (AOL/Yahoo) or any server using an RBL that identifies dynamic IPs.

dig -x (my IP) has already a PTR record. So can I set PTR record to my hostname? Here hostname=host.mydomain.com. I have bought mydomain.com.

chrism01 04-18-2024 12:15 AM

As scasey said
Quote:

It’s also unlikely that email coming from a dynamic IP address will be accepted by gmail or Oath (AOL/Yahoo) or any server using an RBL that identifies dynamic IPs.
You're first post says you've got a Dynamic IP, which is normal for a residential acct .
(& yes, it's the 'outside' ip addr of your router which is the one that counts ie the one that faces the public internet)

Most ISPs only hand out a static IP if you pay extra for a 'business' acct (or similar) with them.

TenTenths 04-18-2024 03:12 AM

Quote:

Originally Posted by cola (Post 6496759)
dig -x (my IP) has already a PTR record. So can I set PTR record to my hostname? Here hostname=host.mydomain.com. I have bought mydomain.com.

I really, really doubt it. PTR are "reverse" records, so only the owner of the IP address block can set them, this will be your ISP. If you have business broadband with a static IP then they may be able to either set it for you or let you change it through their portal. For residential broadband, no chance.

scasey 04-18-2024 10:44 AM

Quote:

Originally Posted by cola (Post 6496759)
dig -x (my IP) has already a PTR record. So can I set PTR record to my hostname? Here hostname=host.mydomain.com. I have bought mydomain.com.

As has been said, no.
You cannot set the rDNS of an IP. I can’t even set the rDNS of static IPs I’ve been assigned…I have to request the ISP that owns the IPs do that for me. They’re happy to do that, given the big(ish) bucks I pay them.

What are you trying to accomplish? If it’s to learn to setup and run a mail server, start by acquiring a static IP from a reputable provider, and be prepared to do a LOT of study and learning to make it work.

If it’s to be able to use your domain to send email, the simplest, easiest way to do that is to contract with a domain/web hosting provider to provide those services. Some can be quite reasonable.


All times are GMT -5. The time now is 09:01 AM.