Chinese translated version of Documentation/namespaces/resource-control.txt
If you are have any comment or update to the content, please contact the
Original document maintainer directly. However, if you have a problem
Communicating in 中文版 can also ask the Chinese maintainer for
Help. Contact the Chinese maintainer if it translation is outdated
Or if there is a problem with the translation.
Chinese maintainer: Tianyu 479103577@qq.com
---------------------------------------------------------------------
The Chinese translation of Documentation/namespaces/resource-control.txt
If you want to comment or update the contents of this article, please contact the maintainer of the original document directly. If you use English
If communication is difficult, you can also ask for help from the Chinese version of the defender. If this translation is not updated in time or over
Please contact the Chinese version of the defender.
Chinese version maintainer: Tianyu 479103577@qq.com
Translator of Chinese version: Tianyu 479103577@qq.com
Chinese version of the translator: Tianyu 479103577@qq.com
2 Fault Injection
3 = fault injection ==============
4 Fault injection is a to forcing errors that may not normally occur, or
5 May is difficult to reproduce. Forcing errors in a controlled environment
6 can help the developer find and fix bugs before their code are shipped in a
7 production system. Injecting an error on the Linux NFS server would allow us to
8 Observe how the client reacts and if it manages to recover its state correctly.
9 Fault injection is a method used to force errors that may not normally occur, or
It can be hard to reproduce. Forcing these errors in a controlled environment
can help developers find and fix error codes before leaving the factory
Production systems. The error on the NFS server injected with Linux will enable us to
Observe how the customer reacts if it is properly managed to restore its status.
Nfsd_fault_injection must is selected when configuring the kernel to use this
One by one feature.
12 When configuring kernel usage, you must select Nfsd_fault_injection
11 function.
13
Using Fault Injection
15 Using fault injection =====================
The client, mount the fault injection server through NFS v4.0+ and do some
Work over NFS (open files, take locks, ...).
18 on the client, install the fault injection server through NFS v4.0+ and do some
17 Jobs in NFS (open file, take lock, ...) )。
On the server, mount the DEBUGFS filesystem to <debug_dir> and LS
<DEBUG_DIR>/NFSD. This'll show a list of the files that'll be used for
Injecting faults on the NFS server. As root, write a number n to the file
Corresponding to the action you want the server to take. The server would then
The process the the ' the ' the ' the ' it finds. So if you are want to forget 5 locks, echo ' 5 '
To <debug_dir>/nfsd/forget_locks. A value of 0 'll tell the server to forget
All corresponding items. A log message would be created containing the number
of the items forgotten (check DMESG).
27 Debugfs file Systems <debug_dir> and LS installed on the server
<debug_dir>/NFSD. This will display a list of the files that will be used for
Inject a failure on the NFS server. As the root, write a file of n
The action you want to take on the server corresponds. The server will then
Process, the first n items and its discovery. So if you want to forget the 5 sluices, echo ' 5 '
To the <debug_dir>//of NFSD forget_locks. A value of 0 tells the server to forget
All the corresponding items. A log message is created that contains a number
Forgotten items (check dmesg).
Work on the client and check if the client recovered from the error
correctly.
30 go back to work on the client and check the client to recover from the error
That's right.
31
Available faults
33 = Available Fault ==============
Forget_clients:
The NFS server keeps a list of clients that have placed a mount call. If
The This list is cleared, the server would have no knowledge the WHO client
Forcing the client to reauthenticate with the server.
Forget_clients:
Client for NFS server placed a list of installation call keeping. If
This list is cleared, and the client server will not have the knowledge
Forcing the client to authenticate with the server.
Forget_openowners:
The NFS server keeps a list of what files are currently opened and who
They were opened by. Clearing this list would force the client to reopen
its files.
Forget_openowners:
NFS server has saved which files are being opened and who
them open. Clearing the list forces the client to reopen
File.
Forget_locks:
The NFS server keeps a list of what files are currently locked in the VFS.
Clearing this list would force the client to reclaim its locks (files are
The unlocked through the VFS as they are cleared from this list).
Forget_locks:
Server for NFS maintains a list of which files are currently locked in the VFS.
Clearing this list will force the client to reclaim its locks (file
Unlock through the VFS because they are cleared from the list.
Forget_delegations:
A delegation is used to assure the client that's a file, or part of a file,
Wuyi has not changed since the delegation is awarded. Clearing this list would
Force the client to reaquire its delegation before accessing the file
Again.
Forget_delegations:
A delegation to ensure that the client file, or part of the file,
has not changed since being delegated to the delegation. Clear the list
Force client Reaquire's delegation before accessing the file
Again.
Recall_delegations:
Delegations can be recalled by the server when another client attempts to
Access a file. This test would notify the client that it delegation has
been revoked, forcing the client to reaquire the delegation using
The file again.
Recall_delegations:
Delegation when the server can invoke another client to try
Access to a file. This test will inform the customer of their delegation
was withdrawn, forcing the client to use the former Reaquire delegation
The file.
61
tools/nfs/inject_faults.sh Script
63 = tool/nfs/inject_faults.sh script ================================
The This script has been created to ease the fault injection process. This script
Mounted detect the Debugfs directory and write to the files located there
Based on the arguments passed by the user. For example, running
This script has been created to mitigate the failure injection process. This script
65 will detect the installation of the Debugfs where the files, directories and write
66 based on the parameters passed by the user. For example, run
The ' inject_faults.sh forget_locks1 ' root instructs the server
The ' inject_faults.sh forget_locks 1 ' as root would instruct the server to forget
One lock. Running ' Inject_faults forget_locks ' would instruct the server to
Forgetall locks.
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.