Bug 1214574 - Snapshot-scheduling helper script errors out while running "snap_scheduler.py init"
Summary: Snapshot-scheduling helper script errors out while running "snap_scheduler.py...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: GlusterFS
Classification: Community
Component: snapshot
Version: mainline
Hardware: Unspecified
OS: Unspecified
unspecified
high
Target Milestone: ---
Assignee: Avra Sengupta
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks: 1218575
TreeView+ depends on / blocked
 
Reported: 2015-04-23 06:31 UTC by Darshan
Modified: 2016-06-16 12:54 UTC (History)
3 users (show)

Fixed In Version: glusterfs-3.8rc2
Doc Type: Bug Fix
Doc Text:
Clone Of:
: 1218575 (view as bug list)
Environment:
Last Closed: 2016-06-16 12:54:19 UTC
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Embargoed:


Attachments (Terms of Use)
Output of df command on the machine (1.68 KB, text/plain)
2015-04-23 06:31 UTC, Darshan
no flags Details

Description Darshan 2015-04-23 06:31:35 UTC
Created attachment 1017739 [details]
Output of df command on the machine

Description of problem:
"snap_scheduler.py init" fails with following traceback:

Traceback (most recent call last):
  File "/usr/sbin/snap_scheduler.py", line 574, in <module>
    sys.exit(main())
  File "/usr/sbin/snap_scheduler.py", line 555, in main
    ret = perform_operation(args)
  File "/usr/sbin/snap_scheduler.py", line 408, in perform_operation
    ret = initialise_scheduler()
  File "/usr/sbin/snap_scheduler.py", line 349, in initialise_scheduler
    os.rename("/tmp/crontab", GCRON_UPDATE_TASK)
OSError: [Errno 18] Invalid cross-device link


Version-Release number of selected component (if applicable):


How reproducible:
Always

Steps to Reproduce:
1.
2.
3.

Actual results:
snap_scheduler.py init fails with traceback.

Expected results:
snapshot scheduler has to be initialized properly by running the script.

Additional info:

Comment 1 Anand Avati 2015-04-23 07:20:37 UTC
REVIEW: http://review.gluster.org/10347 (snapshot/scheduler: Use a .tmp file in /etc/cron.d instead of /tmp) posted (#1) for review on master by Avra Sengupta (asengupt)

Comment 2 Anand Avati 2015-04-23 08:28:47 UTC
REVIEW: http://review.gluster.org/10347 (snapshot/scheduler: Use a .tmp file in /etc/cron.d instead of /tmp) posted (#2) for review on master by Avra Sengupta (asengupt)

Comment 3 Anand Avati 2015-04-29 06:39:15 UTC
REVIEW: http://review.gluster.org/10347 (snapshot/scheduler: Use shutil.move instead of os.rename()) posted (#3) for review on master by Avra Sengupta (asengupt)

Comment 4 Anand Avati 2015-04-29 07:57:48 UTC
REVIEW: http://review.gluster.org/10347 (snapshot/scheduler: Use shutil.move instead of os.rename()) posted (#4) for review on master by Avra Sengupta (asengupt)

Comment 5 Anand Avati 2015-04-30 08:28:18 UTC
COMMIT: http://review.gluster.org/10347 committed in master by Krishnan Parthasarathi (kparthas) 
------
commit 0be5e3d7c580f77f3db0d4282d2ac81071ccd3f5
Author: Avra Sengupta <asengupt>
Date:   Wed Apr 29 12:02:05 2015 +0530

    snapshot/scheduler: Use shutil.move instead of os.rename()
    
    os.rename is a wrapper on top of the rename function,
    which fails with invalid cross-device link if /tmp
    is a tmpfs. Hence using shutil.move
    
    Change-Id: Ia026d2a810b725ccd398db895e612c53bc6a2f95
    BUG: 1214574
    Signed-off-by: Avra Sengupta <asengupt>
    Reviewed-on: http://review.gluster.org/10347
    Reviewed-by: Rajesh Joseph <rjoseph>
    Reviewed-by: Aravinda VK <avishwan>
    Tested-by: Gluster Build System <jenkins.com>
    Reviewed-by: Krishnan Parthasarathi <kparthas>

Comment 6 Nagaprasad Sathyanarayana 2015-10-25 14:54:51 UTC
Fix for this bug is already made in a GlusterFS release. The cloned BZ has details of the fix and the release. Hence closing this mainline BZ.

Comment 7 Nagaprasad Sathyanarayana 2015-10-25 14:58:40 UTC
Fix for this BZ is already present in a GlusterFS release. You can find clone of this BZ, fixed in a GlusterFS release and closed. Hence closing this mainline BZ as well.

Comment 8 Niels de Vos 2016-06-16 12:54:19 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.