ramfs 1.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. .TH RAMFS 4
  2. .SH NAME
  3. ramfs \- memory file system
  4. .SH SYNOPSIS
  5. .B ramfs
  6. [
  7. .B -i
  8. ]
  9. [
  10. .B -s
  11. ]
  12. [
  13. .B -p
  14. ]
  15. [
  16. .B -m
  17. .I mountpoint
  18. ]
  19. .SH DESCRIPTION
  20. .I Ramfs
  21. starts a process that mounts itself (see
  22. .IR bind (2))
  23. on
  24. .I mountpoint
  25. (default
  26. .BR /tmp ).
  27. The
  28. .I ramfs
  29. process implements a file tree rooted at
  30. .IR dir ,
  31. keeping all files in memory.
  32. Initially the file tree is empty.
  33. .PP
  34. The
  35. .B -i
  36. flag tells
  37. .I ramfs
  38. to use file descriptors 0 and 1 for its communication channel
  39. rather than create a pipe.
  40. This makes it possible to use
  41. .I ramfs
  42. as a file server on a remote machine: the file descriptors 0
  43. and 1 will be the network channel from
  44. .I ramfs
  45. to the client machine.
  46. The
  47. .B -s
  48. flag causes
  49. .I ramfs
  50. to post its channel on
  51. .B /srv/ramfs
  52. rather than mounting it on
  53. .IR mountpoint ,
  54. enabling multiple clients to access its files.
  55. However, it does not authenticate its clients and its
  56. implementation of groups is simplistic, so
  57. it should not be used for precious data.
  58. .PP
  59. The
  60. .B -p
  61. flag causes
  62. .I ramfs
  63. to make its memory `private'
  64. (see
  65. .IR proc (3))
  66. so that its files are not accessible through the debugging interface.
  67. .PP
  68. This program is useful mainly as an example of how
  69. to write a user-level file server.
  70. It can also be used to provide high-performance temporary files.
  71. .SH SOURCE
  72. .B /sys/src/cmd/ramfs.c
  73. .SH "SEE ALSO"
  74. .IR bind (2)