News for hackers. Stuff that matters.
Re:How to change symlinks atomically (2005) by geocar on Sunday August 21, 2016 @04:34AM (#12330011)
Yes.

What UNIX called an inode is unfortunately not what Linux now calls an inode. That thing might have better names, but we are stuck with it.

I don't know if it is useful to say "Linux inode" because that can refer to both what "ext4" calls an inode and what the Linux kernel refers to as a "virtual inode".

What POSIX called a "file serial number" (and goes in the `d_ino` field) is also not what Linux calls an inode. I sometimes think this is okay to refer to as a "POSIX inode" because POSIX doesn't otherwise use the term, and up until SUS6 the POSIX file serial number was compatible with a UNIX inode.

However I'm not trying to nit: Trying to develop a simplified mental model is essential to determining what to do (and what to sync!). From an application point of view, knowing that a symbolic link has a name (and contents) and lives in a directory, can help guide us.

Re:How to change symlinks atomically (2005) by caf on Sunday August 21, 2016 @08:00AM (#12330597)
What UNIX called an inode is unfortunately not what Linux now calls an inode. That thing might have better names, but we are stuck with it.

How so? Here's a v6 on-disk inode: https://github.com/hephaex/unix-v6/blob/master/ino.h

and here's an ext4 on-disk inode: http://lxr.free-electrons.com/source/fs/ext4/ext4.h#L704

The latter is considerably larger, to be sure, but still contains all of the fields from the former (many of them with the same name!).

Re:How to change symlinks atomically (2005) by geocar on Sunday August 21, 2016 @12:34PM (#12331490)
That may be, but Linux also uses the term "inode" to refer to what the BSD's refer to as a "vnode", which also have similar names.
Re:How to change symlinks atomically (2005) by caf on Sunday August 21, 2016 @08:08PM (#12333351)
UNIX v6 used the term "inode" to refer to that as well - it was BSD that changed the name.

UNIX called them "inode" and "permanent inode"; Linux calls them "in-memory inode" and "on-disk inode". The BSDs use "vnode" and "inode".