public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
* File inode numbers in Cygwin
@ 2021-08-08 21:31 Lavrentiev, Anton (NIH/NLM/NCBI) [C]
  2021-08-09  1:53 ` Lavrentiev, Anton (NIH/NLM/NCBI) [C]
  0 siblings, 1 reply; 2+ messages in thread
From: Lavrentiev, Anton (NIH/NLM/NCBI) [C] @ 2021-08-08 21:31 UTC (permalink / raw)
  To: 'cygwin@cygwin.com'

Hi all,

I have a question that might have been asked on here before, but I wasn't able to find it, so here it goes:

In Cygwin, it seems like for the local native file system (NTFS), file inode numbers (struct stat::st_ino)
get generated by hashing the file names, rather than them being tied to any underlying NTFS structure.
Hashing creates enormous values, which are ridiculous when, for example, they appear in the output of
"ls" or "find ... -ls" (take a look at the first column):

756886212375058592   1944 -rw-r--r--   1
 76842668642019062   5124 -rw-r--r--   1
 22236523160543609   3968 -rw-r--r--   1
199847233464684144   2196 -rw-r--r--   1
 25332747904353951   1704 -rw-r--r--   1
144678138029403288   2092 -rw-r--r--   1
496803333894707846   2304 -rw-r--r--   1
  1125899906965241   9736 -rw-------   1
105834591243939239  37616 -rw-r--r--   1
 35747322042356092  13176 -rw-r--r--   1
  1125899906965242  29932 -rw-------   1
2099521851284814243  16396 -rw-r--r--   1
10542363777720944191  12848 -rw-r--r--   1
    1688849860377295  19880 -rw-------   1
   24488322973875959  15808 -rw-r--r--   1
   16325548649265885   8820 -rw-r--r--   1
   26458647810840719    136 -rw-r--r--   1
   26458647810904505   1740 -rw-r--r--   1
   68116944363996494   1740 -rw-r--r--   1
   52072870691507121   4320 -rw-r--r--   1
    1125899906965472  17556 -rw-------   1
    1125899906965490  10956 -rw-------   1
   65865144550731394    292 -rw-r--r--   1
  278941701920304249   1364 -rw-r--r--   1
 7004223320468079341  39144 -rw-r--r--   1
  435160313994792954  31172 -rw-r--r--   1
  333266372426149018  14396 -rw-r--r--   1

So the question:  was there any reason that the native NTFS file IDs (which are quite reasonable) weren't used
for inode numbers?

Thanks,

Anton Lavrentiev
Contractor NIH/NLM/NCBI


^ permalink raw reply	[flat|nested] 2+ messages in thread

* RE: File inode numbers in Cygwin
  2021-08-08 21:31 File inode numbers in Cygwin Lavrentiev, Anton (NIH/NLM/NCBI) [C]
@ 2021-08-09  1:53 ` Lavrentiev, Anton (NIH/NLM/NCBI) [C]
  0 siblings, 0 replies; 2+ messages in thread
From: Lavrentiev, Anton (NIH/NLM/NCBI) [C] @ 2021-08-09  1:53 UTC (permalink / raw)
  To: 'cygwin@cygwin.com'

Replying to myself:

> So the question:  was there any reason that the native NTFS file IDs (which are quite
> reasonable) weren't used

Sorry for posting my previous question, it looks like the inode numbers are actually NTFS file IDs for the files.
They are reasonably looking when in hex, but decimal representation makes them look scary.

Anton Lavrentiev
Contractor NIH/NLM/NCBI

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-08-09  1:53 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-08-08 21:31 File inode numbers in Cygwin Lavrentiev, Anton (NIH/NLM/NCBI) [C]
2021-08-09  1:53 ` Lavrentiev, Anton (NIH/NLM/NCBI) [C]

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).