SupremeSpod
Posts: 22
Joined: Thu Jan 05, 2012 12:19 pm

Pi hangs when start.elf replaced

Wed Aug 15, 2012 2:40 pm

My pi hangs when I copy any of the armxxx_start.elf files over the start.elf file and reboot.

I've tried with different SD cards and I still seem to have the same problem. Has anyone else had the same trouble?

Also can someone point me in the right direction for the source URI's for my sources.list file? I'd like to have a play with some of the source code for the packages I've installed.

Thanks.

User avatar
joan
Posts: 15378
Joined: Thu Jul 05, 2012 5:09 pm
Location: UK

Re: Pi hangs when start.elf replaced

Wed Aug 15, 2012 2:58 pm

For Debian edit /etc/apt/sources.list and add deb-src lines by duplicating the deb lines, e.g.
deb [arch=amd64,i386] http://ftp.uk.debian.org/debian/ testing main contrib non-free
deb-src [arch=amd64,i386] http://ftp.uk.debian.org/debian/ testing main contrib non-free
You'll need to do a sudo apt-get update afterwards before you can sudo apt-get source package

I've copied the elf files to start.elf on many occasions. Perhaps yours are corrupt?

bredman
Posts: 1415
Joined: Tue Jan 17, 2012 2:38 pm

Re: Pi hangs when start.elf replaced

Wed Aug 15, 2012 3:48 pm

Some people have reported that they cannot edit the boot partition of their RPi, any changes are lost or corrupted after a reboot.

This is probably related to the type of SD card that you are using.

Try using a Windows or Linux PC to change the contents of your SD card. You should be able to drag-and-drop to copy the files.

User avatar
RaTTuS
Posts: 10744
Joined: Tue Nov 29, 2011 11:12 am
Location: North West UK
Contact: Twitter YouTube

Re: Pi hangs when start.elf replaced

Wed Aug 15, 2012 3:51 pm

if you try and copy on the RPi check any errors in
/var/log/syslog
after a
sync
it maybe that your boot partition has been currupted.
try doing a
rpi-update
How To ask Questions :- http://www.catb.org/esr/faqs/smart-questions.html
WARNING - some parts of this post may be erroneous YMMV

1QC43qbL5FySu2Pi51vGqKqxy3UiJgukSX
Covfefe

lavers
Posts: 17
Joined: Mon Jul 09, 2012 3:45 pm
Location: Canada

Re: Pi hangs when start.elf replaced

Wed Aug 15, 2012 3:53 pm

I think a recent firmware update fixed a bug that was corrupting the boot partition when it was written to (don't quote me on that though ;) ). I did a rpi-update the other day and the process of writing the new firmware to the boot partition seemed to have corrupted it and my Pi would not boot. I just took the card out and ran a fsck on it from my other machine, and that solved it.

Edit: Just glanced at the commit logs and I don't see anything about that, so I must have been imagining things. Either way, there does seem to be a known problem about that partition getting corrupted when written to.

dom
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 5708
Joined: Wed Aug 17, 2011 7:41 pm
Location: Cambridge

Re: Pi hangs when start.elf replaced

Wed Aug 15, 2012 4:36 pm

lavers wrote:Edit: Just glanced at the commit logs and I don't see anything about that, so I must have been imagining things. Either way, there does seem to be a known problem about that partition getting corrupted when written to.
It was this source update:
https://github.com/raspberrypi/linux/co ... 3b9d562b2d
and this binary update:
https://github.com/Hexxeh/rpi-firmware/ ... 3abaac11fd

We believe the problem is fixed. However you still need one successful firmware update to get the fixed kernel, which if you are suffering the problem may be tricky.

I suggest downloading latest kernel from github. E.g.
wget https://github.com/Hexxeh/rpi-firmware/ ... kernel.img
sudo cp kernel.img /boot/kernel.img
sudo reboot

Then run rpi-udpate.

If your firmware is already corrupt, then downloading latest bootcode.bin, loader.bin, start.elf, kernel.img from github, and putting those on sdcard, then running rpi-update should do it.

PaulCheffus
Posts: 381
Joined: Tue May 29, 2012 2:51 pm
Location: Lincolnshire UK

Re: Pi hangs when start.elf replaced

Wed Aug 15, 2012 8:33 pm

dom wrote:
lavers wrote:Edit: Just glanced at the commit logs and I don't see anything about that, so I must have been imagining things. Either way, there does seem to be a known problem about that partition getting corrupted when written to.
It was this source update:
https://github.com/raspberrypi/linux/co ... 3b9d562b2d
and this binary update:
https://github.com/Hexxeh/rpi-firmware/ ... 3abaac11fd

We believe the problem is fixed. However you still need one successful firmware update to get the fixed kernel, which if you are suffering the problem may be tricky.

I suggest downloading latest kernel from github. E.g.
wget https://github.com/Hexxeh/rpi-firmware/ ... kernel.img
sudo cp kernel.img /boot/kernel.img
sudo reboot

Then run rpi-udpate.

If your firmware is already corrupt, then downloading latest bootcode.bin, loader.bin, start.elf, kernel.img from github, and putting those on sdcard, then running rpi-update should do it.
Hi

Just ran rpi-update this evening on my 8GB Transcend Class 10 card and it corrupted the partition. I was previously using the later firmware as I had done one update to #242 and it was ok with that. If I do the same update to my 8GB Kingston Class 4 card its fine. I reformatted the boot partition in Windows Disk Management then copied the files from the Kingston card which allowed it to boot.

Cheers

Paul
Procrastination - The Thief of Time.

SupremeSpod
Posts: 22
Joined: Thu Jan 05, 2012 12:19 pm

Re: Pi hangs when start.elf replaced

Thu Aug 16, 2012 7:54 am

Thanks for your suggestions everyone.

This morning(16/08/2012) I ran an "apt-get update" followed by "aptitude" as "root", aptitude told me I had 10 packages to upgrade. I set "aptitude" to install the upgrades - these included "boot loader updates", I issued a reboot and now I can't access my "Pi" via ssh and considering that I'm at work and my "Pi" is at home this means my lunchtime "Pi" tinkering has gone for a burton.

I guess I'll re-install the "2012-07-15-wheezy-raspbian" image and start from the beginning - which is all part of the fun I suppose.

On the topic of the "2012-07-15-wheezy-raspbian" image, when is this going to be updated with the latest builds etc?

User avatar
joan
Posts: 15378
Joined: Thu Jul 05, 2012 5:09 pm
Location: UK

Re: Pi hangs when start.elf replaced

Thu Aug 16, 2012 8:27 am

SupremeSpod wrote:...
I guess I'll re-install the "2012-07-15-wheezy-raspbian" image and start from the beginning - which is all part of the fun I suppose.
...
When you get home have a look at the LEDs as you try to boot up. You may have a corrupted start.elf.

If so take the card out and pop it into another machine. Run chkdsk on Windows or sudo dosfsck -r /dev/sd?1 on Linux to repair the (unmounted) file system. Mount the sd card and copy the appropriate elf file to start.elf.

Quicker than a reinstall.

SupremeSpod
Posts: 22
Joined: Thu Jan 05, 2012 12:19 pm

Re: Pi hangs when start.elf replaced

Thu Aug 16, 2012 11:44 am

joan wrote:
SupremeSpod wrote:...
I guess I'll re-install the "2012-07-15-wheezy-raspbian" image and start from the beginning - which is all part of the fun I suppose.
...
When you get home have a look at the LEDs as you try to boot up. You may have a corrupted start.elf.

If so take the card out and pop it into another machine. Run chkdsk on Windows or sudo dosfsck -r /dev/sd?1 on Linux to repair the (unmounted) file system. Mount the sd card and copy the appropriate elf file to start.elf.

Quicker than a reinstall.
Thanks, I'll give that a try.
It does beg the question though, how are the ELF files being corrupted when they're being downloaded via aptitude or rpi-update...

Oh well, as I mentioned, part of the fun.

Oliv'
Posts: 35
Joined: Sun Aug 05, 2012 7:57 pm

Re: Pi hangs when start.elf replaced

Thu Aug 16, 2012 1:05 pm

dom wrote:
lavers wrote:Edit: Just glanced at the commit logs and I don't see anything about that, so I must have been imagining things. Either way, there does seem to be a known problem about that partition getting corrupted when written to.
It was this source update:
https://github.com/raspberrypi/linux/co ... 3b9d562b2d
and this binary update:
https://github.com/Hexxeh/rpi-firmware/ ... 3abaac11fd

We believe the problem is fixed. However you still need one successful firmware update to get the fixed kernel, which if you are suffering the problem may be tricky.

I suggest downloading latest kernel from github. E.g.
wget https://github.com/Hexxeh/rpi-firmware/ ... kernel.img
sudo cp kernel.img /boot/kernel.img
sudo reboot

Then run rpi-udpate.

If your firmware is already corrupt, then downloading latest bootcode.bin, loader.bin, start.elf, kernel.img from github, and putting those on sdcard, then running rpi-update should do it.
Hello, I had the same problem, tried to copy the kernel.img file, reboot and everything went fine but still hang when I did a rpi-update. So I use your 2nd solution, it worked and I can now performed and 'rpi-update'

Thanks

SupremeSpod
Posts: 22
Joined: Thu Jan 05, 2012 12:19 pm

Re: Pi hangs when start.elf replaced

Fri Aug 17, 2012 9:44 am

Thanks for your help all.

I started with the base Raspbian release on my SD cards, updated them to the latest bootloader, kernel image etc, ensured they booted OK, then updated the cmdline.txt file to point to SDA2 and updated my core software. All is now well with "Huey and Dewie" :lol:

I must say that the boot process is now much more reliable. :D

Return to “Raspberry Pi OS”