windows-services

How does one stop a Windows service to do an upgrade install?

I have developed a Windows service along with a setup project using Visual Studio 2008. When I do an upgrade install I get the following warning: The following applications are using files which the installer must update. You can either close the applications and click "Try Again", or click "Continue" so that the installer continues the...

How do I make a windows service installer from visual studio 2008?

How do I make a windows service installer from visual studio 2008? ...

Windows Service that runs Periodically

I'm writing a windows service that once started will run every X hours. The process it completes is fairly intensive, so I want to use a background worker. I'm using a Settings file to store both the hours between runs and the last time the service ran. I'm not exactly sure the best way to do this - that is, I want the service to idle...

Make Executable run at a lower priority

Possible Duplicate: Setting a thread priority in a service I've created a Windows Service and I want it to always run at LOW priority. Is there any way to achieve this via code or how I package up the install? ...

Debugging Topshelf service that won't run under restrictive account

I have a Windows service written using Topshelf. I'm trying to configure it to run using a Windows account with restricted privileges rather than using LocalSystem. That's also necessary as I'd like to connect to a database using integrated authentication. The service works when run as LocalSystem (albeit with a database connection stri...

Looking for program execution file location!

Hi all, I have a program running only by using right clicking. How can we find the location of the that source file? I believe im looking for .exe extension. The folder where i installed it don't have the .exe file on that program and many .dll files. is there a possibility that it was running by those .dll file? thanks in advance! ...

Windows service install problem

I have a .NET Windows serivce protected with {smartassembly} which works fine, except that I can't get the protected version to install. When I did the testing the service was already installed, then I copied the protected version over the original. There are some instructions on the {smartassembly} web site regarding Windows services (...

Gracefuly stop .net initiated Java Process

Having the next .net code, I want to stop it correctly so that the jvm executes it's ShutdownHooks. System.Diagnostics.Process p = new Process(); p.StartInfo.UseShellExecute = false; p.StartInfo.RedirectStandardError = true; p.StartInfo.RedirectStandardOutput = true; p.StartInfo.WindowStyle = ProcessWindowStyle.Hidden; p.StartInfo.Worki...

WCF Service Self Hosting Trouble

I'm trying to host a WCF Service inside a Windows Service which I am starting through a console app. Each service is its own project as is the console app. I've copied the app.config from the WCF Service library into the app.config of the console app, but I keep getting "Service has zero application endpoints...". I've read in a few p...

programmatically stop a windows service using ruby

Is there a way to stop a windows service (possibly on a remote machine) using ruby? ...

How to create a web interface for a windows service in .Net ?

I'm looking for a way to host a web UI in a windows service so that I can configure and control it within a browser. I'd like a simple and lightweight solution, and I don't want to use IIS. I could probably hand-roll most of it but I was wondering if there was something already made to ease the process. ...

Receiving MSMQ messages with Windows Service

I'm creating a Windows Service in C#. What is the best way to listen for messages?? How do I code this properly?? ...

How to reliably capture Windows logon, logoff, lock and unlock events from a service?

using Microsoft.Win32; public class App { static void Main() { SystemEvents.SessionSwitch += SystemEvents_SessionSwitch; Console.ReadLine(); SystemEvents.SessionSwitch -= SystemEvents_SessionSwitch; } static void SystemEvents_SessionSwitch(object sender, SessionSwitchEventArgs e) { if(e.Reason == Ses...

How to properly stop a multi-threaded .NET windows service?

I have a windows service written in C# that creates a truck load of threads and makes many network connections (WMI, SNMP, simple TCP, http). When attempting to stop the windows service using the Services MSC snap-in, the call to stop the service returns relatively quickly but the process continues to run for about 30 seconds or so. The...

Retrieving information why .NET service was stopped in OnStop

I have a .NET service, based on ServiceBase: public partial class Service : ServiceBase Something initiates stop on this service. The stuff logged during service stop is consistent with a regular stop using SCM, but user states he didn't initiate it. I am not sure if that is some sort of crash, or user error. Since the OnStop method...

Microsoft Setup Projects for services and automated removal previous versions.

I have an application that runs as a service. I have altered the services installer object so that I can pass setup data to it from a user input screen on the installation/setup project. This all appears to work well apart from the following points: Installation is error free UNLESS there is a copy of my service already installed on ...

Problem with Installing Windows Service Project

Hi, I am trying to make a Windows Service Project using Visual Studio Team Suite 2008. After building the project I am not able to install it into ‘Services’ using InstallUtil tool or through SetUp Project. May I know what could be the reason? Would you please also refer a best tutorial link for this. I Googled and tried different...

How to use SPWindowsService

From what I understand from the sparse documentation on MSDN, the way to do long running jobs in SharePoint is to use a SPWindowsService. I would like an example on how to create a custom windows service to run in the context of a SharePoint farm. ...

msi installer - service isn't starting

I've created an msi for a .net service (AqPlugins). It builds without issue. I've done an install using the msi on a server. In the application log I see: Windows Installer reconfigured the product. Product Name: AqPlugins. Product Version: 1.0.0. Product Language: 1033. Reconfiguration success or error status: 0. Howeve...

SSIS Package won't execute when called.

Hi, I have an 2005 SSIS package that I'm calling in a service created in VS 2005. The package will not run. The purpose of the package is to parse a file and put data into a "Load Table". The package runs perfectly on its own, but will not run at all when executed programatically - when I'm stepping through the code. The Event Viewer ...