Linux – Set the partition type with parted

linuxpartitioningsolaris

I just acquired a new Dell laptop.

I installed Linux on the 1st half of the HDD and on the second part I want to install Oracle Solaris. According to this I need to set the partition type of the second half to be 0x82.

When I installed Linux I used parted version 3.1 and it looks like it does not have a command to change the partition type. Instead it looks like I have to provide [FS-TYPE] when issuing mkpart command.

Now looking at the supported types I see five possibilities: linux-swap(v1), linux-swap(v0), linux-swap, linux-swap(new) and linux-swap(old).

Which one of those 5 I should choose?

The problem I'm facing right now is that trying to install Oracle Solaris, the installer only recognizes NTFS file system. And when the time comes to ask where to install I have the whole disk as un-used. But according to the link above I should be able to cheat with the installer letting him know that I already have ready to use partition for Oracle Solaris.

Best Answer

0x82 is not a revision number of swap it is just the codename for swap so it doesn't matter which you pick they are all 0x82. See this link: http://www.tldp.org/HOWTO/Partition/partition-types.html

It appears you've misread the instructions. The swap partition must be formatted as swap, and the Solaris partition must be formatted as UFS. For parted commands see: http://postbin.per.red/pages/article24/page.php

[These codes are just examples, you will need to change some of the values before using them.]

To create a UFS parition:

Type in Parted "select /dev/sda".

Type in Parted "mkpartfs primary ufs 0.0 700.0"

To format an existing parition as UFS:

Type in Parted "mkfs yes 3 ufs"

Related Question