Commit 7aeb49f
[Monit] Sanity check for Monit services (#2501)
Description of PR
Summary:
This PR aims to add Monit service into sanity check. Specifically before running each pytest script, sanity check will determine whether the Monit is running and at the same time determine whether the services which were monitored by Monit are running correctly or not.
Fixes # (issue)
Type of change
[ x] Testbed and Framework(new/improvement)
Approach
What is the motivation for this PR?
This PR aims to add Monit service into sanity check. Specifically before running each pytest script, sanity check will determine whether the Monit is running and at the same time determine whether the services which were monitored by Monit are running correctly or not.
How did you do it?
I added a new function check_monit(...) in checks.py to achieve the purpose. In this function, it will first call a common function get_monit_services_status(...) in devices.py to get the metadata (service name, service status and service type) of services which are monitored by Monit. Then it will determine whether Monit is running or not and whether each service which was monitored by Monit is running or not.
How did you verify/test it?
I tested this change against the lab device str-dx010-acs-1.
Any platform specific information?
N/A
Supported testbed topology if it's a new test case?
N/A
Signed-off-by: Yong Zhao <[email protected]>
Co-authored-by: Ying Xie <[email protected]>1 parent 099204e commit 7aeb49f
File tree
3 files changed
+108
-2
lines changed- tests/common
- plugins/sanity_check
3 files changed
+108
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
403 | 403 | | |
404 | 404 | | |
405 | 405 | | |
| 406 | + | |
| 407 | + | |
| 408 | + | |
| 409 | + | |
| 410 | + | |
| 411 | + | |
| 412 | + | |
| 413 | + | |
| 414 | + | |
| 415 | + | |
| 416 | + | |
| 417 | + | |
| 418 | + | |
| 419 | + | |
| 420 | + | |
| 421 | + | |
| 422 | + | |
| 423 | + | |
| 424 | + | |
| 425 | + | |
| 426 | + | |
| 427 | + | |
| 428 | + | |
| 429 | + | |
| 430 | + | |
| 431 | + | |
| 432 | + | |
| 433 | + | |
406 | 434 | | |
407 | 435 | | |
408 | 436 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
| 10 | + | |
10 | 11 | | |
11 | 12 | | |
12 | 13 | | |
| |||
171 | 172 | | |
172 | 173 | | |
173 | 174 | | |
| 175 | + | |
| 176 | + | |
| 177 | + | |
| 178 | + | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
| 183 | + | |
| 184 | + | |
| 185 | + | |
| 186 | + | |
| 187 | + | |
| 188 | + | |
| 189 | + | |
| 190 | + | |
| 191 | + | |
| 192 | + | |
| 193 | + | |
| 194 | + | |
| 195 | + | |
| 196 | + | |
| 197 | + | |
| 198 | + | |
| 199 | + | |
| 200 | + | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
| 206 | + | |
| 207 | + | |
| 208 | + | |
| 209 | + | |
| 210 | + | |
| 211 | + | |
| 212 | + | |
| 213 | + | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
| 246 | + | |
| 247 | + | |
| 248 | + | |
174 | 249 | | |
175 | 250 | | |
176 | 251 | | |
| |||
193 | 268 | | |
194 | 269 | | |
195 | 270 | | |
| 271 | + | |
196 | 272 | | |
197 | 273 | | |
198 | 274 | | |
| |||
228 | 304 | | |
229 | 305 | | |
230 | 306 | | |
| 307 | + | |
| 308 | + | |
231 | 309 | | |
232 | 310 | | |
233 | 311 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
21 | 21 | | |
22 | 22 | | |
23 | 23 | | |
24 | | - | |
25 | | - | |
| 24 | + | |
| 25 | + | |
0 commit comments