Dirks G писал(а):Какая версия ПО на LTP?
Покажите top, ps, dmesg из под root.
Что вы используете для управления по snmp?
---
Версии разные:
Eltex LTP-8X:rev.B software version 3.30.0 build 2935 on 28.11.2017
Eltex LTP-8X:rev.B software version 3.26.1 build 1345 on 12.12.2016
на 3.30.0
top:
Mem: 276044K used, 231220K free, 0K shrd, 65536K buff, 58264K cached
CPU: 4.5% usr 4.1% sys 0.5% nic 85.0% idle 0.0% io 0.0% irq 5.5% sirq
Load average: 0.18 0.22 0.17 3/203 17779
PID PPID USER STAT VSZ %MEM CPU %CPU COMMAND
1730 1 root S 99m 20.0 0 4.1 /usr/sbin/pmchal --syslog --daemon
406 1 root S 173m 35.0 0 0.8 /usr/sbin/switchd
1075 1 root S 137m 27.7 0 0.2 alarm -d
17629 17583 root R 2728 0.5 0 0.2 top
310 1 root S 2724 0.5 0 0.2 /bin/sh /usr/sbin/logrotate_master
770 1 root S 121m 24.5 0 0.0 config -o -u -s /etc/sysconfig/dat
1789 1 root S N 78660 15.4 0 0.0 acsd -u
http://192.168.200.1:9595/ 1640 1 root S 41928 8.2 0 0.0 /usr/sbin/snmpd -c /etc/sysconfig/
402 1 root S 37556 7.3 0 0.0 ipcman --daemonize --enable-inet
1058 869 mysql S 33728 6.6 0 0.0 /usr/local/mysql/libexec/mysqld --
413 406 root S 18604 3.6 0 0.0 sw-sys-exec
307 1 root S 16644 3.2 0 0.0 logd --daemonize
17555 739 root S 8532 1.6 0 0.0 login -- root
1684 1 root S 7340 1.4 0 0.0 /usr/sbin/ntpclient -d
1518 1 root S 4280 0.8 0 0.0 /usr/sbin/sshd
869 1 root S 2728 0.5 0 0.0 /bin/sh /usr/local/mysql/bin/mysql
17583 17555 root S 2728 0.5 0 0.0 -sh
17778 310 root S 2592 0.5 0 0.0 sleep 1
1838 1 root S 2012 0.4 0 0.0 /usr/sbin/dhcpd mgmt.4094
17610 1 root S 1720 0.3 0 0.0 /usr/sbin/syslogd -m 0
dmesg:
[root@OTR01 /root]$dmesg
Linux version 2.6.22.18 (user@ee699c4bfefa) (gcc version 3.4.4 (release) (CodeSourcery ARM 2005q3-2)) #1 Tue Nov 28 16:54:12 NOVT 2017
CPU: ARM926EJ-S [56251311] revision 1 (ARMv5TE), cr=00053977
Machine: Feroceon-KW
DMA memory:
mv_high_memory_paddr 0x1f800000
mv_high_memory_paddr_top 0x20000000
mv_high_memory_vaddr 0xf3800000
mv_high_memory_vaddr_top 0xf4000000
Using UBoot passing parameters structure
BoardID from uboot=10
Memory policy: ECC disabled, Data cache writeback
On node 0 totalpages: 129024
DMA zone: 1008 pages used for memmap
DMA zone: 0 pages reserved
DMA zone: 128016 pages, LIFO batch:31
Normal zone: 0 pages used for memmap
calling iotable_init. MEM_TABLE=
virt=0xf3800000, phys=0x1f800000, lengh=0x00800000
virt=0xec000000, phys=0xe8000000, lengh=0x04000000
virt=0xf1000000, phys=0xf1000000, lengh=0x00100000
virt=0xf8000000, phys=0xf8000000, lengh=0x01000000
virt=0xf4000000, phys=0xf4000000, lengh=0x04000000
virt=0xfb000000, phys=0xfb000000, lengh=0x00010000
virt=0xf2000000, phys=0xf2000000, lengh=0x00010000
Internal prestera id register = 0x000dd743
xCat revision = A1
CPU0: D VIVT write-back cache
CPU0: I cache: 16384 bytes, associativity 4, 32 byte lines, 128 sets
CPU0: D cache: 16384 bytes, associativity 4, 32 byte lines, 128 sets
Built 1 zonelists. Total pages: 128016
Kernel command line: init=/sbin/save root=/dev/ram0 rw initrd=0x3000000,0x1000000 console=ttyS0,115200 mtdparts=spi_flash:0x00200000(uboot)ro,0x00200000(kernel),0x00400000(env),0x0010000(snmpenv),0x007F0000(reserved);nand_mtd:12m(nand_kernel),12m(nand_kernel_reserve),32m(nand_initrd),32m(nand_initrd_reserve),32m(nand_env),32m(nand_reserve),64m(nand_ext_disk),296m(nand_firmware)
PID hash table entries: 2048 (order: 11, 8192 bytes)
Console: colour dummy device 80x30
Dentry cache hash table entries: 65536 (order: 6, 262144 bytes)
Inode-cache hash table entries: 32768 (order: 5, 131072 bytes)
Memory: 256MB 248MB 0MB 0MB = 504MB total
Memory: 490624KB available (2568K code, 1784K data, 124K init)
Calibrating delay loop... 799.53 BogoMIPS (lpj=3997696)
Mount-cache hash table entries: 512
CPU: Testing write buffer coherency: ok
NET: Registered protocol family 16
CPU Interface
-------------
SDRAM_CS0 ....base 00000000, size 256MB
SDRAM_CS1 ....base 10000000, size 256MB
SDRAM_CS2 ....disable
SDRAM_CS3 ....disable
PEX0_MEM ....base e8000000, size 64MB
PEX0_IO ....base fc000000, size 1MB
INTER_REGS ....base f1000000, size 1MB
NFLASH_CS ....base d8000000, size 128MB
SPI_CS ....base f8000000, size 16MB
BOOT_ROM_CS ....no such
DEV_BOOTCS ....no such
CRYPT_ENG ....base fb000000, size 64KB
SAGE_UNIT ....base f4000000, size 64MB
DRAGONITE_DTCM ....base f2000000, size 64KB
Marvell Development Board (LSP Version KW_LSP_4.3.0.015)-- DB-98DX4122-48G Soc: 88F6281 A0 LE
Detected Tclk 166666667 and SysClk 320000000
Switch default target range: 1F800000..1F800FFF
Switch address window 0: base=00000E00 size=0FFF0000
Switch address window 1: base=10000D00 size=0FFF0000
Switch default target: UDID=000000D0 UDA=1F800000
Switch decoding windows init is done.
MV Buttons Device Load
PEX0 interface detected Link X1
PCI: bus0: Fast back to back transfers disabled
PCI: Failed to allocate mem resource #0:100000@ec000000 for 0000:00:01.0
NET: Registered protocol family 2
Time: kw_clocksource clocksource has been installed.
IP route cache hash table entries: 4096 (order: 2, 16384 bytes)
TCP established hash table entries: 16384 (order: 5, 131072 bytes)
TCP bind hash table entries: 16384 (order: 4, 65536 bytes)
TCP: Hash tables configured (established 16384 bind 16384)
TCP reno registered
checking if image is initramfs...it isn't (no cpio magic); looks like an initrd
Freeing initrd memory: 16384K
RTC has been updated!!!
RTC registered
Use the XOR engines (acceleration) for enhancing the following functions:
o RAID 5 Xor calculation
o kernel memcpy
o kenrel memzero
Number of XOR engines to use: 2
MV Buttons Driver Load
JFFS2 version 2.2. (NAND) (SUMMARY) © 2001-2006 Red Hat, Inc.
io scheduler noop registered
io scheduler anticipatory registered (default)
Serial: 8250/16550 driver $Revision: 1.90 $ 4 ports, IRQ sharing disabled
serial8250.0: ttyS0 at MMIO 0xf1012000 (irq = 33) is a 16550A
serial8250.0: ttyS1 at MMIO 0xf1012100 (irq = 34) is a 16550A
RAMDISK driver initialized: 1 RAM disks of 65536K size 1024 blocksize
Loading Marvell Ethernet Driver:
o Uncached descriptors in DRAM
o DRAM SW cache-coherency
o Multi RX Queue support - 8 RX queues
o Multi TX Queue support - 8 TX Queues
o TCP segmentation offload enabled
o Receive checksum offload enabled
o Transmit checksum offload enabled
o Network Fast Processing (Routing) supported
o Driver ERROR statistics enabled
o Driver INFO statistics enabled
o Proc tool API enabled
o Rx descripors: q0=64 q1=64 q2=64 q3=64 q4=64 q5=64 q6=64 q7=64
o Tx descripors: q0=532 q1=532 q2=532 q3=532 q4=532 q5=532 q6=532 q7=532
o Loading network interface(s):
o eth0, ifindex = 1, GbE port = 0
Warning: Giga 1 is Powered Off
mvFpRuleDb (8090c000): 4096 entries, 16384 bytes
sizeof(trace_entry)=156
sizeof(trace_entry_switch)=140
sizeof(trace_entry_event)=40
trace entries: 10000 (1560000 bytes)
board: Board control driver_mod5
board: Board ID = 0x05
board: lm75[0] probe read temperature = 26 C
board: lm75[1] probe read temperature = 33 C
board: FPGA version = 8
board: QUAD PHY's reset
NFTL driver: nftlcore.c $Revision: 1.98 $, nftlmount.c $Revision: 1.41 $
INFO: sflash_probe - Detected SFlash device 0 (size 16777216)
Base Address : 0xf4000000
Manufacturer ID : 0xc2
Device ID : 0x2018
Sector Size : 0x10000
Sector Number : 256
SPI Serial flash 0 detected @ 0xf4000000, 16384KB (256sec x 64KB)
mvSFlashInit ERROR: Unknown SPI flash device [DVG]!
ERROR: sflash_probe - Failed to initialize the SFlash1.<5>5 cmdlinepart partitions found on MTD device spi_flash
Creating 5 MTD partitions on "spi_flash":
0x00000000-0x00200000 : "uboot"
0x00200000-0x00400000 : "kernel"
0x00400000-0x00800000 : "env"
0x00800000-0x00810000 : "snmpenv"
0x00810000-0x01000000 : "reserved"
Using Hamming 1-bit ECC for NAND device
NAND device: Manufacturer ID: 0x01, Chip ID: 0xdc (Unknown NAND 512MiB 3,3V 8-bit)
Scanning device for bad blocks
8 cmdlinepart partitions found on MTD device nand_mtd
Using command line partition definition
Creating 8 MTD partitions on "nand_mtd":
0x00000000-0x00c00000 : "nand_kernel"
0x00c00000-0x01800000 : "nand_kernel_reserve"
0x01800000-0x03800000 : "nand_initrd"
0x03800000-0x05800000 : "nand_initrd_reserve"
0x05800000-0x07800000 : "nand_env"
0x07800000-0x09800000 : "nand_reserve"
0x09800000-0x0d800000 : "nand_ext_disk"
0x0d800000-0x20000000 : "nand_firmware"
mice: PS/2 mouse device common for all mice
i2c /dev entries driver
sdma: loaded
nf_conntrack version 0.5.0 (4032 buckets, 32256 max)
ip_tables: (C) 2000-2006 Netfilter Core Team
arp_tables: (C) 2002 David S. Miller
TCP cubic registered
NET: Registered protocol family 1
NET: Registered protocol family 17
Bridge firewalling registered
802.1Q VLAN Support v1.8 Ben Greear <greearb@candelatech.com>
All bugs added by David S. Miller <davem@redhat.com>
RAMDISK: Compressed image found at block 0
VFS: Mounted root (ext2 filesystem).
Freeing init memory: 124K
mvKernelExt_init
mvKernelExt_major = 254 cdev.dev=fe00001
mvKernelExt_init finished
prestera_init
prestera_major = 254
pp_find_all_devices: found 2 PP devices
prestera_init: DMA memory at 0x1f801000 (0x200000 bytes)
DMA - dma_area: f3801000, dma_base: 0x1f801000, dma_len: 0x200000
prestera_init finished
PresteraOpen: connected Prestera IRQ - 9
PresteraOpen: connected Prestera IRQ - 113
prestera_ioctl: lsp_sdma_init(base=ab000000, irq=113, primary=1)
sdma%d: rx irq mask is nonzero (00380000), fixing it
sdma%d: tx irq mask is nonzero (01fffe00), fixing it
sdma%d: SDMA IRQs are globally masked (ffe7fffe), fixing it
sdma0: SDMA at 0xab000000 irq=113 (primary)
dsa0: raw DSA packet interface
mgmt: Ethernet over DSA
pon: Ethernet over DSA
supp: Ethernet over DSA
device pon entered promiscuous mode
ps:
[root@OTR01 /root]$ps
PID USER VSZ STAT COMMAND
1 root 1464 S ini
2 root 0 SW< [kthreadd]
3 root 0 SWN [ksoftirqd/0]
4 root 0 SW< [watchdog/0]
5 root 0 SW< [events/0]
6 root 0 SW< [khelper]
29 root 0 SW< [kblockd/0]
46 root 0 SW [pdflush]
47 root 0 SW [pdflush]
48 root 0 SW< [kswapd0]
49 root 0 SW< [aio/0]
164 root 0 SW< [mtdblockd]
165 root 0 SW< [nftld]
283 root 0 SWN [jffs2_gcd_mtd11]
295 root 0 SWN [jffs2_gcd_mtd12]
307 root 16644 S logd --daemonize
310 root 2724 S /bin/sh /usr/sbin/logrotate_master.sh
347 root 1464 S klogd -x
402 root 37556 S ipcman --daemonize --enable-inet
406 root 173m S /usr/sbin/switchd
413 root 18604 S sw-sys-exec
484 root 0 SW< [replication/0]
739 root 1452 R /sbin/telnetd -d
770 root 121m S config -o -u -s /etc/sysconfig/data.xml -v /usr/loca
869 root 2728 S /bin/sh /usr/local/mysql/bin/mysqld_safe --datadir=/
1058 mysql 33728 S /usr/local/mysql/libexec/mysqld --basedir=/usr/local
1075 root 137m S alarm -d
1518 root 4280 S /usr/sbin/sshd
1640 root 41928 S /usr/sbin/snmpd -c /etc/sysconfig/snmpd.conf -p /var
1684 root 7340 S /usr/sbin/ntpclient -d
1730 root 99.5m S /usr/sbin/pmchal --syslog --daemonize
1734 root 1464 S /sbin/agetty -L ttyS0 115200 vt100
1789 root 78660 S N acsd -u
http://192.168.200.1:9595/ -l acs -p acsacs
1838 root 2012 S /usr/sbin/dhcpd mgmt.4094
17555 root 8532 S login -- root
17583 root 2728 S -sh
17610 root 1720 S /usr/sbin/syslogd -m 0
18112 root 2592 S sleep 1
18114 root 2728 R ps
Команды выполняются скриптом из linux :
Например реализован скрипт:
ip=$1
dogovor=$2
stat=$3
Получение ontid по description
dexontid=`snmpwalk -c public -v2c $1 1.3.6.1.4.1.35265.1.22.3.4.1.8 | grep $2 | cut -d "." -f 16-23 | cut -d " " -f 1`
отключение/включение КТВ порта
snmpset -v2c -c private $1 .1.3.6.1.4.1.35265.1.22.3.4.1.32.1.8.$dexontid i $stat
Бывает при snmpwalk получаем snmp: error: [SNMP] get_ont_i2c : Timeout 1:(-1007)