Solved

Web Server can't send mail to external e-mail.

Posted on 2004-04-21
14
1,247 Views
Last Modified: 2010-04-20
I used asp script  'objMail = Server.CreateObject("CDO.Message")' to send mails.
It works when I send the mail to an internal e-mail account, but not external emails (eg.yahoo, hotmail) ? Any idea how to slove it. Below are the spec.

Web server running IIS6.0 without Exchange installed.
There is another server running Exchange.

How do i get the sendmail working when sending to external e-mail? What are the settings to be configured on my Web Server? IIS? Virtual SMTP?
0
Comment
Question by:zarzar
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 5
  • 5
  • 3
  • +1
14 Comments
 
LVL 51

Expert Comment

by:Ryan Chong
ID: 10890790
0
 
LVL 2

Expert Comment

by:jagoodie
ID: 10893380
Which server are you specifying in teh objMail settings? (local or exchange?
Regardless, you need to configure your SMTP server to allow relaying.  Let me know which SMTP server you are using and i can tell you how to configure it.
0
 

Author Comment

by:zarzar
ID: 10895448
I'm not using any cdo.dll to communicate with the Exchange server. Currently all the mails are relaying on the local Web Server's Virtual STMP.

This is my mail code:
----------------------------
Set objMail = Server.CreateObject("CDO.Message")
objMail.To = frmMailTo
objMail.From = frmMailFrom
objMail.Subject = frmSubject
objMail.HTMLBody = frmMessage
objMail.AddAttachment (Server.MapPath(frmPath))
objMail.Send
-----------------------------
So how do I configure it? And also the Web server is running under a Cisco PIX Firewall.

This is the rejected mail that is send back to objMail.From e-mail
-----------------------------
Your message did not reach some or all of the intended recipients.

      Subject: My Subject
      Sent:      23/Apr/2004 9:27 AM

The following recipient(s) could not be reached:

      me@yahoo.com on 23/Apr/2004 9:27 AM
            The e-mail system was unable to deliver the message, but did not report a specific reason.  Check the address and try again.  If it still fails, contact your system administrator.
            <mydomain.net #5.0.0>
-------------------------------
0
Guide to Performance: Optimization & Monitoring

Nowadays, monitoring is a mixture of tools, systems, and codes—making it a very complex process. And with this complexity, comes variables for failure. Get DZone’s new Guide to Performance to learn how to proactively find these variables and solve them before a disruption occurs.

 
LVL 2

Expert Comment

by:jagoodie
ID: 10900908
try to send me an email to jay@topdogwebsolutions.com and lets see if that goes through.
0
 
LVL 23

Expert Comment

by:rama_krishna580
ID: 10911439
Hi,

you must check the permission for SMTP enabled in Web server running IIS6.0 or not, since it has lot of security restriction u need to check and enable the 25 port also, if its not opened..and check the other options also..then try..u will get...

best of luck..

R.K
0
 

Author Comment

by:zarzar
ID: 10917584
Nope jagoodie, can't get through.

-----------------
Your message did not reach some or all of the intended recipients.

      Subject: Send this file...
      Sent:      26/Apr/2004 7:57 PM

The following recipient(s) could not be reached:

      jay@topdogwebsolutions.com on 26/Apr/2004 7:57 PM
            The e-mail system was unable to deliver the message, but did not report a specific reason.  Check the address and try again.  If it still fails, contact your system administrator.
            <mydomain.net #5.0.0>
------------------
0
 

Author Comment

by:zarzar
ID: 10917602
can't seems to get it working still..... only thing that i haven't try is relaying... How do i set that, lets say my exchange server ip is 111.222.33.444

Any idea....

Can i just relay the mail to my exchange server with the current code, or do i need to write some dll to link/create new mail object stuff???

0
 
LVL 2

Expert Comment

by:jagoodie
ID: 10918735
I recomend getting away from CDO, and moving towards and SMTP product... I have used http://www.aspemail.com/ for years.  Pretty easy to set up, and works great.
You will need to configure an SMTP server to relay FROM your web server (put your web server's IP address in the list of IP's that are allowed).

Let me know if this works/doesn't work for you..
0
 
LVL 23

Expert Comment

by:rama_krishna580
ID: 10923941
HI,

I would suggest doing an NSLookup from your Exchange Server and get the MX
records for that domain and then do a Telnet to that Server and this should
give you the specific reason you cannot send to them.

203204 XFOR: How to Obtain Internet Mail Exchanger Records with the
http://support.microsoft.com/?id=203204

153119 XFOR: Telnet to Port 25 to Test SMTP Communication
http://support.microsoft.com/?id=153119

Hope this helps,

R.K
0
 
LVL 23

Expert Comment

by:rama_krishna580
ID: 10923951
0
 

Author Comment

by:zarzar
ID: 10926721
rama_krishna580,
 
I tried to Telnet to Port 25 to Test SMTP Communication AND IT WORKED FINE! I can create mail with telnet and send it both to my internal e-mails and my external (yahoo, hotmail) account !!!!

Now how do i configured my Exchange or Web server to make it work, since Telnet comfirms that i CAN. I don't wanna to do any stuff on my DNS server, Web and Exchange is fine.

Thanks.
0
 
LVL 2

Accepted Solution

by:
jagoodie earned 500 total points
ID: 10928130
really, try out aspemail. it is free, and good.
0
 

Author Comment

by:zarzar
ID: 10992798
aspemail works fine!!! Thanks. Still i don't get i why i can't relay my mail from my web server. Can do it with Telnet why not with ASP?
0
 
LVL 2

Expert Comment

by:jagoodie
ID: 10995246
CDO is not a relay issue, it is an issue with how your exchange server is set up.  Relay is an SMTP issue - being that telnet to port 25 and ASPEmail work, you are indeed able to relay.  CDO does not use SMTP
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Most ColdFusion developers get confused between the CFSet, Duplicate, and Structcopy methods of copying a Structure, especially which one to use when. This Article will explain the differences in the approaches with examples; therefore, after readin…
One of the typical problems I have experienced is when you have to move a web server from one hosting site to another. You normally prepare all on the new host, transfer the site, change DNS and cross your fingers hoping all will be ok on new server…

730 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question