CubieBoard Forum

Cubieboard itself => Hardware => Cubieboard v2 Hardware (A20 Based) => Topic started by: Den1982 on October 29, 2013, 12:45:17 pm

Title: Cubieboard2 stability
Post by: Den1982 on October 29, 2013, 12:45:17 pm
Hi, all! There is a problem which about I wrote on Cubieez topic:
"But it is strange problem - after a few hours - dark screen and no reaction on keyboard and mouse. Looks like heating processor or something... I install on cubieez: JRE, Torvidalia, i2p and apps for i2p. Well cpu usage about 40-50%, memory usage about 30%.
I would like use cubie 24/7, but with this problem that impossible. :(
are there any ways to solve this? Thanks and sorry for my english ;)"
http://www.cubieforums.com/index.php/topic,528.msg5501.html#msg5501
I'm install and setup Cubian and... same trouble - it's darkscreen again! I assume it is hardware problem? is it really such a problem only for my cubie? :(
Title: Re: Cubieboard2 stability
Post by: camelator on October 30, 2013, 03:42:59 am
Completely agree.
I am not a linux expert, but have some knowledge.
I just installed Cubian with mpd for an audio media player.
After few hours without doing anything, the cubieboard always stop.

Is there any chance to understand this issue?

Title: Re: Cubieboard2 stability
Post by: cubieplayer on October 30, 2013, 05:54:54 am
Completely agree.
I am not a linux expert, but have some knowledge.
I just installed Cubian with mpd for an audio media player.
After few hours without doing anything, the cubieboard always stop.

Is there any chance to understand this issue?
Hi i guess it's related to power management, did you install xserver? or just plain cubian.
Title: Re: Cubieboard2 stability
Post by: camelator on October 31, 2013, 02:24:58 pm
only cubian with mpd
nothing else
Title: Re: Cubieboard2 stability
Post by: Gasz2 on November 11, 2013, 08:00:27 am
Use cpufreq-info and cpufreq-set to adjust CPU frequency. I am using my CB v2 as a MediaServer. SMB, MiniDLNA, SSH, BTSync, Apache, TVHeadEnd and some Mono apps.

I am using Cubian with patwood 3.4.61 kernel, CPU is configure to run at 1.01Ghz using the performance governor.

My Cubie stream IPTV, DTT and media files and also record television programs on a SATA disk.

The Cubie with this configuration and use is very very stable.

Regards, Gustavo.
Title: Re: Cubieboard2 stability
Post by: camelator on November 17, 2013, 11:57:03 am
Hi Gas2,
thank you for your answer,
as of now, my cubieboard becomes very stable.
What player do you use to play media flles?

Title: Re: Cubieboard2 stability
Post by: Kilrah on November 28, 2013, 06:02:10 am
Check this maybe?
http://www.cubieforums.com/index.php/topic,1108.0.html
Title: Re: Cubieboard2 stability
Post by: gedas07 on December 08, 2013, 03:07:34 pm
Use cpufreq-info and cpufreq-set to adjust CPU frequency. I am using my CB v2 as a MediaServer. SMB, MiniDLNA, SSH, BTSync, Apache, TVHeadEnd and some Mono apps.

I am using Cubian with patwood 3.4.61 kernel, CPU is configure to run at 1.01Ghz using the performance governor.

My Cubie stream IPTV, DTT and media files and also record television programs on a SATA disk.

The Cubie with this configuration and use is very very stable.

Regards, Gustavo.
How can i change in Cubieez , because when cubieboard are a long time in sleep doesn't respond to nothing
Thanks for help
Title: Re: Cubieboard2 stability
Post by: berturion on December 19, 2013, 01:10:27 am
Use cpufreq-info and cpufreq-set to adjust CPU frequency. I am using my CB v2 as a MediaServer. SMB, MiniDLNA, SSH, BTSync, Apache, TVHeadEnd and some Mono apps.

I am using Cubian with patwood 3.4.61 kernel, CPU is configure to run at 1.01Ghz using the performance governor.

My Cubie stream IPTV, DTT and media files and also record television programs on a SATA disk.

The Cubie with this configuration and use is very very stable.

Regards, Gustavo.

Hello !
Thanks for the advise. Do you mean that you put min-freq and max-freq at 1.01 Ghz ? If not, Which min-freq did you choose please ? My min-freq, by default, accordingly to cpufreq-info was 300Mhz... I just set it to 528Mhz to see how it goes.
Thank you :-)
Title: Re: Cubieboard2 stability
Post by: vierax on December 21, 2013, 04:26:37 pm
Hello !
Thanks for the advise. Do you mean that you put min-freq and max-freq at 1.01 Ghz ? If not, Which min-freq did you choose please ? My min-freq, by default, accordingly to cpufreq-info was 300Mhz... I just set it to 528Mhz to see how it goes.
Thank you :-)
Hi berturion

The stock min-freq (300Mhz) is very stable so you don't have to raise it. A highest min freq minimizes the power of conservative and ondemand governors when there is a low use of CPUs. It also increases average power consumption and heat especially if your board is often idle.
Title: Re: Cubieboard2 stability
Post by: berturion on December 29, 2013, 12:16:16 pm
Hi berturion

The stock min-freq (300Mhz) is very stable so you don't have to raise it. A highest min freq minimizes the power of conservative and ondemand governors when there is a low use of CPUs. It also increases average power consumption and heat especially if your board is often idle.

Thanks for these information. I was on Cubian r3 with patwood's 3.4.67+ kernel and even after applying these settings (300MHz -> 1.01GHz, performance governor) I had the "cubieboard freezes after few hours" issue.

So I tried max cpufreq at 800MHz but id didn't change anything.
 
Then I decieded to try another distro : Cubieez with patwood's 3.4.67+ kernel again. The nude distro seemed to be very stable, it ran more than 24h without freeze so I quickly reinstalled all my services : samba, nginx, php5-fpm, mysql, minidlna, ampache, phpmyadmin, inadyn, wordpress, seafile, tvheadend.

Then I had the same issue, freeze after about 6 to 10 hours with the settings 300MHz -> 1.01GHz and performance governor.

I try now 300MHz -> 800MHz to see if it changes something. I will post the results tomorrow.

I wonder if it would be better if I run OS from NAND instead of SD Card. Do you think I could have better stability ?
Title: Re: Cubieboard2 stability
Post by: arturbac on December 29, 2013, 01:47:09 pm
My diagnosis:
- problem is connected with xf86-video-fbturbo
- system is working ok while screen goes black - can connect via ssh
- problem is connected with logged in X session, X welcome screen don't  goes black ...

maybe power managment turns off hdmi and dont turn it back on ...

I got same effect with ubuntu and gentoo, totally different instalations.
Title: Re: Cubieboard2 stability
Post by: Den1982 on December 29, 2013, 10:57:15 pm
maybe power managment turns off hdmi and dont turn it back on ...

I tried turn off all screensavers settings (even kill daemon) + turn off all power management settings - that don't solve the problem.
Title: Re: Cubieboard2 stability
Post by: vierax on December 30, 2013, 04:09:17 am
Just in case, did you reproduce this issue with another monitor ?
Title: Re: Cubieboard2 stability
Post by: rwolf on December 30, 2013, 12:57:28 pm
Hi

use

Code: [Select]
xset -dpms
in an x terminal. It is not permanent, you need to do this every time and every session/user.

Or add

Code: [Select]
option "DPMS" "false"

to /usr/share/X11/xorg.conf.d/99-sunxifb.conf. It is permanent.
Title: Re: Cubieboard2 stability
Post by: patwood on December 31, 2013, 12:04:18 am
Did you try setting  consoleblank=0 in the kernel args?
Title: Re: Cubieboard2 stability
Post by: rwolf on December 31, 2013, 08:18:24 am
It was not enough in my situation. I think this is a HDMI/DPMS/X11 issue. The monitor cannot wake up.
If you check the dpms function in X  with the "xset q" command, you can see, that DPMS is active regardles of the consoleblank argument. I could eliminate this monitor sleeping issue only with the option dpms false setting in xorg.conf.
Title: Re: Cubieboard2 stability
Post by: berturion on January 08, 2014, 05:58:21 am
Hello everyone,
I just wanted to say that I had a stability problem with my cubieboard. As my cubieboard is headless, I use it as a web and file server. After few hours, my cubieboard was freezing without any reason. No SSH, no Ping, my router wasn't able to see it. I always had to turn it off with power button and turn it on again.

I tried to adjust cpufreq and governor from advises posted in this thread without any result. I was on Cubian r3 for A20 with patwood 3.4.67+ kernel, I then switched to Cubieez with the same kernel, same problem. I also installed the last patwood's 3.4.75+ kernel and the same problem was there. All was running from my micro-sdcard Transcend 16Go class 10.

So I decided to test my system by installing it on Nand. So I flashed Cubieez on Nand and restored my rootfs. And Wow ! Miracle ! Everthing works fine, no freeze anymore, incredible stability. I also installed patwood's 3.4.75 kernel with success.

I don't know if my sdcard is damaged or what... But, I will always run my future Cubieboard OS from NAND !

Hope that helps.
Title: Re: Cubieboard2 stability
Post by: virgilio on January 08, 2014, 04:46:29 pm
Use cpufreq-info and cpufreq-set to adjust CPU frequency. I am using my CB v2 as a MediaServer. SMB, MiniDLNA, SSH, BTSync, Apache, TVHeadEnd and some Mono apps.

I am using Cubian with patwood 3.4.61 kernel, CPU is configure to run at 1.01Ghz using the performance governor.

My Cubie stream IPTV, DTT and media files and also record television programs on a SATA disk.

The Cubie with this configuration and use is very very stable.

Regards, Gustavo.
Hi ,
which key dvd-t TV to use with TVHeadEnd ?
I tried to use a Flying Green AVer TV HD, but the kernel does not have drivers.
Title: Re: Cubieboard2 stability
Post by: jobarjo on January 11, 2014, 11:06:05 am
Do you think a heatsink could help?

I also noticed some freezes sometimes.
The cpu was quite hot.
Don't know if it was a powering problem.
Title: Re: Cubieboard2 stability
Post by: vierax on January 11, 2014, 09:12:05 pm
The cpu and ram are hot during process, the design is supposed to run in a tiny enclosure without ventilation (some cheap tablets run those SOCs) a heatsink or a fan can improve the stability but the problem must be somewhere else. Undervolting is a cheapest solution.
Title: Re: Cubieboard2 stability
Post by: jobarjo on March 04, 2014, 03:58:58 pm
I remade some stress tests, and my cubie a20 is not stable.
The system is stable with low loads, but it hangs after few minutes when stressing the system.

I'm actualy using cubian r5 on my cubieboard 2 (because it has a cubian-installnand utility, but it doesn't work for me).
I use the microsd to have the kernel, and modified uEnv.txt to use my sata as root.

I use stress to test my system (apt-get install stress in both debian and ubuntu)
Could you guys please test if your system is stable with
stress --cpu 2 --io 2 --vm 2 --vm-bytes 128M -d 2
It stresses both CPU and sata disk.

For the power supply, I actually don't have a 2A power supply, so I'm using 2 distinct usb power: one is 1.5A through the supplied cable and power input, the other (1A) connected to the USB.
It seems to work well. Both power supplies seem to be warm.

The voltages I get with one single power supply is 5v at idle, and about 4.85v during stress. (measured at power supply connector)
With both power supply, I get 5.10v idle and 5v during stress. stress time goes from a few seconds to a few minutes with these.

I also added a heatsink (about 3.5cm x 2cm x 1.5cm (high)). It gets quite hot, stress last longer before fail, but still fails.

I also downclocked to 768Mhz, and still fails after 15-60min. Heatsink is much less warm. it lasts longer I think.

Today, I've put my board in my garage (about 10 degrees celcius), and stress is running since about an hour and still no fail. (always the heatsink on)

I would like to know if it is my board which has a problem.
I really need a rock stable system for my hvac system.

Thanks
Title: Re: Cubieboard2 stability
Post by: jobarjo on March 04, 2014, 04:14:55 pm
It finally freezed after 1h15!!
Title: Re: Cubieboard2 stability
Post by: patwood on March 05, 2014, 12:26:33 am
Perhaps it's the DRAM clock and not the CPU speed: https://groups.google.com/forum/#!topic/linux-sunxi/hw0yyWFVYgM
Title: Re: Cubieboard2 stability
Post by: dd on March 05, 2014, 05:52:24 am
Hi Patwood,

How can we test it?
Title: Re: Cubieboard2 stability
Post by: jobarjo on March 05, 2014, 06:13:22 am
Hi

Is there a howto on the dram?
Is it an uEnv.txt setting or do we have to recompile uboot?
Title: Re: Cubieboard2 stability
Post by: jobarjo on March 07, 2014, 03:11:17 am
I compiled a new u-boot with a 380Mhz (instead of 480) dram clock.
installed it on sdcard (with dd), and stress passed overnight (sata included)
I even overclocked to 1.2ghz, and it is still running after 1h.

Note that one single 1.5A usb power supply with the standard cable is enough even with my sata disk stressed.

I will try other intermediate dram frequencies.

I you want me to upload the u-boot somewhere, just tell me.
Title: Re: Cubieboard2 stability
Post by: dd on March 09, 2014, 06:30:34 am
Yes. Please upload.
Title: Re: Cubieboard2 stability
Post by: luminofor on March 09, 2014, 10:16:26 am
Oh, it's great that someone managed to solve this problem! I am suffering for two months with this issue. Can you write a user guide for newbies?
Title: Re: Cubieboard2 stability
Post by: jobarjo on March 14, 2014, 04:12:40 am
Hi

I compiled my u-boot compiled with 432Mhz instead of 480 from git:
https://github.com/patrickhwood/u-boot.git

change board/sunxi/dram_cubieboard2.c then
Code: [Select]
CROSS_COMPILE=arm-linux-gnueabihf- make cubieboard2
I uploaded it (432Mhz) here:
http://codaspot.com/u-boot/u-boot.bin
http://codaspot.com/u-boot/u-boot-sunxi-with-spl.bin

it works only for sd card. To install
Code: [Select]
dd if=u-boot.img of=/dev/sdX bs=1024 seek=40or
Code: [Select]
dd if=u-boot-sunxi-with-spl.bin of=/dev/sdX bs=1024 seek=8
NOTE: I noticed that this u-boot doesn't load uEnv.txt but uEnv.cb2

https://github.com/linux-sunxi/u-boot-sunxi/wiki

Note that I'm still looking for a solution to boot from nand. The nand u-boot is completely different.
Title: Re: Cubieboard2 stability
Post by: luminofor on March 14, 2014, 09:55:56 am
Yes, I did all the instructions, but I get an error. Perhaps I have curves hands.  ;D
Thank you very much! Hope my CB2 will now work normally
Title: Re: Cubieboard2 stability
Post by: jobarjo on March 14, 2014, 09:59:02 am
What is your error?
Do you have a serial line?
Title: Re: Cubieboard2 stability
Post by: luminofor on March 14, 2014, 10:21:39 am
What is your error?
Do you have a serial line?
Code: [Select]
rootm@rootm ~/u-boot $ CROSS_COMPILE=arm-linux-gnueabihf- make cubieboard2
/bin/bash: arm-linux-gnueabihf-gcc: команда не найдена
/bin/bash: arm-linux-gnueabihf-gcc: команда не найдена
dirname: пропущен операнд
По команде «dirname --help» можно получить дополнительную информацию.
Configuring for Cubieboard2 - Board: sun7i, Options: CUBIEBOARD2,SPL,SUNXI_GMAC,STATUSLED=244,STATUSLED1=245,FAST_MBUS
make
/bin/bash: arm-linux-gnueabihf-gcc: команда не найдена
/bin/bash: arm-linux-gnueabihf-gcc: команда не найдена
dirname: пропущен операнд
По команде «dirname --help» можно получить дополнительную информацию.
make[1]: Вход в каталог `/home/rootm/u-boot'
Generating include/autoconf.mk
/bin/bash: строка 3: arm-linux-gnueabihf-gcc: команда не найдена
Generating include/autoconf.mk.dep
/bin/bash: строка 3: arm-linux-gnueabihf-gcc: команда не найдена
make[1]: Выход из каталога `/home/rootm/u-boot'
/bin/bash: arm-linux-gnueabihf-gcc: команда не найдена
/bin/bash: arm-linux-gnueabihf-gcc: команда не найдена
dirname: пропущен операнд
По команде «dirname --help» можно получить дополнительную информацию.
make[1]: Вход в каталог `/home/rootm/u-boot'
/bin/bash: arm-linux-gnueabihf-gcc: команда не найдена
/bin/bash: arm-linux-gnueabihf-ld: команда не найдена
Generating include/spl-autoconf.mk
/bin/bash: строка 3: arm-linux-gnueabihf-gcc: команда не найдена
Generating include/tpl-autoconf.mk
/bin/bash: строка 3: arm-linux-gnueabihf-gcc: команда не найдена
arm-linux-gnueabihf-gcc -DDO_DEPS_ONLY \
-g  -Os   -ffunction-sections -fdata-sections -fno-common -ffixed-r9 -msoft-float  -D__KERNEL__  -I/home/rootm/u-boot/include  -I/home/rootm/u-boot/arch/arm/include -fno-builtin -ffreestanding -nostdinc -isystem  -pipe  -DCONFIG_ARM -D__ARM__     -march=armv5 -Wall -Wstrict-prototypes       \
-o lib/asm-offsets.s lib/asm-offsets.c -c -S
/bin/bash: arm-linux-gnueabihf-gcc: команда не найдена
make[1]: *** [lib/asm-offsets.s] Ошибка 127
make[1]: Выход из каталога `/home/rootm/u-boot'
make: *** [cubieboard2] Ошибка 2
Sorry, my terminal speaks Russian


Here through Google translator
Code: [Select]
rootm @ rootm ~ / u-boot $ CROSS_COMPILE = arm-linux-gnueabihf-make cubieboard2
/ bin / bash: arm-linux-gnueabihf-gcc: command not found
/ bin / bash: arm-linux-gnueabihf-gcc: command not found
dirname: missing operand
At the command «dirname - help» to get more information .
Configuring for Cubieboard2 - Board: sun7i, Options: CUBIEBOARD2, SPL, SUNXI_GMAC, STATUSLED = 244 , STATUSLED1 = 245 , FAST_MBUS
make
/ bin / bash: arm-linux-gnueabihf-gcc: command not found
/ bin / bash: arm-linux-gnueabihf-gcc: command not found
dirname: missing operand
At the command «dirname - help» to get more information .
make [ 1] : Login directory `/ home / rootm / u-boot '
Generating include / autoconf.mk
/ bin / bash: line 3 : arm-linux-gnueabihf-gcc: command not found
Generating include / autoconf.mk.dep
/ bin / bash: line 3 : arm-linux-gnueabihf-gcc: command not found
make [ 1] : Leaving directory `/ home / rootm / u-boot '
/ bin / bash: arm-linux-gnueabihf-gcc: command not found
/ bin / bash: arm-linux-gnueabihf-gcc: command not found
dirname: missing operand
At the command «dirname - help» to get more information .
make [ 1] : Login directory `/ home / rootm / u-boot '
/ bin / bash: arm-linux-gnueabihf-gcc: command not found
/ bin / bash: arm-linux-gnueabihf-ld: command not found
Generating include / spl-autoconf.mk
/ bin / bash: line 3 : arm-linux-gnueabihf-gcc: command not found
Generating include / tpl-autoconf.mk
/ bin / bash: line 3 : arm-linux-gnueabihf-gcc: command not found
arm-linux-gnueabihf-gcc-DDO_DEPS_ONLY \
-g-Os-ffunction-sections-fdata-sections-fno-common-ffixed-r9-msoft-float-D__KERNEL__ -I/home/rootm/u-boot/include -I/home/rootm/u-boot/arch / arm / include-fno-builtin-ffreestanding-nostdinc-isystem-pipe-DCONFIG_ARM-D__ARM__-march = armv5-Wall-Wstrict-prototypes \
-o lib / asm-offsets.s lib / asm-offsets.c-c-S
/ bin / bash: arm-linux-gnueabihf-gcc: command not found
make [ 1 ]: *** [lib / asm-offsets.s] Error 127
make [ 1] : Leaving directory `/ home / rootm / u-boot '
make: *** [cubieboard2] Error 2
Title: Re: Cubieboard2 stability
Post by: jobarjo on March 14, 2014, 10:23:22 am
Have you installed the cross compiler package?
Don't remember the exact name.
Title: Re: Cubieboard2 stability
Post by: luminofor on March 14, 2014, 10:27:55 am
Have you installed the cross compiler package?
Don't remember the exact name.

That is done
Code: [Select]
sudo add-apt-repository ppa:linaro-maintainers/toolchain
sudo apt-get update
sudo apt-get install gcc-arm-linux-gnueabi
Code: [Select]
apt-get install build-essential git debootstrap u-boot-tools
Code: [Select]
mkdir ~/bin
cd ~/bin
for i in /usr/bin/arm-linux-gnueabihf*-4.7 ; do j=${i##/usr/bin/}; ln -s $i ${j%%-4.7} ; done
Title: Re: Cubieboard2 stability
Post by: jobarjo on March 14, 2014, 10:28:59 am
have you tried my binary?
Title: Re: Cubieboard2 stability
Post by: luminofor on March 14, 2014, 10:31:14 am
Exactly! I probably missed a Cross Compiler

have you tried my binary?
Not yet, I'm still at work, will try tonight
Title: Re: Cubieboard2 stability
Post by: jobarjo on March 14, 2014, 10:42:33 am
gnueabihf
hf is hard-float.
The package to intall would be gcc-arm-linux-gnueabihf
Title: Re: Cubieboard2 stability
Post by: luminofor on March 14, 2014, 11:00:30 am
gnueabihf
hf is hard-float.
The package to intall would be gcc-arm-linux-gnueabihf
Ok, I'll try. But at home
Title: Re: Cubieboard2 stability
Post by: luminofor on March 14, 2014, 05:08:08 pm
have you tried my binary?
I tried your binary
Code: [Select]
cubie@cubieez:~$ sudo /home/cubie/a10-meminfo-static
dram_clk          = 432
dram_type         = 3
dram_rank_num     = 1
dram_chip_density = 4096
dram_io_width     = 16
dram_bus_width    = 32
dram_cas          = 9
dram_zq           = 0x7f
dram_odt_en       = 0
dram_tpr0         = 0x42d899b7
dram_tpr1         = 0xa090
dram_tpr2         = 0x22a00
dram_tpr3         = 0x0
dram_emr1         = 0x4
dram_emr2         = 0x10
dram_emr3         = 0x0
As seen frequency changed, see now how it will affect the stability of