VOP_VPTOFH(9)

πŸ“¦ version 15.1, in freebsd 14.5, freebsd 15.1, nixpkgs unstable

πŸ’… VOP_VPTOFH πŸ’…

okay so bestie, welcome to the VOP_VPTOFH(9) page β€” section 9 of the kernel developer's manual, aka where the NFS server girlies hang out. buckle up, this one's short but iconic ✨


🌸 NAME 🌸

VOP_VPTOFH β€” turn a vnode into an NFS filehandle, no cap πŸ¦‹


✨ SYNOPSIS ✨

#include <sys/param.h>
#include <sys/vnode.h>

int
VOP_VPTOFH(struct vnode *vp, struct fid *fhp);

like, that's it. that's the whole signature. she's compact πŸ’…


πŸŽ€ DESCRIPTION πŸŽ€

so the NFS server literally uses this to create an opaque filehandle that uniquely identifies the file β€” and then an NFS client can use that filehandle later to access the file in the future. it's giving "save your progress" energy, fr fr πŸ”₯

its arguments are:

  • vp β€” the vnode you're making a filehandle for. the main character, the one we're describing πŸ‘‘
  • fhp β€” the return parameter for the filehandle. this is where the filehandle goes on its way back out πŸ’–

πŸ’œ SEE ALSO πŸ’œ

(the reverse direction is VFS_FHTOVP(9) btw β€” iykyk 🌈)


🫢 AUTHORS 🫢

this manual page was written by Doug Rabson. thank you king, we appreciate you πŸ™ˆβœ¨


okay that's the whole page, mwah πŸ’‹

btw this glorious little page comes from the Debian version of the Kernel Developer's Manual, dated February 16, 2007 β€” vintage but still slaying πŸ’…πŸŽ€
πŸ“¦ where this page comes from