LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   I Cant Boot up Windows (https://www.linuxquestions.org/questions/linux-newbie-8/i-cant-boot-up-windows-682288/)

generalgiantsfan 11-10-2008 02:09 AM

I Cant Boot up Windows
 
Hey, I am new to Linux. I was trying it out to see how it was and I think I accidentally got rid of windows somehow. Just wondering if there is any way to get it back. When I turn on my laptop, it goes straight to linux, doesnt even give me an opportunity to load windows. Any help?

pinniped 11-10-2008 02:23 AM

1. what distribution did you use?

2. as 'root', post the output of:
fdisk -l

3. what bootloader are you using? If you use 'grub', then this command will usually show you something:
ls -ld /boot/grub

4. what version of MSWin was installed?

Of course if you accidentally installed over MSWin, then there's not much we can do for you.

Larry Webb 11-10-2008 06:06 AM

First can you tell us which linux distro you are using? I am hoping you understand what pinniped asked for. If not please let us know and we will try and help you step by step.

generalgiantsfan 11-10-2008 11:48 PM

Reply
 
1. I loaded ubuntu linux 8.10

2. Dont understand this question...

3. output of ls -ld /boot/grub:
drwxr-xr-x 2 root root 4096 2008-11-10 03:05 /boot/grub

4. I had microsoft windows xp



I am almost positive that it installed over windows because it is finally letting me choose what to boot up but my only options are linux and a linux recovery and one more thing related to linux, I would have to double check if necessary.

claudius753 11-11-2008 12:00 AM

What option did you choose when you installed Ubuntu? Usually it asks how you want to partition, using available free space, use the whole drive, or manually.

For number 2, you can run a command as root by prefacing the command with sudo. Note that root is a user account that has full access to everything, and you can break your install if you do something you shouldn't, which is why you should never log in as root and only use sudo when needed. It's similar to the Administrator account in Windows.

Code:

sudo fdisk -l

generalgiantsfan 11-11-2008 12:03 AM

Thanks for the help...

Here is the answer to number 2:

Disk /dev/sda: 80.0 GB, 80026361856 bytes
255 heads, 63 sectors/track, 9729 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0xd3e7d3e7

Device Boot Start End Blocks Id System
/dev/sda1 * 1 9327 74919096 83 Linux
/dev/sda2 9328 9729 3229065 5 Extended
/dev/sda5 9328 9729 3229033+ 82 Linux swap / Solaris

And I went with whatever was the standard option when that partition part came up...whatever was default, sorry I cant remember what it was.

claudius753 11-11-2008 12:25 AM

Ok, I'm no expert here, but I see no partition for Windows....meaning you may have deleted it when installing Linux.


Code:

Disk /dev/sda: 80.0 GB, 80026361856 bytes
255 heads, 63 sectors/track, 9729 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0xd3e7d3e7

Device Boot Start End Blocks Id System
/dev/sda1 * 1 9327 74919096 83 Linux
/dev/sda2 9328 9729 3229065 5 Extended
/dev/sda5 9328 9729 3229033+ 82 Linux swap / Solaris

I'm not sure what the bolded one is, but I'm pretty sure it's not your Windows partition. I'm not sure why it seems to be the same as your swap. Maybe someone more skilled could answer that.

generalgiantsfan 11-11-2008 12:30 AM

That is what I figured I did...well that kinda stinks lol...

Thanks for the help though!

pinniped 11-11-2008 12:39 AM

Well, I'm sorry to say that your last post has confirmed that XP had been nuked. I hope you had no valuable data on it. If you did (and didn't have a backup), it may still be possible to recover *some* files but that's a time consuming process.

Junior Hacker 11-11-2008 12:40 AM

Quote:

Originally Posted by claudius753 (Post 3337969)
I'm not sure what the bolded one is, but I'm pretty sure it's not your Windows partition. I'm not sure why it seems to be the same as your swap. Maybe someone more skilled could answer that.

This is an extended partition defining the remainder of the drive where you can make many "logical" partitions within. The swap is the only logical partition taking up the entire space.

Quote:

Ok, I'm no expert here, but I see no partition for Windows....meaning you may have deleted it when installing Linux.
This appears to be correct.
You may be able to recover data if need be, but not the Windows installation.

generalgiantsfan 11-11-2008 12:43 AM

In order to see if I can recover anything, would I take it to someone, or is there some online instructions you can refer me to...?

pinniped 11-11-2008 12:43 AM

Quote:

Originally Posted by claudius753 (Post 3337969)
I'm not sure what the bolded one is, but I'm pretty sure it's not your Windows partition. I'm not sure why it seems to be the same as your swap. Maybe someone more skilled could answer that.

'sda2' is a DOS 'primary' partition. It has been divided into 'logical' partitions (and so it is referred to as 'extended' rather than 'primary').

'sda5' is the logical partition which takes up most of sda2.

So - the disk is essentially divided into 2 partitions - sda1 (Linux) and sda5 (swap).

pinniped 11-11-2008 12:48 AM

Quote:

Originally Posted by generalgiantsfan (Post 3337994)
In order to see if I can recover anything, would I take it to someone, or is there some online instructions you can refer me to...?

It's safest if you have a buddy who knows Linux well enough that they won't do more damage to the data on the disk. The idea is to boot from a LiveCD (or plug your HD into another machine and boot linux from another HD) and use recovery tools to look for data on the disk. The Linux installation would have wiped out a lot of data, and each time you boot linux from that HD and the HD is 'mounted' as read+write, a bit more data is wiped out by normal system tasks. You can bet that all data that was on the 'swap' section had been wiped. On the topic of recovery tools - you'd need a second HD to write the recovered files to.

[edit] You do have to read through very carefully before (and while) installing an operating system, and everyone recommends you make a backup beforehand even if you know what you're doing. It only takes 1 little mistake to do a lot of damage, whether you're installing MSWin or Linux or some other system.

generalgiantsfan 11-11-2008 12:53 AM

Yah, it was pretty dumb on my part...I am just glad that I do not hold my value in something on a laptop, lol, so although I lost pretty much all my files, I am not really upset, I will just move on. Thanks to all of you guys for your help, this was much appreciated.

claudius753 11-11-2008 01:27 AM

If you are going to reinstall XP, your best bet is to delete all partitions, and create a new one of the size you want the install to be from the XP installer (eg 40GB), then you can install ubuntu (if you are still willing to try linux) in the remaining space.

Of course, you could just keep your system as Linux only...

And to other posters, thanks for clearing up that partition information, I didn't even think of it being an primary / logical thing. Nice to know from now on.


All times are GMT -5. The time now is 09:39 PM.