473,385 Members | 1,597 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Service


I have created a service that create a process.
The service is running in local system account & it also create the
new process in system account.

In process i have to access network resource .
In Windows 2000 new process is working fine but in Windows XP it does't
do anything .
The problem is that newly created problem could not access network path
thats y creating problem .
What may b the reason ?
Any Help ?

FAISAL NAWAZ

Jul 21 '05 #1
3 1488
<ma***********@gmail.com> wrote in message
news:11**********************@f14g2000cwb.googlegr oups.com...
In process i have to access network resource .
In Windows 2000 new process is working fine but in Windows XP it does't
do anything .
The problem is that newly created problem could not access network path
thats y creating problem .
What may b the reason ?


Make sure you have your service dependencies set as needed. You may need
Remote Procedure Call (RPC) for networking. You can set these dependencies
in VS.NET by setting the ServicesDependedOn property of the ServiceInstaller
component in your project. Use "RPCSS" for RPC. If you change this
setting, you will have to uninstall and reinstall the service for the
setting to take affect. You may have other dependencies as well, such as
message queueing, etc. It is important to set the service dependencies
correctly, because otherwise the ordering of the various service startups at
boot time may be wrong for your service.

Secondly, you may need to set the logon user for the service to a domain
user that has rights to the network resources that you are trying to access,
rather than your system account. If necessary, you may have to assign the
"Log on as a service" right to the login in the Local Security Policy's
SecuritySettings/LocalPolicies/UserRightsAssignment option.

-- Alan

Jul 21 '05 #2

Thanks 4 feedback.

There is nothing wrong with the service as it works on Windows 2000.

Actually whole things r working fine in windows 2k SP 4.but
on Windows XP SP 2 the process is unable to access the network path.
People say that if ur process is running in local system account then u
can't
access network resources.

Its OK on Xp i.e when we try to access network it could't but why it is
working in windows 2000 when the process is running in system account.

Why there is difference in service activity on WindowsXP & Windows 2K.

Hope u will guide me...
Thanks in advance





Alan Pretre wrote:
<ma***********@gmail.com> wrote in message
news:11**********************@f14g2000cwb.googlegr oups.com...
In process i have to access network resource .
In Windows 2000 new process is working fine but in Windows XP it does't do anything .
The problem is that newly created problem could not access network path thats y creating problem .
What may b the reason ?
Make sure you have your service dependencies set as needed. You may

need Remote Procedure Call (RPC) for networking. You can set these dependencies in VS.NET by setting the ServicesDependedOn property of the ServiceInstaller component in your project. Use "RPCSS" for RPC. If you change this
setting, you will have to uninstall and reinstall the service for the setting to take affect. You may have other dependencies as well, such as message queueing, etc. It is important to set the service dependencies correctly, because otherwise the ordering of the various service startups at boot time may be wrong for your service.

Secondly, you may need to set the logon user for the service to a domain user that has rights to the network resources that you are trying to access, rather than your system account. If necessary, you may have to assign the "Log on as a service" right to the login in the Local Security Policy's SecuritySettings/LocalPolicies/UserRightsAssignment option.

-- Alan


Jul 21 '05 #3
Windows 2000 and Windows XP have very different security models. To add to
the flavor, Windows XP SP2 has a different security model than Windows XP
SP1. Just because your app works on W2K does not at all mean it will work
with the security model of XP especially when we are talking about network
access.

As Alan stated below, for your service to work correctly across the network
you should probably have the service start under a Domain user account that
has the privileges you require of your service. Microsoft has reduced the
authority of LocalSystem, LocalService, and NetworkService accounts to
increase network security.

Hope that helps,
PJ

<ma***********@gmail.com> wrote in message
news:11**********************@z14g2000cwz.googlegr oups.com...

Thanks 4 feedback.

There is nothing wrong with the service as it works on Windows 2000.

Actually whole things r working fine in windows 2k SP 4.but
on Windows XP SP 2 the process is unable to access the network path.
People say that if ur process is running in local system account then u
can't
access network resources.

Its OK on Xp i.e when we try to access network it could't but why it is
working in windows 2000 when the process is running in system account.

Why there is difference in service activity on WindowsXP & Windows 2K.

Hope u will guide me...
Thanks in advance





Alan Pretre wrote:
<ma***********@gmail.com> wrote in message
news:11**********************@f14g2000cwb.googlegr oups.com...
> In process i have to access network resource .
> In Windows 2000 new process is working fine but in Windows XP it does't > do anything .
> The problem is that newly created problem could not access network path > thats y creating problem .
> What may b the reason ?


Make sure you have your service dependencies set as needed. You may

need
Remote Procedure Call (RPC) for networking. You can set these

dependencies
in VS.NET by setting the ServicesDependedOn property of the

ServiceInstaller
component in your project. Use "RPCSS" for RPC. If you change this
setting, you will have to uninstall and reinstall the service for the

setting to take affect. You may have other dependencies as well,

such as
message queueing, etc. It is important to set the service

dependencies
correctly, because otherwise the ordering of the various service

startups at
boot time may be wrong for your service.

Secondly, you may need to set the logon user for the service to a

domain
user that has rights to the network resources that you are trying to

access,
rather than your system account. If necessary, you may have to

assign the
"Log on as a service" right to the login in the Local Security

Policy's
SecuritySettings/LocalPolicies/UserRightsAssignment option.

-- Alan

Jul 21 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

9
by: Hardy Wang | last post by:
Hi all: I read an article from http://www.c-sharpcorner.com/Code/2003/Sept/InstallingWinServiceProgrammatically.asp about how to install a windows service programmatically. Based ont the code...
7
by: Mike | last post by:
I want to create a windows service that will monitor another window service. what i need for the service to do is, if a service is stopped I need it to start the service back up example: ...
4
by: carson | last post by:
I have written two windows services: - service A does some crunching of local data files and uploads them to a central processing computer via http. - service B monitors a manifest file on a...
20
by: =?Utf-8?B?cmtibmFpcg==?= | last post by:
I was executing the steps given in http://suppor.microsoft.com/kb/308359 for testing a sample web service application. However, the following line gives a compilation error: localhost.Service1...
5
by: dm3281 | last post by:
I'm really starting to hate writing services -- or trying to, anyway. Why do I need to rename my project to the service name? Why do I need to set the "ServiceName" property to my service name?...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.