Skip to content

Commit 5e5b9e1

Browse files
committed
add instructions about AUR
Signed-off-by: YangKeao <[email protected]>
1 parent 7fae4e1 commit 5e5b9e1

File tree

1 file changed

+39
-4
lines changed

1 file changed

+39
-4
lines changed

README.md

Lines changed: 39 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,48 @@
11
# Chaos Driver
22

3-
## Build
4-
3+
## Install
4+
5+
You can install the Chaos Driver in two ways: install from the package manager, or build manually.
6+
7+
### Packages
8+
9+
#### Arch Linux
10+
11+
If you are using Arch Linux, you can find the package on AUR: [chaos-driver](https://aur.archlinux.org/pkgbase/chaos-driver/). You can install it with the help of any AUR helper. For example:
12+
13+
```bash
14+
yay chaos-driver-dkms
15+
yay kchaos
16+
```
17+
18+
The `chaos-driver-dkms` is the kernel module, and the `kchaos` is the client to communicate with it. After installing the packages, you can load the kernel module through:
19+
20+
```bash
21+
modprobe chaos_driver
22+
```
23+
524
### Build Manually
625

7-
Run `make all` to build the kernel module. The `KBUILD_PATH` environment variable should point to the kernel source code or kernel headers, which can be installed through `yum install kernel-devel` or `apt install linux-headers-$(uname -r)` according to your distribution. By default, it's `/lib/modules/$(uname -r)/build`.
26+
#### Client
827

9-
## Usage
28+
The client `kchaos` is a normal cgo program. Use the following commands to compile it:
29+
30+
```bash
31+
go build -o ./bin/kchaos ./cmd
32+
```
33+
34+
#### Kernel Module
35+
36+
Run `make all` to build the kernel module. The `KBUILD_PATH` environment variable should point to the kernel source code or kernel headers, which can be installed through `yum install kernel-devel` or `apt install linux-headers-$(uname -r)` according to your distribution. By default, it's `/lib/modules/$(uname -r)/build`.
1037

1138
After building the kernel module, you could load it by running the following command:
1239

1340
```bash
1441
insmod ./driver/chaos_driver.ko
1542
```
1643

44+
## Usage
45+
1746
### IOEM
1847

1948
Change the io scheduler of target device into the `ioem`. For example:
@@ -67,6 +96,12 @@ WIP. It's too dangerous to inject long delay in an atomic context, so this funct
6796

6897
- [x] Inject latency
6998
- [x] Traffic controll of IO
99+
- Package for distributions
100+
- [x] AUR
101+
- [ ] Debian
102+
- [ ] Ubuntu PPA
103+
- [ ] Fedora
104+
- [ ] Cent OS
70105

71106
### Test
72107

0 commit comments

Comments
 (0)