The Unix Heritage Society mailing list
 help / color / mirror / Atom feed
From: random832@fastmail.com (Random832)
Subject: [TUHS] self-reproducing programs
Date: Thu, 24 Mar 2016 10:41:54 -0400	[thread overview]
Message-ID: <1458830514.3531537.558627306.3CB6781D@webmail.messagingengine.com> (raw)
In-Reply-To: <alpine.LSU.2.00.1603241405180.11434@hermes-2.csi.cam.ac.uk>

On Thu, Mar 24, 2016, at 10:24, Tony Finch wrote:
> There was only ever one instance of the
> program running, but its pid changed hundreds of times per second.
> 
> Since it had daemonized, I couldn't use process groups to kill it.
> 
> Since it was running as root, I couldn't use `kill -TERM -1` to kill just
> one user's processes.
> 
> Since it was a production server, I reslly didn't want to reboot.
> 
> I tried picking a pid somewhat larger than the program's rapidly
> increasing pid, and ran a script: while !kill $pid; do :; done

Out of a curiosity, if a C program executes kill(-1, SIGSTOP), will it
itself be stopped? Or can SIGSTOP be ignored?

If so, maybe you could have solved it by stopping everything and then
continuing everything but the offending program. Of course, then you
risk that other programs on the system may have side effects from being
stopped and continued (interrupted system calls they may not be able to
handle, etc)


      reply	other threads:[~2016-03-24 14:41 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <mailman.144.1458776817.15972.tuhs@minnie.tuhs.org>
2016-03-24 13:45 ` David
2016-03-24 14:24   ` Tony Finch
2016-03-24 14:41     ` Random832 [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1458830514.3531537.558627306.3CB6781D@webmail.messagingengine.com \
    --to=random832@fastmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).