Linux - GeneralThis Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Linux works fine, but when I try to boot windows with GRUB, the screen just goes black (The computers still on), and I have to restart and use linux. I use linux more often than windows, but I still have to do some things on it.
Please provide some details about your configuration. Where's Windows installed (1st or 2nd HDD)? Most helpful would be the output of fdisk -l, your menu.lst and grub.conf.
Please provide some details about your configuration. Where's Windows installed (1st or 2nd HDD)? Most helpful would be the output of fdisk -l, your menu.lst and grub.conf.
And tell us if it ever worked- if it stopped working after you changed something---etc.
Linux and windows are on the same HD, just different partitions. I think that it stopped working because I deleted an empty partition that was before the windows one.
And abisko, where do I find those things you mentioned (menu, fdisk, etc)
fdisk -l is a command that has to run with root permissions.
The location of menu.lst may depend on your distribution. Have a look in /boot/grub.
For grub.conf look in the same directory or /etc.
Most probably the partition number has changed. Once you locate menu.lst, you'll find that the partitions are addressed something like (hdx,y). x addresses the drive. hd0 is the first drive on the controller. y points to the partition. If you previously had 3 partitions (Linux, something, Windows), Windows would be on hd0,2. After deleting partition "something", Windows would change to hd0,1. Change this parameter below "title windows" accordingly. You need root permissions to be able to save the changes.
Linux and windows are on the same HD, just different partitions. I think that it stopped working because I deleted an empty partition that was before the windows one.
And abisko, where do I find those things you mentioned (menu, fdisk, etc)
Open a terminal and do this:
Code:
su (to take on root powers)
fdisk -l (to see how your drives are partitioned)
(on some systems, you might need to do /sbin/fdisk -l)
---copy and paste to put the output of fdisk into a post---
To edit the grub config file:
Code:
cd /boot/grub
ls (look for a file named "menu.lst" or "grub.conf")
Open with an editor, eg:
nano menu.lst OR
gedit menu.lst OR
kate menu.lst
Disk /dev/sda: 80.0 GB, 80000000000 bytes
255 heads, 63 sectors/track, 9726 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/sda2 * 9 9267 74372917+ 7 HPFS/NTFS
/dev/sda3 9269 9725 3670852+ 83 Linux
/dev/sda4 9726 9726 8032+ 82 Linux swap / Solaris
This is what my windows part on the menu.lst file looks like:
title Windows NT/2000/XP (loader)
root (hd0,1)
savedefault
makeactive
chainloader +1
boot
And can someone with windows post what their menu.lst file (or similar) looks like?
My Pc came with a small hidden partition before the main Windows XP parition. This is apparently used for restoring Windows. Some Linux distributions would try and set this first partition sda1/hd0,0 as the Windows partition and the boot into Windows failed because what I needed was sda2/hd0,1. When I first installed Linux I made the mistake of thinking that my Windows installation had been trashed. I wonder whether this 'empty first partition' was important to your Windows boot.
title SlackwareLinux-11.0 smp (on /dev/sdb3)
root (hd1,2)
kernel /boot/vmlinuz-generic-smp-2.6.17.13 root=/dev/sdb3 ro #hda=ide-scsi
initrd /boot/initrd.gz
savedefault
boot
title SlackwareLinux-2.6 (old system) (on /dev/sdb1)
root (hd1,0)
kernel /boot/vmlinuz060821_3 root=/dev/sdb1 ro
savedefault
boot
title SlackwareLinux-11.0 2.4 (on /dev/sdb3)
root (hd1,2)
kernel /boot/vmlinuz-satai-2.4.33.3 root=/dev/sdb3 ro
savedefault
boot
title Slamd64 (on /dev/sdb10)
root (hd1,9)
kernel /boot/vmlinuz root=/dev/sdb10 ro
savedefault
boot
# This entry automatically added by the Debian installer for a non-linux OS
# on /dev/sda2
title Microsoft Windows XP Home Edition
root (hd0,1)
savedefault
makeactive
chainloader +1
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.