supervision - discussion about system services, daemon supervision, init, runlevel management, and tools such as s6 and runit
 help / color / mirror / Atom feed
* Recommended steps for upgrading?
@ 2008-06-28 19:11 Lloyd Zusman
  2008-06-28 19:25 ` Lloyd Zusman
  0 siblings, 1 reply; 4+ messages in thread
From: Lloyd Zusman @ 2008-06-28 19:11 UTC (permalink / raw)
  To: supervision

I've been using runit for a while, and whenever I upgrade to a new
version, I want to shut down everything and then restart, so that I can
make use of the the newest runsvdir and runsv binaries.

However, when I have done this, I have found that I often find problems
with the existing lock files and sockets that runsv uses.  Therefore,
I've come up with a procedure for doing a complete restart that deletes
these files as part of the process.

My procedure seems like overkill, however, and I'm hoping that there is
some lack of understanding that I have which, when corrected, will
result in my knowing how to do this in a more straightforward manner,
and without any manual file deletions.

Here are my steps. Can any of you could suggest improvements? Thanks in
advance.

  # cd /service
  # for i in *
  > do
  > sv stop $i
  > done

  # vi /etc/inittab   # (I'm using sysvinit and inittab)
  ... comment out this line, save the file, and then exit from vi:
  SV:123456:respawn:/sbin/runsvdir-start

  # init q

  # pkill -f runsv 

  # cd /etc/sv
  # find . -name ok | xargs rm
  # find . -name lock | xargs rm
  # find . -name control | xargs rm

  Now, do the complete runit upgrade.

  Then ...

  # vi /etc/inittab
  ... un-comment the line that I commented out above,
  ... save the file, and then exit from vi

  # init q



-- 
 Lloyd Zusman
 ljz@asfast.com
 God bless you.



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Recommended steps for upgrading?
  2008-06-28 19:11 Recommended steps for upgrading? Lloyd Zusman
@ 2008-06-28 19:25 ` Lloyd Zusman
  2008-06-30  8:49   ` Radek Podgorny
  0 siblings, 1 reply; 4+ messages in thread
From: Lloyd Zusman @ 2008-06-28 19:25 UTC (permalink / raw)
  To: supervision

Lloyd Zusman <ljz@asfast.com> writes:

> [ ... ]
>
> Here are my steps. Can any of you could suggest improvements? Thanks in
> advance.

I'm sorry for responding to my own message, but I left a step out of my
procedure. Here's the corrected version:

  # cd /service
  # for i in *
  > do
  > sv stop $i
  > done

  # vi /etc/inittab   # (I'm using sysvinit and inittab)
  ... comment out this line, save the file, and then exit from vi:
  SV:123456:respawn:/sbin/runsvdir-start

  # init q

  # pkill -f runsv
  # pkill -f svlogd  # (this is the step I left out)

  # cd /etc/sv
  # find . -name ok | xargs rm
  # find . -name lock | xargs rm
  # find . -name control | xargs rm

  Now, do the complete runit upgrade.

  Then ...

  # vi /etc/inittab
  ... un-comment the line that I commented out above,
  ... save the file, and then exit from vi

  # init q


-- 
 Lloyd Zusman
 ljz@asfast.com
 God bless you.



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Recommended steps for upgrading?
  2008-06-28 19:25 ` Lloyd Zusman
@ 2008-06-30  8:49   ` Radek Podgorny
  2008-06-30 10:05     ` Lloyd Zusman
  0 siblings, 1 reply; 4+ messages in thread
From: Radek Podgorny @ 2008-06-30  8:49 UTC (permalink / raw)
  To: supervision

> Lloyd Zusman <ljz@asfast.com> writes:
>
>> [ ... ]
>>
>> Here are my steps. Can any of you could suggest improvements? Thanks in
>> advance.
>
> I'm sorry for responding to my own message, but I left a step out of my
> procedure. Here's the corrected version:
>
>   # cd /service
>   # for i in *
>   > do
>   > sv stop $i
>   > done

"sv st /service/*" works for me so "sv stop" should work, too IMHO...

>   # vi /etc/inittab   # (I'm using sysvinit and inittab)
>   ... comment out this line, save the file, and then exit from vi:
>   SV:123456:respawn:/sbin/runsvdir-start
>
>   # init q
>
>   # pkill -f runsv
>   # pkill -f svlogd  # (this is the step I left out)
>
>   # cd /etc/sv
>   # find . -name ok | xargs rm
>   # find . -name lock | xargs rm
>   # find . -name control | xargs rm
>
>   Now, do the complete runit upgrade.
>
>   Then ...
>
>   # vi /etc/inittab
>   ... un-comment the line that I commented out above,
>   ... save the file, and then exit from vi
>
>   # init q
>
>
> --
>  Lloyd Zusman
>  ljz@asfast.com
>  God bless you.
>
>




^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Recommended steps for upgrading?
  2008-06-30  8:49   ` Radek Podgorny
@ 2008-06-30 10:05     ` Lloyd Zusman
  0 siblings, 0 replies; 4+ messages in thread
From: Lloyd Zusman @ 2008-06-30 10:05 UTC (permalink / raw)
  To: supervision

"Radek Podgorny" <radek@podgorny.cz> writes:

>> Lloyd Zusman <ljz@asfast.com> writes:
>>
>>> [ ... ]
>>>
>>> Here are my steps. Can any of you could suggest improvements? Thanks in
>>> advance.
>>
>> I'm sorry for responding to my own message, but I left a step out of my
>> procedure. Here's the corrected version:
>>
>>   # cd /service
>>   # for i in *
>>   > do
>>   > sv stop $i
>>   > done
>
> "sv st /service/*" works for me so "sv stop" should work, too IMHO...

Thanks. I'll do "sv st{op} /service/*" next time.

If you folks agree that there isn't any way to avoid the manual kills of
the runsv and svlogd processes and the manual removals of the sockets
and the lock files, what do all of you think about having this
documented somewhere in the "upgrading from previous versions" page
(http://smarden.org/runit/upgrade.html)?  I'd be happy to submit an
attempt at this documentation.

I've gotten bit more than once with this during upgrades, where the
runit-based processes wouldn't properly restart, and I wouldn't doubt
that others might have encountered similar difficulties.


>>   # vi /etc/inittab   # (I'm using sysvinit and inittab)
>>   ... comment out this line, save the file, and then exit from vi:
>>   SV:123456:respawn:/sbin/runsvdir-start
>>
>>   # init q
>>
>>   # pkill -f runsv
>>   # pkill -f svlogd  # (this is the step I left out)
>>
>>   # cd /etc/sv
>>   # find . -name ok | xargs rm
>>   # find . -name lock | xargs rm
>>   # find . -name control | xargs rm
>>
>>   Now, do the complete runit upgrade.
>>
>>   Then ...
>>
>>   # vi /etc/inittab
>>   ... un-comment the line that I commented out above,
>>   ... save the file, and then exit from vi
>>
>>   # init q

-- 
 Lloyd Zusman
 ljz@asfast.com
 God bless you.



^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2008-06-30 10:05 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-06-28 19:11 Recommended steps for upgrading? Lloyd Zusman
2008-06-28 19:25 ` Lloyd Zusman
2008-06-30  8:49   ` Radek Podgorny
2008-06-30 10:05     ` Lloyd Zusman

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).