PDA

View Full Version : [SOLVED] Erase disk and install Ubuntu - will this erase data on all drives?



JYzeeeJ
October 8th, 2013, 08:03 AM
I would like to install Xubuntu onto my C: hard disk (which has Vista on it).

I have a second hard disk (D:) that I haven't backed up yet. I was thinking I would be able to install on C:, and then copy from D: at my leisure. But know I'm wondering whether this "erase disk and install ubuntu" will format everything! Will the install give my options on the next step?

This is the output from fdisk -l


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: 0xe13269ca

Device Boot Start End Blocks Id System
/dev/sda1 2048 20482047 10240000 27 Hidden NTFS WinRE
/dev/sda2 * 20482048 127467519 53492736 7 HPFS/NTFS/exFAT
/dev/sda3 127467520 234438655 53485568 7 HPFS/NTFS/exFAT

Disk /dev/sdc: 1993 MB, 1993342976 bytes
2 heads, 63 sectors/track, 30898 cylinders, total 3893248 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: 0x0026b695

Device Boot Start End Blocks Id System
/dev/sdc1 * 32 3893247 1946608 6 FAT16

So I believe sda1 and sda2 are C: and sda3 is D: - is that correct?

arubislander
October 8th, 2013, 08:16 AM
The output of fdisk -l shows that you only have one hard disk drive with three partitions on it.
The option to erase disk and install ubuntu will reformat the drive, wiping out all the partitions in the process.
/dev/sda1 is probably the recovery partition. It is Hidden, and thus invisible to Windows during normal operation.
/dev/sda2 had the Boot flag set, and is the C:\ under Windows
/dev/sda3 is D:\

What you want to do is choose the last option 'Something Else' I think it is labeled, and then manually select the /dev/sda2 partition and tell the installer to format that and mount it as / (the root of the Linux filesystem)

But only do this if you are defenitely sure that you really want to get rid of Vista alltogether.

JYzeeeJ
October 8th, 2013, 08:35 AM
Thanks arubislander.

There is not a lot of data on sda3 so I might back it up then let the installer wipe everything. Would it keep the size of the partitions, or just reset everything and leave 1 drive/partition?

westie457
October 8th, 2013, 08:49 AM
arubislander is correct.
The wipe drive and install option will completely clear the hard drive of all information with no way of recovering it. His suggestion to use the 'something else' option if used properly will preserve the current Windows and hidden partitions.

Using Windows tools shrink your D: drive (/sda2) to create some space for Ubuntu. Leave this space as unallocated, then run the Ubuntu installer and select the 'something else' option.

This way should leave you with a dual-booting system and the recovery software to restore Vista to the state when your computer left the factory.

Elfy
October 8th, 2013, 08:51 AM
Thanks arubislander.

There is not a lot of data on sda3 so I might back it up then let the installer wipe everything. Would it keep the size of the partitions, or just reset everything and leave 1 drive/partition?

It would remove all existing partitions and start again.

In addition to creating the / partition you'll likely want to create a swap partition.

If you delete sda2 - you can then create partitions as you wish.

I'd create an extended partition first.

Then create a swap then / both as logical partitions in the extended.

I'd leave sda3 - you can use that as a data partition and mount that at boot if you wish with fstab.

https://help.ubuntu.com/community/Partitioning/Swap
https://help.ubuntu.com/community/SwapFaq

https://help.ubuntu.com/community/HowtoPartition

https://help.ubuntu.com/community/Fstab

JYzeeeJ
October 8th, 2013, 10:02 AM
In addition to creating the / partition you'll likely want to create a swap partition.


Will it give me the option to create the swap partition after selecting the Erase disk and install Ubuntu option?

Thanks for the links, it looks like I need to create a 2GB swap file (as I have 2GB RAM and 120GB HD).

Elfy
October 8th, 2013, 10:21 AM
If you use the erase and install option it will do so itself.

JYzeeeJ
October 8th, 2013, 11:38 AM
Thanks. Marked as solved.