Page 1 of 1

reinstalling bootloader after adding Win - SOLVED

Posted: 23. Sep 2013, 19:44
by mimosa
No joy with either Lilo or Grub - though os-prober correctly identifies both OSs. I have searched and fiddled to no end. If need be, my next step will be to reinstall Salix, but I'd be delighted to solve this properly. Also, who knows, maybe that won't work either?
This SSD earlier had partitions out of order (sda6 before sda5) but I then removed sda6 to see if that might help - it didn't, but I mention it in the interest of full disclosure.

I'd be most grateful for any illumination!

Here is some output (all from a Salix Live USB). First off, lilosetup, liloconfig and lilo itself all give the same error:

Code: Select all

Reading boot sector from /dev/sda
Fatal: Trying to map files from unnamed device 0x0012 (NFS/RAID mirror down ?)
lilosestup only sees Salix, gmountman only sees the two windows partitions. Here is fdisk -l:

Code: Select all

Disk /dev/sda: 120.0 GB, 120034123776 bytes
255 heads, 63 sectors/track, 14593 cylinders, total 234441648 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000b7363

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *        2048      206847      102400    7  HPFS/NTFS/exFAT
/dev/sda2          206848    41166847    20480000    7  HPFS/NTFS/exFAT
/dev/sda3        67244032   234440703    83598336    5  Extended
/dev/sda5   *   170704959   233834495    31564768+  83  Linux

Disk /dev/sdb: 4009 MB, 4009754624 bytes
126 heads, 22 sectors/track, 2825 cylinders, total 7831552 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000e6ed5

   Device Boot      Start         End      Blocks   Id  System
/dev/sdb1   *        2048     7831551     3914752    b  W95 FAT32
So I thought I'd try grub:

Code: Select all

root[one]# grub-install /dev/sda
/usr/sbin/grub-probe: error: cannot stat `none'.
But this looks fine:

Code: Select all

root[one]# os-prober
  No volume groups found
/dev/sda1:Windows 7 (loader):Windows:chain
/dev/sda5:Slackware Linux (Slackware 14.0):Slackware:linux
:?:

Just for fun, I just ran lilosetup without trying to add in Windows (it only sees Salix) and it reported success. I will post back here in a minute to say whether that worked. :twisted:

Yes: I now have Salix, but not Windows. lilosetup still can't see win.

Re: reinstalling bootloader after adding Win

Posted: 23. Sep 2013, 23:36
by laprjns
I believe you need to install window first, then linux. That's the only way I've done it in the past.

http://www.makeuseof.com/tag/dualboot-w ... -computer/

Re: reinstalling bootloader after adding Win

Posted: 24. Sep 2013, 00:43
by mimosa
@laprjns

yes you are right - in the sense that that way of things just works. However I have managed to do it the other way round in the past, in particular, on this very machine which initially had 32 bit win, after a very pleasant couple of months using it with Salix only before my stepdaughter came back home.

The problem is SOLVED in that I installed grub2 in Salix, just did update-grub and grub-install (or whatever it is exactly) and now have dual boot. Lilo would be nice and actually working out the reason for the problem would too, but that's a luxury ;)

Grub2 in Live seems to be Grub1.99, whereas I installed grub2 proper in Salix sda5. Maybe that made the difference, or maybe the fact of trying to run it from a different drive other than the target device.