Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsWindows Server 2003Windows 2000Windows NTSmall Business ServerVirtual ServerExchange ServerIISHost Integration ServerISA ServerSMSWSUSMOMWindows Media ServerSecurityCertification
Related Topics
SQL ServerMS WindowsMS OfficePC HardwareMore Topics ...

Windows Server Forum / Windows NT / Registry / June 2008

Tip: Looking for answers? Try searching our database.

ServiceGroupOrder?

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
tmarin7 - 18 Jun 2008 19:39 GMT
Hi All,

   I have created a service with a start value = 2 (SERVICE_AUTO_START).
The service calls the Windows function WSAStartup which initates the use of
the Winsock.dll.  If I add my service to a group I can control when it gets
started by adding it into the following list that is in the resgistry under:
/HKLM/SYSTEM/CurrentControlSet/ServiceGroupOrder.  Most of the groups in the
list contain services that contain a start value of 0 (SERVICE_BOOT_START)
or 1 (SERVICE_SYSTEM_START).  The higher a service in the list the sooner it
loads.  All the groups with a 0 get started first, then the groups with a 1
and then the groups with a 2.  So, a group that contains a service with a
start value of 1 that is high in the list will not start until all the
groups with services that have a start value of 0 get loaded.

Please see:  http://support.microsoft.com/kb/115486

My question:  if the service I have created calls the Windows function
WSAStartup (start value of 2), where in the ServiceGroupOrder List can I
place it so I would be sure that the proper services have already been
started to support the WSAStartup function call?

Thanks in advance,
- Tom
Calvin - 19 Jun 2008 03:12 GMT
Hi,

> I have created a service with a start value = 2 (SERVICE_AUTO_START).
> The service calls the Windows function WSAStartup which initates the use of
[quoted text clipped - 4 lines]
> place it so I would be sure that the proper services have already been
> started to support the WSAStartup function call?

I think I would be investigating the "DependOnGroup" or
"DependOnService" entries features and nominate an appropriate service
(ie: winsock or winsock2) as the dependency for your service.

Your service then will not start until after the winsock reports start
successful.

You may also want to build a bit of a time delay into your service
before it attempts to make any calls. I have seen some services that do
not like having calls made of them IMMEDIATELY after they start (test
your situation and see what happens) - you can trigger some really weird
behaviours like race conditions - I don't know whether the winsock would
be in this category.

Calvin.
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2009 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.