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

Re: changing partition names



Frank McCormick composed on 2016-02-14 15:42 (UTC-0500):

> I have deleted a partition from my HD containing a distro I no longer use.

What motivated doing so? What exactly was/were your goal(s) in doing so?

> As a result, my partitions on /dev/sda are numbered sda1. sda2 (windows) 
> and sda4. sda3 contained the distro I dumped.

> Can I just use fdisk or fsdisk to dump the existing partition record

It's not something I've ever done, but as I understand them, using either to
delete and recreate an existing partition should do that job, but compatibly
only if you know how to recreate the same size and have it start on the same
sector as it now does.

> edit the file to change sda4 to sda3 and then use fdisk or sfdisk to
> read the file and create a properly named partition record ?

Any binary disk editor can move the slot 4 partition record to slot 3. That's
the only difference between your existing native partition being named sda4
and being named sda3. Do you understand the ramifications of making such a
change? As long as your existing Debian partition is referred to by name,
UUID or ID in bootloader config and fstab, it shouldn't matter the device
name resulting from its partition table entry.

Frank McCormick composed on 2016-02-14 19:11 (UTC-0500):

> This is what I have now from sfdisk -l

> label: dos
> label-id: 0x5a74aac4
> device: /dev/sda
> unit: sectors

> /dev/sda1 : start= 2048, size= 194560, type=7
> /dev/sda2 : start= 196608, size= 81920000, type=7
> /dev/sda4 : start= 82116608, size= 74131456, type=83, bootable

> ^^^^^^^^ this is what I need to change to /dev/sda3

Why the "need".

> sda1 and sda2 are the Windows partitions. sda4 is Debian

As the size recovered by your deletion of sda3 was minimal
(82116608-81920000=196608), you're probably best off, in terms of
complication, by creating another partition in its space. Once created, make
a new filesystem, and maybe mount it as /usr/local, /var/cache, /tmp or even
/boot (assuming you know and can deal with the bootloader complications
involved in doing so).
-- 
"The wise are known for their understanding, and pleasant
words are persuasive." Proverbs 16:21 (New Living Translation)

 Team OS/2 ** Reg. Linux User #211409 ** a11y rocks!

Felix Miata  ***  http://fm.no-ip.com/


Reply to: