IIS and SMTP - SMTP and IIS

This is Interesting: Free IT Magazines  
Home > Archive > IIS and SMTP > February 2004 > SMTP and IIS





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author SMTP and IIS
JJ

2004-02-22, 6:34 am

Hi,

On my network I have a Win Xp Pro machine that has IIS and SMTP virtual
Installed. I was wondering if I am on another machine that is on the same
network to use the SMTP on Win XP Pro machine in order to send out mail?
How can I determine what that SMTP virtual servers name is? Would it be
something like smtp.winxpmachinename or smtp.IISnameOnWinXPMachine? I am
creating a script to send out email but need to supply the smtp name to
script to use. Any Ideas?

JJ


Jonathan Maltz [MS-MVP]

2004-02-22, 6:34 am

Hi,

It would be the XP machine's IP address (or host name)

--
--Jonathan Maltz [Microsoft MVP - Windows Server, Virtual PC]
http://www.visualwin.com - A Windows Server 2003 visual, step-by-step
tutorial site :-)
http://vpc.visualwin.com - Does <insert OS name> work on VPC 2004? Find out
here
Only reply by newsgroup. I do not do technical support via email. Any
emails I have not authorized are deleted before I see them.


"JJ" <jmraz@bellatlantic.net> wrote in message
news:O4DqC7X%23DHA.2324@tk2msftngp13.phx.gbl...
> Hi,
>
> On my network I have a Win Xp Pro machine that has IIS and SMTP virtual
> Installed. I was wondering if I am on another machine that is on the same
> network to use the SMTP on Win XP Pro machine in order to send out mail?
> How can I determine what that SMTP virtual servers name is? Would it be
> something like smtp.winxpmachinename or smtp.IISnameOnWinXPMachine? I am
> creating a script to send out email but need to supply the smtp name to
> script to use. Any Ideas?
>
> JJ
>
>



JJ

2004-02-22, 7:34 am

Here is the script I am running :

Set objEmail = CreateObject("CDO.Message")
objEmail.From = "jm@somewebserver.com"
objEmail.To = "jm2@somewebser.com"
objEmail.Subject = "Server Down Test Email JJ"
objEmail.Textbody = "Sbs server is up and running !"
objEmail.AddAttachment "D:\VBScript\AppLog.txt"
objEmail.Configuration.Fields.Item _
("http://schemas.microsoft.com/cdo/configuration/sendusing") = 2

'objEmail.Configuration.Fields.Item _
'("http://schemas.microsoft.com/cdo/configuration/smtpserver") = "IP or host
name here"

objEmail.Configuration.Fields.Item _
("http://schemas.microsoft.com/cdo/configuration/smtpserverport") = 25
objEmail.Configuration.Fields.Update
objEmail.Send

On the line where it has IP or host name here. I tried both but fails to
find the smtp server on win XP pro machine.

That line has "http://schemas.microsoft.com/cdo/configuration/smtpserver" is
this correct or should it be something else?

Thanks,

JJ




"Jonathan Maltz [MS-MVP]" <jmaltz@mvps.org> wrote in message
news:OJQdM%23X%23DHA.3700@TK2MSFTNGP09.phx.gbl...
> Hi,
>
> It would be the XP machine's IP address (or host name)
>
> --
> --Jonathan Maltz [Microsoft MVP - Windows Server, Virtual PC]
> http://www.visualwin.com - A Windows Server 2003 visual, step-by-step
> tutorial site :-)
> http://vpc.visualwin.com - Does <insert OS name> work on VPC 2004? Find

out
> here
> Only reply by newsgroup. I do not do technical support via email. Any
> emails I have not authorized are deleted before I see them.
>
>
> "JJ" <jmraz@bellatlantic.net> wrote in message
> news:O4DqC7X%23DHA.2324@tk2msftngp13.phx.gbl...
virtual[color=blue]
same[color=blue]
>
>



JJ

2004-02-22, 8:34 am

Hi Jonathan,

I found out why it didn't work with ip address. I needed to go over to
the Win Xp pro client and in the smtp virtual server under the
properties/Access/Relay. I added the IP address of machine sending the email
and now it works !

Now my question is why does this work ? How does SMTP vitrual server know
where to send the email?

Thanks,

JJ


"Jonathan Maltz [MS-MVP]" <jmaltz@mvps.org> wrote in message
news:OJQdM%23X%23DHA.3700@TK2MSFTNGP09.phx.gbl...
> Hi,
>
> It would be the XP machine's IP address (or host name)
>
> --
> --Jonathan Maltz [Microsoft MVP - Windows Server, Virtual PC]
> http://www.visualwin.com - A Windows Server 2003 visual, step-by-step
> tutorial site :-)
> http://vpc.visualwin.com - Does <insert OS name> work on VPC 2004? Find

out
> here
> Only reply by newsgroup. I do not do technical support via email. Any
> emails I have not authorized are deleted before I see them.
>
>
> "JJ" <jmraz@bellatlantic.net> wrote in message
> news:O4DqC7X%23DHA.2324@tk2msftngp13.phx.gbl...
virtual[color=blue]
same[color=blue]
>
>



Jonathan Maltz [MS-MVP]

2004-02-22, 8:34 am

Hi JJ,

It knows where to send the email much in the same way Internet Explorer
knows where to go when you type www.microsoft.com. DNS. When your SMTP
server gets an email to bleh@somesite.com it looks up "somesite.com" by
going to DNS and saying "Hey, where does this email go?" Then the DNS
server says "Oh, that goes here." The SMTP server then thinks to itself "Can
I send an email to this place?" (that's where the relay permissions come in)
and if everything works out, the SMTP server connects to the receiving SMTP
server and introduces itself, etc, and just like that a new email message is
born! :-)

--
--Jonathan Maltz [Microsoft MVP - Windows Server, Virtual PC]
http://www.visualwin.com - A Windows Server 2003 visual, step-by-step
tutorial site :-)
http://vpc.visualwin.com - Does <insert OS name> work on VPC 2004? Find out
here
Only reply by newsgroup. I do not do technical support via email. Any
emails I have not authorized are deleted before I see them.


"JJ" <jmraz@bellatlantic.net> wrote in message
news:ONOGAhY%23DHA.3820@TK2MSFTNGP09.phx.gbl...
> Hi Jonathan,
>
> I found out why it didn't work with ip address. I needed to go over to
> the Win Xp pro client and in the smtp virtual server under the
> properties/Access/Relay. I added the IP address of machine sending the

email
> and now it works !
>
> Now my question is why does this work ? How does SMTP vitrual server know
> where to send the email?
>
> Thanks,
>
> JJ
>
>
> "Jonathan Maltz [MS-MVP]" <jmaltz@mvps.org> wrote in message
> news:OJQdM%23X%23DHA.3700@TK2MSFTNGP09.phx.gbl...
> out
> virtual
> same
mail?[color=blue]
be[color=blue]
am[color=blue]
to[color=blue]
>
>



JJ

2004-02-22, 11:34 am

Jonathan,

So my smtp server is calling another smtp server out on the net with the
domain name of somesite.com. So in order for it to be able to transmit email
to somewhere else it needs to be able to resolve the somesite.com domain.
How does your smtp virtual server through DNS know where to look? What I
mean is how does the DNS list on my server get updated with new domains?
Does it look out on the net some where for a list of DNS's with associated
IP's? If it can't find the domain from the list out on the net and I know
the domain name and IP how can I tell my SMTP server or update my DNS list
to look there?

I guess I am alittle confused on smtp because we have Exchange Server
running on W2k3 and I needed to configure the SMTP to use a smarthost from
ISP. But why would I need to do that if my SMTP can look out on the net and
send out emails on its own?
We unfortunately have Dialup connection to ISP for email and internet. We
are located out in the booney's.

Thanks,

JJ


"Jonathan Maltz [MS-MVP]" <jmaltz@mvps.org> wrote in message
news:%23Pg0uvY%23DHA.3068@tk2msftngp13.phx.gbl...
> Hi JJ,
>
> It knows where to send the email much in the same way Internet Explorer
> knows where to go when you type www.microsoft.com. DNS. When your SMTP
> server gets an email to bleh@somesite.com it looks up "somesite.com" by
> going to DNS and saying "Hey, where does this email go?" Then the DNS
> server says "Oh, that goes here." The SMTP server then thinks to itself

"Can
> I send an email to this place?" (that's where the relay permissions come

in)
> and if everything works out, the SMTP server connects to the receiving

SMTP
> server and introduces itself, etc, and just like that a new email message

is
> born! :-)
>
> --
> --Jonathan Maltz [Microsoft MVP - Windows Server, Virtual PC]
> http://www.visualwin.com - A Windows Server 2003 visual, step-by-step
> tutorial site :-)
> http://vpc.visualwin.com - Does <insert OS name> work on VPC 2004? Find

out
> here
> Only reply by newsgroup. I do not do technical support via email. Any
> emails I have not authorized are deleted before I see them.
>
>
> "JJ" <jmraz@bellatlantic.net> wrote in message
> news:ONOGAhY%23DHA.3820@TK2MSFTNGP09.phx.gbl...
to[color=blue]
> email
know[color=blue]
Find[color=blue]
Any[color=blue]
> mail?
> be
I[color=blue]
> am
> to
>
>



Ken Schaefer

2004-02-22, 1:34 pm


"JJ" <jmraz@bellatlantic.net> wrote in message
news:uPolSNa%23DHA.2524@TK2MSFTNGP11.phx.gbl...
: Jonathan,
:
: So my smtp server is calling another smtp server out on the net with the
: domain name of somesite.com. So in order for it to be able to transmit
email
: to somewhere else it needs to be able to resolve the somesite.com domain.
: How does your smtp virtual server through DNS know where to look? What I
: mean is how does the DNS list on my server get updated with new domains?
: Does it look out on the net some where for a list of DNS's with associated
: IP's?


DNS is heirachical, like a tree. There are a set of root DNS servers which
are hard-coded. They have information about all the top-level domain names.
So, they would know which are the servers that look after the .au domain. If
you were looking for my organisation (unsw.edu.au), then the root DNS server
could point you to the .au root servers. Then the .au root DNS servers could
point you to the .edu.au root servers, and the edu.au root servers would
point you to the unsw.edu.au root servers (149.171.96.2 and 149.171.192.2),
which would tell you where to deliver the mail.

In reality, that entire process isn't usually required. On your computer,
you enter details about your ISPs DNS servers, and your ISP's DNS servers do
these lookups for you (and cache them, so they don't have to be done over
and over again), and send your machine the results.

Cheers
Ken


If it can't find the domain from the list out on the net and I know
: the domain name and IP how can I tell my SMTP server or update my DNS list
: to look there?
:
: I guess I am alittle confused on smtp because we have Exchange Server
: running on W2k3 and I needed to configure the SMTP to use a smarthost from
: ISP. But why would I need to do that if my SMTP can look out on the net
and
: send out emails on its own?
: We unfortunately have Dialup connection to ISP for email and internet. We
: are located out in the booney's.
:
: Thanks,
:
: JJ
:
:
: "Jonathan Maltz [MS-MVP]" <jmaltz@mvps.org> wrote in message
: news:%23Pg0uvY%23DHA.3068@tk2msftngp13.phx.gbl...
: > Hi JJ,
: >
: > It knows where to send the email much in the same way Internet Explorer
: > knows where to go when you type www.microsoft.com. DNS. When your SMTP
: > server gets an email to bleh@somesite.com it looks up "somesite.com" by
: > going to DNS and saying "Hey, where does this email go?" Then the DNS
: > server says "Oh, that goes here." The SMTP server then thinks to itself
: "Can
: > I send an email to this place?" (that's where the relay permissions come
: in)
: > and if everything works out, the SMTP server connects to the receiving
: SMTP
: > server and introduces itself, etc, and just like that a new email
message
: is
: > born! :-)
: >
: > --
: > --Jonathan Maltz [Microsoft MVP - Windows Server, Virtual PC]
: > http://www.visualwin.com - A Windows Server 2003 visual, step-by-step
: > tutorial site :-)
: > http://vpc.visualwin.com - Does <insert OS name> work on VPC 2004? Find
: out
: > here
: > Only reply by newsgroup. I do not do technical support via email. Any
: > emails I have not authorized are deleted before I see them.
: >
: >
: > "JJ" <jmraz@bellatlantic.net> wrote in message
: > news:ONOGAhY%23DHA.3820@TK2MSFTNGP09.phx.gbl...
: > > Hi Jonathan,
: > >
: > > I found out why it didn't work with ip address. I needed to go over
: to
: > > the Win Xp pro client and in the smtp virtual server under the
: > > properties/Access/Relay. I added the IP address of machine sending the
: > email
: > > and now it works !
: > >
: > > Now my question is why does this work ? How does SMTP vitrual server
: know
: > > where to send the email?
: > >
: > > Thanks,
: > >
: > > JJ
: > >
: > >
: > > "Jonathan Maltz [MS-MVP]" <jmaltz@mvps.org> wrote in message
: > > news:OJQdM%23X%23DHA.3700@TK2MSFTNGP09.phx.gbl...
: > > > Hi,
: > > >
: > > > It would be the XP machine's IP address (or host name)
: > > >
: > > > --
: > > > --Jonathan Maltz [Microsoft MVP - Windows Server, Virtual PC]
: > > > http://www.visualwin.com - A Windows Server 2003 visual,
step-by-step
: > > > tutorial site :-)
: > > > http://vpc.visualwin.com - Does <insert OS name> work on VPC 2004?
: Find
: > > out
: > > > here
: > > > Only reply by newsgroup. I do not do technical support via email.
: Any
: > > > emails I have not authorized are deleted before I see them.
: > > >
: > > >
: > > > "JJ" <jmraz@bellatlantic.net> wrote in message
: > > > news:O4DqC7X%23DHA.2324@tk2msftngp13.phx.gbl...
: > > > > Hi,
: > > > >
: > > > > On my network I have a Win Xp Pro machine that has IIS and SMTP
: > > virtual
: > > > > Installed. I was wondering if I am on another machine that is on
the
: > > same
: > > > > network to use the SMTP on Win XP Pro machine in order to send out
: > mail?
: > > > > How can I determine what that SMTP virtual servers name is? Would
it
: > be
: > > > > something like smtp.winxpmachinename or
smtp.IISnameOnWinXPMachine?
: I
: > am
: > > > > creating a script to send out email but need to supply the smtp
name
: > to
: > > > > script to use. Any Ideas?
: > > > >
: > > > > JJ
: > > > >
: > > > >
: > > >
: > > >
: > >
: > >
: >
: >
:
:


Jonathan Maltz [MS-MVP]

2004-02-22, 1:34 pm

Hi JJ,

All that the SMTP server knows is that it needs to find out where this
domain is, and that DNS knows where to find it. It goes to DNS and asks the
address, DNS then replies with the address, if it has it, or uses forwarders
to ask another D/NS server if it knows where this domain is, and then
returns it back to the SMTP server. If you know the domain name's IP and
you run a local DNS server on your network, you can add the entry.

I think smart hosts are a bit different - smart hosts connect to the mail
server(s) of the place you are trying to email, and sends the email using
their server (smart hosts are one of those things I'm still in the process
of understanding). This is useful in cases like having a dynamic IP but
wanting to email AOL. So you set up an AOL smart host, and then the letter
will go through

--
--Jonathan Maltz [Microsoft MVP - Windows Server, Virtual PC]
http://www.visualwin.com - A Windows Server 2003 visual, step-by-step
tutorial site :-)
http://vpc.visualwin.com - Does <insert OS name> work on VPC 2004? Find out
here
Only reply by newsgroup. I do not do technical support via email. Any
emails I have not authorized are deleted before I see them.


"JJ" <jmraz@bellatlantic.net> wrote in message
news:uPolSNa%23DHA.2524@TK2MSFTNGP11.phx.gbl...
> Jonathan,
>
> So my smtp server is calling another smtp server out on the net with the
> domain name of somesite.com. So in order for it to be able to transmit

email
> to somewhere else it needs to be able to resolve the somesite.com domain.
> How does your smtp virtual server through DNS know where to look? What I
> mean is how does the DNS list on my server get updated with new domains?
> Does it look out on the net some where for a list of DNS's with associated
> IP's? If it can't find the domain from the list out on the net and I know
> the domain name and IP how can I tell my SMTP server or update my DNS list
> to look there?
>
> I guess I am alittle confused on smtp because we have Exchange Server
> running on W2k3 and I needed to configure the SMTP to use a smarthost from
> ISP. But why would I need to do that if my SMTP can look out on the net

and
> send out emails on its own?
> We unfortunately have Dialup connection to ISP for email and internet. We
> are located out in the booney's.
>
> Thanks,
>
> JJ
>
>
> "Jonathan Maltz [MS-MVP]" <jmaltz@mvps.org> wrote in message
> news:%23Pg0uvY%23DHA.3068@tk2msftngp13.phx.gbl...
> "Can
> in)
> SMTP
message[color=blue]
> is
> out
> to
> know
step-by-step[color=blue]
> Find
> Any
the[color=blue]
it[color=blue]
smtp.IISnameOnWinXPMachine?[color=blue]
> I
name[color=blue]
>
>



Jeff Cochran

2004-02-23, 8:34 am

On Sun, 22 Feb 2004 19:23:34 -0500, "JJ" <jmraz@bellatlantic.net>
wrote:

> So my smtp server is calling another smtp server out on the net with the
>domain name of somesite.com. So in order for it to be able to transmit email
>to somewhere else it needs to be able to resolve the somesite.com domain.
>How does your smtp virtual server through DNS know where to look?


That's exactly what DNS does. And it looks where you tell it to look,
as configured in your DNS settings on the network connection.

>What I
>mean is how does the DNS list on my server get updated with new domains?


It doesn't. It knows the domain isn't local and goes where the
forwarder list points. Unless you didn't use a forwarder, in which
case it simply gives up.

>Does it look out on the net some where for a list of DNS's with associated
>IP's?


No. It looks for an authoritative DNS server for the domain it's
looking up. As defined in that domain's registration.

>If it can't find the domain from the list out on the net and I know
>the domain name and IP how can I tell my SMTP server or update my DNS list
>to look there?


You enter the data manually into your DNS or Hosts file. Which is a
dumb thing to do, since you couldn't possibly type them all in and
track all the changes that may turn up. That's why you configure DNS
correctly in the first place.

>I guess I am alittle confused on smtp because we have Exchange Server
>running on W2k3 and I needed to configure the SMTP to use a smarthost from
>ISP. But why would I need to do that if my SMTP can look out on the net and
>send out emails on its own?


You wouldn't. If it's possible. And configured correctly. And DNS
works. And your firewall is configured for it. And you don't get
blacklisted for an open relay. And... Mostly, it's just easier to use
your ISP as a relay/smart host.

>We unfortunately have Dialup connection to ISP for email and internet. We
>are located out in the booney's.


Then you *really* don't want to run your own DNS or SMTP. When you're
not dialed in, the whole system breaks. Someone sending you mail
finds you're not online and you never will get it. Tht's one of the
benefits of a smarthost relaying mail, they store mail and send it to
you when you come back online.

Jeff


>"Jonathan Maltz [MS-MVP]" <jmaltz@mvps.org> wrote in message
>news:%23Pg0uvY%23DHA.3068@tk2msftngp13.phx.gbl...
>"Can
>in)
>SMTP
>is
>out
>to
>know
>Find
>Any
>I
>


Sponsored Links






Free braindumps | Software forum | Database administration forum

Copyright 2003 - 2008 webservertalk.com