Bug 1580020

Summary: ctime: Rename and unlink does not update ctime
Product: [Community] GlusterFS Reporter: Kotresh HR <khiremat>
Component: posixAssignee: Kotresh HR <khiremat>
Status: CLOSED CURRENTRELEASE QA Contact:
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: mainlineCC: bugs
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: glusterfs-5.0 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of:
: 1582068 (view as bug list) Environment:
Last Closed: 2018-10-23 15:09:12 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1582068    

Description Kotresh HR 2018-05-19 07:41:14 UTC
Description of problem:
Successful rename and unlink (if link count > 1) is not updating ctime.

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

How reproducible:
Alwasy

Steps to Reproduce:
1. Create gluster volume and mount 
2. Create file, stat file to record ctime. Rename file to rn_file, stat rn_file to check ctime. Ctime should be changed
3. Create file, create hard link named 'hl_file', stat file to record ctime.
   unlink hl_file, stat file to check ctime. ctime should be changed

Actual results:
Ctime doesn't change

Expected results:
Ctime should be changed.

Additional info:

Comment 1 Kotresh HR 2018-05-19 07:42:44 UTC
Forgot to mention,

This is with ctime feature enabled, i.e.,

gluster vol set utime on
gluster vol set ctime on

Comment 2 Worker Ant 2018-05-19 08:09:25 UTC
REVIEW: https://review.gluster.org/20039 (features/posix: Fix updating ctime in rename and unlink) posted (#1) for review on master by Kotresh HR

Comment 3 Worker Ant 2018-05-24 05:49:53 UTC
COMMIT: https://review.gluster.org/20039 committed in master by "Kotresh HR" <khiremat> with a commit message- ctime: Fix updating ctime in rename and unlink

1. Successful rename was not updating ctime.
   Fixed the same.
2. Successful unlink when link count is more than 1
   was not updating ctime. Fixed the same.
3. Copy ctime and flags during frame copy.

fixes: bz#1580020
Change-Id: Ied47275a36aea60254b2add7a59128a9c83b3645
Signed-off-by: Kotresh HR <khiremat>

Comment 4 Shyamsundar 2018-10-23 15:09:12 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-5.0, please open a new bug report.

glusterfs-5.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] https://lists.gluster.org/pipermail/announce/2018-October/000115.html
[2] https://www.gluster.org/pipermail/gluster-users/