Re: Windows Services

From: Chakkaradeep (Chakkaradeep_at_discussions.microsoft.com)
Date: 11/30/04


Date: Tue, 30 Nov 2004 07:29:09 -0800

Hi Willy,

so u mean to say that i can accept a socket and receive messages but i cant
send messages back to the client??

with regards,
C.C.Chakkaradeep

"Willy Denoyette [MVP]" wrote:

> Socket communications are no issue. But you should be aware that services
> are (should be) running in a restricted security context:
> - They should not assume the presence of an interactive desktop nor an
> interactive user (logon session).
> - For security reasons, they should run with the least privileges possible
> (run as NetworkService or LocalService).
> Running as LocalSystem gives the service high privileges on the local system
> but no access to remote system resources, it's the only account that enables
> a service to interact with the desktop (to enable this - run services applet
> and check/enable this property).
> While it's possible to enable this option for quick and dirty debugging, I
> would suggest you use one of the other facilities offered by .NET for
> debugging and tracing (write to log file or eventlog, output to debugger
> window etc.).
>
> Willy.
>
> "Chakkaradeep" <Chakkaradeep@discussions.microsoft.com> wrote in message
> news:E18ADDA3-A51C-494B-B92B-5CF7B6C0A3EC@microsoft.com...
> > Hi Willy,
> >
> > so then how to check it out whether it is running or not..and is Socket
> > Communication possible in Services.....that is,..my service should act as
> > a
> > Multithreaded Server monitoring a Port Number and if any informations come
> > to
> > the port it should accept the sockets and exeute something so that the
> > Service has completed it's job...
> >
> > am a newbie to to this Service...
> >
> > with regards,
> > C.C.Chakkaradeep
> >
> > "Willy Denoyette [MVP]" wrote:
> >
> >> The errors is that you should not show a message box from a service.
> >> Services are meant to run in the background without any user interaction
> >> requirements.
> >>
> >> Willy.
> >>
> >> "Chakkaradeep" <Chakkaradeep@discussions.microsoft.com> wrote in message
> >> news:1272BBFF-AE44-4919-976A-3394F1AE569F@microsoft.com...
> >> > Hi all,
> >> >
> >> > I created a Minimal Windows Service Program in Visual Studio.NET VC#
> >> > using
> >> > the Wizard...i just added the MessageBox Display in OnStart() function
> >> > and
> >> > my
> >> > service is installed properly...but when i started the Service it
> >> > display
> >> > that "Local Service started and stopped , Serivces should have Log
> >> > Support
> >> > and Alerts Isssued"..
> >> >
> >> > what is this error??...am running Windows XP Home Edition,
> >> >
> >> > i have given the AccountType as "LocalService",i tried with everything
> >> > excpet with User...i no need to run as User...
> >> >
> >> > i would be happy if anyone could help me sort out this ...
> >> >
> >> > with regards,
> >> > C.C.Chakkaradeep
> >>
> >>
> >>
>
>
>



Relevant Pages

  • Re: Listen to Port
    ... Beste Grüsse / Best regards / Votre bien devoue ... A socket is basically a combination of an IP address and a port. ... Joe Fawcett (MVP - XML) ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: Windows Services
    ... so then how to check it out whether it is running or not..and is Socket ... Multithreaded Server monitoring a Port Number and if any informations come to ... >> with regards, ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: using protected methods in compact framework
    ... Also note that a remote port and a local port have different values. ... Best regards, ... so as to get the local endpoint of the current connected socket. ...
    (microsoft.public.dotnet.framework.compactframework)
  • Re: UDP socket with multiple ports
    ... each way through my proxy. ... computers resources if I had to bould a proxy that took every port from 1 to ... | a SocketException because the socket is already bound. ... | Best regards, ...
    (microsoft.public.dotnet.framework)
  • Re: [patch 00/13] Syslets, "Threadlets", generic AIO support, v3
    ... bugs showed up as a subtle epoll performance ... And debugging state machine code has exactly the same complexity as ... with, even in the most simple, TCP socket case! ... data is already on the kernel stack. ...
    (Linux-Kernel)

Quantcast