Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pi freezes up regularly #66

Open
Schwambo opened this issue Feb 7, 2018 · 8 comments
Open

Pi freezes up regularly #66

Schwambo opened this issue Feb 7, 2018 · 8 comments

Comments

@Schwambo
Copy link

Schwambo commented Feb 7, 2018

I built the 64 bit desktop OS on a fresh SD card and set it up, connected it to wi-fi and installed various basic packages. During that the pi randomly froze and was not responding at all.
After a hard reset I tried again and everything went fine.
I am now at a point where I try to build another package from source via “make“ and I can't make it through the whole process without the pi freezing again. I tried several times, the issue occurs at different places during the build and I noticed that the yellow arrow sometimes flashes in the top right corner before the pi locks up.
The process is also very slow, the longest it run was 8 minutes before the pi froze.
I use a pi3 with the “official“ 2.5A power supply. No issues with other builds / SD cards.

@Schwambo
Copy link
Author

Schwambo commented Feb 9, 2018

While trying various ways to decrease the "stress" on the pi one of my solutions was creating a swap file.
This fixed the problem, maybe consider creating a swap file natively with the build due to the pi's restricted memory?

@ether-btc
Copy link

@Schwambo how did you manually create a swap file?

@Crazyhead90
Copy link

Could you share the entire process of how you got it to work, the swapfile etc

@ThomasKaiser
Copy link

I noticed that the yellow arrow sometimes flashes in the top right corner before the pi locks up.

https://www.raspberrypi.org/forums/viewtopic.php?t=177477

You run into a hardware issue called under-voltage. There's no software fix available for this only mitigations. The so called 'firmware' controlling the hardware monitors available voltage and as soon it drops below 4.65V the symbol will be shown and all subsystems are underclocked. Sometimes to no avail and you experience a brownout.

If you use the official RPi power supply you should check the Micro USB receptacle since then it's either the Micro USB jack (contact resistance) or the PSU dying. The cable between PSU and board is 18AWG rated so should not be an issue.

Seriously: yellow lightning bolt --> under-voltage that can only be fixed with a hardware change.

@ThomasKaiser
Copy link

With most recent kernel (hoping for @bamarni to provide a new release soon) we can now check for this problem on our own and without using vcgencmd get_throttled. All that's needed then is dmesg | grep -i voltage. See raspberrypi/linux#2367 for details!

@jlong777
Copy link

jlong777 commented Apr 17, 2018

Create a swap file:

$ sudo dd if=/dev/zero of=/swap bs=512M count=1
$ sudo chown root:root /swap
$ sudo chmod 0600 /swap
$ sudo mkswap /swap
$ sudo swapon /swap

and add to /etc/fstab:

/swap	none	swap	sw	0	0

@ThomasKaiser
Copy link

Create a swap file

Swap on SD card is a horrible idea. In general and especially when the real problem is freezes/instabilities caused by under-voltage. @Schwambo clearly wrote he's suffering from this common hardware problem: 'I noticed that the yellow arrow sometimes flashes in the top right corner before the pi locks up'

@jlong777
Copy link

True, it's not a great idea; implementation depends on what trade-offs you are willing to consider.
raspian creates a 100M swap file by default at /var/swap, controlled by /etc/dphys-swapfile, and managed as a service. Personally, I turn it off, and run everything off of a USB hard drive w/swap partition.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants