-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathPort__Cumulus_.xml
141 lines (141 loc) · 7.86 KB
/
Port__Cumulus_.xml
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
<ObjectDefinition>
<information>
<icon>none</icon>
<description></description>
<displayField>object_id</displayField>
<serviceTaskType/>
<order>0</order>
<visibility>5</visibility>
<configType>cli</configType>
<createTemplateId/>
<createTemplateObject/>
<defaultDisplay>false</defaultDisplay>
<dynamic>false</dynamic>
<importIfMandatoryPresent>false</importIfMandatoryPresent>
<maxInstances>0</maxInstances>
<relatedObjects/>
<name>Port (Cumulus)</name>
<group>Default</group>
<importonce>false</importonce>
<importrank>0</importrank>
<reorderinstances>false</reorderinstances>
<sortascending>false</sortascending>
<sortauto>false</sortauto>
<sortnumerical>false</sortnumerical>
<sortvariable>param._order</sortvariable>
</information>
<variables frozen="0">
<variable displayName="Port" name="params.object_id" startIncrement="0" type="String" mandatoryArray="false" visible="true" description="" groupSeparator="" groupDisplayName="" displayOrder="0" increment="0" refServiceURI="" keepOnImport="false" editable="false" onlyDetailView="false" localVarNameMatch="" remoteVarNameMatch="" arrayCanAdd="true" arrayCanRemove="true" arrayCanMove="true" arrayCanEdit="true" displayNameHeader="" fullDisplayName="" isMandatory="false" isUserLocked="true" isGrouped="false" isSearchable="false" isUniqueGlobal="false"/>
<variable displayName="State" name="params.state" startIncrement="0" type="String" mandatoryArray="false" visible="true" description="" groupSeparator="" groupDisplayName="" displayOrder="1" increment="0" refServiceURI="" keepOnImport="false" editable="false" onlyDetailView="false" localVarNameMatch="" remoteVarNameMatch="" arrayCanAdd="true" arrayCanRemove="true" arrayCanMove="true" arrayCanEdit="true" displayNameHeader="" fullDisplayName="" isMandatory="false" isUserLocked="false" isGrouped="false" isSearchable="false" isUniqueGlobal="false">
<values>
<values displayValue="UP">UP</values>
<values displayValue="DN">DN</values>
<values displayValue="ADMDN">ADMDN</values>
</values>
</variable>
<variable displayName="Speed" name="params.speed" startIncrement="0" type="String" mandatoryArray="false" visible="true" description="" groupSeparator="" groupDisplayName="" displayOrder="2" increment="0" refServiceURI="" keepOnImport="false" editable="false" onlyDetailView="false" localVarNameMatch="" remoteVarNameMatch="" arrayCanAdd="true" arrayCanRemove="true" arrayCanMove="true" arrayCanEdit="true" displayNameHeader="" fullDisplayName="" isMandatory="false" isUserLocked="true" isGrouped="false" isSearchable="false" isUniqueGlobal="false"/>
<variable displayName="MTU" name="params.mtu" startIncrement="0" type="String" mandatoryArray="false" visible="true" description="" groupSeparator="" groupDisplayName="" displayOrder="3" increment="0" refServiceURI="" keepOnImport="false" editable="false" onlyDetailView="false" localVarNameMatch="" remoteVarNameMatch="" arrayCanAdd="true" arrayCanRemove="true" arrayCanMove="true" arrayCanEdit="true" displayNameHeader="" fullDisplayName="" isMandatory="false" isUserLocked="true" isGrouped="false" isSearchable="false" isUniqueGlobal="false"/>
<variable displayName="Mode" name="params.mode" startIncrement="0" type="String" mandatoryArray="false" visible="true" description="" groupSeparator="" groupDisplayName="" displayOrder="4" increment="0" refServiceURI="" keepOnImport="false" editable="false" onlyDetailView="false" localVarNameMatch="" remoteVarNameMatch="" arrayCanAdd="true" arrayCanRemove="true" arrayCanMove="true" arrayCanEdit="true" displayNameHeader="" fullDisplayName="" isMandatory="false" isUserLocked="true" isGrouped="false" isSearchable="false" isUniqueGlobal="false"/>
</variables>
<example>
<content>net show interface all
State Name Spd MTU Mode LLDP Summary
----- -------- --- ----- ------------- ---------------------------- ------------------
UP lo N/A 65536 Loopback IP: 127.0.0.1/8
lo IP: 10.10.10.3/32
lo IP: ::1/128
UP eth0 1G 1500 Mgmt tip-sw1-n3k-4 (Ethernet1/41) IP: 10.25.27.11/24
DN swp1 10G 1500 NotConfigured
DN swp2 10G 1500 NotConfigured
DN swp3 10G 1500 NotConfigured
DN swp4 10G 1500 NotConfigured
DN swp5 10G 1500 NotConfigured
DN swp6 10G 1500 NotConfigured
DN swp7 10G 1500 NotConfigured
DN swp8 10G 1500 NotConfigured
DN swp9 10G 1500 NotConfigured
UP swp10 10G 1500 Trunk/L2 Master: bridge(UP)DN swp11 10G 1500 NotConfigured
DN swp12 10G 1500 NotConfigured
DN swp13 10G 1500 NotConfigured
DN swp14 10G 1500 NotConfigured
DN swp15 10G 1500 NotConfigured
DN swp16 10G 1500 NotConfigured
DN swp17 10G 1500 NotConfigured
DN swp18 10G 1500 NotConfigured
DN swp19 10G 1500 NotConfigured
DN swp20 10G 1500 NotConfigured
DN swp21 10G 1500 NotConfigured
DN swp22 10G 1500 NotConfigured
DN swp23 10G 1500 NotConfigured
DN swp24 10G 1500 NotConfigured
DN swp25 10G 1500 NotConfigured
DN swp26 10G 1500 NotConfigured
DN swp27 10G 1500 NotConfigured
DN swp28 10G 1500 NotConfigured
DN swp29 10G 1500 NotConfigured
DN swp30 10G 1500 NotConfigured
DN swp31 10G 1500 NotConfigured
DN swp32 10G 1500 NotConfigured
DN swp33 10G 1500 NotConfigured
DN swp34 10G1500 NotConfigured
DN swp35 10G 1500 NotConfigured
DN swp36 10G 1500 NotConfigured
DN swp37 10G 1500 NotConfigured
DN swp38 10G 1500 NotConfigured
DN swp39 10G 1500 NotConfigured
ADMDN swp40 N/A 1500 NotConfigured
DN swp41 10G 1500 NotConfigured
DN swp42 10G 1500 NotConfigured
DN swp43 10G 1500 NotConfigured
DN swp44 10G 1500 NotConfigured
DN swp45 10G 1500 NotConfigured
DN swp4610G 1500 NotConfigured
DN swp47 10G 1500 NotConfigured
DN swp48 10G 1500 NotConfigured
UP swp49 40G 1500 Interface/L3 sonic (fortyGigE1/1) IP: 10.1.0.2/24
DN swp50 40G 1500 Interface/L3 IP: 10.3.0.2/24
DN swp51 40G 1500 NotConfigured
DN swp52 40G 1500 NotConfigured
ADMDN swp53 N/A 1500 NotConfigured
DN swp54 40G 1500 NotConfigured
UP bridge N/A 1500 Bridge/L2
UP vlan10 N/A 1500NotConfigured
UP vni10010 N/A 1500 Trunk/L2 Master: bridge(UP)</content>
</example>
<command name="IMPORT">
<operation>net show interface all</operation>
<parser>
<section>
<regexp>@(?<state>\S+)\s+(?<object_id>\S+)\s+(?<speed>\S+)\s+(?<mtu>\S+)\s+(?<mode>\S+)@</regexp>
<xpath/>
</section>
<lines>
<ignore>
<regexp>@State@</regexp>
</ignore>
<ignore>
<regexp>@----@</regexp>
</ignore>
</lines>
</parser>
</command>
<command name="UPDATE">
<operation>{if $params.state=='ADMDN'}
net add interface {$params.object_id} link down
net commit
{/if}
{if $params.state=='DN'}
net del interface {$params.object_id} link down
net commit
{/if}
{if $params.state=='UP'}
net del interface {$params.object_id} link down
net commit
{/if}</operation>
</command>
<command name="CONSTRAINT"/>
<command name="CREATE"/>
<command name="DELETE"/>
<command name="READ"/>
<command name="LIST"/>
</ObjectDefinition>