Vietnamese (machine translation)

Lưu ý

Mục đích của file này là để độc giả tiếng Việt có thể đọc và hiểu tài liệu nhân kernel dễ dàng hơn, không phải để tạo ra một nhánh tài liệu riêng. Nếu bạn có bất kỳ nhận xét hoặc cập nhật nào cho file này, vui lòng thử cập nhật file tiếng Anh gốc trước. Nếu bạn thấy có sự khác biệt giữa bản dịch và bản gốc, hoặc có vấn đề về bản dịch, vui lòng gửi góp ý hoặc patch cho người dịch của file này, hoặc nhờ người bảo trì và người review tài liệu tiếng Việt giúp đỡ.

Bản gốc:

Administrative interfaces for nfsd

Người dịch:

Google Translate (machine translation)

Phiên bản gốc:

8541d8f725c6

Cảnh báo

Tài liệu này được dịch tự động bằng máy và chưa được review bởi người dịch. Nội dung có thể không chính xác hoặc khó hiểu ở một số chỗ. Khi có sự khác biệt với bản gốc, bản gốc luôn là chuẩn. Bản dịch chất lượng cao (được review) được đặt trong thư mục vi_VN/.

Administrative interfaces for nfsd

Note that normally these interfaces are used only by the utilities in nfs-utils.

nfsd is controlled mainly by pseudofiles under the “nfsd” filesystem, which is normally mounted at /proc/fs/nfsd/.

The server is always started by the first write of a nonzero value to nfsd/threads.

Before doing that, NFSD can be told which sockets to listen on by writing to nfsd/portlist; that write may be:

  • an ascii-encoded file descriptor, which should refer to a bound (and listening, for tcp) socket, or

  • “transportname port”, where transportname is currently either “udp”, “tcp”, or “rdma”.

If nfsd is started without doing any of these, then it will create one udp and one tcp listener at port 2049 (see nfsd_init_socks).

On startup, nfsd and lockd grace periods start. nfsd is shut down by a write of 0 to nfsd/threads. All locks and state are thrown away at that point.

Between startup and shutdown, the number of threads may be adjusted up or down by additional writes to nfsd/threads or by writes to nfsd/pool_threads.

For more detail about files under nfsd/ and what they control, see fs/nfsd/nfsctl.c; most of them have detailed comments.

Implementation notes

Note that the rpc server requires the caller to serialize addition and removal of listening sockets, and startup and shutdown of the server. For nfsd this is done using nfsd_mutex.