Re: installing C7 on a laptop with Win7, dual boot

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]




------------ Original Message ------------
> Date: Sunday, March 01, 2015 20:06:26 -0500
> From: Fred Smith <fredex@xxxxxxxxxxxxxxxxxxxxxx>
> To: centos@xxxxxxxxxx
> Subject:  installing C7 on a laptop with Win7, dual boot
>
> Hi all!
> 
> I've just installed C7 on my netbook that already contained Win7
> (and also Fedora 19, which the C7 is intended to replace). The
> Fedora installer had found the windows installation and it
> appeared in the grub menu, and was bootable and worked fine.
> 
> The C7 installer did not put the windows installation into the grub
> menu.
> 
> with some googling I found a page at
> https://priteshugrankar.wordpress.com/2014/09/12/dual-booting-cent
> os-7-and-windows-7/ that gives a simple recipe for fixing this
> problem. basically:
> 
> cp /boot/grub2/grub.cfg orig.grub.cfg
> grub2-mkconfig -o /boot/grub2/grub.cfg
> 
> with (on his system) the second command above producing this
> output:
> 
> 	[root@localhost ~]# grub2-mkconfig -o /boot/grub2/grub.cfg
> 	Generating grub configuration file ...
> 	Found linux image: /boot/vmlinuz-3.16.2-1.el7.elrepo.x86_64
> 	Found initrd image: /boot/initramfs-3.16.2-1.el7.elrepo.x86_64.img
> 	Found linux image: /boot/vmlinuz-3.10.0-123.el7.x86_64
> 	Found initrd image: /boot/initramfs-3.10.0-123.el7.x86_64.img
> 	Found linux image: /boot/vmlinuz-3.10.0-123.6.3.el7.x86_64
> 	Found initrd image: /boot/initramfs-3.10.0-123.6.3.el7.x86_64.img
> 	Found linux image:
> /boot/vmlinuz-0-rescue-327fe33f3b364802871211321a2790b7 	Found
> initrd image:
> /boot/initramfs-0-rescue-327fe33f3b364802871211321a2790b7.img
> 	Found Windows 7 (loader) on /dev/sda1
> 	Found Windows 7 (loader) on /dev/sda2
> 	done
> 
> Unfortunately, when I did it, I got this:
> 
> Generating grub configuration file ...
> Found linux image: /boot/vmlinuz-3.10.0-123.el7.x86_64
> Found initrd image: /boot/initramfs-3.10.0-123.el7.x86_64.img
> Found linux image: /boot/vmlinuz-3.10.0-123.20.1.el7.x86_64
> Found initrd image: /boot/initramfs-3.10.0-123.20.1.el7.x86_64.img
> Found linux image:
> /boot/vmlinuz-0-rescue-c875112952114f6284f69abaa4f9a2f7 Found
> initrd image:
> /boot/initramfs-0-rescue-c875112952114f6284f69abaa4f9a2f7.img done
> 
> No mention of the windows installation.
> 
> It's not that I use the win7 installation much, but I do want to
> be able to do so when one of those rare occasions pops up.
> 
> Thanks in advance!
> 
> Fred

I too encountered this issue putting centos7 on a win7 machine. The
solution is to:

edit:   

    /etc/grub.d/40_custom

putting in:

    menuentry 'name' {

    insmod ntfs

    set root=(hd0,2)

    chainloader +1

    }

note: "name" can be anything you want (within reason), and is the
name that will show in the boot menu. 

the values here:

    root=(hd0,2)

will vary based on your disk setup. if you still have your fc19
grub/grub2 (whichever it used) configuration file you should be able
to confirm the values from that.

when done, then:

  grub2-mkconfig -o <output file>

personally, i didn't set the -o to the production grub.cfg file as
my preference is to make backups and check things before potentially
trashing a file like that, but do as you wish. when you're
comfortable with the generated file move it to the production
location and reboot.


    - Richard



_______________________________________________
CentOS mailing list
CentOS@xxxxxxxxxx
http://lists.centos.org/mailman/listinfo/centos




[Index of Archives]     [CentOS]     [CentOS Announce]     [CentOS Development]     [CentOS ARM Devel]     [CentOS Docs]     [CentOS Virtualization]     [Carrier Grade Linux]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Linux USB]
  Powered by Linux