免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
12
最近访问板块 发新帖
楼主: 海崎洋光
打印 上一主题 下一主题

文件和目录的链接数都由什么决定 [复制链接]

论坛徽章:
0
11 [报告]
发表于 2007-10-21 22:11 |只看该作者
you can type "info link" in the shell.
  1. $info link
  2. A "hard link" is another name for an existing file; the link and the
  3. original are indistinguishable.  Technically speaking, they share the
  4. same inode, and the inode contains all the information about a
  5. file--indeed, it is not incorrect to say that the inode _is_ the file.
  6. On all existing implementations, you cannot make a hard link to a
  7. directory, and hard links cannot cross file system boundaries.  (These
  8. restrictions are not mandated by POSIX, however.)

  9. "Symbolic links" ("symlinks" for short), on the other hand, are a
  10. special file type (which not all kernels support: System V release 3
  11. (and older) systems lack symlinks) in which the link file actually
  12. refers to a different file, by name.  When most operations (opening,
  13. reading, writing, and so on) are passed the symbolic link file, the
  14. kernel automatically "dereferences" the link and operates on the target
  15. of the link.  But some operations (e.g., removing) work on the link
  16. file itself, rather than on its target.  *Note Symbolic Links:
  17. (libc)Symbolic Links.
复制代码

论坛徽章:
0
12 [报告]
发表于 2007-10-22 10:52 |只看该作者

回复 #10 ShadowStar 的帖子

呵呵,老师今天也是这么说的!!!谢谢您的更正!!!

论坛徽章:
0
13 [报告]
发表于 2007-10-22 12:42 |只看该作者
看遍《UNIX教程》就不会对这种问题存有疑问了
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP