ܼ

CetnOS7ˤlldpdѤˡ

x86ؤƳ

ŪIntelƥĶؤƳ

Ķ

  • ǥȥӥ塼
    # cat /etc/redhat-release 
    CentOS Linux release 7.3.1611 (Core) 
  • Kernel
    # cat /proc/version 
    Linux version 3.10.0-514.16.1.el7.x86_64 (builder@kbuilder.dev.centos.org) (gcc version 4.8.5 20150623 (Red Hat 4.8.5-11) (GCC) ) #1 SMP Wed Apr 12 15:04:24 UTC 2017
  • CPU
    # cat /proc/cpuinfo
    processor       : 0
    vendor_id       : GenuineIntel
    cpu family      : 6
    model           : 60
    model name      : Intel(R) Xeon(R) CPU E3-1240 v3 @ 3.40GHz
    stepping        : 3
    microcode       : 0x20
    cpu MHz         : 3400.000
    cache size      : 8192 KB
    physical id     : 0
    siblings        : 8
    core id         : 0
    cpu cores       : 4
    apicid          : 0
    initial apicid  : 0
    fpu             : yes
    fpu_exception   : yes
    cpuid level     : 13
    wp              : yes
    flags           : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx pdpe1gb rdtscp lm constant_tsc arch_perfmon pebs bts rep_good nopl xtopology nonstop_tsc aperfmperf eagerfpu pni pclmulqdq dtes64 monitor ds_cpl vmx smx est tm2 ssse3 fma cx16 xtpr pdcm pcid sse4_1 sse4_2 x2apic movbe popcnt tsc_deadline_timer aes xsave avx f16c rdrand lahf_lm abm ida arat epb pln pts dtherm tpr_shadow vnmi flexpriority ept vpid fsgsbase tsc_adjust bmi1 avx2 smep bmi2 erms invpcid xsaveopt
    bogomips        : 6784.76
    clflush size    : 64
    cache_alignment : 64
    address sizes   : 39 bits physical, 48 bits virtual
    power management:
    ʲά

Ƴ

󥹥ȡ

CentOSΥݥȥꥤ󥹥ȡԤ

  • ѥåƳ
    # yum install lldpad
  • ӥμưưꤹ
    # systemctl enable lldpad 
  • ӥư
    # systemctl start lldpad 
  • ư
    # systemctl status lldpad 
     lldpad.service - Link Layer Discovery Protocol Agent Daemon.
      Loaded: loaded (/usr/lib/systemd/system/lldpad.service; enabled; vendor preset: disabled)
      Active: active (running) since Mon 2017-05-08 00:06:48 JST; 5min ago
    Main PID: 16454 (lldpad)
      CGroup: /system.slice/lldpad.service
              16454 /usr/sbin/lldpad -t
    
    May 08 00:06:48 HOSTNAME systemd[1]: Started Link Layer Discovery Protocol Agent Daemon..
    May 08 00:06:48 HOSTNAME systemd[1]: Starting Link Layer Discovery Protocol Agent Daemon....

ARMؤƳ(Raspberry Pi)

Raspberry PiƳλ㡣

Ķ

  • ǥȥӥ塼
    # cat /etc/redhat-release 
    CentOS Linux release 7.2.1511 (Core) 
  • Kernel
    # cat /proc/version 
    Linux version 4.4.26-v7.1.el7 (mockbuild@armv7-02.dev.centos.org) (gcc version 4.8.5 20150623 (Red Hat 4.8.5-4) (GCC) ) #1 SMP Sat Oct 22 16:14:43 UTC 2016
  • CPU
    # cat /proc/cpuinfo 
    processor       : 0
    model name      : ARMv7 Processor rev 4 (v7l)
    BogoMIPS        : 38.40
    Features        : half thumb fastmult vfp edsp neon vfpv3 tls vfpv4 idiva idivt vfpd32 lpae evtstrm crc32 
    CPU implementer : 0x41
    CPU architecture: 7
    CPU variant     : 0x0
    CPU part        : 0xd03
    CPU revision    : 4
    ʲά

Ƴ

󥹥ȡ

CentOS7(ARM)ΥݥȥˤlldpadޤޤƤʤᡢFedora release 21Υݥȥѥåɤ롣

  • ѥå
  • lldpad
    wget https://archive.fedoraproject.org/pub/archive/fedora/linux/releases/21/Cloud/armhfp/os/Packages/l/lldpad-0.9.46-8.git48a5f38.fc21.armv7hl.rpm
  • libconfig
    wget https://archive.fedoraproject.org/pub/archive/fedora/linux/releases/21/Cloud/armhfp/os/Packages/l/libconfig-1.4.9-7.fc21.armv7hl.rpm
  • libnl
    wget https://archive.fedoraproject.org/pub/archive/fedora/linux/releases/21/Cloud/armhfp/os/Packages/l/libnl3-3.2.25-4.fc21.armv7hl.rpm
    wget https://archive.fedoraproject.org/pub/archive/fedora/linux/releases/21/Cloud/armhfp/os/Packages/l/libnl3-cli-3.2.25-4.fc21.armv7hl.rpm
  • ѥåƳ
    rpm -ivh libconfig-1.4.9-7.fc21.armv7hl.rpm  
    rpm -Uvh libnl3-cli-3.2.25-4.fc21.armv7hl.rpm libnl3-3.2.25-4.fc21.armv7hl.rpm
    rpm -ivh lldpad-0.9.46-8.git48a5f38.fc21.armv7hl.rpm
  • ӥμưưꤹ
    # systemctl enable lldpad.service
    
    Created symlink from /etc/systemd/system/multi-user.target.wants/lldpad.service to /usr/lib/systemd/system/lldpad.service.
    Created symlink from /etc/systemd/system/sockets.target.wants/lldpad.socket to /usr/lib/systemd/system/lldpad.socket.
  • ӥư
    # systemctl start lldpad
  • ư
    # systemctl status lldpad.service
     lldpad.service - Link Layer Discovery Protocol Agent Daemon.
      Loaded: loaded (/usr/lib/systemd/system/lldpad.service; enabled; vendor preset: disabled)
      Active: active (running) since Sun 2017-05-07 14:59:10 UTC; 12s ago
    Main PID: 14649 (lldpad)
      CGroup: /system.slice/lldpad.service
              14649 /usr/sbin/lldpad -t
    
    May 07 14:59:10 hw-mon01.localnet.asabiya.net systemd[1]: Started Link Layer Discovery Protocol Agent Daemon..
    May 07 14:59:10 hw-mon01.localnet.asabiya.net systemd[1]: Starting Link Layer Discovery Protocol Agent D......
    Hint: Some lines were ellipsized, use -l to show in full.

  • 󥿡ե֤ͤ
    for i in `ls /sys/class/net/ | grep 'eth\|ens\|eno\|em\|enp1s6f\|enp2s'`;
    do echo "enabling lldp for interface: $i";
    lldptool set-lldp -i $i adminStatus=rxtx;
    lldptool -T -i $i -V sysName enableTx=yes;
    lldptool -T -i $i -V portDesc enableTx=yes;
    lldptool -T -i $i -V sysDesc enableTx=yes;
    lldptool -T -i $i -V sysCap enableTx=yes;
    lldptool -T -i $i -V mngAddr enableTx=yes;
    done
  • ̤γǧ
    # lldptool get-tlv -i eth0
    Chassis ID TLV
           MAC: b8:27:eb:39:f8:13
    Port ID TLV
           MAC: b8:27:eb:39:f8:13
    Time to Live TLV
           120
    Port Description TLV
           Interface   2 as eth0
    System Name TLV
           hw-mon02.localnet.asabiya.net
    System Description TLV
           Linux hw-mon02.localnet.asabiya.net 3.18.13-501.20150510gitf36e19f.sc20.armv7hl.bcm2709 #1 SMP PREEMPT Sun May 10 13:50:02 BST 2015 armv7l
    System Capabilities TLV
           System capabilities:  Station Only
           Enabled capabilities: Station Only
    Management Address TLV
           IPv4: 192.168.xxx.xxx
           Ifindex: 2
    End of LLDPDU TLV

ȥå   Խ ʬ ʎގ̎ ź ʣ ̾ѹ   ǽ   إ   ǽRSS
Last-modified: 2017-07-04 () 21:56:45 (143d)