[Stgt-devel] [PATCH] in tgt-setup-lun: fix check if tgtd daemon is running
FUJITA Tomonori
fujita.tomonori
Mon Apr 7 14:48:40 CEST 2008
On Mon, 07 Apr 2008 11:15:36 +0300
Doron Shoham <dorons at voltaire.com> wrote:
> FUJITA Tomonori wrote:
> >>> But the old script checks there are two tgtd daemons running. The new
> >>> one doesn't. Can you improve the new one to do that?
> >> Why tgtd has two daemons (process)?
> >
> > One daemon does only logging and another (the main daemon) does the
> > rest. Two daemons use shared memory.
> >
> >
> >> When running tgtd with -f flag it has only one process,
> >> why is it?
> >
> > It's just for debugging.
> >
> >
> >> So if I'll check for two process the script will exit.
> >>
> >>> Note that one of the two tgtd daemons could die due to a bug.
> >> When does it happen?
> >
> > It happens when we put a bug to the main daemon.
>
> For conclusion, we can check if there are two process
> running but then if some one use tgtd with -f flag the
> script will not work.
The current script doesn't work for the -f flag. I think that it's
fine since the -f flag is only for debugging. Common users don't use
it.
If you want, you can improve the script to check whether a tgt daemon
runs with the -f flag when the script finds only one tgt daemon, I
think.
> On the other hand, we can check if such process exists
> (without checking the amount of process).
> This way, the script will work on both cases but
> won't catch the bug on the main daemon (if exist).
>
> Which solution should we use?
>
>
> _______________________________________________
> Stgt-devel mailing list
> Stgt-devel at lists.berlios.de
> https://lists.berlios.de/mailman/listinfo/stgt-devel
More information about the stgt
mailing list