overdue-scratch

Author Topic: "Error loading operating system"?  (Read 11540 times)

0 Members and 2 Guests are viewing this topic.

rcfa

  • Member
  • Posts: 47
"Error loading operating system"?
« on: May 09, 2009, 04:37:40 AM »
I had to reinstall Chameleon on the EFI partition because I was playing around with XP.

Now, I get "error loading operating system". The system boots fine, however, using my custom boot-132 CD, as is evidenced by me writing this on the machine in question.

What's causing this error message? Also, we really need a "fix Chameleon install" script. Reinstalling Chameleon wipes out the EFI partition and requires all kexts to be copied over again, the boot.plist to be edited again, etc. when all that's needed would be the Chameleon equivalent of blessing the disk properly again.

I can't think of what would be different now as compared to yesterday when things worked just fine.

Also, to avoid future issues like these, what's the best way to create an image of the EFI partition that can be written back exactly as it was? Might save some hassle in the future...

rocksteady

  • Global Moderator
  • Posts: 233
  • Root Down
Re: "Error loading operating system"?
« Reply #1 on: May 09, 2009, 10:53:41 PM »
I had to reinstall Chameleon on the EFI partition because I was playing around with XP...

Now, I get "error loading operating system"...
What's causing this error message?
what partition scheme are you using? guid/mbr?
Stop bitching, start coding or documenting or both..

P5Q-EM : Q6600 : 8GB RAM : 8800GT : SATA Drives

rcfa

  • Member
  • Posts: 47
Re: "Error loading operating system"?
« Reply #2 on: May 09, 2009, 10:59:38 PM »
I had to reinstall Chameleon on the EFI partition because I was playing around with XP...

Now, I get "error loading operating system"...
What's causing this error message?
what partition scheme are you using? guid/mbr?

GUID/MBR hybrid, i.e. GUID set up by Apple's DiskUtility. That hasn't changed, neither should there have been any changes in the Mac OS X partition.

So all I can think is that some boot blocks got messed with, and that reinstalling Chameleon does not properly rewrite them. The OS X partition boots fine with a home-spun boot-132 CD, so I know the OS itself is bootable and working (there's only a small subset of the required kexts on the CD).

I know somewhere in the vast expanse of the internet I read something about what boot blocks need to be written where to get things to boot where someone had an issue dual booting, but I don't seem to be able to find that post again, not do I remember on which site it was...

Ronald

rocksteady

  • Global Moderator
  • Posts: 233
  • Root Down
Re: "Error loading operating system"?
« Reply #3 on: May 09, 2009, 11:53:28 PM »
hmm not sure if i got you right...

are we talking about the same HD but different partitions?
or different HDs?

XP doesn't like GUID and iirc, you could hack your way with a util (gptsync) but i've 'm not sure no idea if it's reliable or not

in any case re-installing boot0/boot1h should fix that, did you try?
Code: [Select]
sudo fdisk -f boot0 -u -y /dev/rdisk0
sudo dd if=boot1h of=/dev/rdisk0s2

best way is to chose different HDs for different OSes, you might find MacGirl's solution interesting (among others)

« Last Edit: May 10, 2009, 12:09:35 AM by rocksteady »
Stop bitching, start coding or documenting or both..

P5Q-EM : Q6600 : 8GB RAM : 8800GT : SATA Drives

rcfa

  • Member
  • Posts: 47
Re: "Error loading operating system"?
« Reply #4 on: May 10, 2009, 12:33:38 AM »
XP doesn't like GUID and iirc, you could hack your way with a util (gptsync) but i've 'm not sure no idea if it's reliable or not

I'm aware of that, which is why I'm playing around to find a way to get it to work.
Have to figure out how to reorder existing partitions in the guid and mbr partition tables, since there's some evidence that XP will properly boot on the fourth partition, now it's on the third.

in any case re-installing boot0/boot1h should fix that, did you try?
Code: [Select]
sudo fdisk -f boot0 -u -y /dev/rdisk0
sudo dd if=boot1h of=/dev/rdisk0s2

Thanks, that were exactly the lines I was looking for. I cd-ed into /usr/standalone/i386/ first, or do these commands magically know where to get the files from?

I wish Chameleon would do this when it's being (re)installed. Is that a bug, oversight, or is there a good reason for that not being part of the Chameleon postinstall scripts?

best way is to chose different HDs for different OSes, you might find MacGirl's solution interesting (among others)

I'm aware of some of these, but since I'm working with a EeePC 1000HE netbook (although upgraded with a 500GB harddisk), more than one drive isn't an option, or else I lose precisely the portability that made me buy one of these in the first place. If I want to schlepp stuff around, I could use my 15" MacBook Pro, and if/when I buy a new desktop, it's highly-likely going to be a Mac, too, for a whole bunch of reasons.
So the hackintosh approach is for my purposes interesting where Apple has no offerings. I may think of a Atom330/ION/4GB+ nettop setup once such a machine is available. Would be the ideal low-power home server....

Ronald

rocksteady

  • Global Moderator
  • Posts: 233
  • Root Down
Re: "Error loading operating system"?
« Reply #5 on: May 10, 2009, 01:47:48 AM »
hi ronald,
Thanks, that were exactly the lines I was looking for. I cd-ed into /usr/standalone/i386/ first, or do these commands magically know where to get the files from?
magic? what magic? 
always cd to the directory  ;)
btw, you can find the (manual) installation instructions in the doc folder:



I wish Chameleon would do this when it's being (re)installed.
it does (if you uncheck the rest of the options):

 

Is that a bug, oversight, or is there a good reason for that not being part of the Chameleon postinstall scripts?
i guess only the developers can answer that,
given its RC status, i find it pretty impressive anyway



but since I'm working with a EeePC 1000HE netbook (although upgraded with a 500GB harddisk), more than one drive isn't an option, or else I lose precisely the portability that made me buy one of these in the first place.
ah i see,
did you try to go for MBR where XP would feel like home and OS X could be installed with a hacked retail dvd..?
can't help much with win-specific stuff as i don't (have to) use them myself


If I want to schlepp stuff around, I could use my 15" MacBook Pro, and if/when I buy a new desktop, it's highly-likely going to be a Mac, too, for a whole bunch of reasons.
So the hackintosh approach is for my purposes interesting where Apple has no offerings. I may think of a Atom330/ION/4GB+ nettop setup once such a machine is available. Would be the ideal low-power home server....
nice style,
whatever works for someone, i find that having a real MacBook Pro + a netbook, is a complete waste of (my) time as nothing is more portable than my hacked ipod (if/when i want to go small)

truth is that osX86 has come a long way and it's a matter or swapping a couple cd/dvds, shuffle a few drivers around and in half an hour it runs on cheap hardware. then again when something becomes easy most people miss the fun part. i did a guide @ insanelymac and most people think that it'll turn their PCs into macs...

i started messing with osX86 about a month ago, just for kicks, to run x.5 on a cheap box that was lying around.
i administer a small army of macs @ work so i'm not looking for cheap frills. as you said, if you want a mac get a real one, otherwise just have fun with the hack :)
Stop bitching, start coding or documenting or both..

P5Q-EM : Q6600 : 8GB RAM : 8800GT : SATA Drives

rcfa

  • Member
  • Posts: 47
Re: "Error loading operating system"?
« Reply #6 on: May 10, 2009, 07:56:17 AM »
hi ronald,
Thanks, that were exactly the lines I was looking for. I cd-ed into /usr/standalone/i386/ first, or do these commands magically know where to get the files from?
magic? what magic? 
always cd to the directory  ;)
btw, you can find the (manual) installation instructions in the doc folder:

I guess, I'll have to consult that again, I may have deleted anything but the installer package a while ago...


I wish Chameleon would do this when it's being (re)installed.
it does (if you uncheck the rest of the options):


Hehe, that's just the inverse of what I had checked. I guess it worked so far, because initially I did the regular install, but then decided I want to keep the OS X partition as "vanilla" as possible, and moved towards using an HFS+ formatted EFI partition. So the first attempt must have written the proper boot blocks (which then in the sequence of messing with XP were overwritten).
Then reinstalling the EFI Chameleon install doesn't seem to write the boot blocks. Hence the confusion.
Now I'm wiser ;)

Anyway, I'll stick with GUID, since I use 99% MacOS, WinXP is basically only there, because
a) I have a license and no computer to run it on
b) my car's factory repair/maintenance manual is in eBahn format, thus only accessible from windows.
If I can't get dual boot to work eventually, I just will have to do with Parallels or VirtualBox (if they ever start supporting a native partition instead of a virtual drive).
There are some people who report success with getting XP to run in a Chameleon dual-boot setup, so I hope to eventually be one of them, too.

Time to continue hacking on the Windows stuff ;) Thanks for your help!

Ronald

distantstorm

  • Entrant
  • Posts: 7
Re: "Error loading operating system"?
« Reply #7 on: May 10, 2009, 01:32:29 PM »
For backing up, try Clonezilla. It has support for backing up HFS+ and recognises GUID scheme (as well as all the usual Windows FAT, NTFS, MBR scheme etc) It's a bootable CD and not the prettiest UI but for folk happy messing with EFI commands etc it should be fairly straightforward. Remember and select the option that includes HFS when using it (-f2 i think). The only caveat is that currently it doesn't support WRITING the image to HFS formatted disks and will stop with an error. I have an NTFS formatted external drive that I keep all my backup images to so it's not been a problem for me.

I've successfully full disk cloned my OSX drive, including the EFI partition and restored it no problem and Chameleon was restored to EFI perfectly with all Kexts, Boot.plist intact. I haven't done it with a Hybrid scheme such as yours or tried just backing up EFI partition on it's own but I would suggest it as an option to try. I don't think it would do you any harm to have an image of your whole disk once it's working. But I'm a bit of an imaging addict when I get things working. Hangover from my Windows days.

steve

rcfa

  • Member
  • Posts: 47
Re: "Error loading operating system"?
« Reply #8 on: May 10, 2009, 06:11:08 PM »
Yup, a disk image is in my future, first need to get another drive though. I may end up just using dd to dump the entire raw device into a file or a disk of the same size/type.
But I'll have a look at the program you mentioned. Thanks!

rocksteady

  • Global Moderator
  • Posts: 233
  • Root Down
Re: "Error loading operating system"?
« Reply #9 on: May 12, 2009, 03:12:48 AM »
For disk cloning you may also try CCC, I'm using it @work for ages, never had a single glitch
Stop bitching, start coding or documenting or both..

P5Q-EM : Q6600 : 8GB RAM : 8800GT : SATA Drives

rcfa

  • Member
  • Posts: 47
Re: "Error loading operating system"?
« Reply #10 on: May 12, 2009, 08:54:28 AM »
For disk cloning you may also try CCC, I'm using it @work for ages, never had a single glitch

I know about it, but isn't that more of a file system cloner than a disk cloner? i.e. it seems to be more or less what asr and ditto are doing, just with a nicer interface.

At this point, I'm a bit annoyed that the gpt tool Apple supplies doesn't seem to be half as functional as fdisk.
In fdisk I can modify the partition table at will, gpt doesn't let me do anything, except print the partition table.
diskutility lacks fine grained controll, and parted has it's own set of problems, like messing up flags.

Disk partitioning seems to be in a pretty sorry state, at least for GUID partitioned drives. I had to jump through hoops backwards to get what I wanted, which I now finally seem to have. (At least at a partition table level. That doesn't mean that XP will be booting yet, but it's a step forward...)

Ronald

rocksteady

  • Global Moderator
  • Posts: 233
  • Root Down
Re: "Error loading operating system"?
« Reply #11 on: May 12, 2009, 12:55:23 PM »
yeah all gui frontends rely on the built-in tools, just thought to suggest it to you

btw, asr can do some really slick things. If you start working with disk images give cCC a try. Keep it or toss it but it's not just a nice gui (actually it's ugly & ad-supported but it's free), the guy behind it knows what he's doing

as for editing GUID tables: it sucks big time at the moment  >:(
« Last Edit: May 12, 2009, 01:19:00 PM by rocksteady »
Stop bitching, start coding or documenting or both..

P5Q-EM : Q6600 : 8GB RAM : 8800GT : SATA Drives