User Tools

Site Tools


doc:appunti:hardware:cisco_router

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
doc:appunti:hardware:cisco_router [2012/08/03 18:24] – [Configurazione server DHCP] niccolodoc:appunti:hardware:cisco_router [2019/02/02 14:20] (current) – [SNMP] niccolo
Line 121: Line 121:
 Vedere **[[http://www.cisco.com/en/US/products/sw/iosswrel/ps1835/products_configuration_guide_chapter09186a00800ca75c.html|Configuring DHCP]]**. Vedere **[[http://www.cisco.com/en/US/products/sw/iosswrel/ps1835/products_configuration_guide_chapter09186a00800ca75c.html|Configuring DHCP]]**.
  
-In questo esempio si configura un pool pari a tutta la ntework **192.168.2.0/24** ad eccezione del router stesso (che funziona da server DHCP e gateway) che ha indirizzo **192.168.2.1**:+In questo esempio si configura un pool pari a tutta la ntework **192.168.2.0/24** ad eccezione dei primi 10 indirizzi. Il router (che funziona da server DHCP e gateway) ha indirizzo **192.168.2.1**:
  
 <code> <code>
 #configure terminal #configure terminal
-(config)#ip dhcp excluded-address 192.168.2.1 +(config)#ip dhcp excluded-address 192.168.2.1 192.168.2.10 
-(config)#ip dhcp pool CLIENT+(config)#ip dhcp pool DHCP-POOL
 (dhcp-config)#network 192.168.2.0 255.255.255.0 (dhcp-config)#network 192.168.2.0 255.255.255.0
 (dhcp-config)#default-router 192.168.2.1 (dhcp-config)#default-router 192.168.2.1
-(dhcp-config)#dns-server 151.99.125.3+(dhcp-config)#dns-server 151.99.125.3 8.8.8.8
 (dhcp-config)#lease 0 2 (dhcp-config)#lease 0 2
 (dhcp-config)#exit (dhcp-config)#exit
Line 154: Line 154:
  
 Notare che nell'access list la netmask va scritta negata (operazione NOT). Notare che nell'access list la netmask va scritta negata (operazione NOT).
 +
 +
 +====== Qualità connessione DSL ======
 +
 +Come valutare la qualità del segnale ADSL su un Cisco 877:
 +
 +<code>
 +Router#show dsl interface ATM 0
 +ATM0
 +Alcatel 20190 chipset information
 +                ATU-R (DS)                      ATU-C (US)
 +Modem Status:    Showtime (DMTDSL_SHOWTIME)
 +DSL Mode:        ITU G.992.1 (G.DMT) Annex A
 +ITU STD NUM:     0x01                            0x1 
 +Vendor ID:       'STMI'                          'TSTC'
 +Vendor Specific: 0x0000                          0x0000
 +Vendor Country:  0x0F                            0xB5
 +Chip ID:         C196 (0)
 +DFE BOM:         DFE3.0 Annex A (1)
 +Capacity Used:   100%                            100%
 +Noise Margin:    11.5 dB                         13.0 dB
 +Output Power:    20.0 dBm                        12.5 dBm
 +Attenuation:     41.0 dB                         23.5 dB
 +Defect Status:   None                            None                        
 +Last Fail Code:  None
 +Watchdog Counter: 0xE0
 +Watchdog Resets: 0
 +Selftest Result: 0x00
 +Subfunction:     0x00 
 +Interrupts:      8254 (0 spurious)
 +PHY Access Err:  0
 +Activations:     1
 +LED Status:      ON
 +LED On Time:     100
 +LED Off Time:    100
 +Init FW:         init_AMR-3.0.014_no_bist.bin
 +Operation FW:    AMR-3.0.014.bin
 +FW Source:       embedded
 +FW Version:      3.0.14
 +
 +                 Interleave             Fast    Interleave              Fast
 +Speed (kbps):          5888                0           736                 0
 +Cells:               383635                0         23443                 0
 +Reed-Solomon EC:          8                0                             0
 +CRC Errors:                              0                             0
 +Header Errors:            0                0                             0
 +Total BER:                0E-0           0E-0
 +Leakage Average BER:      0E-0           0E-0
 +                        ATU-R (DS)      ATU-C (US)
 +Bitswap:               enabled            enabled
 +Bitswap success:          0                   0
 +Bitswap failure:          0                   0
 +
 +LOM Monitoring : Disabled
 +</code>
 +
 +Si vedono i parametri **downstream** (download) e **upstram** (upload), il valore di **Noise Margin** (detto anche rapporto segnale/rumore) è il fattore più importante.
 +
 +Questa una tabella esplicativa del **rapporto segnale/rumore (SNR)**, dove un numero **maggiore è meglio**:
 +
 +^ SNR Signal/Noise Ratio (Noise Margin)  ^^
 +^ 6dB or below   | Noise margin is bad, it will experience no synch or intermittent synch problems  |
 +^ 7dB-10dB       | Fair but does not leave much room for variances in conditions  |
 +^ 11dB-20dB      | Good with little or no synch problems (if no large variation)  |
 +^ 20dB-28dB      | Excellent  |
 +^ 29dB or above  | Outstanding  |
 +
 +L'attenuazione aumenta di solito con la distanza percorsa dal segnale, un valore **minore è meglio**:
 +
 +^ Attenuation  ^^
 +^ 20-30  | Excellent  |
 +^ 30-40  | Very Good  |
 +^ 40-60  | Average  |
 +
 +La **velocità di allineamento** della portante è indicata da **Speed (kbps)** **Interleave**, nell'esempio sopra abbiamo 5888 kbit in download e 736 kbit in upload.
 +
 +Altro comando per verificare la velocità di allineamento in download:
 +
 +<code>
 +Router#show interfaces ATM 0
 +ATM0 is up, line protocol is up 
 +  Hardware is MPC ATMSAR (with Alcatel ADSL Module)
 +  MTU 4470 bytes, sub MTU 4470, BW 736 Kbit, DLY 500 usec, 
 +     reliability 255/255, txload 1/255, rxload 8/255
 +  Encapsulation ATM, loopback not set
 +  Encapsulation(s): AAL5  AAL2, PVC mode
 +  10 maximum active VCs, 1024 VCs per VP, 2 current VCCs
 +  VC Auto Creation Disabled.
 +  VC idle disconnect time: 300 seconds
 +  Last input never, output 00:00:01, output hang never
 +  Last clearing of "show interface" counters never
 +  Input queue: 0/224/0/0 (size/max/drops/flushes); Total output drops: 0
 +  Queueing strategy: Per VC Queueing
 +  5 minute input rate 24000 bits/sec, 0 packets/sec
 +  5 minute output rate 0 bits/sec, 0 packets/sec
 +     43749 packets input, 41209447 bytes, 0 no buffer
 +     Received 0 broadcasts, 0 runts, 0 giants, 0 throttles
 +     0 input errors, 0 CRC, 0 frame, 0 overrun, 0 ignored, 0 abort
 +     28917 packets output, 2283137 bytes, 0 underruns
 +     0 output errors, 0 collisions, 0 interface resets
 +     0 output buffer failures, 0 output buffers swapped out
 +</code>
 +
 +Il valore **BW 736 Kbit** indica che la portante si è allineata a 736 kbit (upload).
 +
 +====== VLAN ======
 +
 +Il router Cisco 877 ha 4 porte Ethernet che possono essere configurate in VLAN. L'impostazione predefinita è che **tutte le porte sono untagged su Vlan1** (''switchport access vlan 1''), cioè si configura l'interfaccia Vlan1 e tutte le porte sono collegate (in bridge) con tale interfaccia.
 +
 +In questo esempio si configura la quarta porta **FastEthernet3** su una VLAN separata, con un diverso indirizzo IP, ecc.
 +
 +Anzitutto si definisce la Vlan2:
 +
 +<code>
 +Router#vlan database
 +Router(vlan)#vlan 2
 +Router(vlan)#show 
 +  VLAN ISL Id: 1
 +    Name: default
 +    Media Type: Ethernet
 +    VLAN 802.10 Id: 100001
 +    State: Operational
 +    MTU: 1500
 +    Translational Bridged VLAN: 1002
 +    Translational Bridged VLAN: 1003
 +
 +  VLAN ISL Id: 2
 +    Name: VLAN0002
 +    Media Type: Ethernet
 +    VLAN 802.10 Id: 100002
 +    State: Operational
 +    MTU: 1500
 +  ...
 +</code>
 +
 +Quindi si configura la porta Ethernet e l'interfaccia virtuale:
 +
 +<code>
 +interface FastEthernet3
 + switchport access vlan 2
 +...
 +interface Vlan2
 + ip address 172.16.1.1 255.255.255.0
 +...
 +</code>
 +
 +**ATTENZIONE**: configurare **prima** il database delle VLAN e **dopo** assegnare la porta alla VLAN con il comando ''switchport'', altrimenti l'interfaccia non funziona (manca la rotta per la rete locale direttamente connessa, verificare con il comando **''show ip route''**).
 +
 +====== SNMP ======
 +
 +Esempio per abilitare il monitoraggio via SNMP, community **public** in sola lettura, filtrato con una access list:
 +
 +<code>
 +Router#configure terminal 
 +Router(config)#snmp-server community public ro 60
 +Router(config)#access-list 60 permit 10.2.0.1
 +</code>
 +
 +====== CISCO 800 - SNMP OIDs for ADSL Line ======
 +
 +^ Data                    ^ Example  ^ SNMP data                                             ^
 +^ Noise Margin Downstrem    |    11.5 dB | iso.3.6.1.2.1.10.94.1.1.3.1.4.11 = Gauge32: 115     |
 +^ Noise Margin Upstream        12.0 dB | iso.3.6.1.2.1.10.94.1.1.2.1.4.11 = Gauge32: 120     |
 +^ Attenuation Downstrem        17.0 dB | iso.3.6.1.2.1.10.94.1.1.3.1.5.11 = Gauge32: 170     |
 +^ Attenuation Upstream      |    17.0 dB | iso.3.6.1.2.1.10.94.1.1.2.1.5.11 = Gauge32: 170     |
 +^ Speed US Channel0           532 kbps | iso.3.6.1.2.1.10.94.1.1.3.1.8.11 = Gauge32: 532000  |
 +^ Speed DS Channel0          3898 kbps | iso.3.6.1.2.1.10.94.1.1.2.1.8.11 = Gauge32: 3898000  |
 +^ Interface Dialer 1 input  |      bytes | iso.3.6.1.2.1.2.2.1.10.15 = Counter32: 232357736  |
 +^ Interface Dialer 1 output |      bytes | iso.3.6.1.2.1.2.2.1.16.15 = Counter32: 11197059  |
 +
 +====== Backup/restore configurazione via TFTP ======
 +
 +Predisporre una connessione LAN tra il router ed un host con un server TFTP (es. **tftpd-hpa** in Debian). Viene chiesto l'indirizzo IP del server e il nome da dare al file:
 +
 +<code>
 +copy run tftp
 +</code>
 +
 +La procedura inversa:
 +
 +<code>
 +copy tftp run
 +copy run start
 +</code>
doc/appunti/hardware/cisco_router.1344011079.txt.gz · Last modified: 2012/08/03 18:24 by niccolo