Posts Tagged ‘Linux’

Fun with LILO and rEFIt: Resolving Boot Errors After an Upgrade

Sunday, May 9th, 2010

When debian is the only OS running on a machine, running apt-get update and apt-get upgrade works well.

Under my Mac/Debian dual boot setup, though, upgrading has always been something of a crap shoot.

The most recent problem was this error, after an upgrade and a reboot:

EBDA is big; kernel setup stack overlaps LILO second stage

This solution was closest to my situation, and although the advice was helpful, I managed to fix mine with fewer steps:

  1. Boot the Mac partition (which, fortunately, was still working)
  2. Run Terminal, and use the diskutil list command to find out where Linux was installed on hard drive (in my setup, it was /dev/sda3)
  3. Reboot, this time with the Debian install disc I used to install Debian originally
  4. Choose Advance Options -> Rescue Mode -> Shell mounted on /dev/sda3 (this saved me the effort of doing all the mounting described in steps 1 through 5 of the ubuntu forum solution)
  5. Inspect /etc/lilo.conf (it looked correct, so I didn’t make and edits)
  6. Update lilo: /sbin/lilo -v
  7. Reboot (my mistake was doing this from the rescue mode shell, when I should have exited and rebooted out of the installer)

This time, when I chose Linux from the rEFIt menu, the kernal loaded normally (/dev/sda3 was scanned because of an improper unmount, or lack thereof, but fsck did its job without incident), and my linux partition was usable again.

How to Install Debian as a Dual-Boot (with Mac OS X) on the Mac Mini

Monday, February 16th, 2009

Update: March 31, 2013 — I’ve since ditched this setup in favor of running ubuntu with a lightweight window manager under VirtualBox instead.

Inspired by this how to guide, I recently installed Debian 5.0 (a.k.a. “Lenny“) on a new Mac Mini.

My experience was basically the same, with a few key differences (highlighted):

  • Started MacOS X
  • Ran BootCamp (my version of OS X already had BootCamp installed), and created a 32 gb sized partition for “Windows” (BootCamp assumes the partition is for XP). As per the original instructions, I quit BootCamp when it prompted for the Windows XP CD.
  • Downloaded and installed rEFIt. Piece of cake.
  • Downloaded and burned the i386 netinst CD version of “Lenny“.
  • Put the netinst CD into the drive and rebooted; the next time the Mini started, I saw the rEFIt menu.
  • At the rEFIt menu, I scrolled to the “partition map tool” and, as suggested, copied the GPT partition map into the MBR. It left me with three partitions:
    1. Boot
    2. Mac OS X
    3. Empty (where Linux is going to go)
  • Exited the partition map tool and booted Linux from CD; the familiar Debian install screen appeared. Two critical steps followed.
  • At Debian’s disk partition step, I chose “manual” (using any other option would have given the Debian installer the all-clear to wipe out Mac OS X from the hard drive). Here I re-sized partition #3 to 31 gb, and created a fourth partition of 1 gb for swap. The final table was:
    1. Boot
    2. Mac OS X
    3. ext3 mounted as “/” with the bootable flag on
    4. swap
  • The installer continued, but when it prompted me to install GRUB, I hit “Go Back” and installed LILO instead (the original guide says install GRUB and then edit it manually; I simply could not get that to work, so I tried LILO instead, and LILO worked), allowing LILO to write to the Master Boot Record (MBR)
  • After the Debian install finished, I rebooted, and saw the rEFIt menu offered two choices: start Mac OS X or Linux