|
Home > Archive > Slony1 PostgreSQL Replication > November 2005 > Stop slon process?
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
Stop slon process?
|
|
| Melvin Davidson 2005-11-28, 1:24 pm |
| Per the documentation, the correct way to start the slon process is:
slon [option...] [clustername] [conninfo]
Throughout the documentation, there are several references to stopping
the slon process,
but no mention of a specific command to do it. Currently, I use
ps -ef | grep slon
and then kill -9 the process(s).
Is there a better way to stop slon?
I am aware of the PERL tool "slon_kill", but if I am using PERL, what
do I do?
Why is there no stop option for the slon command?
Am I missing something?
| |
| Jeff Frost 2005-11-28, 1:24 pm |
| Melvin,
I certainly would not kill -9 the process as kill -9 does not give the
process the opportunity to clean exit. A simple "killall slon" should do
the trick on most linux variants, or you can simply kill `ps -ef | grep
[s]lon | awk '{print $2}'` which will do essentially the same thing.
You could also run under daemontools or something similar.
----
Jeff Frost, Owner <jeff- MyrtwiXdM0PnZcttdmLD
tcI/UQi/AW5J@public.gmane.org>
Frost Consulting, LLC http://www.frostconsultingllc.com/
Phone: 650-780-7908 FAX: 650-649-1954
----- Original Message -----
From: "Melvin Davidson" <mdavidson- BW9lXTF7vLsAvxtiuMwx
3w@public.gmane.org>
Subject: [Slony1-general] Stop slon process?
> Throughout the documentation, there are several references to stopping the
> slon process,
> but no mention of a specific command to do it. Currently, I use
> ps -ef | grep slon
> and then kill -9 the process(s).
| |
| Vivek Khera 2005-11-28, 1:24 pm |
|
On Nov 28, 2005, at 1:37 PM, Melvin Davidson wrote:
> and then kill -9 the process(s).
kill -9 is a "rude" way to kill processes. a normal TERM signal
should be sufficient and gives slon time to cleanup after itself.
kill -9 should be the method of last resort to kill any process.
| |
| Andrew Sullivan 2005-11-28, 1:24 pm |
| This is not sysadmin-support, but . . .
On Mon, Nov 28, 2005 at 10:51:38AM -0800, Jeff Frost wrote:
> process the opportunity to clean exit. A simple "killall slon" should do
> the trick on most linux variants, or you can simply kill `ps -ef | grep
.. . .if someone is naturally pulling out the -9
cannon-cum-flamethrower, it's worth pointing out that "killall" is
different on Linux than some other systems, and you'd _better be
sure_ what system you're using before you go using that command.
Remember: man pages are your friend.
A
--
Andrew Sullivan | ajs-oaT0K0jot5/q2IAV+ODieA@public.gmane.org
I remember when computers were frustrating because they *did* exactly what
you told them to. That actually seems sort of quaint now.
--J.D. Baldwin
| |
| Jeff Frost 2005-11-28, 8:28 pm |
| Andrew makes an excellent point!
Solaris and HPUX killall kills _ALL_ processes while Linux/IRIX killall only
kills all instances of the specified process.
This is a trap many linux users fall into while working with other OSes.
----- Original Message -----
From: "Andrew Sullivan" <ajs-oaT0K0jot5/q2IAV+ODieA@public.gmane.org>
> . . .if someone is naturally pulling out the -9
> cannon-cum-flamethrower, it's worth pointing out that "killall" is
> different on Linux than some other systems, and you'd _better be
> sure_ what system you're using before you go using that command.
> Remember: man pages are your friend.
| |
| Scott Marlowe 2005-11-28, 8:28 pm |
| I'd recommend pkill. It seems to behave well on most unix OSes.
On Mon, 2005-11-28 at 13:27, Jeff Frost wrote:
> Andrew makes an excellent point!
>
> Solaris and HPUX killall kills _ALL_ processes while Linux/IRIX killall only
> kills all instances of the specified process.
> This is a trap many linux users fall into while working with other OSes.
>
> ----- Original Message -----
> From: "Andrew Sullivan" <ajs-oaT0K0jot5/q2IAV+ODieA@public.gmane.org>
>
>
> ____________________
____________________
_______
> Slony1-general mailing list
> Slony1-general- AuKwsB3Fm+ugFIWk8tvy
RWD2FQJk+8+b@public.gmane.org
> http://gborg.postgresql.org/mailman.../slony1-general
| |
| Jan Wieck 2005-11-29, 1:24 pm |
| On 11/28/2005 2:00 PM, Vivek Khera wrote:
> On Nov 28, 2005, at 1:37 PM, Melvin Davidson wrote:
>
>
> kill -9 is a "rude" way to kill processes. a normal TERM signal
> should be sufficient and gives slon time to cleanup after itself.
>
> kill -9 should be the method of last resort to kill any process.
I do agree that -9 is a bad habit. Although in the case of slon, not
much harm will be done as all work is covered by transactions in the
corresponding DB connections and killing slon the rude way will simply
rollback.
Jan
--
#===================
====================
====================
===========#
# It's easier to get forgiveness for being wrong than for being right. #
# Let's break this rule - forgive me. #
#===================
====================
=========== JanWieck- bwPqjjyvM7QAvxtiuMwx
3w@public.gmane.org #
|
|
|
|
|