Problem Starting a Windows Service Automatically
-
hi all! this is my first post here, so please bare with me. do you know what could possibly cause a windows service not to start automatically at windows startup? here are my settings: 1. Startup type: "Automatic" 2. Log on as: "Local System account" 3. When I install it under the "C:\Program Files folder", it works just fine. It starts automatically. But when I install it in a different folder (for example, under "C:\") it does not start automatically. 4. OS: Windows XP Professional 2002 Service Pack 2 5. User Account type: Administrator i hope you can help a newbie like me. thanks in advance! :)
-
hi all! this is my first post here, so please bare with me. do you know what could possibly cause a windows service not to start automatically at windows startup? here are my settings: 1. Startup type: "Automatic" 2. Log on as: "Local System account" 3. When I install it under the "C:\Program Files folder", it works just fine. It starts automatically. But when I install it in a different folder (for example, under "C:\") it does not start automatically. 4. OS: Windows XP Professional 2002 Service Pack 2 5. User Account type: Administrator i hope you can help a newbie like me. thanks in advance! :)
genie13 wrote:
it does not start automatically
What is the error that gets logged to eventlog?
Vasudevan Deepak Kumar Personal Homepage
Tech Gossips
A pessimist sees only the dark side of the clouds, and mopes; a philosopher sees both sides, and shrugs; an optimist doesn't see the clouds at all - he's walking on them. --Leonard Louis Levinson -
genie13 wrote:
it does not start automatically
What is the error that gets logged to eventlog?
Vasudevan Deepak Kumar Personal Homepage
Tech Gossips
A pessimist sees only the dark side of the clouds, and mopes; a philosopher sees both sides, and shrugs; an optimist doesn't see the clouds at all - he's walking on them. --Leonard Louis Levinson -
the OS is japanese, but from what i can understand from the event log, access is denied or some permission error. i was wondering why, because i log in using the Administrator account.
The nature of a service means that it runs independently, under a default, or configured, user account, not the user account you log on as. It is normally a lesser privileged account.
Semicolons: The number one seller of ostomy bags world wide. - dan neely
-
the OS is japanese, but from what i can understand from the event log, access is denied or some permission error. i was wondering why, because i log in using the Administrator account.
Contrary to popular belief, the Local System account is very restricted. It doesn't have permissions to a lot of the system, including the root of the SystemDrive and about half of the registry. Also, it doesn't matter what account YOU use to login to Windows, since Services run completely independant of a user being logged in at all.
A guide to posting questions on CodeProject[^]
Dave Kreskowiak Microsoft MVP Visual Developer - Visual Basic
2006, 2007, 2008 -
Contrary to popular belief, the Local System account is very restricted. It doesn't have permissions to a lot of the system, including the root of the SystemDrive and about half of the registry. Also, it doesn't matter what account YOU use to login to Windows, since Services run completely independant of a user being logged in at all.
A guide to posting questions on CodeProject[^]
Dave Kreskowiak Microsoft MVP Visual Developer - Visual Basic
2006, 2007, 2008Dave Kreskowiak wrote:
Contrary to popular belief, the Local System account is very restricted. It doesn't have permissions to a lot of the system, including the root of the SystemDrive and about half of the registry.
I think you are wrong here, the LocalSystem account is the highest privileged level that a service can get. For more info read LocalSystem account[^] and how the system account is used[^]. Just a quick quote: "By default, the system account is granted full control to all files on an NTFS volume. Here the system account has the same functional privileges as the administrator account."
-
Dave Kreskowiak wrote:
Contrary to popular belief, the Local System account is very restricted. It doesn't have permissions to a lot of the system, including the root of the SystemDrive and about half of the registry.
I think you are wrong here, the LocalSystem account is the highest privileged level that a service can get. For more info read LocalSystem account[^] and how the system account is used[^]. Just a quick quote: "By default, the system account is granted full control to all files on an NTFS volume. Here the system account has the same functional privileges as the administrator account."
Zoltan Balazs wrote:
I think you are wrong here, the LocalSystem account is the highest privileged level that a service can get.
You'd think that's the case, but there have been too many questions about "Access Denied" errors when using it to get at various parts of the file system, registry, and of course, network access. In practice, unless you REALLY need Desktop Interaction, it's best to create an account explicitly for the service to use so you have greater control over what it can and cannot get to. Truthfuly, how many services REALLY need admin access to the machine?
A guide to posting questions on CodeProject[^]
Dave Kreskowiak Microsoft MVP Visual Developer - Visual Basic
2006, 2007, 2008