2
2
3
3
Directory ` compat ` implements an ipc library using dpdk ` rte_ring ` and ports some source files compatible with FreeBSD and Linux.
4
4
5
+ Directory ` sbin ` contains all the tools binary that compiled.
6
+
5
7
All other directories are useful tools ported from FreeBSD.
6
8
Since F-Stack is multi-process architecture and every process has an independent stack, so we must communicate with every F-Stack process.
7
9
Each tool add an option ` -p ` (Which F-Stack process to communicate with, default 0), except that, it is same with the original FreeBSD.
@@ -48,38 +50,38 @@ Examples:
48
50
```
49
51
Add a default route:
50
52
51
- ./route -p 0 add -net 0.0.0.0/0 192.168.1.1
53
+ ./sbin/ route -p 0 add -net 0.0.0.0/0 192.168.1.1
52
54
53
55
A shorter version of adding a default route can also be written as:
54
56
55
- ./route -p 0 add default 192.168.1.1
57
+ ./sbin/ route -p 0 add default 192.168.1.1
56
58
57
59
Add a static route to the 172.16.10.0/24 network via the 172.16.1.1 gate-
58
60
way:
59
61
60
- ./route -p 0 add -net 172.16.10.0/24 172.16.1.1
62
+ ./sbin/ route -p 0 add -net 172.16.10.0/24 172.16.1.1
61
63
62
64
Change the gateway of an already established static route in the routing
63
65
table:
64
66
65
- ./route -p 0 change -net 172.16.10.0/24 172.16.1.2
67
+ ./sbin/ route -p 0 change -net 172.16.10.0/24 172.16.1.2
66
68
67
69
Display the route for a destination network:
68
70
69
- ./route -p 0 show 172.16.10.0
71
+ ./sbin/ route -p 0 show 172.16.10.0
70
72
71
73
Delete a static route from the routing table:
72
74
73
- ./route -p 0 delete -net 172.16.10.0/24 172.16.1.2
75
+ ./sbin/ route -p 0 delete -net 172.16.10.0/24 172.16.1.2
74
76
75
77
Remove all routes from the routing table:
76
78
77
- ./route -p 0 flush
79
+ ./sbin/ route -p 0 flush
78
80
79
81
FreeBSD uses `netstat -rn ` to list the route table which we havn't ported,
80
82
you can execute the following command instead, `-d` means debug mode, `-v`
81
83
means verbose.
82
- . /route -p 0 -d -v flush
84
+ ./sbin /route -p 0 -d -v flush
83
85
```
84
86
Note that, if you want to modify the route table, you must use ` -p ` to execute the same command for each f-stack process.
85
87
@@ -92,7 +94,7 @@ top [-p <f-stack proc_id>] [-d <secs>] [-n num]
92
94
```
93
95
Examples:
94
96
```
95
- ./tools/top /top
97
+ ./sbin /top
96
98
97
99
|---------|---------|---------|---------------|
98
100
| idle| sys| usr| loop|
@@ -219,7 +221,7 @@ traffic [-p <f-stack proc_id>] [-d <secs>] [-n num]
219
221
```
220
222
Examples:
221
223
```
222
- ./tools/traffic /traffic
224
+ ./sbin /traffic
223
225
224
226
|--------------------|--------------------|--------------------|--------------------|
225
227
| rx packets| rx bytes| tx packets| tx bytes|
0 commit comments