-
Notifications
You must be signed in to change notification settings - Fork 67
/
p4app_example.json
151 lines (151 loc) · 4.93 KB
/
p4app_example.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
{
"p4_src": "<path to gobal p4 source>" (string),
"cli": "<true|false>" (bool),
"pcap_dump": "<true|false>" (bool),
"enable_log": "<true|false>" (bool),
"tasks_file": "<path to the tasks file>" (string),
"host_node":
{
"file_path": "<path to module>" (string),
"module_name": "<module file name>" (string),
"object_name": "<module object name>" (string)
},
"switch_node":
{
"file_path": "<path to module>" (string),
"module_name": "<module file name>" (string),
"object_name": "<module object name>" (string)
},
"router_node":
{
"file_path": "<path to module>" (string),
"module_name": "<module file name>" (string),
"object_name": "<module object name>" (string)
},
"compiler_module":
{
"file_path": "<path to module>" (string),
"module_name": "<module file name>" (string),
"object_name": "<module object name>" (string),
"options": "<options passed to init>" (dict)
},
"client_module":
{
"file_path": "<path to module>" (string),
"module_name": "<module file name>" (string),
"object_name": "<module object name>" (string),
"options": "<options passed to init>" (dict)
},
"mininet_module":
{
"file_path": "<path to module>" (string),
"module_name": "<module file name>" (string),
"object_name": "<module object name>" (string)
},
"exec_scripts":
[
{
"cmd": "<path to script>" (string),
"reboot_run": "<true|false>" (bool)
},
...
],
"topology":
{
"assignment_strategy": "<assignment_strategy>" (string),
"default":
{
"weight": "<weight>" (int) (*),
"bw": "<bandwidth>" (int) (*),
"delay": "<transmit_delay>" (int) (*),
"loss": "<loss>" (float) (*),
"max_queue_size": "<max_queue_size>" (int) (*),
"auto_arp_tables": "<true|false>" (bool) (*),
"auto_gw_arp": "<true|false>" (bool) (*)
},
"links":
[
[
"r1",
"h1",
{
"weight": "<link weight>" (int) (*),
"port1": "<number of port1>" (int) (*),
"port2": "<number of port2>" (int) (*),
"intfName1": "<name of the interface1>" (string) (*),
"intfName2": "<name of the interface2>" (string) (*),
"addr1": "<mac address of interface1>" (string) (*),
"addr2": "<mac address of interface2>" (string) (*),
"params1": "<parameters for interface1>" (dict) (*),
"params2": "<parameters for interface2>" (dict) (*),
"bw": "<bandwidth weight>" (int) (*),
"delay": "<transmit delay>" (int) (*),
"loss": "<link data loss>" (float) (*),
"max_queue_size": "<max queue size>" (int) (*)
}
],
...
],
"hosts":
{
"h1":
{
"scheduler": "<true|false>" (bool) (*),
"socket_path": "<dir to socket file>" (string) (*),
"defaultRoute": "via "<gateway ip>"" (string) (*),
"dhcp": "<true|false>" (bool) (*),
"log_enabled" : "<true|false>" (bool) (*),
"log_dir": "<log path for host>" (string) (*),
"host_node": "<custom host_node>" (dict) (*)
},
...
},
"switches":
{
"s1":
{
"p4_src": "<path to p4 program>" (string) (*),
"cpu_port": "<true|false>" (bool) (*),
"cli_input": "<path to cli input file>" (string) (*),
"switch_node": "<custom switch_node>" (dict) (*),
"log_enabled" : "<true|false>" (bool) (*),
"log_dir": "<log path for switch binary>" (string) (*),
"pcap_dump": "<true|false>" (bool) (*),
"pcap_dir": "<path for pcap files>" (string) (*),
"sw_bin": "<switch binary>" (string) (*),
"thrift_port": "<thrift port>" (int) (*),
"grpc_port": "<grpc port>" (int) (*)
},
...
},
"routers":
{
"r1":
{
"int_conf": "<path to the router's integrate configuration file>" (string),
"conf_dir": "<path to the directory which contains the folder
(named after the router) with the configuration
files for all the daemons>" (string),
"router_node": "<custom router_node>" (dict) (*),
"zebra": "<true|false>" (bool) (*),
"bgpd": "<true|false>" (bool) (*),
"ospfd": "<true|false>" (bool) (*),
"ospf6d": "<true|false>" (bool) (*),
"ripd": "<true|false>" (bool) (*),
"ripngd": "<true|false>" (bool) (*),
"isisd": "<true|false>" (bool) (*),
"pimd": "<true|false>" (bool) (*),
"ldpd": "<true|false>" (bool) (*),
"nhrpd": "<true|false>" (bool) (*),
"eigrpd": "<true|false>" (bool) (*),
"babeld": "<true|false>" (bool) (*),
"sharpd": "<true|false>" (bool) (*),
"staticd": "<true|false>" (bool) (*),
"pbrd": "<true|false>" (bool) (*),
"bfdd": "<true|false>" (bool) (*),
"fabricd" : "<true|false>" (bool) (*)
},
...
}
}
}