Windows Service cannot connect to the network.

Hi!

I have a windows service, which connects over http to a remote website. I am running the service as Network Service. However, i get the exception (which i write out to the event log), that the remote name cannot be resolved.

Any ideas what could be going wrong

Thanks,

Mustansir



Answer this question

Windows Service cannot connect to the network.

  • sd_dracula

    It seems like your DNS cannot resolve the name. To which Machine you are try to connection. Where is the code which Resolves the Uri

    Have you tried your code in Windows or Console Application. (Should Not Matter, Just for the Test).

    Best Regards,



  • Eby

    Try Local System, Etc.. Why you need it to be a Network Service Is there a specific Reason

    Best Regards,



  • Chhaya

    Like I've mentioned, I've got it to work using my user account, so its not that I'm yet stuck getting it to work.

    The question is - why doesnt it work with Network Service Network Service supposed to have permissions to access the network ...


  • SoulSolutions

    Sorry! have no Idea I have always used Local System Coz it has always worked for me whether is a Network Application or is Database or somthing else...

    Lets wait for some more comments on it..... Amit Paka Where are you.... Come here is a question for you, Gorti, See this Guy needs help .

    Cheers Mate ,



  • sanwanas

    Hi!

    The machine is a public website on the Internet. The address is fine - if I change the Windows Service to Logon as User (and use my credentials) instead of using Network Service, it works fine.

    Thanks,

    Mustansir


  • Windows Service cannot connect to the network.