Commande CISCO pour récupérer les adresses MAC

Bonjour,

Je voudrais utiliser la commande port-security de CISCO. Je voudrais d'abord récupérer les adresses IP et MAC de chaque équipement. Est-ce qu'il existe une commande pour ce faire Sinon, comment dois-je procéder ?

2 réponses

  1. Salut,
    sur un switch show mac-address-table (sh mac)
    sur un routeur:
    show ip arp
    exemples chez moi:
    cisco-ipv6#sh mac-address-table 
    Destination Address Address Type VLAN Destination Port
    ------------------- ------------ ---- --------------------
    001a.6cc1.1c92 Self 1 Vlan1
    0030.489a.63f2 Dynamic 1 FastEthernet8
    a063.91b9.2c0d Dynamic 1 FastEthernet8
    001a.6cc1.1c92 Self 2 Vlan2
    0030.489a.63f2 Dynamic 2 FastEthernet8
    0014.3819.bed1 Dynamic 3 FastEthernet8
    0016.3e70.1467 Dynamic 3 FastEthernet8
    001a.6cc1.1c92 Self 3 Vlan3
    0030.489a.63f2 Dynamic 3 FastEthernet8
    00e0.4c68.040b Dynamic 3 FastEthernet8
    0226.44ef.84a2 Dynamic 3 FastEthernet8
    2816.adf1.5022 Dynamic 3 FastEthernet8
    4c66.41fc.ad29 Dynamic 3 FastEthernet8
    5254.000c.af8e Dynamic 3 FastEthernet8
    5254.0077.212e Dynamic 3 FastEthernet8
    5254.00cd.ea33 Dynamic 3 FastEthernet8
    8425.dbc2.e451 Dynamic 3 FastEthernet8
    b827.ebde.7f52 Dynamic 3 FastEthernet8
    e0cb.4e49.11e3 Dynamic 3 FastEthernet8
    001a.6cc1.1c92 Self 4 Vlan4

    cisco-ipv6#sh ip arp
    Protocol Address Age (min) Hardware Addr Type Interface
    Internet 192.168.0.254 - 001a.6cc1.1c92 ARPA Vlan1
    Internet 192.168.1.1 - 001a.6cc1.1c92 ARPA FastEthernet0
    Internet 192.168.1.254 6 0876.ff9a.5817 ARPA FastEthernet0
    Internet 192.168.2.3 0 0030.489a.63f2 ARPA Vlan3
    Internet 192.168.2.11 6 5254.000c.af8e ARPA Vlan3
    Internet 192.168.2.12 0 5254.00cd.ea33 ARPA Vlan3
    Internet 192.168.2.28 21 0016.3e70.1467 ARPA Vlan3
    Internet 192.168.2.115 192 0226.44ef.84a2 ARPA Vlan3
    Internet 192.168.2.120 14 fcf8.ae5b.fcf7 ARPA Vlan3
    Internet 192.168.2.126 78 8425.dbc2.e451 ARPA Vlan3
    Internet 192.168.2.128 4 00e0.4c68.040b ARPA Vlan3
    Internet 192.168.2.140 1 0014.3819.bed1 ARPA Vlan3
    Internet 192.168.2.146 1 4c66.41fc.ad29 ARPA Vlan3
    Internet 192.168.2.147 142 54e1.ad16.1c55 ARPA Vlan3
    Internet 192.168.2.148 104 e490.7e9f.2451 ARPA Vlan3
    Internet 192.168.2.149 0 2816.adf1.5022 ARPA Vlan3
    Internet 192.168.2.240 0 b827.ebde.7f52 ARPA Vlan3
    Internet 192.168.2.250 4 e0cb.4e49.11e3 ARPA Vlan3
    Internet 192.168.2.254 - 001a.6cc1.1c92 ARPA Vlan3
    Internet 192.168.3.254 - 001a.6cc1.1c92 ARPA Vlan2
    cisco-ipv6#


    1. Bonjour,
      Merci de ta réponse. Je suis un peu perdu en voyant ce résultat :
      Est-ce a dire que toutes ces machine de differentes adresses IP sont dns le vlan3 ?
      Analysons un peu mon résultat :

      Protocol Address Age (min) Hardware Addr Type Interface
      Internet 10.10.30.247 97 0000.0c07.ac00 ARPA GigabitEthernet0/0
      Internet 10.10.30.248 139 0000.0c07.ac00 ARPA GigabitEthernet0/0
      Internet 10.10.30.250 131 0000.0c07.ac00 ARPA GigabitEthernet0/0

      Est-ce que toutes ces machines sont connectées à l'interface G0/0 ? et ces adresses MAC me paraissent bizarres. Elles sont réelles ? (de passage "Age" désigne quoi).
    2. Contributeur
      La commande " arp -a " te donne toutes tes adresses de ton réseau.. en écran DOS

      Interface : 192.168.1.10 --- 0xa
      Adresse Internet Adresse physique Type
      192.168.1.12 b8-74-24-03-04-2d dynamique
      192.168.1.13 22-e9-38-d6-97-79 dynamique
      192.168.1.14 50-cc-f8-f3-7f-23 dynamique
      192.168.1.15 d0-76-58-07-11-a2 dynamique

      Voici un exemple.

      ARPA est un type d'encapsulation à 16 bits
    3. Slt,
      Ici j ai une toute petite liste alors que j ai beaucoup plus de machine. Je demande la commande sir Cisco
    4. @fasodenâge,
      c'est depuis combien de temps la machine répond à ARP
      ça ne veut pas dire pour ça qu'elle n'était pas connectée, juste qu'on n'a pas fait d'arp dessus avant.
      Tes adresses mac sont réelles oui, juste que cisco les affiche différemment de windows, là elles ont les mêmes pour les 3 adresses ip, ça correspond à une machine cisco, elle a plusieurs adresses IP sur la même interface ou du proxy arp ?
      ARPA désigne le protocole ipV4
    5. Merci