Hello, Finally, I use your solution. I build a table of IP/MH with show devices and show attributes. Then I query this table by IP. The first run is a little slow (15s) but after, there is no penalty.
I wonder how Spectrum is doing the search. It is rather fast. (Except for a search on 127.0.0.1 witch give a lot of answers). By the way, I use Tcl as a scripting language. I hope I'm not the only one ... Brgds, Stéphane. -----Message d'origine----- De : Naiman, Eugen [mailto:[email protected]] Envoyé : mercredi 24 février 2010 23:16 À : spectrum Objet : RE: [spectrum] CLI equivalent of Devices By IP Address Sorry, my bad - I had no idea what you meant by "Devices By IP Address". Indeed, you can't use "seek" to do what you want and there is no simple command to do that. You will need to build a script to do the following: - find a way to get model handles for devices you want to search (usually "seek" for a certain attributes - for every device run "show attributes attr=0x12a53, mh=your.model.handle" - the result will be the list with all IP addresses - search in the list for desired IP - go to next model handle You can see that it is not a simple way to do this. Depending of how many devices you want to search, the process may prove to be kinda slow. I have just noticed that 0x12a53 is not an external attribute so the script could be quite fast - anyway, you will have to try it so you'll have an idea. Someone else might find a better way to do it (this is only what I could think of) - so, just wait for other answers. Unfortunately I am not a perl guru so I can't build a perl script for you; if you can then you're in luck. The scripting language I'm using is AutoIt. Not many people in our Spectrum list use it (maybe I'm the only one) - but if anyone else is interested I might put a library of functions together to allow CLI commands manipulations (something like SpecTools). Anyway - good luck with your script. If you need any help, you're welcome to ask. Regards, Eugen NAIMAN -----Original Message----- From: JEANJEAN, Stéphane [mailto:[email protected]] Sent: Wednesday, 24 February 2010 7:56 PM To: Naiman, Eugen; spectrum Subject: RE: [spectrum] CLI equivalent of Devices By IP Address Hello, 0x12d7f is the Network_Address (0x1027f before 9.0) This command finds only the devices where the Network_Address is the searched address. Devices By IP Address works on all the addresses of the devices. I tried to search by the deviceIPAddressList (0x12a53) but this is not supported by the seek command: seek attr=0x12a53,val=10.10.10.11 seek: Attribute 0x12a53 is a list attribute and list attribute seeking is not supported. Regards, Stéphane. -----Message d'origine----- De : Naiman, Eugen [mailto:[email protected]] Envoyé : mardi 23 février 2010 23:02 À : spectrum Objet : RE: [spectrum] CLI equivalent of Devices By IP Address Try seek attr=0x12d7f,val=my.ip.here 0664.pdf is the manual detailing all CLI commands. Example from this manual: seek attr=0x12d7f,val=192.168.93.* Regards, Eugen NAIMAN -----Original Message----- From: JEANJEAN, Stéphane [mailto:[email protected]] Sent: Wednesday, 24 February 2010 2:53 AM To: spectrum Subject: [spectrum] CLI equivalent of Devices By IP Address Hi list, I seek the equivalent with the CLI of the search of devices by ip address. Best regards, Stéphane. -- Les donnees et renseignements contenus dans ce message sont personnels, confidentiels et secrets. Toute publication, utilisation ou diffusion, meme partielle, doit etre autorisee. Si vous n'etes pas le bon destinataire, nous vous demandons de ne pas lire, copier, utiliser ou divulguer cette communication. Nous vous prions de notifier cette erreur a l'expediteur et d'effacer immediatement cette communication de votre systeme. Any data and information contained in this electronic mail is personal, confidential and secret. Any total or partial publication, use or distribution must be authorized. If you are not the right addressee, we ask you not to read, copy, use or disclose this communication. Please notify this error to the sender and erase at once this communication from your system. --- To unsubscribe from spectrum, send email to [email protected] with the body: unsubscribe spectrum [email protected] CONFIDENTIALITY NOTICE AND DISCLAIMER The information in this transmission may be confidential and/or protected by legal professional privilege, and is intended only for the person or persons to whom it is addressed. If you are not such a person, you are warned that any disclosure, copying or dissemination of the information is unauthorised. If you have received the transmission in error, please immediately contact this office by telephone, fax or email, to inform us of the error and to enable arrangements to be made for the destruction of the transmission, or its return at our cost. No liability is accepted for any unauthorised use of the information contained in this transmission. If the transmission contains advice, the advice is based on instructions in relation to, and is provided to the addressee in connection with, the matter mentioned above. Responsibility is not accepted for reliance upon it by any other person or for any other purpose. --- To unsubscribe from spectrum, send email to [email protected] with the body: unsubscribe spectrum [email protected] -- Les donnees et renseignements contenus dans ce message sont personnels, confidentiels et secrets. Toute publication, utilisation ou diffusion, meme partielle, doit etre autorisee. Si vous n'etes pas le bon destinataire, nous vous demandons de ne pas lire, copier, utiliser ou divulguer cette communication. Nous vous prions de notifier cette erreur a l'expediteur et d'effacer immediatement cette communication de votre systeme. Any data and information contained in this electronic mail is personal, confidential and secret. Any total or partial publication, use or distribution must be authorized. If you are not the right addressee, we ask you not to read, copy, use or disclose this communication. Please notify this error to the sender and erase at once this communication from your system. CONFIDENTIALITY NOTICE AND DISCLAIMER The information in this transmission may be confidential and/or protected by legal professional privilege, and is intended only for the person or persons to whom it is addressed. If you are not such a person, you are warned that any disclosure, copying or dissemination of the information is unauthorised. If you have received the transmission in error, please immediately contact this office by telephone, fax or email, to inform us of the error and to enable arrangements to be made for the destruction of the transmission, or its return at our cost. No liability is accepted for any unauthorised use of the information contained in this transmission. If the transmission contains advice, the advice is based on instructions in relation to, and is provided to the addressee in connection with, the matter mentioned above. Responsibility is not accepted for reliance upon it by any other person or for any other purpose. --- To unsubscribe from spectrum, send email to [email protected] with the body: unsubscribe spectrum [email protected] -- Les donnees et renseignements contenus dans ce message sont personnels, confidentiels et secrets. Toute publication, utilisation ou diffusion, meme partielle, doit etre autorisee. Si vous n'etes pas le bon destinataire, nous vous demandons de ne pas lire, copier, utiliser ou divulguer cette communication. Nous vous prions de notifier cette erreur a l'expediteur et d'effacer immediatement cette communication de votre systeme. Any data and information contained in this electronic mail is personal, confidential and secret. Any total or partial publication, use or distribution must be authorized. If you are not the right addressee, we ask you not to read, copy, use or disclose this communication. Please notify this error to the sender and erase at once this communication from your system. --- To unsubscribe from spectrum, send email to [email protected] with the body: unsubscribe spectrum [email protected]
