GRUB bootloader issue

I'm actually new to Solaris on x86 (worked with Cadence on Ultra Sparc).
I succesfully installed Solaris 10 on the slave HD of a 'Packard Bell' Desktop computer.
On the master I have Fedora installed.
Currently I can only boot Solaris via the BIOS menu, by selecting the slave as boot device.
When I add the proper code in the Fedora bootloader:
title Solaris 10 8/07 s10x_u4wos_12b X86
root (hd1,0,a)
kernel /platform/i86pc/multiboot
module /platform/i86pc/boot_archive
I receive GRUB error 17.
Is there a way I can point from the MBR to the slave boot record?
Or should I simply physically switch the devices and add Fedora
to the Solaris menu.lst?
Otherwise Solaris 10 works excellent. Up until now it's the only
OS from the many I've tried where the correct screen size was selected automatically.

Hi
It's not (yet) possible for a Linux version of GRUB to boot Solaris. The problem is that GRUB needs to have a small amount of ability to read the filesystem being booted (when using 'kernel' etc, rather thasn chain booting). Sun has added the required changes, and submitted them to be folded into the GRUB source. However, this may take some time since GRUB 2 is being developed and, from a GNU perspective, the Sun extensions were Not Invented Here.
So, either you need to boot from Solaris GRUB, of you need to chain boot Solaris GRUB from Fedora GRUB.
Paul

Similar Messages

  • Solaris 10x86 and grub, bootloading and how to add new disk

    In the latest version of Solaris 10 (1/06) it now uses grub to do the bootloading.
    I cannot get grub to create a new partition on my new second disk.
    BIOS sees my disk.
    At first "format" would not see the disk. I ran "reboot -- -r" to fix this.
    Now, I go into the grub shell with /boot/grub/bin/grub and attempt to run "partnew" -- the grub command to add partitions. It fails.
    One of the arguments for 'partnew' is TYPE. However, I've googled my fingers to death, and nowhere can I find out what number I should use in type. The grub docs only say it should be a number between 0 and 0xff.
    I want to multi-partition the second disk for linux/solaris/and or windows.
    What if I take out disk1 containing solaris, move disk2 into that slot, then insert the windows installation cd and let it partition the disk.? Then put it back in slot 2....

    Why are you trying to partition the disk with 'grub'? Since you've completed the installtion you can use 'fdisk' directly.
    However I wouldn't bother. I'd just let the installer of whatever OS you're putting on do the right thing. Either Linux or Windows could partition it as you're installing.
    Then you could go back and edit grub if you needed to so that they would boot properly.
    This page talks about multibooting some different operating systems. You dont need to use it as a recipe, but you might find some of the concepts handy.
    http://www.sun.com/bigadmin/features/articles/multiboot_laptop.html
    Darren

  • Found a FIX for MBR and GRUB GRUB2 ISSUES!

    I like many other have had issues with Linux (Ubuntu), and the MBR modification and GRUB.
    My tragedy went something like this. I wanted to install Ubuntu on a netbook without a CD Drive.
    I put a Live Ubuntu CD in my computer and booted up.
    I connected a Sata drive through my esata port.
    I proceeded to install Ubuntu on the external drive.
    Drive would not work on netbook,
    Compute would not boot to windows 7.
    What really happened:
    When I installed Ubuntu on the external drive, GRUB was installed on my primary hard drive on my laptop.
    If the external drive was attached to the laptop, GRUB came up and I could choose what I wanted to boot to (windows worked fine). But, if that drive was not connected, it gave the error "Device not present", that was it.
    DONT DO THIS:
    I tried to use a windows 7 dvd from another computer to "repair", didn't work, I think it recognized it was an OEM install.
    I tried to use an XP install disk, got blue screen of death, and the computer would not boot, not even with external sata drive connected (now I was starting to sweat)
    What worked:
    I used the live Ubuntu CD to access my windows drive and did an immediate backup of all important files, all 112GB worth...
    I saw I could purchase a windows 7 CD to repair my computer for about $10 (tempting but didn't)
    Solution:
    I want to my wifes computer: Start->Control Panel->System Security (click: Backup Your Computer)
    On the left hand column click: Create System Repair Disk
    Create Disk.
    Took the disk to my laptop and booted it. I was concerned that It said Toshiba, not Lenovo. I clicked on the language and it noticed the MBR was not correct and asked if it could repair it? I said Yes, then it gave me the option to reboot. I rebooted and removed the CD. Everything is working fine!
    I hope this helps someone sort through the sea of informaton concerning GRUB and the MBR file. This solution is for so  many people, like myself have no windows 7 disk to boot from.
    Lewis.

    I should also point out that all the files of my website are in the root folder of my FTP, not in root/Website_Folder_Here folder.

  • Mac Pro 2007 and the Bootloader issues with EFI

    So, I've been working to get Arch on an old mac pro that I'm currently using for work.  This is the oldest of the old Mac Pros ever made, and uses 32-bit EFI and has 32GB of ram.  This means that I need to use a 64-bit OS, but am having immense difficulty getting it to boot.
    I am installing to /dev/sdb, and /dev/sda contains the EFI partition and Mac OSX.
    I'm currently using rEFInd liveCD to find and boot the .efi files.  I can select and boot into grub2 (which is stored completely on the EFI partition on /dev/sda), and have been able configure it so that it can find the vmlinuz-linux and initrd successfully (both stored on /dev/sdb2), but whenever I try to boot it, I get the following message:
    "No suitable video mode found.
    Booting in blind mode"
    At which time no keyboard input is accepted, and I have to reboot and try again.  I know that the system uses UGA, and I tried adding that to grub.conf, but no results. Even with grub-mkconfig, I cannot get it to boot without receiving that error message. 
    How can I get my system to boot correctly?  I've been working on this for about a week, so all help is appreciated.
    Here was my process.
    Steps:
    1. Tried to install from new arch linux media.  The media would not boot, no matter what I tried. Changed to 64-bit Archbang live-cd. Booted fine. 
    2. Created a GPT disk with a protective MBR on /dev/sdb (/dev/sda contains the EFI fat32 partition and the macintosh OS).
    3. Installed Archbang onto GPT disk on /dev/sdb3, as /root /dev/sdb4 as /home, /dev/sdb2 as /boot and /dev/sda1 as /boot/efi
    4. Chrooted from the LiveCD into the disk, updated pacman, installed grub-efi-i386, built the sysimage and kernel (stored in /boot on /dev/sdb2), and grub mkconfig storing all of it to the EFI partition at /boot/efi/EFI/grub
    Gdisk prints the following for /dev/sdb
    Disk /dev/sdb: 976773168 sectors, 465.8 GiB
    Logical sector size: 512 bytes
    Disk identifier (GUID): 43A3E85A-F473-468C-B361-6B3383AA65C5
    Partition table holds up to 128 entries
    First usable sector is 34, last usable sector is 976773134
    Partitions will be aligned on 2048-sector boundaries
    Total free space is 4077 sectors (2.0 MiB)
    Number  Start (sector)    End (sector)  Size       Code  Name
       1            4096          413695   200.0 MiB   AF00  Apple HFS/HFS+           
       2          413696          618495   100.0 MiB   8300  Linux filesystem         /boot
       3          618496       164458495   78.1 GiB    8300  Linux filesystem       /
       4       164458496       976773119   387.3 GiB   8300  Linux filesystem   /home

    bsilbaugh wrote:In regards to the step 1 you described in your post, you mentioned difficulty booting "arch linux media". What did you mean by "arch linux media"? Is this a CD you burned containing the latest Arch Linux ISO? If so, did you verify the checksum of the iso image you downloaded, and that it burned correctly to CD?
    Yes. I verified that the 2012.09.07 official Arch Linux installation iso burned correctly and that the checksum was correct.  What happened was that the disc would attempt to load after selecting it in the Mac bootloader, and then I would get a black screen with the following
    " 1.
      2.
    Please select an option:
    At this point the keyboard was unresponsive, and not recognized by the USB bus (I use a backlit keyboard, and it was not lit).  So I changed strategies.
    WonderWoofy wrote:You say that you need to use a 64-bit OS, don't you mean 32-bit.
    No, I mean that I have to be able to use 32 Gigabytes of RAM with any application I am using, which cannot be done with a 32-bit OS.  This system is used for Memory intensive 3D images and volumes.
    WonderWoofy wrote:A 32-bit EFI is incapable of booting a 64-bit OS.  I should know, I have a late 2006 MacBook and spent quite a bit of time banging my head against the wall over this.  If you want to use a 64-bit OS, you have to use bios emulation.  This is in fact why those other distros you mention above boot correctly.  Many Mac users tend to (incorrectly) call this mode bootcamp.
    Can you provide a link with a procedure or more information about booting in BIOS mode?  I think all the places I looked I ignored this because I wasn't sure what the difference was.
    WonderWoofy wrote:I think with the new install discs and macs, you have to remove the UEFI.  Especially in your case where you need a 32-bit uefi, as this is not an option on the installer.  I tried booting an installer on my macbook, and it would not go.  These forums were filled with these threads a couple months ago, and the.redikulus.rat pointed everyone to a page in our wiki to remove the UEFI.  Personally I did not try I because my mac is not my main machine anymore, but it is reported to work.
    You know you can install Arch from any live cd or other distro now that it is a chroot install method.  You could before, if you didn't use the AIF, but now there is no choice.  I think it would be especially easy with the archbang live cd, as I think that they use the same repositories.  So you should be able to install the arch-install-scripts package.  If not, you could always simply fire up links and download the package and manually install it.  Then you should be able to proceed like normal.
    I am unclear what you mean with removing the UEFI.  Do you mean removing it from the kernel or the bootloader?  Please, point me to this page used by the.redikulus.rat.  As for the second half, I have already installed via chroot, and the difficulty is getting it to boot from anywhere.

  • [Solved] Grub Startup Issue

    So after my last post and finally getting it booted I ran into more issued.
    Turns out apparently nVidia isn't a big fan of EFI booting so I've been trying to switch back to BIOS booting.
    I uninstalled grub-efi and install grub-bios.
    I put it on /dev/sda2, now when I start up my computer I get this from grub.
    http://i.imgur.com/tyNHHz8.jpg?1
    Been using linux a while but this is a new one to me.
    Last edited by orthanc (2013-06-23 18:36:42)

    Ah yes sorry, I forgot to mention, once I installed the nvidia drivers I no longer need the nomodeset kernel option. I turned on debug at one point and it looked like neoveu was having issues with a frame buffer. With the binary blob it booted fine.
    I don't recall exactly where but after some googling it I read that some devices are initialized differently under EFI and nvidia's drivers don't always work with it.
    Alright, I got EFI booting back and it is sooo much faster than bios mode.
    The error I am getting with nvidia is 'could not open the device file /dev/nvidia0 (Input/output error)' when I tried to start X. I tried a couple things from here but none seemed to help.
    Below is a couple things from dmesg aswell.
    [ 24.793125] NVRM: failed to copy vbios to system memeory.
    [ 24.793387] NVRM: RmInitAdapter failed! (0x30:0ffffffff:711)
    [ 24.793398] NVRM: rm_init_adapter(0) failed
    Edit: https://wiki.archlinux.org/index.php/Ma … _7,1#Video and https://bbs.archlinux.org/viewtopic.php?id=162289&p=2 both talk about nvidia not working in EFI mode. I'm going to try again to get legacy mode working.
    Last edited by orthanc (2013-06-22 15:43:11)

  • GRUB UEFI Issues

    First off, let me preface this by saying I've read and tried a significant number of tutorials on this and always run into the same/similar problems.  Sorry for the verbosity but I've been wrestling with this for way longer than I should and could really use some help.
    Relevant portion of the layout as found by lsblk -
    sdc
    --> sdc1  8:33 0 100M  0  part
    --> sdc2  8:34 0   80G  0  part
    --> sdc3  8:35 0   80G  0  part
    --> sdc4  8:36 0     8G  0  part
    My goal is to use the UEFI boot partition required (sdc1) to successfully setup GRUB so I can boot into arch linux.  I'm using the most recent stable/core distribution available on the http download mirrors, then installing it onto a flash drive as directed in the tutorial.
    When I follow this guide, I get to the GRUB install section and type
    # mount -t efivarfs efivarfs /sys/firmware/efi/efivars
    This produces errors both in and out of arch-chroot (from / to /mnt) while installing, saying that there is no such directory.  I've read a lot of posts on this including this, this, and this.  It has been an incredibly frustrating experience as it seems no matter how many times I nuke the partitions and restart this, I always end up with the same result.
    Just to be clear, efivarfs and efivars both give errors of directory not found or does not exist.  In many cases, the /sys directory exists, but does not contain the subdir firmware; this occurs both in and out of chroot as walked through in the very first link above.  Also, just for clarity sake, this is what cgdisk shows for sdc:
    Part#  Size      Partition Type      Partition Name
    1       100 MiB  Linux Filesystem
    2         80 GiB  Linux Filesystem arch
    3         80 GiB  Linux Filesystem
    4           8 GiB  Linux Filesystem swap
    Finally, when I do parted -l I find that sdc1 is fat32, sdc2 and sdc3 are both ext4, and sdc4 is linux-swap(v1) with no partitions having any flags set.  When I boot up, the prompt says missing boot loader if I push return, but otherwise gives a blank screen with a blinking white bar.  I've tried installing and nuking/repartitioning sdc multiple times with the same result.  So far, I have not been able to get GRUB to boot into anything no matter what I try.  Similar things happen when I tried to install syslinux instead.  Everything seems to revolve around these *.efi files that never show up in the installation and don't seem to exist when I search for them.  I've also read that there are a lot of known problems with installing GRUB to UEFI systems, but no solutions that fix the fact that these efi folders and files are not even there to use.  I also cannot boot into the EFI shell (when it is available in /) by going into the bios and selecting boot to EFI from filesystem as described here.  I download, successfully unzip Shell2.zip into /Shell2/{filenames} but again, no success.
    Lastly, I also consistently get errors stating "The backup GPT table is not ad the end of the disk"; should I have moved sdc1 to the end of the disk, or is this talking about something else?
    Thanks in advance for any help you can provide in getting Arch to actually boot and GRUB to even just show up...

    IMHO, the best way to force a computer to boot in EFI mode is to use an EFI-only boot manager or boot loader, such as rEFInd, gummiboot, or ELILO. Prepare a boot medium (a USB flash drive, say) with your chosen EFI boot program and boot it. If you boot through to your chosen Linux without rebooting, you can be sure you're in EFI mode. (One caveat: rEFInd does support chainloading to a BIOS boot loader, but the ability to do so is disabled with the default configuration file.) Checking for the presence of the /sys/firmware/efi directory will verify that you're in EFI mode.
    One big problem with many Linux installation media is that they support multiple boot modes. On the face of it, this sounds like a good idea; it makes the boot media universal (or as near to it as can be managed), which minimizes the odds of user confusion. Look deeper, though, and it actually causes problems, because so many EFIs are unclear about their boot paths. The boot options ("UEFI," "UEFI/Legacy", "CSM," etc.) are often interpreted as priorities or suggestions, not restrictions. Thus, you may think that you'll be booting in EFI mode, but if the computer has problems with the EFI-mode boot loader, the firmware will "helpfully" fall back on a BIOS/CSM/legacy-mode boot, and the Linux tool you're booting won't present any big flashing signs to inform you that you booted in the wrong mode. This problem is exacerbated by the fact that so many Linux installers have twisted themselves into shapes that make pretzels looks straight in order to boot in so many different ways (EFI vs. BIOS, CD-R vs. USB flash drive). This makes it hard for the firmware to figure out what to do with them, or to interpret a desired boot mode as invalid for that medium.

  • [SOLVED]: Grub setup issue

    Hi Arch community !
    First, please excuse my (very) (bad) english...
    I'm installing the Arch on a new machine, but in the grub installation step, something is blocking me.
    The output says
    grub> root (hd0,2)
    Filesystem type unknown, partition type 0x82
    grub> setup (hd0,3)
    Error 17: Cannot mount selected partition
    Huh... is really 0x82 an unknown type ? There might be a problem somewhere...
    So i look my fdisk :
    # fdisk -l
    /dev/sda1 * 946 25261 195318270 7 HPFS/NTFS
    /dev/sda2 1 945 7590681 7 HPFS/NTFS
    /dev/sda3 25262 25784 4200997+ 82 Linux swap / Solaris
    /dev/sda4 25785 48641 183598852+ 83 Linux
    Partition table entries are not in disk order
    I agree with this... one redmond, one redmond/backup, one swap and my /.
    And they are not in disk order, ok.
    I check my menu.lst with thoses informations :
    title Arch Linux
    root (hd0,2)
    kernel /boot/vmlinuz26 root=/dev/sda3 ro
    initrd /boot/kernel26.img
    It seems to me to be all right ! Where is the problem ?
    Do you maybe have an idea ?
    Last edited by F-eeks (2007-10-09 21:52:59)

    Thank you peart
    You are right, (hd0,2) seems to be my swap partition, and (hd0,3) my ext2 one.
    I did the change, bu grub is always trying
    root (hd0,2)
    setup (hd0,3)
    with the same errors... strange
    SOLVED : That is allright after re-install...
    thank you quand même !
    Last edited by F-eeks (2007-10-09 21:52:40)

  • GRUB pause issue

    I have a computer with two hard drives. Solaris 10 is on hd0 and Windows XP is on hd1.
    The menu.lst entry for Windows looks something like this:
    title Windows
    rootnoverify (hd1,0)
    chainloader +1
    My problem is that when you select this option a black screen comes up with a little smiley face in the corner. You need to press a key to get Windows XP going. How do you skip this screen?
    | : > | (The smiley face looks like this except it's standing up)
    Is it even a smiley face? It kinda looks like Tux.

    The smiley u r talkin abt is an ASCII character set which i belive is coming from the BIOS setting.
    This does not seem to be a Solaris problem.
    Enabling/Disabling the ACPI function in BIOS may solve the need to press a key to boot into Windows.

  • [x86_64] Let's fix grub issues - help wanted

    We have some issues with our grub bootloader. Lilo is working well but need to be recalled for every kernel update. Grub2 is not ready for x86_64 and still under heavy developement. So we should get grub (legacy) working. Arch32 is not patching it at all. It looks like we need to do this now.
    I myself have two systems: one with GeForce 6100 chipset (nforce4) booting from IDE hard disc very well. No issues there. The other system with Uli1695 chipset booting form IDE or SATA installs grub fine but cannot find the right partition when booting, even not in grub-shell. I cannot play to much with it as it is my main system.
    Read more on the mailing lists: http://savannah.gnu.org/mail/?group=grub
    You can base any testing package on this PKGBUILD
    The Package has to be build on i686 (Arch32) as it will not compile on x86_64 natively.
    So I've tried to collect all important patches and it's up to you to test them and report which will help!
    CLFS http://cross-lfs.org/view/svn/x86_64/bo … build.html
    1) http://cross-lfs.org/files/patches/svn/ … es-1.patch
    Description: Contains various fixes and enhancements
    Graphics mode support
    Fixes for Raid Support
    XFS Filesystem Boot Freeze Fixes
    Removed 2GB Memory Limitation
    Freebsd support
    Fixes for initrd support
    Grub installation Fixes
    Linux 2.6 geometry Fixes
    Intel Mac Support
    Autoconf and aclocal updates
    2) http://cross-lfs.org/files/patches/svn/ … ap-1.patch
    Description: This patch fixes the following issues on x86_64
    1) malloc'd pages seem to lack the execute bit on x86_64;
    2) grub seems to use some stack pointer diversion to malloc'd pages;
    3) nested functions execute data on the stack;
    4) this causes a segfault (at least on my machine)
    Frugalware http://darcs.frugalware.org/darcsweb/da … /base/grub
    They patch for better network support, cd support and a graphical menu.
    Gentoo
    http://www.gentoo.org/cgi-bin/viewcvs.c … iew=markup
    http://ftp.ucsb.edu/pub/mirrors/linux/g … .2.tar.bz2
    The patchset includes fixes for: splash, PIC, bounced checks, unsigned adresses, i2o raid, nxstac, netboot-pic, reiser4, netboot-gcc4.
    So user with grub issues - come on - test the patches and report if you got  it working for you :!:

    @gs:judd is mainating the installer. if you wanna see something new in there open a featurew request in flyspray ;-)
    I will checkin the fixed grub package. Then I will make new isos for a (hopefully) short testing period.
    @gs, here are some small fixes you can locally test if they fix your issues:
    Submitted By: Jim Gifford <jim>
    Date: 07-14-2006
    Initial Package Version: 0.97
    Upstream Status: Unknown
    Origin: Grub Bug Report - http://savannah.gnu.org/bugs/?func=detailitem&item_id=11312
    Description: This patch fixes the following issues on x86_64
    1) malloc'd pages seem to lack the execute bit on x86_64;
    2) grub seems to use some stack pointer diversion to malloc'd pages;
    3) nested functions execute data on the stack;
    4) this causes a segfault (at least on my machine)
    diff -Naur grub-0.97.orig/grub/asmstub.c grub-0.97/grub/asmstub.c
    --- grub-0.97.orig/grub/asmstub.c 2005-02-16 12:45:14.000000000 -0800
    +++ grub-0.97/grub/asmstub.c 2006-07-14 12:38:08.305902933 -0700
    @@ -43,6 +43,8 @@
    #include <termios>
    #include <signal>
    +#include <sys>
    +
    #ifdef __linux__
    # include <sys> /* ioctl */
    # if !defined(__GLIBC__) ||
    @@ -142,14 +144,25 @@
    assert (grub_scratch_mem == 0);
    - scratch = malloc (0x100000 + EXTENDED_MEMSIZE + 15);
    + scratch = mmap(NULL,
    + 0x100000 + EXTENDED_MEMSIZE + 15,
    + PROT_EXEC | PROT_READ | PROT_WRITE,
    + MAP_PRIVATE | MAP_GROWSDOWN | MAP_ANONYMOUS | MAP_32BIT,
    + -1,
    + 0);
    +
    assert (scratch);
    grub_scratch_mem = (char *) ((((int) scratch) >> 4) << 4);
    /* FIXME: simulate the memory holes using mprot, if available. */
    assert (disks == 0);
    - disks = malloc (NUM_DISKS * sizeof (*disks));
    + disks = mmap(NULL,
    + NUM_DISKS * sizeof (*disks),
    + PROT_EXEC | PROT_READ | PROT_WRITE,
    + MAP_PRIVATE | MAP_GROWSDOWN | MAP_ANONYMOUS | MAP_32BIT,
    + -1,
    + 0);
    assert (disks);
    /* Initialize DISKS. */
    for (i = 0; i < NUM_DISKS; i++)
    @@ -215,9 +228,9 @@
    /* Release memory. */
    restore_device_map (device_map);
    device_map = 0;
    - free (disks);
    + munmap(disks, NUM_DISKS * sizeof (*disks));
    disks = 0;
    - free (scratch);
    + munmap(scratch, 0x100000 + EXTENDED_MEMSIZE + 15);
    grub_scratch_mem = 0;
    if (serial_device)
    or this one, a part from http://ftp.jg555.com/grub-0.97-disk_geometry-2.patch
    diff -Naur grub-0.97.orig/grub/asmstub.c grub-0.97/grub/asmstub.c
    --- grub-0.97.orig/grub/asmstub.c 2005-02-16 12:45:14.000000000 -0800
    +++ grub-0.97/grub/asmstub.c 2006-07-14 12:38:08.305902933 -0700
    @@ -43,6 +43,8 @@
    #include <termios>
    #include <signal>
    +#include <sys>
    +
    #ifdef __linux__
    # include <sys> /* ioctl */
    # if !defined(__GLIBC__) ||
    @@ -142,14 +144,25 @@
    assert (grub_scratch_mem == 0);
    - scratch = malloc (0x100000 + EXTENDED_MEMSIZE + 15);
    + scratch = mmap(NULL,
    + 0x100000 + EXTENDED_MEMSIZE + 15,
    + PROT_EXEC | PROT_READ | PROT_WRITE,
    + MAP_PRIVATE | MAP_GROWSDOWN | MAP_ANONYMOUS | MAP_32BIT,
    + -1,
    + 0);
    +
    assert (scratch);
    grub_scratch_mem = (char *) ((((int) scratch) >> 4) << 4);
    /* FIXME: simulate the memory holes using mprot, if available. */
    assert (disks == 0);
    - disks = malloc (NUM_DISKS * sizeof (*disks));
    + disks = mmap(NULL,
    + NUM_DISKS * sizeof (*disks),
    + PROT_EXEC | PROT_READ | PROT_WRITE,
    + MAP_PRIVATE | MAP_GROWSDOWN | MAP_ANONYMOUS | MAP_32BIT,
    + -1,
    + 0);
    assert (disks);
    /* Initialize DISKS. */
    for (i = 0; i < NUM_DISKS; i++)
    @@ -215,9 +228,9 @@
    /* Release memory. */
    restore_device_map (device_map);
    device_map = 0;
    - free (disks);
    + munmap(disks, NUM_DISKS * sizeof (*disks));
    disks = 0;
    - free (scratch);
    + munmap(scratch, 0x100000 + EXTENDED_MEMSIZE + 15);
    grub_scratch_mem = 0;
    if (serial_device)
    diff -Naur grub-0.97.orig/lib/device.c grub-0.97/lib/device.c
    --- grub-0.97.orig/lib/device.c 2005-03-27 15:14:25.000000000 -0800
    +++ grub-0.97/lib/device.c 2006-07-14 12:37:02.523614144 -0700
    @@ -131,6 +131,152 @@
    #include <shared>
    #include <device>
    +#if defined(__linux__)
    +/* The 2.6 kernel has removed all of the geometry handling for IDE drives
    + * that did fixups for LBA, etc. This means that the geometry we get
    + * with the ioctl has a good chance of being wrong. So, we get to
    + * also know about partition tables and try to read what the geometry
    + * is there. *grumble* Very closely based on code from cfdisk
    + */
    +static void get_kernel_geometry(int fd, long long *cyl, int *heads, int *sectors) {
    + struct hd_geometry hdg;
    +
    + if (ioctl (fd, HDIO_GETGEO, &hdg))
    + return;
    +
    + *cyl = hdg.cylinders;
    + *heads = hdg.heads;
    + *sectors = hdg.sectors;
    +}
    +
    +struct partition {
    + unsigned char boot_ind; /* 0x80 - active */
    + unsigned char head; /* starting head */
    + unsigned char sector; /* starting sector */
    + unsigned char cyl; /* starting cylinder */
    + unsigned char sys_ind; /* What partition type */
    + unsigned char end_head; /* end head */
    + unsigned char end_sector; /* end sector */
    + unsigned char end_cyl; /* end cylinder */
    + unsigned char start4[4]; /* starting sector counting from 0 */
    + unsigned char size4[4]; /* nr of sectors in partition */
    +};
    +
    +#define ALIGNMENT 2
    +typedef union {
    + struct {
    + unsigned char align[ALIGNMENT];
    + unsigned char b[SECTOR_SIZE];
    + } c;
    + struct {
    + unsigned char align[ALIGNMENT];
    + unsigned char buffer[0x1BE];
    + struct partition part[4];
    + unsigned char magicflag[2];
    + } p;
    +} partition_table;
    +
    +#define PART_TABLE_FLAG0 0x55
    +#define PART_TABLE_FLAG1 0xAA
    +
    +static void
    +get_partition_table_geometry(partition_table *bufp, long long *cyl, int *heads,
    + int *sectors) {
    + struct partition *p;
    + int i,h,s,hh,ss;
    + int first = 1;
    + int bad = 0;
    +
    + if (bufp->p.magicflag[0] != PART_TABLE_FLAG0 ||
    + bufp->p.magicflag[1] != PART_TABLE_FLAG1) {
    + /* Matthew Wilcox: slightly friendlier version of
    + fatal(_("Bad signature on partition table"), 3);
    + */
    + fprintf(stderr, "Unknown partition table signaturen");
    + return;
    + }
    +
    + hh = ss = 0;
    + for (i=0; i<4>p.part[i]);
    + if (p->sys_ind != 0) {
    + h = p->end_head + 1;
    + s = (p->end_sector & 077);
    + if (first) {
    + hh = h;
    + ss = s;
    + first = 0;
    + } else if (hh != h || ss != s)
    + bad = 1;
    + }
    + }
    +
    + if (!first && !bad) {
    + *heads = hh;
    + *sectors = ss;
    + }
    +}
    +
    +static long long my_lseek (unsigned int fd, long long offset,
    + unsigned int origin)
    +{
    +#if defined(__linux__) && (!defined(__GLIBC__) ||
    + ((__GLIBC__ < 2) || ((__GLIBC__ == 2) && (__GLIBC_MINOR__ <1>> 32, offset & 0xffffffff, &result, SEEK_SET))
    - errnum = ERR_DEV_VALUES;
    - return 0;
    -#else
    - off_t offset = (off_t) sector * (off_t) SECTOR_SIZE;
    - if (lseek (fd, offset, SEEK_SET) != offset)
    - errnum = ERR_DEV_VALUES;
    - return 0;
    -#endif
    + if (my_lseek(fd, offset, SEEK_SET) != offset)
    + {
    + errnum = ERR_DEV_VALUES;
    + return 0;
    + }
    if (write (fd, buf, size * SECTOR_SIZE) != (size * SECTOR_SIZE))
    diff -Naur grub-0.97.orig/util/grub-install.in grub-0.97/util/grub-install.in
    --- grub-0.97.orig/util/grub-install.in 2004-07-24 11:57:31.000000000 -0700
    +++ grub-0.97/util/grub-install.in 2006-07-14 12:37:02.535613832 -0700
    @@ -336,6 +336,10 @@
    # Create a safe temporary file.
    test -n "$mklog" && log_file=`$mklog`
    + # Before all invocations of the grub shell, call sync to make sure
    + # the raw device is in sync with any bufferring in filesystems.
    + sync
    +
    $grub_shell --batch $no_floppy --device-map=$device_map <<EOF>$log_file
    quit
    EOF
    @@ -450,6 +454,10 @@
    # Create a safe temporary file.
    test -n "$mklog" && log_file=`$mklog`
    +# Before all invocations of the grub shell, call sync to make sure
    +# the raw device is in sync with any bufferring in filesystems.
    +sync
    +
    # Now perform the installation.
    $grub_shell --batch $no_floppy --device-map=$device_map <<EOF>$log_file
    root $root_drive

  • Problems with partitioning and install Grub. Fresh install

    All,
    First post here. I appreciate any help you can offer.
    I am having some problems when installing Arch Linux.
    I am installing Arch on a brand new (3 days old) Toshiba SatelliteC655D-S5300 Laptop.
    Hot sheet can be found at http://cdgenp01.csd.toshiba.com/content … -S5300.pdf.
    I was initially installing from 2011.08.19 x86_64 Core CD but someone suggested using the latest version.
    Now I am installing from 2011.11.13 x86_64 CD burned at 4x (the slowest my burner can go).
    I am able to complete all steps up to installing GRUB, but it fails to install.
    During partitioning I receive a few errors and I believe this is contributing to the issue.
    At first I tried automatic partitioning with 100mb boot, 1024mb swap, 10,000mb / and the rest of 320g for /home. Each partition is ext3 except /boot which is ext2.
    During the automatic partitioning an error briefly occured: /usr/lib/aif/core/libs/lib-blockdevices-filesystems.sh: line 355: !((partition_flag)): command not found.
    After speaking with a friend they suggested manually partitioning and using UUIDs instead.
    1) So far I have removed all partitions, rebooted.
    2) Partitioned using cFdisk. Bootable 100mb parition, 1024mb swap, 15,000mb primary (/), 3000mb logical (/var), and the rest 300949mb logical (/home).
    3) Once I write the changes and quit I reboot.
    4)I go back into the installer and complete steps 1-3.
    5) Go to step 4 and and then manually configure block devices, file systems, or mount points.
    6) I choose the option for uuid and hit ok.
    At this point 3 error messages appear at the bottom:
    /usr/lib/aif/core/libs/lib-ui-interactive.sh: line 602: local: 'part,' : not a valid identifier
    /usr/lib/aif/core/libs/lib-ui-interactive.sh: line 602: local: 'type,' : not a valid identifier
    /usr/lib/aif/core/libs/lib-ui-interactive.sh: line 602: local: 'label,' : not a valid identifier
    (Screenshot: http://i.imgur.com/OHRKo.jpg)
    7) Next it prompts me to add the mount points for each partition set.
    8) Select the partition, the mount point, it asks me for label and any additional opts for mkfs.ext3.
    9) I leave the label and opts field blank. After selecting ok to the opts field I get the same 3 errors as above:
    /usr/lib/aif/core/libs/lib-ui-interactive.sh: line 602: local: 'part,' : not a valid identifier
    /usr/lib/aif/core/libs/lib-ui-interactive.sh: line 602: local: 'type,' : not a valid identifier
    /usr/lib/aif/core/libs/lib-ui-interactive.sh: line 602: local: 'label,' : not a valid identifier
    (Screenshot: http://i.imgur.com/QqkSP.jpg)
    I am able to successfully set a mount point and format each partition. But I receive the same set of 3 errors occur for each partition.
    10) Once I complete the formatting I proceed to step 8, install bootloader.
    It says Generating Grub device map.. This could take a while. Please be patient.
    I receivieve the following error on this screen: /usr/lib/aif/core/libs/lib-blockdevices-filesystems.sh: line 355: !((partition_flag)): command not found.
    (Screenshot: http://i.imgur.com/B5j4K.jpg)
    11) After the error displays it goes to the next screen, before installing grub you must review config file. etc.
    12) I hit ok and then :q the config file. Is there a critical change in the config file that I'm missing?
    13) After closing the file I select which the boot device where the GRUB bootloader will be installed. My only option is /dev/sda. I hit ok
    Then I get the following 2 errors:
    /usr/lib/aif/core/libs/lib-blockdevices-filesystems.sh: line 355: !((partition_flag)): command not found
    /usr/lib/aif/core/libs/lib-blockdevices-filesystems.sh: line 355: !((partition_flag)): command not found
    (Screenshot: http://i.imgur.com/ol840.jpg)
    13) Error installing GRUB. See /dev/tty7 for output. Ok
    14) GRUB was NOT successfully installed. Ok
    I checked out TTY7.
    It shows the installer issuing the following commands in GRUB.
    1) device (hd0,) /dev/sda
         Error 12: Invalid device requested
    2) root (hd0,0)
         Filesystem type is extf2, partition type 0x83
    3) setup (hd0,)
    Checking if "/boot/grub/stage1" exists... no
    Checking if "/grub/stage1" exists... yes
    Checking if "/grub/stage2" exists... yes
    Checking if "/grub/e2fs_stage1_5" exists... yes
    Running "embed /grub/e2fs_stage1_5 (hd0,0)"... failed (this is not fatal)
    Running "embed /grub/e2fs_stage1_5 (hd0,0)"... failed (this is not fatal)
    Running "install /grub/stage1 (hd0,0) /grub/stage2 p /grub/menu.lst "... succeeded
    Done.
    4) quit
    I have tried rebooting from here and using the Arch CD to boot into the existing OS but it does not work.
    I tried grub-install /dev/sda
    I get Probing devices to check BIOS drives. This may take a long time.
    /dev/mapper../dm-0 does not have any corresponding BIOS drive.
    I have tried going into grub and issuing the same commands the install script did.
    Same errors.
    I'm afraid I don't have network access at the moment so I can't get a successful /arc/report-issues to run.
    I hope I've included enough information to start the troubleshooting.
    Let me know if I've missed anything!
    Thanks in advance,
    -Jason
    Last edited by username17 (2011-11-17 22:37:56)

    username17 wrote:I get Probing devices to check BIOS drives. This may take a long time.
    /dev/mapper../dm-0 does not have any corresponding BIOS drive.
    Your drive does not have an MBR to install grub to as it is a GPT disk - which is also not supported under the old GRUB.
    You need to create a small partition at the very beginning of the drive (8MB is plenty) and set the "bios_grub" flag. ie the "BIOS drive" your error refers to.
    You will then need to install the grub2-bios package following the chroot instructions on the grub2 wiki page here: https://wiki.archlinux.org/index.php/GRUB2#Installation
    ** Please note that I found the chroot mounts to be outdated - replace "/tmp/install" with "/mnt" **
    Your alternative solution is to boot a gparted liveCD and prepare your disk as MBR - this will (most likely) destroy all existing data on the disk.

  • Dual boot windows 7+archlinux on separate disks; grub errors. [solved]

    Hello,
    I am very excited to try arch linux, but am having trouble with the
    installation.  My situation is as follows:  I have 3 hard drives: windows 7
    lives on sda and sdb.  I am installing arch on sdc, which is 500GB.
    I partitioned the hard drive as follows (which may look kind of ridiculous,
    but please understand I am new at this):
    sdc1    /boot    1GB    ext2
    sdc2    swap    8GB     swap
    sdc3    /       50GB    ext3
    sdc4    /home   400+GB  ext3
    After some initial issues, I managed to run the installation program
    smoothly, performed the basic configuration, and then went to install grub. I
    scrutinized the grub menu.lst file over and over, and could not find anything
    wrong.  It had the following entry for archlinux:
    title: Arch Linux
    root: (hd2,0)
    kernel: /vmlinuz26 root=/dev/sdc3 ro
    initrd: /kernel26.img
    There is no entry for windows, as I can just use the BIOS boot menu to switch
    between the two bootable hard disks, or at least that was my plan...
    When I boot to windows, everything works just fine.  When I go to the
    BIOS boot menu and choose to boot from the third disk, I get the grub
    bootloader with choices of arch and arch fallback, just as expected. 
    I select the former, and I get the following message from grub:
    Booting 'Arch Linux'
    root    hd(2,0)
    Filesystem type unknown, partition type 0x7
    kernel /vmlinuz26 root=/dev/sdc3 ro
    Error17: cannot mount selected partition
    The same thing happens for the fallback image.  I made very sure to install
    grub to the mbr, /dev/sdc.
    I have also tried to use the UUID entry for /root in the menu.lst file, and
    this gives the exact same results.  I have also run grub interactively from
    the bootable CD image, and it does not give such errors-  it knows that
    hd(2,0) has type 82, and not 7.  However, when I try the initrd command in
    interactive grub, I get a complaint about the image not fitting in memory.
    However, I have 16GB of ram...
    One other note that may be (but probably is not) relevant:  initially I could
    not get the Arch disk to recognize the hard drive (the format disk phase of
    installation would always fail), so from windows, I went to the disk manager
    and formatted it with ntfs.  This enabled me to format the disk from the arch
    install process and install the new FS.  I didn't think the temporary presence
    of ntfs would be any kind of an issue since I immediately reformatted it.
    Many thanks for your time reading this.  Much appreciated.
    Last edited by wes (2011-03-07 21:24:44)

    I guess here:
    https://wiki.archlinux.org/index.php/Be … Bootloader
    or here
    https://wiki.archlinux.org/index.php/Wi … ard_Drives
    would be sensible places, but as a complete rookie, I don't feel qualified to start editing the wiki...

  • Boot images: bootsplash v grub splashimage v lilo bitmap

    I'm interested in the pros and cons here - I've only ever used bootsplash back in the 2.4 days and i could never get the loading bar thing to work
    Ideally, I wouldn't want to patch anything - I like stock builds...
    I want to know how each of these works...
    I am assuming the bootloader images will not coverup the dmesg spam at the beginning... and I also heard grub supports only 14 colors (!?)... so wtf?
    anyone have experience with all 3?

    I think there are two different issues here:
    - Grub splashimage is just that : an image in the background of the grub bootloader menu.  it really has nothing to do with the kernel.  so your assumption about not covering dmesg "spam" is correct.  it just makes it look less dull than having a black background with colors while you are making a choice
    - don't know about lilo bitmap but I would assume the same kind of thing
    - i have experience with bootsplash with SUSE linux.   I like it a lot (of course the progress bar was working perfectly  ).  I am going to try to patch the 2.6.9 kernel this weekend and get a bootsplash going (with the same config file as arch)  and make a package.  if I am successful, I could either let you know how I did it and somehow get the package over to you so you can have a bootsplash as well (prepackaged and all).  so let me know if you are interested.  I was going to ask someone from the TUR group to see if it would be possible to get the package posted.
    as far as cons go, I don't really see any because you could always press F2 and it drops into the normal "spam" mode in case you need to trouble shoot the init process or something. 
    pro: eye candy!  + ability to show windows and MacOSX users that Linux can be both functional and beautiful.

  • GRUB and Solaris 10 installation with WinXP

    Hi All,
    I am new to Solaris 10 and want to install it on my PC.(Intel81845GVM-RZ Motherboard,256 mb RAM,80gb Hard disk)I am comfortable with installations on Sparc m/c but this GRUB bootloader is all new to me.I am not able to find any good document explaining X86 installations for solaris which include GRUB bootloader.How should I go about?Will it be possible for me to install WinXP+Solaris togather?If yes,kindly guide me in detail as to how should i go about doing it?will it be possible only wen I enhance my RAM to say 1 gb?How should I go about it then if I make it 1gb.How will i get GRUB bootloader??too many questions ....but then..consider me being new to solaris that too on X86.Sparc is easier and I have done it too.I also had installed Solaris 10 only(no WinXP)on my un n/w system.Somehow it got corrupted n I have downloaded the CDs.but the are in some other format and I wrote 3 images on one CD and remaining 2 on other.How can I get Installation Cds from those downloaded form?

    I am new to Solaris 10 and want to install it on my PC.(Intel81845GVM-RZ
    Motherboard,256 mb RAM,80gb Hard disk)IOne of my test machines is Intel 810e based one with 512MB SDRAM and 80 GB UltraATA drive. You need at least 512 MB to run it with OK on x86. But I would strongly recommend you 1 GB RAM, assuming you wish to go for x86 Developer Express.
    I am not able to find any good document explaining X86 installations for
    solaris which include GRUB bootloader.How should I go about?Will it be
    possible for me to install WinXP+Solaris togatherOn that test machine, I run Windows XP - SP2, Sun Solaris x86 Developer Express 03/07, KUbuntu 3.70, PCLinuxOS 2007 final, Sabayon 3.4 Mini, Fedora Core 8 and Open SUSU 10.3 KDE.
    Trick is two things, where you won't find in those (poorly maintained) Sun documents!
    a) Know your Hardware: this is a must.
    b) Learn how to put things where: partition expertise
    c) Learn how to control your boot loader: GRUB
    It's no magic, everything is possible, provided time and patience :) Best of Luck!
    .Sparc is easier and I have done it too.II have done on SPARC and Apple BookPro (new Intel models with Dual Core). I didn't get what you meant by easier?

  • What Bootloader or Boot Manage Is OS X Based From?

    Hi. Just curious. Since Linux and OS X have origins in Unix (Linux isn't Unix based though I believe) does it base its bootloader or boot manager (the one you see when you hold Option on reboot) from popular bootloaders like Grub or Lilo? Is OS X's boot manager/bootloader embedded in the EFI chip/firmware or it's in one of the hidden system files of OS X?
    Thank you in advance.
    Gbu.
    P.S. Although I've played with Linux before on the PC, I've been trying to play with Linux (Ubuntu 11.10, Live CD or installing it to a Flash drive and USB external) on my iMac but I had to let it go coz' I can't make it boot on my iMac (late 2009 i7) inspite of the command line I had typed based on Ubuntu forum posts and the netboot type of install). The Live CD booted ok on a virtualization machine like VirtualBox (from Oracle) but from this VM I can't make it see my USB external to install it there.

    OS X uses the Darwin bootloader that most likely derived from the one used by FreeBSD.
    If you partition your drive so you have a separate volume for Linux, then install Linux from the Live CD it will install the Grub bootloader modified to enable you to choose which OS to boot at startup time. Alternatively, the rEFIt bootloader provides a startup GUI sort of akin to the OS X boot manager.

  • Grub Install on FAT32 Partition

    Howdy Y'all,
    I often remote into my home system and I need to be able to switch between my Arch Linux install and my Windows 7 partition from time to time. I am toying with the idea of installing Grub on /boot as a FAT32 partition so I can edit the Grub menu from within Windows or Arch and change the default boot OS.
    That way I can remote into my system, change the grub menu, issue a reboot command and have my home system switch over to the other OS.
    Would that be a good way to remotely switch what OS I am running? Or does any one have a better idea on how to do that?
    Thanks!

    Doesn't need to be all that difficult. Have a look at this.

Maybe you are looking for

  • New ledger Migration issue: Account contronl on G/L Accounts

    Hello We did the Test validation Service report for the migration. There is an error that I can't understand how to solve it. The purpose: The classification of G/L accounts for document splitting is based on the assumption that, for example, a recon

  • How to Generate a Report Based on User's Parameters from Web Site

    Hi, all, I am trying to use Oracle Developer 6.0 Report Builder to generate report based on what user types in from the web site. Since I am a novice, I am wondering if anybody would help me with the following questions: 1. How can I create a report

  • Cross Platform Migration (BI XI 31-Win to BI 4.1 - Linux)

    Hi I would like to know Will the Update Manager Tool of BI 4.1 running on Linux 64 bit environment migrate the Universes, Users, Groups and other related information from BI XI 3.1 running on Windows (32 bit)? Will the Report Conversion Tool running

  • Failed from the get-go

    Just installed Snow Leopard. Upgraded to 10.6.2. I'm on a MacPro 3ghz quad core. Start up Boot Camp Assistant. Hit continue and "You must update your system software before using this setup assistant". Vista Ultimate disk is in the drive, my second p

  • I do not understand the number icon stands for

    It is a small icon to the right of awesome bar. And there is a number displayed on the icon, sometimes it changes. I am wondering what it means.