• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

james send email doesn't arrive at destination

 
Ranch Hand
Posts: 145
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I'm using the example here:
http://www.ibm.com/developerworks/java/library/j-james1/index.html
I've forwarded, virtual hosted, port 25. No firewall. Debug checks all ok but no email goes through!? Mail sends from one user to another at localhost, just not to my internet mail account.
What could be the problem please?


SENDING message from red@localhost to tudor.raneti@gmail.com

DEBUG: getProvider() returning javax.mail.Provider[TRANSPORT,smtp,com.sun.mail.smtp.SMTPTransport,Sun Microsystems, Inc]
DEBUG SMTP: useEhlo true, useAuth false
DEBUG SMTP: trying to connect to host "localhost", port 25, isSSL false
220 Desktop SMTP Server (JAMES SMTP Server 2.3.2) ready Sun, 5 Aug 2012 01:35:18 +0300 (EEST)
DEBUG SMTP: connected to host "localhost", port: 25

EHLO Desktop
250-Desktop Hello Desktop (localhost [127.0.0.1])
250-PIPELINING
250 ENHANCEDSTATUSCODES
DEBUG SMTP: Found extension "PIPELINING", arg ""
DEBUG SMTP: Found extension "ENHANCEDSTATUSCODES", arg ""
DEBUG SMTP: use8bit false
MAIL FROM:<red@localhost>
250 2.1.0 Sender <red@localhost> OK
RCPT TO:<tudor.raneti@gmail.com>
250 2.1.5 Recipient <tudor.raneti@gmail.com> OK
DEBUG SMTP: Verified Addresses
DEBUG SMTP: tudor.raneti@gmail.com
DATA
354 Ok Send data ending with <CRLF>.<CRLF>
To: tudor.raneti@gmail.com
Message-ID: <23063136.2.1344119718490.JavaMail.red@localhost>
Subject: Testing blue from red
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

This is a test message
.
250 2.6.0 Message received
QUIT
221 2.0.0 Desktop Service closing transmission channel

 
Marshal
Posts: 28193
95
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Quite possibly Gmail is rejecting that mail because it doesn't come from a host which matches the from-address on the e-mail message. But that's just speculation. It would be better to look at the logs of your mail server and see exactly what happened when it tried to send that message.
 
Tudor Raneti
Ranch Hand
Posts: 145
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I've also sent to yahoo.com, nothing arrives there. It's possible it's my ISP's blocking of port 25, but I'll see that in a few days. I made a request for unblocking.
In the meantime should I know anything else about mail server? Something I didn't configure?

EDIT: Ok, this is what happened:
when sending to yahoo:
05/08/12 02:05:27 INFO James.Mailet: RemoteDelivery: Could not connect to SMTP host: 98.136.216.26, port: 25

when sending to gmail:
05/08/12 01:59:51 INFO James.Mailet: RemoteDelivery: Could not connect to SMTP host: 74.125.127.26, port: 25

Any thoughts?
 
Bartender
Posts: 1051
5
Hibernate Eclipse IDE Chrome
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You are using the wrong ports is my theory.
 
Paul Clapham
Marshal
Posts: 28193
95
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Well, if you're going to be running a responsible mail server, it should be configured correctly. So if you're using it to send e-mail messages from addresses in domain X, then your DNS should be set up so that anybody who wants to send e-mails to addresses in domain X can find your server.

Generally servers who see messages which claim to be from (say) GMail addresses will check to ensure that they are coming from GMail servers. If they aren't, then they may be considered to be forgeries.
 
Tudor Raneti
Ranch Hand
Posts: 145
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I'll follow this tomorrow, and by that time maybe my ISP responds too.
http://www.warriorforum.com/programming-talk/161354-how-setup-email-namecheap-domains.html

I managed to get blacklisted by yahoo in the meantime , so I got an extra chore now...
http://help.yahoo.com/kb/index?page=content&y=PROD_MAIL_ML&locale=en_US&id=SLN5070&impressions=true

Will come back with outcome...
 
Tudor Raneti
Ranch Hand
Posts: 145
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I've set my email server in my domain's MX record and configured the email server name as such. Thanks for pointing that out

The problem most probably was that public mail servers block "anonymous" emailing as spam, not even bothering to send it to spam or junk folders (sometimes it did, then it didn't catch my mails at all). After making my email server "legit", the mails arrive in yahoo and gmail safely.

P.S.
Also... keep in mind that most public or commercial email servers out there have a send email per hour limit, which is why it isn't a good idea to use gmail as your email sending device. Roll your own server for unconstrained mail services
 
Tudor Raneti
Ranch Hand
Posts: 145
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Now I've run into another problem:
mailet*.log sais:

Exception delivering message (Mail1345880665225-8-to-gmail.com) - [EOF]


Upon some quick investigation (why do these happen when I'm out of time), it seems it may have to to with my PTR record:
http://old.nabble.com/emails-gets-spooled-but-not-delivered--td32509992.html
with more info on that here:

http://hosting.intermedia.net/support/kb/default.asp?id=1317

like

One common myth about PTR records is that they are created for domain names and your domain has to have one to make sure your mail will not be rejected by other mail servers.


and
http://en.wikipedia.org/wiki/List_of_DNS_record_types

Anyone has any help for me before I waste more time investigating setting a proper email server solution further?
Do I need to set reverse DNS?
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic