Bug 1243812 - [Backup]: Crash observed when keyboard interrupt is encountered in the middle of any glusterfind command
Summary: [Backup]: Crash observed when keyboard interrupt is encountered in the middle...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: GlusterFS
Classification: Community
Component: glusterfind
Version: mainline
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: ---
Assignee: Aravinda VK
QA Contact: bugs@gluster.org
URL:
Whiteboard:
Depends On: 1228079
Blocks: 1223636 1282465
TreeView+ depends on / blocked
 
Reported: 2015-07-16 11:57 UTC by Aravinda VK
Modified: 2016-06-16 13:24 UTC (History)
4 users (show)

Fixed In Version: glusterfs-3.8rc2
Clone Of: 1228079
: 1282465 (view as bug list)
Environment:
Last Closed: 2016-06-16 13:24:44 UTC
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Embargoed:


Attachments (Terms of Use)

Description Aravinda VK 2015-07-16 11:57:24 UTC
+++ This bug was initially created as a clone of Bug #1228079 +++

Description of problem:
While executing any of the glusterfind CLI commands, if Ctrl+C is pressed before the command is completed, it results in a crash with the below trace:

[root@dhcp43-48 ~]# glusterfind pre sessn1 nash outn1.txt --output-prefix /tmp/ -N
^CProcess Process-3:
Traceback (most recent call last):
  File "/usr/lib64/python2.6/multiprocessing/process.py", line 232, in _bootstrap
Process Process-2:
Traceback (most recent call last):
  File "/usr/lib64/python2.6/multiprocessing/process.py", line 232, in _bootstrap
Traceback (most recent call last):
  File "/usr/bin/glusterfind", line 17, in <module>
    main()
  File "/usr/libexec/glusterfs/glusterfind/main.py", line 519, in main
    globals()["mode_" + args.mode](session_dir, args)
  File "/usr/libexec/glusterfs/glusterfind/main.py", line 380, in mode_pre
    run_cmd_nodes("pre", args, start=start)
  File "/usr/libexec/glusterfs/glusterfind/main.py", line 161, in run_cmd_nodes
    p.join()
  File "/usr/lib64/python2.6/multiprocessing/process.py", line 119, in join
Process Process-1:
Traceback (most recent call last):
  File "/usr/lib64/python2.6/multiprocessing/process.py", line 232, in _bootstrap
Process Process-4:
Traceback (most recent call last):
  File "/usr/lib64/python2.6/multiprocessing/process.py", line 232, in _bootstrap
    self.run()
  File "/usr/lib64/python2.6/multiprocessing/process.py", line 88, in run
    self._target(*self._args, **self._kwargs)
  File "/usr/libexec/glusterfs/glusterfind/main.py", line 65, in node_cmd
    execute(cmd, exit_msg="%s - %s failed" % (host, task), logger=logger)
  File "/usr/libexec/glusterfs/glusterfind/utils.py", line 164, in execute
    (out, err) = p.communicate()
  File "/usr/lib64/python2.6/subprocess.py", line 732, in communicate
    self.run()
  File "/usr/lib64/python2.6/multiprocessing/process.py", line 88, in run
    self._target(*self._args, **self._kwargs)
  File "/usr/libexec/glusterfs/glusterfind/main.py", line 65, in node_cmd
    execute(cmd, exit_msg="%s - %s failed" % (host, task), logger=logger)
  File "/usr/libexec/glusterfs/glusterfind/utils.py", line 164, in execute
    (out, err) = p.communicate()
  File "/usr/lib64/python2.6/subprocess.py", line 732, in communicate
    res = self._popen.wait(timeout)
  File "/usr/lib64/python2.6/multiprocessing/forking.py", line 122, in wait
    self.run()
  File "/usr/lib64/python2.6/multiprocessing/process.py", line 88, in run
    self._target(*self._args, **self._kwargs)
  File "/usr/libexec/glusterfs/glusterfind/main.py", line 65, in node_cmd
    execute(cmd, exit_msg="%s - %s failed" % (host, task), logger=logger)
  File "/usr/libexec/glusterfs/glusterfind/utils.py", line 164, in execute
    (out, err) = p.communicate()
  File "/usr/lib64/python2.6/subprocess.py", line 732, in communicate
    self.run()
  File "/usr/lib64/python2.6/multiprocessing/process.py", line 88, in run
    self._target(*self._args, **self._kwargs)
  File "/usr/libexec/glusterfs/glusterfind/main.py", line 65, in node_cmd
    execute(cmd, exit_msg="%s - %s failed" % (host, task), logger=logger)
  File "/usr/libexec/glusterfs/glusterfind/utils.py", line 164, in execute
    (out, err) = p.communicate()
  File "/usr/lib64/python2.6/subprocess.py", line 732, in communicate
    stdout, stderr = self._communicate(input, endtime)
  File "/usr/lib64/python2.6/subprocess.py", line 1316, in _communicate
    stdout, stderr = self._communicate_with_poll(input, endtime)
  File "/usr/lib64/python2.6/subprocess.py", line 1388, in _communicate_with_poll
    ready = poller.poll(self._remaining_time(endtime))
KeyboardInterrupt
    stdout, stderr = self._communicate(input, endtime)
  File "/usr/lib64/python2.6/subprocess.py", line 1316, in _communicate
    stdout, stderr = self._communicate_with_poll(input, endtime)
  File "/usr/lib64/python2.6/subprocess.py", line 1388, in _communicate_with_poll
    ready = poller.poll(self._remaining_time(endtime))
KeyboardInterrupt
    stdout, stderr = self._communicate(input, endtime)
  File "/usr/lib64/python2.6/subprocess.py", line 1316, in _communicate
    stdout, stderr = self._communicate_with_poll(input, endtime)
  File "/usr/lib64/python2.6/subprocess.py", line 1388, in _communicate_with_poll
    ready = poller.poll(self._remaining_time(endtime))
KeyboardInterrupt
    stdout, stderr = self._communicate(input, endtime)
  File "/usr/lib64/python2.6/subprocess.py", line 1316, in _communicate
    stdout, stderr = self._communicate_with_poll(input, endtime)
  File "/usr/lib64/python2.6/subprocess.py", line 1388, in _communicate_with_poll
    ready = poller.poll(self._remaining_time(endtime))
KeyboardInterrupt
    return self.poll(0)
  File "/usr/lib64/python2.6/multiprocessing/forking.py", line 107, in poll
    pid, sts = os.waitpid(self.pid, flag)
KeyboardInterrupt


Version-Release number of selected component (if applicable):
glusterfs-3.7.0-3.el6rhs.x86_64

How reproducible:    Always

Comment 1 Aravinda VK 2015-07-16 12:29:56 UTC
Upstream Patch is sent
http://review.gluster.org/#/c/11698/

Comment 2 Anand Avati 2015-07-23 05:04:06 UTC
REVIEW: http://review.gluster.org/11698 (tools/glusterfind: Handle Keyboard interrupt) posted (#2) for review on master by Aravinda VK (avishwan)

Comment 3 Anand Avati 2015-08-05 08:06:43 UTC
REVIEW: http://review.gluster.org/11698 (tools/glusterfind: Handle Keyboard interrupt) posted (#3) for review on master by Aravinda VK (avishwan)

Comment 4 Anand Avati 2015-08-12 09:46:25 UTC
REVIEW: http://review.gluster.org/11698 (tools/glusterfind: Handle Keyboard interrupt) posted (#4) for review on master by Aravinda VK (avishwan)

Comment 5 Anand Avati 2015-08-19 05:59:08 UTC
REVIEW: http://review.gluster.org/11698 (tools/glusterfind: Handle Keyboard interrupt) posted (#5) for review on master by Aravinda VK (avishwan)

Comment 6 Anand Avati 2015-08-26 05:57:03 UTC
REVIEW: http://review.gluster.org/11698 (tools/glusterfind: Handle Keyboard interrupt) posted (#6) for review on master by Aravinda VK (avishwan)

Comment 7 Vijay Bellur 2015-10-14 06:22:09 UTC
REVIEW: http://review.gluster.org/11698 (tools/glusterfind: Handle Keyboard interrupt) posted (#9) for review on master by Aravinda VK (avishwan)

Comment 8 Vijay Bellur 2015-11-02 06:24:47 UTC
REVIEW: http://review.gluster.org/11698 (tools/glusterfind: Handle Keyboard interrupt) posted (#10) for review on master by Aravinda VK (avishwan)

Comment 9 Vijay Bellur 2015-11-16 05:35:08 UTC
REVIEW: http://review.gluster.org/11698 (tools/glusterfind: Handle Keyboard interrupt) posted (#13) for review on master by Aravinda VK (avishwan)

Comment 10 Vijay Bellur 2015-11-16 11:05:11 UTC
REVIEW: http://review.gluster.org/11698 (tools/glusterfind: Handle Keyboard interrupt) posted (#14) for review on master by Aravinda VK (avishwan)

Comment 11 Vijay Bellur 2015-11-16 14:03:08 UTC
REVIEW: http://review.gluster.org/11698 (tools/glusterfind: Handle Keyboard interrupt) posted (#15) for review on master by Aravinda VK (avishwan)

Comment 12 Vijay Bellur 2015-11-19 04:05:14 UTC
COMMIT: http://review.gluster.org/11698 committed in master by Venky Shankar (vshankar) 
------
commit 6c3895fd132765a5ad098b9ef35e037be7d116b1
Author: Aravinda VK <avishwan>
Date:   Thu Jul 16 17:05:25 2015 +0530

    tools/glusterfind: Handle Keyboard interrupt
    
    Do not print Python traceback when glusterfind command is interrupted
    
    Change-Id: I67383534f965e410fef7ce09798e9d435ef738ae
    Signed-off-by: Aravinda VK <avishwan>
    BUG: 1243812
    Reviewed-on: http://review.gluster.org/11698
    Tested-by: NetBSD Build System <jenkins.org>
    Tested-by: Gluster Build System <jenkins.com>
    Reviewed-by: Milind Changire <mchangir>
    Reviewed-by: Saravanakumar Arumugam <sarumuga>
    Reviewed-by: Venky Shankar <vshankar>

Comment 13 Niels de Vos 2016-06-16 13:24:44 UTC
This bug is getting closed because a release has been made available that should address the reported issue. In case the problem is still not fixed with glusterfs-3.8.0, please open a new bug report.

glusterfs-3.8.0 has been announced on the Gluster mailinglists [1], packages for several distributions should become available in the near future. Keep an eye on the Gluster Users mailinglist [2] and the update infrastructure for your distribution.

[1] http://blog.gluster.org/2016/06/glusterfs-3-8-released/
[2] http://thread.gmane.org/gmane.comp.file-systems.gluster.user


Note You need to log in before you can comment on or make changes to this bug.