Skip to content

kill -SIGTERM PID #177

zanderisrael opened this Issue Oct 21, 2013 · 3 comments

3 participants


From what i understand from this code :
rapns / lib / rapns / daemon.rb

def self.setup_signal_traps
@shutting_down = false

  Signal.trap('SIGHUP') { AppRunner.sync }
  Signal.trap('SIGUSR2') { AppRunner.debug }

  ['SIGINT', 'SIGTERM'].each do |signal|
    Signal.trap(signal) { handle_shutdown_signal }

I can gracefully shutdown the daemon by calling this:

kill -SIGTERM pidof rapns

When i call it from root with ssh , it works , yet no shutdown message is shown.
When i call it from my rails controller:

system("kill -SIGTERM pidof rapns")

It has no effect.

i noticed that if the queue was empty and no sending happend the kill command worked from the rails controller...

Am i doing things wrong?


I believe the system command should be 'kill -TERM '


Still a no go :(, its not killing the daemon.

ileitch commented Nov 11, 2013

Did you manage to figure out what was wrong here?

@ileitch ileitch closed this Nov 20, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.