zombies

Ensuring subprocesses are dead on exiting Python program

Is there a way to ensure all created subprocess are dead at exit time of a Python program? By subprocess I mean those created with subprocess.Popen(). If not, should I iterate over all of the issuing kills and then kills -9? anything cleaner? ...

How to determine the state of a process (i.e. if it is a zombie)

Hi, how can I get information on the state of a process (i.e. if it is a zombie) using C under Linux? After reading the answers so far I want to narrow my question somewhat: I would prefer a pure C solution. After reading the ps source (which reads /proc/) I thought that there should be a better way and asked here :) ...

What's the reason for cookies mysteriously reappearing?

I'm developing a web application using a cookie to store session information. I've manually deleted the session cookies because I'm working on another part of the code where I don't want a login session. However, after a couple reloads of the page, the session cookie mysteriously reappears, including an earlier cookie that I had only set...

Handling ungraceful shutdowns when using fork and sockets

I have a server that listens for socket connections and perform different kind of actions, depending on the request. One of them is long lived database queries, for which the server forks. The server keeps a log of all the active children and whenever asked to shutdown, it will kill all it's children before exiting. A couple of times I ...

Why isn't my Perl program reaping children processes after fork?

I have been trying to write a bare-bones ping scanner using Perl for internal use. Since it scans a 24-bit CIDR network the script takes too long to run if it runs in a single thread. I have tried adding fork functionality to speed up the process but my first attempt was taking pretty much the same time since there was only one child pro...

Why does my program crash when accessing a property with self. and a synthesized accessor?

I have data object class: @interface Item: NSObject { NSString *title; NSString *text; } @property (copy) NSString *title; @property (copy) NSString *text; @end @implementation Item @synthesize text; - (void)updateText { self.text=@"new text"; } - (NSString *)title { return title; } - (void)setTitle:(NSString *)aS...

Threads, subprocess & zombies

Hi, I need to launch several remote jobs each at a precise moment using threads and SSH. So I write: def dojob(hostname): command = "echo Done" p = Popen(['ssh','%s@%s' % (user, hostname), command], stdout=PIPE, shell=False) output = p.communicate()[0].strip() print output [...] fire_starter = [Timer(t, dojob, [y]) f...

NSZombieEnabled doesn't report the type of object causing an EXC_BAD_ACCESS error

I have a crash that is happening deep within UIKit for some reason; an EXC_BAD_ACCESS error is happening something like 8 calls deep into a dismissModalViewController call. I tried enabling NSZombieEnabled for my executable, but the console log prints the same error regardless of whether or not zombies are turned on and i don't know whi...

How can I avoid zombies in Perl CGI scripts run under Apache 1.3?

Hi guys, Various Perl scripts (Server Side Includes) are calling a Perl module with many functions on a website. EDIT: The scripts are using use lib to reference the libraries from a folder. During busy periods the scripts (not the libraries) become zombies and overload the server. The server lists: 319 ? Z 0:00 [scriptnam...

Overreleasing issue and Zombies

this program crashes if i uncomment the release statements. i get that i am overreleasing and realized that quickly. but, just to test zombies, i turned them on (NSZombiesEnabled = YES and CFZombieLevel = 16) and the program runs fine and throws no exceptions. what gives? i thought turning on zombies would have just told me what a doofu...

NSLocalizedStringFromTable crash

I create a UIActionSheet with button texts from a txts file. After I set NSZombieEnabled, NSDebuEnabled to YES and NSDeallocateZombies to NO, I get a breakpoint with the message: * -[CFString isEqual:]: message sent to deallocated instance 0x11fae00 This happens after showing for the third or fourth time the UIActionSheet, not imm...

Zombie Processes Appearing When I Spawn Processes

I have a pieces of code where i spawn off children processes to make it more efficient. However, they appear to create all sorts of zombie processes which block sockets and bring down the site. spawn(:method => :thread) do if @login_user.suggested_group_info.new_record? xxx end end 1) Why is this creating zombie processe...

Python-daemon doesn't kill its kids

When using python-daemon, I'm creating subprocesses likeso: import multiprocessing class Worker(multiprocessing.Process): def __init__(self, queue): self.queue = queue # we wait for things from this in Worker.run() ... q = multiprocessing.Queue() with daemon.DaemonContext(): for i in xrange(3): Worker(q) ...

ADO.NET zombie transaction bug? How to ensure that commands will not be executed on implicit transaction?

e.g. When deadlock occurs, following SQL commands are successfully executed, even if they have assigned SQL transaction that is after rollback. It seems, it is caused by a new implicit transaction that is created on SQL Server. Someone could expect that ADO.NET would throw an exception that the commands are being executed on a zombie tr...

What are Zombies and what causes them? Are there Zombie processes and Zombie objects?

I can find questions about zombies but none that directly addresses what they are and why and how they occur. There are a couple that address what zombie processes are in the context of answering a specific question but don't address the cause. There are also questions regarding zombie processes and questions about Objective-C/Cocoa-rel...

respondsToSelector send to deallocated object

Hi, I try to find out why my app crashes (RSS Reader) if I send a wrong URL to NSXML Parser. I got an EXC_BAD_ACCESS. So after some Searching I found out that I have to use Zombies. So I added the following arguments to the environment: CFZombieLevel = 3 NSMallocStaclLogging = YES NSDeallocateZombies = NO MallocStackLoggingNoCompact...

BOT/Spider Trap Ideas

I have a client whose domain seems to be getting hit pretty hard by what appears to be a DDoS. In the logs it's normal looking user agents with random IPs but they're flipping through pages too fast to be human. They also don't appear to be requesting any images. I can't seem to find any pattern and my suspicion is it's a fleet of Window...

Question about zombie processess and threads

Hi, i had these questions in my mind since i was reading some new topics on processes and threads. I would be glad if somebody could help me out. 1) What happens if a thread is marked uncancelable, and then the process is killed inside of the critical section? 2) Do we have a main thread for the program that is known to the operating s...