473,405 Members | 2,344 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,405 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 1489
<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: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
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
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
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...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

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.