Awesome program! Thanks alot for the time put into it. I finally got it working and love it. I have a question in regards to the MACs that are created. Is there a way to preserve the '.' in each MAC or the '-'? For example, when i do a 'sh ip arp' on my switch:
7613A-Plano-ODNET#sh ip arp
Protocol Address Age (min) Hardware Addr Type Interface
Internet 192.168.11.99 6 0012.3f7b.0e54 ARPA GigabitEthernet1/27
Internet 192.168.11.98 3 0014.22f8.24e7 ARPA GigabitEthernet1/27
Internet 10.224.28.254 - 0000.0c07.ac48 ARPA Vlan702
Internet 10.224.29.254 61 0000.0c07.ac48 ARPA Vlan704
It would be great to keep the decimals.
Also, when i run FindOffice.pl, can I have it return longer Port Label info? Some of my descriptions are truncated and I would like it to be longer as the DNS Name is not used in or instance.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
The HTML files that were created in my instance (on IOS switches) have the description of greater than 20 characters. I was wondering if that feature could be implemented in the search function. For example, on one of the HTML files created , the Port Label Reads 'Future RCATS device RCATS-Anaheim', which is greater than 20 characters. It would cool to have the search feature find on "RCATS-Anaheim" which is like 22 character into the label.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I think the "right" solution to this problem is to allow longer than 20 character Port Labels in the HTML, and then change the way FindOffice.pl works. Today, FindOffice.pl parses the .map files, which are simple text versions of the web pages. That was the quick-and-easy way to implement a search function. A better approach would be to make FindOffice.pl parse the HTML files. The parsing would be a bit more complex, and I'd have to create a scheme to make the resulting web pages useful, but it could be done. Once it's done, I could relax the 20-character limit on the Port Label field and everything would work.
I'll add this to the TO-DO list. It sounds like fun, so I might even get to it fairly soon :-)
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Network equipment displays MAC addresses in several different formats. A comment in FindOffice.pl
describes some of them:
CATOS "show cam" => 00-0d-60-9c-b1-ba
IOS "show ip arp" => 000d.609c.b1ba
Linux "arp -a" & "ifconfig -a" => 00:0d:60:9c:b1:ba
Windows "arp -a" & "ipconfig -a" => 00-0d-60-9c-b1-ba
I use the format that switches return when queried with SNMP - no dots, dashes or colons. This helps keep line lengths short, so it seemed like a good "standard".
You can supply any of these formats to FindOffice.pl's search window. FindOffice.pl strips out the extra characters before searching. So you can cut-and-paste a MAC address into the FindOffice search window without problems.
I think it's best to leave it as is rather than use ane ofthe other formats.
The Port Label field is 20 characters wide because that was the limit in the switches that I had when I wrote the code. Do you have switches that will store more than 20 characters in the "name" field?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Well, I see in the HTML files that the Port Labels are longer. Also, if you issue 'sh int desc', you can receive full interface desc:
7613A-Anaheim-ODNET#sh int desc
Gi1/6 up up CALEA CCDU
Gi1/7 up up MSC1-AMA-Proxy-Port1
Gi1/8 up up MSC2-AMA-Proxy-Port1
Gi1/9 up up Anypath Front End Port 1
Gi1/10 up up Anypath Back End Port 1
Gi1/11 up up Tellabs 5500 DACS Ethernet port 1
Gi1/12 up up Future RCATS device RCATS-Anaheim 10.222.14.65
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
When I wrote SwitchMap, I wrote it to support CATOS switches. I logged into a 6509 running CATOS 8.4(5) just now, and did
ml-16c-c1-gs> (enable) set port name 2/2 test567890123456789012345
Name string must be less than 21 characters.
ml-16c-c1-gs>
So I made the field 20 characters long in SwitchMap.
Later, I added support for IOS switches, which allow a longer "description" field, but I save the description in the same variable in SwitchMap, so it gets truncated to 20 characters or less.
The .map files that SwitchMap writes to the "text" subdirectory are fixed-width, with "Port Label" columns that are 20 characters wide. The FindOffice.pl script relies on this. I could change SwitchMap so that the fields can be longer than 20 characters in the HTML files, yet are truncated to 20 characters as I write the .map files. It might cause odd problems for people who use FindOffice.pl to search for Port Label strings, as only the first 20 characters will be searchable.
What do you think?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Awesome program! Thanks alot for the time put into it. I finally got it working and love it. I have a question in regards to the MACs that are created. Is there a way to preserve the '.' in each MAC or the '-'? For example, when i do a 'sh ip arp' on my switch:
7613A-Plano-ODNET#sh ip arp
Protocol Address Age (min) Hardware Addr Type Interface
Internet 192.168.11.99 6 0012.3f7b.0e54 ARPA GigabitEthernet1/27
Internet 192.168.11.98 3 0014.22f8.24e7 ARPA GigabitEthernet1/27
Internet 10.224.28.254 - 0000.0c07.ac48 ARPA Vlan702
Internet 10.224.29.254 61 0000.0c07.ac48 ARPA Vlan704
It would be great to keep the decimals.
Also, when i run FindOffice.pl, can I have it return longer Port Label info? Some of my descriptions are truncated and I would like it to be longer as the DNS Name is not used in or instance.
The HTML files that were created in my instance (on IOS switches) have the description of greater than 20 characters. I was wondering if that feature could be implemented in the search function. For example, on one of the HTML files created , the Port Label Reads 'Future RCATS device RCATS-Anaheim', which is greater than 20 characters. It would cool to have the search feature find on "RCATS-Anaheim" which is like 22 character into the label.
I think the "right" solution to this problem is to allow longer than 20 character Port Labels in the HTML, and then change the way FindOffice.pl works. Today, FindOffice.pl parses the .map files, which are simple text versions of the web pages. That was the quick-and-easy way to implement a search function. A better approach would be to make FindOffice.pl parse the HTML files. The parsing would be a bit more complex, and I'd have to create a scheme to make the resulting web pages useful, but it could be done. Once it's done, I could relax the 20-character limit on the Port Label field and everything would work.
I'll add this to the TO-DO list. It sounds like fun, so I might even get to it fairly soon :-)
Network equipment displays MAC addresses in several different formats. A comment in FindOffice.pl
describes some of them:
CATOS "show cam" => 00-0d-60-9c-b1-ba
IOS "show ip arp" => 000d.609c.b1ba
Linux "arp -a" & "ifconfig -a" => 00:0d:60:9c:b1:ba
Windows "arp -a" & "ipconfig -a" => 00-0d-60-9c-b1-ba
I use the format that switches return when queried with SNMP - no dots, dashes or colons. This helps keep line lengths short, so it seemed like a good "standard".
You can supply any of these formats to FindOffice.pl's search window. FindOffice.pl strips out the extra characters before searching. So you can cut-and-paste a MAC address into the FindOffice search window without problems.
I think it's best to leave it as is rather than use ane ofthe other formats.
The Port Label field is 20 characters wide because that was the limit in the switches that I had when I wrote the code. Do you have switches that will store more than 20 characters in the "name" field?
Well, I see in the HTML files that the Port Labels are longer. Also, if you issue 'sh int desc', you can receive full interface desc:
7613A-Anaheim-ODNET#sh int desc
Gi1/6 up up CALEA CCDU
Gi1/7 up up MSC1-AMA-Proxy-Port1
Gi1/8 up up MSC2-AMA-Proxy-Port1
Gi1/9 up up Anypath Front End Port 1
Gi1/10 up up Anypath Back End Port 1
Gi1/11 up up Tellabs 5500 DACS Ethernet port 1
Gi1/12 up up Future RCATS device RCATS-Anaheim 10.222.14.65
When I wrote SwitchMap, I wrote it to support CATOS switches. I logged into a 6509 running CATOS 8.4(5) just now, and did
ml-16c-c1-gs> (enable) set port name 2/2 test567890123456789012345
Name string must be less than 21 characters.
ml-16c-c1-gs>
So I made the field 20 characters long in SwitchMap.
Later, I added support for IOS switches, which allow a longer "description" field, but I save the description in the same variable in SwitchMap, so it gets truncated to 20 characters or less.
The .map files that SwitchMap writes to the "text" subdirectory are fixed-width, with "Port Label" columns that are 20 characters wide. The FindOffice.pl script relies on this. I could change SwitchMap so that the fields can be longer than 20 characters in the HTML files, yet are truncated to 20 characters as I write the .map files. It might cause odd problems for people who use FindOffice.pl to search for Port Label strings, as only the first 20 characters will be searchable.
What do you think?