| View previous topic :: View next topic |
| Author |
Message |
haven Tux's lil' helper


Joined: 19 Nov 2003 Posts: 141 Location: Belfast, Uk
|
Posted: Fri Apr 27, 2012 7:29 am Post subject: Elf errors on a broken machine - tracking down the cause |
|
|
Hi All,
I had a home system die on me this week. I had a cron job set to do world updates nightly and one night the system simply stopped working. When rebooting I got the following:
http://haven.thehavennet.org.uk/files/Elf.jpg
Once I chrooted from a recovery disk I saw a lot of "is not an ELF file - it has the wrong magic bytes at the start." warnings on many different applications (htop, bash, cp, echo and others).
What I'm looking for is simply to understand what these errors are related too in package terms - I assume this is a package issue and not disk corruption although I'm open to suggestions. Unfortunately on this issue I hit a wall of lack of understanding and would like to know more so I can fix without a re-install in the future.
If its any help here's the emerge log from the last day of the systems working life:
http://haven.thehavennet.org.uk/files/emerge.log.txt
Thanks
Haven |
|
| Back to top |
|
 |
eccerr0r Advocate

Joined: 01 Jul 2004 Posts: 3001 Location: USA
|
Posted: Fri Apr 27, 2012 2:28 pm Post subject: |
|
|
ELF is a file format. If there's an ELF error, it means corruption.
Normally when you build executables on a modern system, it will be ELF of the architecture of your machine by default. If it's not, it's crosscompiling which you're not doing...
This looks like hardware failure to me. I've never seen something this drastic before other than if the machine was failing such as bad RAM...
Try moving the disk to another computer and see if anything is still usable? This will narrow the problem down a bit. The worry is that bad ram/bad chipset causes bad data be written onto the disk. If lucky, it's just having trouble reading from your disk and the hard drive data is intact. _________________ Core-i7-2700K@4.1GHz/8GB RAM/180GB SSD/Intel HD3000 graphics
What the heck am I advocating? |
|
| Back to top |
|
 |
haven Tux's lil' helper


Joined: 19 Nov 2003 Posts: 141 Location: Belfast, Uk
|
Posted: Mon Apr 30, 2012 8:06 am Post subject: |
|
|
Thanks eccerr0r,
Unfortunately I never did find out the cause and had to do a full re-install. I was using btrfs as the root file system so I may have been burned by that - back to ext4 for now just in-case.
I did find a useful utility that may help others in the future: readelf will show you the magic bits at the start of your file and may help tracking down whats broken and whats not i.e:
Regards
Haven |
|
| Back to top |
|
 |
eccerr0r Advocate

Joined: 01 Jul 2004 Posts: 3001 Location: USA
|
Posted: Mon Apr 30, 2012 2:29 pm Post subject: |
|
|
Yes, probably should have reinstalled anyway, when there's one corrupt file there's bound to be another somewhere.
I suppose you could readelf to figure out what's bad and what's not, but it doesn't rootcause the issue, hope the problem does not show up again... _________________ Core-i7-2700K@4.1GHz/8GB RAM/180GB SSD/Intel HD3000 graphics
What the heck am I advocating? |
|
| Back to top |
|
 |
|