Hacker News new | past | comments | ask | show | jobs | submit login

> Couldn't this pretty easily be solved at the file system level? Just store a back pointer from a file to each of its names.

In theory yes, but no filesystem does this as far as I know.




In Windows both NTFS and ReFS keep backpointers to all their names. They store the file ID of the directory, and the name of the file in the directory. In NTFS these are stored as a special attribute, and in ReFS they reside as rows in the file table.

It's required for a few reasons. Historically NTFS has had an API to query all of a files names and this needs to be done efficiently. And when a file is opened by ID, the file system needs to construct a canonical path for it in the name space.

Source: I am the Microsoft developer that added hardlink support to ReFS. All opinions are my own.




Consider applying for YC's W25 batch! Applications are open till Nov 12.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: