Open ForrestHong opened 6 years ago
please offer info above:
Check https://www.armbian.com/nanopi-neo/ Armbian Stretch/Xenial with 4.14.y or Armbian Bionic (testing) with 4.17.y
Hello igorpecovnik kernel 4.14 is ok, I've tried "nanopi-neo_friendlycore-xenial_4.14.0_20180511.img.zip" last week and it work as expected,
But, we need to use 3.4.x kernel because in our project, some of external device drivers are not supported in 4.x kernel.
Can this issue be resovled in kernel 3.4.x ?
I pasted the dmesg output after I issue "apt-get install tcpdump", at the bottom of the dmesg, there is a line "Killed process 856 (apt-get) total-vm:40820kB, anon-rss:32708kB, file-rss:736kB", does it mean that the vm was run out of space?
`root@NanoPi-NEO:~# dmesg
[ 0.000000] Booting Linux on physical CPU 0
[ 0.000000] Initializing cgroup subsys cpuset
[ 0.000000] Initializing cgroup subsys cpu
[ 0.000000] Linux version 3.4.39-h3 (root@test) (gcc version 4.6.3 20120201 (prerelease) (crosstool-NG linaro-1.13.1-2012.02-20120222 - Linaro GCC 2012.02) ) #3 SMP PREEMPT Thu Jun 7 12:45:47 HKT 2018
[ 0.000000] CPU: ARMv7 Processor [410fc075] revision 5 (ARMv7), cr=10c5387d
[ 0.000000] CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing instruction cache
[ 0.000000] Machine: sun8i
[ 0.000000] cma: CMA: reserved 160 MiB at 46000000
[ 0.000000] Memory policy: ECC disabled, Data cache writealloc
[ 0.000000] On node 0 totalpages: 65536
[ 0.000000] free_area_init_node: node 0, pgdat c0a6a2c0, node_mem_map c0b8f000
[ 0.000000] Normal zone: 576 pages used for memmap
[ 0.000000] Normal zone: 0 pages reserved
[ 0.000000] Normal zone: 64960 pages, LIFO batch:15
[ 0.000000] script_init enter!
[ 0.000000] script_init exit!
[ 0.000000] PERCPU: Embedded 8 pages/cpu @c0de0000 s11840 r8192 d12736 u32768
[ 0.000000] pcpu-alloc: s11840 r8192 d12736 u32768 alloc=8*4096
[ 0.000000] pcpu-alloc: [0] 0 [0] 1 [0] 2 [0] 3
[ 0.000000] Built 1 zonelists in Zone order, mobility grouping on. Total pages: 64960
[ 0.000000] Kernel command line: console=ttyS0,115200 console=tty0 root=/dev/mmcblk0p2 rootwait storage_type=1 init=/sbin/init loglevel=8 partitions= selinux=0 fsck.repair=yes boot_type=1 disp_para=0 init_disp=20b0404 tv_vdid=0 fb_base=0x46400000 config_size=34796
[ 0.000000] setup_bootdev 1
[ 0.000000] PID hash table entries: 1024 (order: 0, 4096 bytes)
[ 0.000000] Dentry cache hash table entries: 32768 (order: 5, 131072 bytes)
[ 0.000000] Inode-cache hash table entries: 16384 (order: 4, 65536 bytes)
[ 0.000000] allocated 524288 bytes of page_cgroup
[ 0.000000] please try 'cgroup_disable=memory' option if you don't want memory cgroups
[ 0.000000] Memory: 256MB = 256MB total
[ 0.000000] Memory: 79848k/79848k available, 182296k reserved, 0K highmem
[ 0.000000] Virtual kernel memory layout:
[ 0.000000] vector : 0xffff0000 - 0xffff1000 ( 4 kB)
[ 0.000000] fixmap : 0xfff00000 - 0xfffe0000 ( 896 kB)
[ 0.000000] vmalloc : 0xd0800000 - 0xff000000 ( 744 MB)
[ 0.000000] lowmem : 0xc0000000 - 0xd0000000 ( 256 MB)
[ 0.000000] pkmap : 0xbfe00000 - 0xc0000000 ( 2 MB)
[ 0.000000] modules : 0xbf000000 - 0xbfe00000 ( 14 MB)
[ 0.000000] .text : 0xc0008000 - 0xc09621cc (9577 kB)
[ 0.000000] .init : 0xc0963000 - 0xc09b6e40 ( 336 kB)
[ 0.000000] .data : 0xc09b8000 - 0xc0a6caf8 ( 723 kB)
[ 0.000000] .bss : 0xc0a6d2ac - 0xc0b8e160 (1156 kB)
[ 0.000000] Preemptible hierarchical RCU implementation.
[ 0.000000] Additional per-CPU info printed with stalls.
[ 0.000000] NR_IRQS:544
[ 0.000000] Architected local timer running at 24.00MHz.
[ 0.000000] Switching to timer-based delay loop
[ 0.000000] sched_clock: 32 bits at 24MHz, resolution 41ns, wraps every 178956ms
[ 0.000000] Console: colour dummy device 80x30
[ 0.000000] console [tty0] enabled
[ 0.001426] Calibrating delay loop (skipped), value calculated using timer frequency.. 4800.00 BogoMIPS (lpj=24000000)
[ 0.001494] pid_max: default: 32768 minimum: 301
[ 0.001865] Mount-cache hash table entries: 512
[ 0.002972] Initializing cgroup subsys cpuacct
[ 0.003015] Initializing cgroup subsys memory
[ 0.003086] Initializing cgroup subsys devices
[ 0.003121] Initializing cgroup subsys freezer
[ 0.003154] Initializing cgroup subsys blkio
[ 0.003197] Initializing cgroup subsys perf_event
[ 0.003278] CPU: Testing write buffer coherency: ok
[ 0.003360] ftrace: allocating 25992 entries in 77 pages
[ 0.040365] CPU0: thread -1, cpu 0, socket 0, mpidr 80000000
[ 0.040417] [sunxi_smp_prepare_cpus] enter
[ 0.040479] Setting up static identity map for 0x406a1d38 - 0x406a1d90
[ 0.041596] CPU1: Booted secondary processor
[ 0.041596] CPU1: thread -1, cpu 1, socket 0, mpidr 80000001
[ 0.041737] CPU2: Booted secondary processor
[ 0.041737] CPU2: thread -1, cpu 2, socket 0, mpidr 80000002
[ 0.050298] CPU3: Booted secondary processor
[ 0.050298] CPU3: thread -1, cpu 3, socket 0, mpidr 80000003
[ 0.050421] Brought up 4 CPUs
[ 0.050421] SMP: Total of 4 processors activated (19200.00 BogoMIPS).
[ 0.051124] devtmpfs: initialized
[ 0.060145] wakeup src cnt is : 2.
[ 0.060173] [exstandby]leave extended_standby_enable_wakeup_src : event 0x800000
[ 0.060204] [exstandby]leave extended_standby_enable_wakeup_src : wakeup_gpio_map 0x0
[ 0.060237] [exstandby]leave extended_standby_enable_wakeup_src : wakeup_gpio_group 0x40
[ 0.060270] [exstandby]leave extended_standby_enable_wakeup_src : event 0x800000
[ 0.060301] [exstandby]leave extended_standby_enable_wakeup_src : wakeup_gpio_map 0x8
[ 0.060333] [exstandby]leave extended_standby_enable_wakeup_src : wakeup_gpio_group 0x40
[ 0.060366] sunxi pm init
[ 0.060527] pinctrl core: initialized pinctrl subsystem
[ 0.067430] NET: Registered protocol family 16
[ 0.068672] DMA: preallocated 2048 KiB pool for atomic coherent allocations
[ 0.068672] script_sysfs_init success
[ 0.068672] sunxi_dump_init success
[ 0.068672] gpiochip_add: registered GPIOs 0 to 383 on device: sunxi-pinctrl
[ 0.068672] sunxi-pinctrl sunxi-pinctrl: initialized sunXi PIO driver
[ 0.068672] plat: add adxl34x device
[ 0.068672] plat: add bmp085 device
[ 0.068672] plat: add ds1307 device
[ 0.068672] plat: add pcf8591 device
[ 0.068672] hw-breakpoint: found 5 (+1 reserved) breakpoint and 4 watchpoint registers.
[ 0.068672] hw-breakpoint: maximum watchpoint size is 8 bytes.
[ 0.068672] script config pll_video to 297 Mhz
[ 0.068672] script config pll_de to 864 Mhz
[ 0.068672] script config pll_ve to 402 Mhz
[ 0.068672] sunxi_default_clk_init
[ 0.068672] try to set pll6ahb1 to 200000000
[ 0.068672] try to set ahb clk source to pll6ahb1
[ 0.068672] set ahb clk source to pll6ahb1
[ 0.068672] try to set ahb1 to 200000000
[ 0.068672] try to set apb1 to 100000000
[ 0.080276] bio: create slab
[ 3.796073] calibrat: max_cpufreq 1200Mhz Type 0!
[ 3.805913] [cpu_freq] ERR:get cpu extremity frequency from sysconfig failed, use max_freq
[ 3.820218] [mmc]: SD/MMC/SDIO Host Controller Driver(v1.111 2015-4-13 15:24) Compiled in May 25 2018 at 14:41:09
[ 3.836560] [mmc]: get mmc0's sdc_power is null!
[ 3.846592] [mmc]: MMC host used card: 0x1, boot card: 0x1, io_card 0
[ 3.860772] no red_led, ignore it!
[ 3.862220] [mmc]: sdc0 power_supply is null
[ 3.879201] Registered led device: green_led
[ 3.888061] Registered led device: blue_led
[ 3.898170] usbcore: registered new interface driver usbhid
[ 3.908437] usbhid: USB HID core driver
[ 3.917536] pcm5102a_probe
[ 3.927950] asoc: pcm5102a-hifi <-> pri_dai mapping ok
[ 3.933054] mmc0: new high speed SDHC card at address b368
[ 3.933498] mmcblk0: mmc0:b368 USD 7.45 GiB
[ 3.934591] mmcblk0: p1 p2
[ 3.968865] asoc: sndhdmi <-> sunxi-hdmiaudio.0 mapping ok
[ 3.980201] oprofile: using arm/armv7-ca7
[ 3.988940] u32 classifier
[ 3.995968] Actions configured
[ 4.003712] Netfilter messages via NETLINK v0.30.
[ 4.013001] nf_conntrack version 0.5.0 (3853 buckets, 15412 max)
[ 4.024102] ctnetlink v0.93: registering with nfnetlink.
[ 4.034124] NF_TPROXY: Transparent proxy support initialized, version 4.1.0
[ 4.045984] NF_TPROXY: Copyright (c) 2006-2007 BalaBit IT Ltd.
[ 4.056987] xt_time: kernel timezone is -0000
[ 4.066188] IPv4 over IPv4 tunneling driver
[ 4.075487] gre: GRE over IPv4 demultiplexor driver
[ 4.085066] ip_gre: GRE over IPv4 tunneling driver
[ 4.095069] ip_tables: (C) 2000-2006 Netfilter Core Team
[ 4.105207] arp_tables: (C) 2002 David S. Miller
[ 4.114370] TCP: cubic registered
[ 4.121974] Initializing XFRM netlink socket
[ 4.130877] NET: Registered protocol family 10
[ 4.140910] Mobile IPv6
[ 4.147450] ip6_tables: (C) 2000-2006 Netfilter Core Team
[ 4.157460] IPv6 over IPv4 tunneling driver
[ 4.166882] NET: Registered protocol family 17
[ 4.175630] NET: Registered protocol family 15
[ 4.184579] Bluetooth: RFCOMM TTY layer initialized
[ 4.193778] Bluetooth: RFCOMM socket layer initialized
[ 4.203248] Bluetooth: RFCOMM ver 1.11
[ 4.211118] Bluetooth: BNEP (Ethernet Emulation) ver 1.3
[ 4.220754] Bluetooth: BNEP filters: protocol multicast
[ 4.230293] Bluetooth: HIDP (Human Interface Emulation) ver 1.2
[ 4.240772] L2TP core driver, V2.0
[ 4.248193] PPPoL2TP kernel driver, V2.0
[ 4.256078] L2TP IP encapsulation support (L2TPv3)
[ 4.264928] L2TP netlink interface
[ 4.272157] L2TP ethernet pseudowire support (L2TPv3)
[ 4.281210] Registering the dns_resolver key type
[ 4.290441] VFP support v0.3: implementor 41 architecture 2 part 30 variant 7 rev 5
[ 4.302508] ThumbEE CPU extension supported.
[ 4.310835] Registering SWP/SWPB emulation handler
[ 4.321272] sunxi-rtc sunxi-rtc: setting system clock to 1970-01-01 00:00:14 UTC (14)
[ 4.333682] ths_fetch_sysconfig_para: type err device_used = 1.
[ 4.345583] CPU Budget:Register notifier
[ 4.353660] CPU Budget:register Success
[ 4.361560] sunxi-budget-cooling sunxi-budget-cooling: Cooling device registered: thermal-budget-0
[ 4.378364] [rf_pm]: module power0 name vcc-wifi-33
[ 4.387672] [rf_pm]: Did not config module_power1 in sys_config
[ 4.398075] [rf_pm]: Did not config module_power2 in sys_config
[ 4.408396] [rf_pm]: Did not config module_power3 in sys_config
[ 4.418687] [rf_pm]: mod has no chip_en gpio
[ 4.427129] [rf_pm]: failed to fetch lpo_use_apclk
[ 4.436140] [rf_pm]: regulator on.
[ 4.443604] [wifi_pm]: no wifi used in configuration
[ 4.452763] [rfkill]: init no bt used in configuration
[ 4.462078] ALSA device list:
[ 4.468906] #0: Pcm5102a
[ 4.475402] #1: sndhdmi
[ 4.482141] Freeing init memory: 332K
[ 5.289923] EXT4-fs (mmcblk0p2): mounted filesystem with ordered data mode. Opts: (null)
[ 5.321638] EXT4-fs (mmcblk0p2): re-mounted. Opts: data=ordered
[ 5.770154] systemd[1]: System time before build time, advancing clock.
[ 6.310391] systemd[1]: systemd 229 running in system mode. (+PAM +AUDIT +SELINUX +IMA +APPARMOR +SMACK +SYSVINIT +UTMP +LIBCRYPTSETUP +GCRYPT +GNUTLS +ACL +XZ -LZ4 +SECCOMP +BLKID +ELFUTILS +KMOD -IDN)
[ 6.352792] systemd[1]: Detected architecture arm.
[ 6.407478] systemd[1]: Set hostname to
Thanks Forrest
But, we need to use 3.4.x kernel because in our project, some of external device drivers are not supported in 4.x kernel.
Then still it is better to use our 3.4.113 kernel since it has a ton of fixes: https://github.com/armbian/linux + https://github.com/armbian/build/tree/master/patch/kernel/sun8i-default and perhaps this problem is solved.
Check for images in archive: https://dl.armbian.com/nanopineo/archive/
Hello igorpecovnik
Does Armbian support NanpiNEO-CORE board, we will finally use this board and burn the image(boot/kernel/rootfs) to it's board nand flash. which was described in following link:
http://wiki.friendlyarm.com/wiki/index.php/Assembling_the_SD_card_image_yourself
Thanks Forrest
I see this link https://docs.armbian.com/User-Guide_Getting-Started/#how-to-install-to-emmc-nand-sata-usb it should support install image to NAND flash, I will try it when I go the NanoPiNeo Core board,
Anyway, I tried the Armbian image "Armbian_5.35_Nanopineo_Ubuntu_xenial_default_3.4.113.7z", and I didn't see the OOM issue when running the apt-get command.
I will keeping on testing this image.
Thanks Forrest
may be swap enabled or some kernel update?
Yes, enable the swap can resolve this issue, I enabled the "zram" in kernel, and add following lines in "/etc/rc.local"
echo $((64*1024*1024)) > /sys/block/zram0/disksize &&
mkswap /dev/zram0 &&
swapon -p 5 /dev/zram0 &&
after that, i didn't see the OOM issue anymore.
Hello
I got following error every time on my NanoPi NEO when running apt-get command.
root@NanoPi-NEO:/home/pi# apt-get update
Hit:1 http://ports.ubuntu.com xenial InRelease
Hit:2 http://ports.ubuntu.com xenial-security InRelease Hit:3 http://ports.ubuntu.com xenial-updates InRelease Hit:4 http://ports.ubuntu.com xenial-backports InRelease [ 1083.337086] Out of memory: Kill process 2204 (apt-get) score 117 or sacrifice child [ 1083.345843] Killed process 2204 (apt-get) total-vm:42564kB, anon-rss:34092kB, file-rss:2160kB Killed
This issue doesn't happen on the mainline Kernel. I opened another SSH session to check the free memory periodically, and I can see it should have enough memory for "LowFree”.
root@NanoPi-NEO:~# egrep 'High|Low' /proc/meminfo HighTotal: 0 kB HighFree: 0 kB LowTotal: 246992 kB LowFree: 140976 kB root@NanoPi-NEO:~# egrep 'High|Low' /proc/meminfo HighTotal: 0 kB HighFree: 0 kB LowTotal: 246992 kB LowFree: 141576 kB root@NanoPi-NEO:~# egrep 'High|Low' /proc/meminfo HighTotal: 0 kB HighFree: 0 kB LowTotal: 246992 kB LowFree: 140532 kB root@NanoPi-NEO:~# egrep 'High|Low' /proc/meminfo HighTotal: 0 kB HighFree: 0 kB LowTotal: 246992 kB LowFree: 140664 kB root@NanoPi-NEO:~# egrep 'High|Low' /proc/meminfo HighTotal: 0 kB HighFree: 0 kB LowTotal: 246992 kB LowFree: 139876 kB root@NanoPi-NEO:~# root@NanoPi-NEO:~# egrep 'High|Low' /proc/meminfo HighTotal: 0 kB HighFree: 0 kB LowTotal: 246992 kB LowFree: 138508 kB root@NanoPi-NEO:~# egrep 'High|Low' /proc/meminfo HighTotal: 0 kB HighFree: 0 kB LowTotal: 246992 kB LowFree: 172348 kB root@NanoPi-NEO:~# egrep 'High|Low' /proc/meminfo HighTotal: 0 kB HighFree: 0 kB LowTotal: 246992 kB LowFree: 171912 kB
Could help to check this ?
Thanks