473,753 Members | 8,053 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

My windows service just "stops"

I have a windows service that has been running fine for almost 6 months.
Last week, it just stopped working. It is still in the task list and
still shows "started" in the service manager. There are no exceptions
thrown, it just seems to have fell asleep.

The service runs in a loop that checks about 80 servers on a daily basis
to see what the status of the previous nights backup job is. It
downloads the zipped log files from each server. I have two
FileSystemWatch er's running, one that watches for the Zip files to
appear, then adds a routine to the threading.threa dpool that unzips the
Xml files contained in them. The other FileSystemWatch er watches for the
Xml files to appear, then adds a routine to the threading.threa dpool
that reads the data out of the Xml files.

Since there were no exceptions being thrown, I added debug lines
throughout the code to try to determine where it stops. It does not stop
at the same place every time. Sometimes it'll stop during the FTP
download of a file. Other times it'll stop after finishing reading an
Xml file or executing an Sql Insert statement.

I'm wondering if anyone else has come across this strange behavior and
what you found was the cause? If you want to view the log file, follow
this link: http://boycot.no-ip.com/images/vlm_debug.txt

I should note that the service is running on another computer and has
not exibited this behavior, it's still working fine there.

*** Sent via Developersdex http://www.developersdex.com ***
Aug 12 '06 #1
3 1414
I have seen this happen if the event log is getting full and the service
cant write to the local log............

--
Regards

John Timney (MVP)
"Terry Olsen" <to******@hotma il.comwrote in message
news:%2******** ********@TK2MSF TNGP06.phx.gbl. ..
>I have a windows service that has been running fine for almost 6 months.
Last week, it just stopped working. It is still in the task list and
still shows "started" in the service manager. There are no exceptions
thrown, it just seems to have fell asleep.

The service runs in a loop that checks about 80 servers on a daily basis
to see what the status of the previous nights backup job is. It
downloads the zipped log files from each server. I have two
FileSystemWatch er's running, one that watches for the Zip files to
appear, then adds a routine to the threading.threa dpool that unzips the
Xml files contained in them. The other FileSystemWatch er watches for the
Xml files to appear, then adds a routine to the threading.threa dpool
that reads the data out of the Xml files.

Since there were no exceptions being thrown, I added debug lines
throughout the code to try to determine where it stops. It does not stop
at the same place every time. Sometimes it'll stop during the FTP
download of a file. Other times it'll stop after finishing reading an
Xml file or executing an Sql Insert statement.

I'm wondering if anyone else has come across this strange behavior and
what you found was the cause? If you want to view the log file, follow
this link: http://boycot.no-ip.com/images/vlm_debug.txt

I should note that the service is running on another computer and has
not exibited this behavior, it's still working fine there.

*** Sent via Developersdex http://www.developersdex.com ***

Aug 13 '06 #2
That doesn't seem to be the problem here. I cleared the event log of all
events and it still stops. In fact, it stopped on the first server this
time. The debug log shows that it made an ftp connection to the first server
in the list, and then no more entries... It's like it's waiting for a
response from the server that never comes. But I tried telnetting into the
server on port 21 and I always get a response. This is the strangest thing.
I'm considering now re-writing the entire service using all synchronous
calls. At least then it'd be easier to tell exactly where it's stopping.
"John Timney (MVP)" <x_****@timney. eclipse.co.ukwr ote in message
news:gL******** *************** *******@eclipse .net.uk...
>I have seen this happen if the event log is getting full and the service
cant write to the local log............

--
Regards

John Timney (MVP)
"Terry Olsen" <to******@hotma il.comwrote in message
news:%2******** ********@TK2MSF TNGP06.phx.gbl. ..
>>I have a windows service that has been running fine for almost 6 months.
Last week, it just stopped working. It is still in the task list and
still shows "started" in the service manager. There are no exceptions
thrown, it just seems to have fell asleep.

The service runs in a loop that checks about 80 servers on a daily basis
to see what the status of the previous nights backup job is. It
downloads the zipped log files from each server. I have two
FileSystemWatc her's running, one that watches for the Zip files to
appear, then adds a routine to the threading.threa dpool that unzips the
Xml files contained in them. The other FileSystemWatch er watches for the
Xml files to appear, then adds a routine to the threading.threa dpool
that reads the data out of the Xml files.

Since there were no exceptions being thrown, I added debug lines
throughout the code to try to determine where it stops. It does not stop
at the same place every time. Sometimes it'll stop during the FTP
download of a file. Other times it'll stop after finishing reading an
Xml file or executing an Sql Insert statement.

I'm wondering if anyone else has come across this strange behavior and
what you found was the cause? If you want to view the log file, follow
this link: http://boycot.no-ip.com/images/vlm_debug.txt

I should note that the service is running on another computer and has
not exibited this behavior, it's still working fine there.

*** Sent via Developersdex http://www.developersdex.com ***


Aug 14 '06 #3
Sorry I cant help any further, certainly sounds like a mysterious one to
solve!

Regards

John Timney (MVP)
"Terry Olsen" <to******@hotma il.comwrote in message
news:Oz******** ******@TK2MSFTN GP02.phx.gbl...
That doesn't seem to be the problem here. I cleared the event log of all
events and it still stops. In fact, it stopped on the first server this
time. The debug log shows that it made an ftp connection to the first
server in the list, and then no more entries... It's like it's waiting
for a response from the server that never comes. But I tried telnetting
into the server on port 21 and I always get a response. This is the
strangest thing. I'm considering now re-writing the entire service using
all synchronous calls. At least then it'd be easier to tell exactly where
it's stopping.
"John Timney (MVP)" <x_****@timney. eclipse.co.ukwr ote in message
news:gL******** *************** *******@eclipse .net.uk...
>>I have seen this happen if the event log is getting full and the service
cant write to the local log............

--
Regards

John Timney (MVP)
"Terry Olsen" <to******@hotma il.comwrote in message
news:%2******* *********@TK2MS FTNGP06.phx.gbl ...
>>>I have a windows service that has been running fine for almost 6 months.
Last week, it just stopped working. It is still in the task list and
still shows "started" in the service manager. There are no exceptions
thrown, it just seems to have fell asleep.

The service runs in a loop that checks about 80 servers on a daily basis
to see what the status of the previous nights backup job is. It
downloads the zipped log files from each server. I have two
FileSystemWat cher's running, one that watches for the Zip files to
appear, then adds a routine to the threading.threa dpool that unzips the
Xml files contained in them. The other FileSystemWatch er watches for the
Xml files to appear, then adds a routine to the threading.threa dpool
that reads the data out of the Xml files.

Since there were no exceptions being thrown, I added debug lines
throughout the code to try to determine where it stops. It does not stop
at the same place every time. Sometimes it'll stop during the FTP
download of a file. Other times it'll stop after finishing reading an
Xml file or executing an Sql Insert statement.

I'm wondering if anyone else has come across this strange behavior and
what you found was the cause? If you want to view the log file, follow
this link: http://boycot.no-ip.com/images/vlm_debug.txt

I should note that the service is running on another computer and has
not exibited this behavior, it's still working fine there.

*** Sent via Developersdex http://www.developersdex.com ***



Aug 15 '06 #4

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

Similar topics

0
1451
by: pillbug22 | last post by:
Hi everyone I am trying to write a fairly simple VB.NET service (use a timer to poll a network location for a file, if file exists, send message) The service correctly start, stops, runs the timer, etc. I can tell this from a custom event log I created, and it adds new entries on start, stop, and each time the timer expires FYI...sice this is my first service to write, I'm going by the MSDN article at...
1
3024
by: PeterB | last post by:
Hi! I'm using Pure ASP File Upload (http://www.asp101.com/articles/jacob/scriptupload.asp) to upload a file from a client to a server. I am testing both on a local IIS and a remote server. The welcome page has a browse button (for locating your local file), a textfield where the path is displayed, and a upload button. When clicking upload a VB ASP script is run, and the outcome is displayed on a new page. 1. On my local machine I got the...
1
2442
by: Stan | last post by:
I get this error when I try to access any page on the website: An error occurred while try to load the string resources (GetModuleHandle failed with error 126). At the same time here is what I got in the Event Log: Event Type: Error Event Source: ASP.NET 1.0.3705.288 Event Category: None
1
2047
by: st | last post by:
Hi, I'm using xmlDocument.Save(xmlTextWriter) to create an Excel-readable file. All works well, except where I've replaced the carriage return chars in the .innertext to XML-compliant " "; It gets changed to "&amp;#10" and doesn't render new lines in the Excel sheet. Can anyone help? Many thanks,
0
2128
by: JM | last post by:
I have created simple windows service which just write message to event log when it starts and stops. I am able to install it succesfully using: installutil <service_file.exe>, where <service_file.exeis the executable of the service. (Thanks to Rohan). But I want to install it using VS 2005 Setup project and I am unable to do that. I have created a Solution in VS 2005 with 2 simple projects.
0
1306
by: Ola | last post by:
I have an application that is runing all the time, 24 7. Sometimes it just stops and I recive this error: " has encounted a problem and needs to close. We are sorry for the inconvenience" And more. When I open the information that windows wants to send it is jibirish. Is there any way to catch this error. The application has an extensive error handling and also restart service that starts the application again if it stops, but this does...
1
5264
by: McKool | last post by:
Hello Group, I'm writting a Windows Services under C# to get some USB events. Because the ServiceBase class does not supports the SERVICE_CONTROL_DEVICEEVENT handler, I'm using P/Invoke to call the RegisterServiceCtrlHandlerEx funtion, using a callback to manage the needed handler. The invoke looks ok, it works. The problem is when the services stops. My callback function receives the SERVICE_CONTROL_STOP handler but the function don't...
2
1290
pod
by: pod | last post by:
Hello I am importing Excel files data into an Access database. My script goes through one Excel file at a time, row by row, and build a SQL statement for each row to insert data into the database. But on one of the Excel files, it encountered a cell with the value "#VALUE" in it, and the macro stops dead, leaving no debug message, no error popup, it just stops, with Excel file hanging in the process. Has anyone ever encountered this? I...
25
30967
by: Peng Yu | last post by:
Hi, It is possible to change the length of "\t" to a number other than 8. std::cout << "\t"; Thanks, Peng
0
9072
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8896
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
1
9421
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9333
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8328
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, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6869
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6151
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4771
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
3
2284
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.