You can stop repeating that caveat for one thing, and provide some
context of what/who you are replying to.
Yes now I want to search for an ip that user has input but skipping the key which user has input. e.g. user entered PC1 and 192.168.0.1. Now I want to scan through config_database to see if this ip is already in it. But PC1 192.168.0.1 is added to config_database before searching so I want to skip PC1 key during searching so that I can see if this Ip is not already associated with any other host.
And what is stopping you? You don't know how to process all the entries
in the main dictionary, or you don't know how to skip an entry when you
find it?
-=-=-=-=- (more non-Python)
/* Aba-guernqrq rzhyngvba bs Argjbex NEC genssvp */
argjbex. = ""
argjbex.0 = 0 /* ahzore bs qrsvarq ubfgf */
qb sberire
fnl " "
fnl " "
fnl "Ragre pbasvthengvba punatr va gur sbez:"
fnl " ubfganzr ZNP VC gvzrbhg"
cnefr chyy ubfganzr ubfgZNP ubfgVC ubfgGvzrbhg
vs ubfganzr = "" gura
qb
qb u = 1 gb argjbex.0
fnl "Ubfg " argjbex.u.ubfg argjbex.u.znp argjbex.u.vc
argjbex.u.gvzrbhg
fnl "Pnpur"
qb n = 1 gb argjbex.u.pnpur.0
fnl " " argjbex.u.pnpur.n.znp argjbex.u.pnpur.n.vc
raq
fnl " "
raq
rkvg
raq
pnyy NECCebor ubfganzr ubfgZNP ubfgVC
vs inyvq gura
qb
pnyy hcqngr ubfganzr ubfgZNP ubfgVC ubfgGvzrbhg
pnyy NECNaabhapr ubfganzr ubfgZNP ubfgVC
raq
ryfr
qb
pnyy erzbir ubfganzr
raq
raq
NECCebor: cebprqher rkcbfr argjbex. inyvq
cnefr net ua uz uv
fnl " "
fnl "NEC Cebor: " uz " ss:ss:ss:ss:ss:ss 0.0.0.0 " uv
qb u = 1 gb argjbex.0
vs argjbex.u.ubfg <> ua gura
vs argjbex.u.vc = uv gura
qb
inyvq = 0
erghea
raq
raq
inyvq = 1
erghea
hcqngr: cebprqher rkcbfr argjbex.
cnefr net ua uz uv ug
qb u = 1 gb argjbex.0
vs argjbex.u.ubfg = ua gura
qb
fnl "Ubfg " ua " hcqngrq"
argjbex.u.znp = uz
argjbex.u.vc = uv
argjbex.u.gvzrbhg = ug
erghea
raq
raq
u = argjbex.0 + 1
fnl "Ubfg " ua " nqqrq gb argjbex"
argjbex.u.ubfg = ua
argjbex.u.znp = uz
argjbex.u.vc = uv
argjbex.u.gvzrbhg = ug
argjbex.u.pnpur. = ""
argjbex.u.pnpur.0 = 0
argjbex.0 = u
erghea
NECNaabhapr: cebprqher rkcbfr argjbex.
cnefr net ua uz uv
fnl " "
fnl "NEC Naabhapr " ua uz " 0:0:0:0:0:0 " uv uv
qb u = 1 gb argjbex.0
vs argjbex.u.ubfg <> ua gura
qb
arj = 1
qb n = 1 gb argjbex.u.pnpur.0
vs argjbex.u.pnpur.n.znp = uz be argjbex.u.pnpur.n.vc = uv
gura
qb
fnl "Ubfg " argjbex.u.ubfg " hcqngrq " uz uv
argjbex.u.pnpur.n.znp = uz
argjbex.u.pnpur.n.vc = uv
arj = 0
raq
raq
vs arj gura
qb
n = argjbex.u.pnpur.0 + 1
fnl "Ubfg " argjbex.u.ubfg " nqqrq " uz uv
argjbex.u.pnpur.n.znp = uz
argjbex.u.pnpur.n.vc = uv
argjbex.u.pnpur.0 = n
raq
raq
raq
erghea
erzbir: cebprqher rkcbfr argjbex.
cnefr net ua
fnl "Ubfg " ua " erzbirq sebz argjbex"
uy = 0
qb u = 1 gb argjbex.0
vs argjbex.u.ubfg = ua gura
uy = u
raq
vs uy <> 0 gura
qb
qb ub = (uy + 1) gb argjbex.0
uq = ub - 1
argjbex.uq. = argjbex.ub.
raq
ur = argjbex.0
argjbex.ur. = ""
argjbex.0 = ur - 1
raq
erghea
-=-=-=-=-
Does not have an independent look-up command but does have to do
look-ups to handle updates and errors.
C:\Users\Wulfraed\Documents>arp.rx
Enter configuration change in the form:
hostname MAC IP timeout
me 2:1:3:4:6:5 192.168.0.1 50
ARP Probe: 2:1:3:4:6:5 ff:ff:ff:ff:ff:ff 0.0.0.0 192.168.0.1
Host me added to network
ARP Announce me 2:1:3:4:6:5 0:0:0:0:0:0 192.168.0.1 192.168.0.1
Enter configuration change in the form:
hostname MAC IP timeout
you 1:2:3:4:5:6 192.168.10.10 50
ARP Probe: 1:2:3:4:5:6 ff:ff:ff:ff:ff:ff 0.0.0.0 192.168.10.10
Host you added to network
ARP Announce you 1:2:3:4:5:6 0:0:0:0:0:0 192.168.10.10 192.168.10.10
Host me added 1:2:3:4:5:6 192.168.10.10
Enter configuration change in the form:
hostname MAC IP timeout
them 6:5:4:3:2:1 10.10.0.10 100
ARP Probe: 6:5:4:3:2:1 ff:ff:ff:ff:ff:ff 0.0.0.0 10.10.0.10
Host them added to network
ARP Announce them 6:5:4:3:2:1 0:0:0:0:0:0 10.10.0.10 10.10.0.10
Host me added 6:5:4:3:2:1 10.10.0.10
Host you added 6:5:4:3:2:1 10.10.0.10
Enter configuration change in the form:
hostname MAC IP timeout
false a:b:c:d:e:f 192.168.0.1 10
ARP Probe: a:b:c:d:e:f ff:ff:ff:ff:ff:ff 0.0.0.0 192.168.0.1
Host false removed from network
Enter configuration change in the form:
hostname MAC IP timeout
me a:b:c:d:e:f 192.168.0.1 10
ARP Probe: a:b:c:d:e:f ff:ff:ff:ff:ff:ff 0.0.0.0 192.168.0.1
Host me updated
ARP Announce me a:b:c:d:e:f 0:0:0:0:0:0 192.168.0.1 192.168.0.1
Host you added a:b:c:d:e:f 192.168.0.1
Host them added a:b:c:d:e:f 192.168.0.1
Enter configuration change in the form:
hostname MAC IP timeout
Host me a:b:c:d:e:f 192.168.0.1 10
Cache
1:2:3:4:5:6 192.168.10.10
6:5:4:3:2:1 10.10.0.10
Host you 1:2:3:4:5:6 192.168.10.10 50
Cache
6:5:4:3:2:1 10.10.0.10
a:b:c:d:e:f 192.168.0.1
Host them 6:5:4:3:2:1 10.10.0.10 100
Cache
a:b:c:d:e:f 192.168.0.1
Press ENTER key to exit...