Bug 10604

Summary: stat truncates inode numbers to 32 bits
Product: [Retired] Red Hat Linux Reporter: Phil Schwan <phil>
Component: statAssignee: Preston Brown <pbrown>
Status: CLOSED RAWHIDE QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: 6.2Keywords: FutureFeature
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Enhancement
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2000-04-06 19:13:57 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Phil Schwan 2000-04-05 19:41:37 UTC
Filesystems (XFS, for example) are starting to use 64 bit inodes.  The
userspace tools should correctly report these.

--- stat-1.5/stat.c	Wed Apr  5 10:55:53 2000
+++ stat-1.5/stat.c	Wed Apr  5 10:50:42 2000
@@ -314,9 +314,9 @@
 	if(oneperline)
 		(void) printf("\n");
 	if(oneperline)
-		(void) printf("Inode: %-10ld\n", Sbuf.st_ino);
+		(void) printf("Inode: %-15lld\n", Sbuf.st_ino);
 	else
-		(void) printf("  Inode: %-10ld", Sbuf.st_ino);
+		(void) printf("  Inode: %-15lld", Sbuf.st_ino);
 	(void) printf("Links: %-5d", Sbuf.st_nlink);

 	/* Only meaningful if file is device */

(In unrelated news, is there a 'stat' maintainer that all distributions
feed from?)

Comment 1 Nalin Dahyabhai 2000-04-06 19:13:59 UTC
It looks like stat(1) is no longer maintained.  Someone did a from-scratch
rewrite, called it 2.2, and uploaded it to metalab, though.

Comment 2 Jeff Johnson 2000-07-27 21:40:55 UTC
Fixed by upgrading to stat-2.2-1.