View previous topic :: View next topic |
Author |
Message |
Gladdle Guru
Joined: 27 Jul 2008 Posts: 313 Location: Cleebronn, Germany
|
Posted: Sat Feb 13, 2016 4:12 pm Post subject: Banana Pi SD Card Crashed - now not booting |
|
|
Hi there, i have a few Problems with my Banana Pi. A vew days ago, my SD Card filesystem crashed. I used my Gentoo Desktop Computer to fix the Problem successful (fsck.ext4 and fsck.vfat). A few Days later my MySQL server stopped. I try to restart, but the whole System crashed. Now the Server doesn't boot anymore. Is it possible to activate some kind of logging? Here is my uEnv.txt: Code: | bootargs=console=ttyS0,115200 disp.screen0_output_mode=EDID:1024x768p50 hdmi.audio=EDID:0 root=/dev/mmcblk0p2 rootfstype=ext4 elevator=deadline rootwait
aload_script=fatload mmc 0 0x43000000 script.bin;
aload_kernel=fatload mmc 0 0x48000000 uImage;bootm 0x48000000;
uenvcmd=run aload_script aload_kernel |
The Monitor is still black. With another SD Card the Banana Pi is booting. But i need this SD with the files! If its working again i will copy all files to my new SD card. |
|
Back to top |
|
|
NeddySeagoon Administrator
Joined: 05 Jul 2003 Posts: 54421 Location: 56N 3W
|
Posted: Sat Feb 13, 2016 4:36 pm Post subject: |
|
|
Gladdle,
Get the files you need off the SD card with your PC. _________________ Regards,
NeddySeagoon
Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail. |
|
Back to top |
|
|
Gladdle Guru
Joined: 27 Jul 2008 Posts: 313 Location: Cleebronn, Germany
|
Posted: Sat Feb 13, 2016 4:41 pm Post subject: |
|
|
Okay, but then i didn't have a bootable SD Card anymore. Or is it easyer to move all needed files to a fresh installed gentoo? Can i move "/etc/", "home" and "/var" to the new SD Card whitout problems? |
|
Back to top |
|
|
NeddySeagoon Administrator
Joined: 05 Jul 2003 Posts: 54421 Location: 56N 3W
|
Posted: Sat Feb 13, 2016 4:48 pm Post subject: |
|
|
Gladdle,
That all depends on what you can salvage from the SD card ... if anything.
Make an image of the card before you even consider using fsck.
fsck makes the filesystem meta data self consistent. It does this by making some guesses about whats wrong.
When its done, the iflesystem meta data is self consistent, so mount works. However, it may well have trashed your data in the process.
That is, fsck often makes a bad situation worse. You image is your 'undo' facility. _________________ Regards,
NeddySeagoon
Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail. |
|
Back to top |
|
|
Irre Guru
Joined: 09 Nov 2013 Posts: 434 Location: Stockholm
|
Posted: Sat Feb 13, 2016 7:43 pm Post subject: |
|
|
I think you should move the root file system to a real hard disk. I Have very bad experience with sd-cards ext4 and my raspberry pi:s.
Nowadays I keep important data and system on external usb-disk. And sd-cards are only read during boot process. |
|
Back to top |
|
|
NeddySeagoon Administrator
Joined: 05 Jul 2003 Posts: 54421 Location: 56N 3W
|
Posted: Sat Feb 13, 2016 9:00 pm Post subject: |
|
|
Irre,
I was trying to avoid saying that yet. With Pi 1s, its a power supply issue.
Pi 2's are supposed to be better but I've not tested that yet. _________________ Regards,
NeddySeagoon
Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail. |
|
Back to top |
|
|
Gladdle Guru
Joined: 27 Jul 2008 Posts: 313 Location: Cleebronn, Germany
|
Posted: Thu Feb 18, 2016 4:50 pm Post subject: |
|
|
Okay, currently i am installing Gentoo on a new System (With the world file and the make.conf), and there are only 91 packages left ...
But now my next question, HOW can i make a effective backup? If i use "dd" all bits will be stored in the Backup file, also the empty space of the disk and the System have to be shut down for a while. The other option is to make a tar.gz file. Is it possible to make a backup while running the system (not realy neccessary)? Also can i make full backup (except "proc", "tmp" and "dev")? Or is there a third option i didnt know? I search for backup tools, specially for Linux Gentoo, but the only thing i found is a depreaced backup script from 2004. |
|
Back to top |
|
|
NeddySeagoon Administrator
Joined: 05 Jul 2003 Posts: 54421 Location: 56N 3W
|
Posted: Thu Feb 18, 2016 6:04 pm Post subject: |
|
|
Gladdle,
You want a stage4.
When you know that, google is your friend.
If you don't want to shut down for a backup, you need something that supports snapshots.
Logical Volume Manager comes to mind but there are other solutions too. _________________ Regards,
NeddySeagoon
Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail. |
|
Back to top |
|
|
Irre Guru
Joined: 09 Nov 2013 Posts: 434 Location: Stockholm
|
Posted: Thu Feb 18, 2016 6:42 pm Post subject: |
|
|
Gladdle wrote: | HOW can i make a effective backup? If i use "dd" all bits will be stored in the Backup file, also the empty space of the disk and the System have to be shut down for a while. |
I use nothing but dd for compressed backups. To backup /sdax:
Code: | mount /dev/sdax /mnt
dd if=/dev/zero of=/mnt/zerofile
rm /mnt/zerofile
umount /dev/sdax
dd if=/dev/sdax | gzip > yourbackup.gz |
And to restore: Code: | zcat yourbackup.gz | dd of=/dev/sdax |
You can also backup a running system this way (not recommended). Filesystem will get errors on open files, but fsck will probably repair most of the filesystem. |
|
Back to top |
|
|
NeddySeagoon Administrator
Joined: 05 Jul 2003 Posts: 54421 Location: 56N 3W
|
Posted: Fri Feb 19, 2016 7:56 pm Post subject: |
|
|
Irre,
Irre wrote: | Filesystem will get errors on open files, but fsck will probably repair most of the filesystem. |
Don't count on it.
Also, a backup is only useful if its validated. _________________ Regards,
NeddySeagoon
Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail. |
|
Back to top |
|
|
|