[Gluster-devel] removing the statedump options file

Anand Avati anand.avati at gmail.com
Tue Feb 19 07:17:33 UTC 2013


On Mon, Feb 18, 2013 at 11:03 PM, Raghavendra Bhat <rabhat at redhat.com>wrote:

>
> Hi,
>
> As of now when statedump command is issued via cli (gluster volume
> statedump <volname> [options]) depending upon what options is given via cli
> a temporary file (glusterdump.<pid>.options) file is created by glusterd
> and glusterfsd process read that file to decide what information should be
> dumped. But the problem is glusterd after issuing the SIGUSR1 signal to the
> glusterfsd processes, sleeps for 1 second and then unlinks the options
> file. To fix that a patch was sent (
> http://review.gluster.org/#change,2585), where
>
> * the glusterfsd process after dumping the information to the statedump
> file, unlinked the options by (instead of glusterd doing it)
>
> Another approach suggested to me was this:
>
> * Have a separate thread in glusterd which keeps on polling for the file
> glusterdump.<pid>.options.over (i.e some renamed file). glusterfsd after
> dumping the information, renames the options file and thats when glusterd
> realizes the statedump is taken and unlinks the file. (The new thread is
> spawned whenever statedump is issued and is finished after unlinking the
> renamed options file).
>
>
If the purpose of the other thread is to just keep polling for rename() to
complete and eventually delete, why not just let the file be deleted by
glusterfsd? If glusterd needs to know when glusterfsd "finished its work",
then instead of polling for rename, it could just poll for unlink() of the
options file, no?

Avati


> Please let me know the inputs.
>
>
> Regards,
> Raghavendra Bhat
>
> _______________________________________________
> Gluster-devel mailing list
> Gluster-devel at nongnu.org
> https://lists.nongnu.org/mailman/listinfo/gluster-devel
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://supercolony.gluster.org/pipermail/gluster-devel/attachments/20130218/4fba9674/attachment-0001.html>


More information about the Gluster-devel mailing list