cfs 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124
  1. .TH CFS 4
  2. .SH NAME
  3. cfs \- cache file system
  4. .SH SYNOPSIS
  5. .B cfs
  6. .B -s
  7. .RB [ -dknrS ]
  8. .RB [ -f
  9. .IR partition ]
  10. .PP
  11. .B cfs
  12. .B -a
  13. .I netaddr
  14. .RB [ -dknrS ]
  15. .RB [ -f
  16. .IR partition ]
  17. .RI [ mtpt ]
  18. .PP
  19. .B cfs
  20. .B -F
  21. .I srvfile
  22. .RB [ -dknrS ]
  23. .RB [ -f
  24. .IR partition ]
  25. .RI [ mtpt ]
  26. .SH DESCRIPTION
  27. .I Cfs
  28. is a user-level file server that caches data from remote
  29. files onto a local disk.
  30. It is normally started by the kernel at boot time, though users may start
  31. it manually.
  32. .I Cfs
  33. is interposed between the kernel and a network connection to a
  34. remote file server to improve the
  35. efficiency of access across slow network connections such as modem
  36. lines.
  37. On each open of a file
  38. .I cfs
  39. checks the consistency of cached information and discards any old
  40. information for that file.
  41. .PP
  42. .I Cfs
  43. mounts onto
  44. .I mtpt
  45. (default
  46. .BR / )
  47. after connecting to the file server.
  48. .PP
  49. The options are:
  50. .TF -
  51. .PD
  52. .TP
  53. .BI "a " netaddr
  54. dial the destination
  55. .I netaddr
  56. to connect to a remote file server.
  57. Exclusive with
  58. .BR -F .
  59. .TP
  60. .B d
  61. turn on debugging.
  62. .TP
  63. .BI "f " partition
  64. use file
  65. .I partition
  66. as the cache disk partition.
  67. .TP
  68. .BI "F " srvfile
  69. open
  70. .I srvfile
  71. (often a file under
  72. .BR /srv )
  73. to connect to a remote file server.
  74. Exclusive with
  75. .BR -a .
  76. .TP
  77. .B k
  78. keep cache contents even if they might have come from a different server.
  79. .I Cfs
  80. will obey
  81. .B -r
  82. even if
  83. .B -k
  84. is given.
  85. .TP
  86. .B n
  87. mount the remote file server without authentication;
  88. often useful with
  89. .BR -F .
  90. .TP
  91. .B r
  92. reformat the cache disk partition.
  93. .TP
  94. .B s
  95. the connection to the remote file server is on file
  96. descriptors 0 and 1.
  97. .TP
  98. .B S
  99. turn on statistics gathering. A file called
  100. .B cfsctl
  101. at the root of the caching file system can be read to get
  102. statistics concerning number of calls/bytes on client and server
  103. sides and latencies.
  104. .PP
  105. All 9P messages except
  106. .BR read ,
  107. .BR clone ,
  108. and
  109. .B walk
  110. (see
  111. .IR intro (5))
  112. are passed through
  113. .I cfs
  114. unchanged to the remote server.
  115. If possible, a
  116. .B read
  117. is satisfied by cached data.
  118. Otherwise, the file server is queried for any missing data.
  119. .SH FILES
  120. .TP
  121. .B /dev/sdC0/cache
  122. Default file used for storing cached data.
  123. .SH SOURCE
  124. .B /sys/src/cmd/cfs