-
Notifications
You must be signed in to change notification settings - Fork 59
/
Copy pathget_cmd.sh
executable file
·52 lines (47 loc) · 2.61 KB
/
get_cmd.sh
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
#!/bin/bash
trap 'failure ${LINENO} "$BASH_COMMAND"' ERR
# get
$gnmic_base_cmd -a clab-test1-srl1 -e json_ietf get \
--path /system/name/host-name
$gnmic_base_cmd -a clab-test1-srl2 -e json_ietf get \
--path /system/name/host-name
$gnmic_base_cmd -a clab-test1-srl3 -e json_ietf get \
--path /system/name/host-name
# get multi paths
$gnmic_base_cmd -a clab-test1-srl1 -e json_ietf get \
--path /system/name/host-name \
--path /system/gnmi-server
$gnmic_base_cmd -a clab-test1-srl2 -e json_ietf get \
--path /system/name/host-name \
--path /system/gnmi-server
$gnmic_base_cmd -a clab-test1-srl3 -e json_ietf get \
--path /system/name/host-name \
--path /system/gnmi-server
# comma separated paths
$gnmic_base_cmd -a clab-test1-srl1 -e json_ietf get \
--path /system/name/host-name \
--path /system/gnmi-server
$gnmic_base_cmd -a clab-test1-srl2 -e json_ietf get \
--path /system/name/host-name \
--path /system/gnmi-server
$gnmic_base_cmd -a clab-test1-srl3 -e json_ietf get \
--path /system/name/host-name \
--path /system/gnmi-server
# get multi hosts
$gnmic_base_cmd -a clab-test1-srl1,clab-test1-srl2,clab-test1-srl3 -e json_ietf get \
--path /system/name/host-name
$gnmic_base_cmd -a clab-test1-srl1 -a clab-test1-srl2 -a clab-test1-srl3 -e json_ietf get \
--path /system/name/host-name
# get multi hosts and paths
$gnmic_base_cmd -a clab-test1-srl1,clab-test1-srl2,clab-test1-srl3 -e json_ietf get \
--path /system/name/host-name \
--path /system/gnmi-server
$gnmic_base_cmd -a clab-test1-srl1,clab-test1-srl2,clab-test1-srl3 -e json_ietf get \
--path /system/name/host-name \
--path /system/gnmi-server
$gnmic_base_cmd -a clab-test1-srl1 -a clab-test1-srl2 -a clab-test1-srl3 -e json_ietf get \
--path /system/name/host-name \
--path /system/gnmi-server
$gnmic_base_cmd -a clab-test1-srl1 -a clab-test1-srl2 -a clab-test1-srl3 -e json_ietf get \
--path /system/name/host-name \
--path /system/gnmi-server