Hi,
More often than not, when installing CentOS, I choose manual partitioning and then apply the KISS principle, with a very simple partitioning scheme that looks more or less like this:
* /boot partition: 500 MB, ext2 * swap partition: equivalent to amount of RAM * root partition: available space, ext4
Now when I do this, Anaconda insists on switching my swap and root partitions, so instead of this:
* /dev/sda1: boot partition * /dev/sda2: swap partition * /dev/sda3: root partition
... I get this:
* /dev/sda1: boot partition * /dev/sda2: root partition * /dev/sda3: swap partition
Up until now this hasn't bothered me much. But for my needs right now it does, because I need my root partition to be at the end of the disk, so it can be expanded later on.
Anyone knows how I can prevent Anaconda from switching my root and swap partitions? What I'm doing right now is switching to a text console with Ctrl-Alt-F5, manually partition using fdisk, switch back to Anaconda and then rescan the disk, but it's quite a PITA.
These are the moments where I miss the good old bone-headed Slackware installer. :o)
Cheers,
Niki
Hi,
More often than not, when installing CentOS, I choose manual partitioning and then apply the KISS principle, with a very simple partitioning scheme that looks more or less like this:
- /boot partition: 500 MB, ext2
- swap partition: equivalent to amount of RAM
- root partition: available space, ext4
Now when I do this, Anaconda insists on switching my swap and root partitions, so instead of this:
- /dev/sda1: boot partition
- /dev/sda2: swap partition
- /dev/sda3: root partition
... I get this:
- /dev/sda1: boot partition
- /dev/sda2: root partition
- /dev/sda3: swap partition
Up until now this hasn't bothered me much. But for my needs right now it does, because I need my root partition to be at the end of the disk, so it can be expanded later on.
Anyone knows how I can prevent Anaconda from switching my root and swap partitions? What I'm doing right now is switching to a text console with Ctrl-Alt-F5, manually partition using fdisk, switch back to Anaconda and then rescan the disk, but it's quite a PITA.
That's exactly what I wanted to suggest you :-)
I never found a better way...
Simon
On 31.03.21 11:30, Simon Matter wrote:
Hi,
More often than not, when installing CentOS, I choose manual partitioning and then apply the KISS principle, with a very simple partitioning scheme that looks more or less like this:
- /boot partition: 500 MB, ext2
- swap partition: equivalent to amount of RAM
- root partition: available space, ext4
Now when I do this, Anaconda insists on switching my swap and root partitions, so instead of this:
- /dev/sda1: boot partition
- /dev/sda2: swap partition
- /dev/sda3: root partition
... I get this:
- /dev/sda1: boot partition
- /dev/sda2: root partition
- /dev/sda3: swap partition
Up until now this hasn't bothered me much. But for my needs right now it does, because I need my root partition to be at the end of the disk, so it can be expanded later on.
Anyone knows how I can prevent Anaconda from switching my root and swap partitions? What I'm doing right now is switching to a text console with Ctrl-Alt-F5, manually partition using fdisk, switch back to Anaconda and then rescan the disk, but it's quite a PITA.
That's exactly what I wanted to suggest you :-)
I never found a better way...
I never have done that but is %pre script section not exactly the place for that ?
-- Leon
On Wed, 31 Mar 2021 at 05:11, Nicolas Kovacs info@microlinux.fr wrote:
Hi,
More often than not, when installing CentOS, I choose manual partitioning and then apply the KISS principle, with a very simple partitioning scheme that looks more or less like this:
- /boot partition: 500 MB, ext2
- swap partition: equivalent to amount of RAM
- root partition: available space, ext4
Now when I do this, Anaconda insists on switching my swap and root partitions, so instead of this:
- /dev/sda1: boot partition
- /dev/sda2: swap partition
- /dev/sda3: root partition
... I get this:
- /dev/sda1: boot partition
- /dev/sda2: root partition
- /dev/sda3: swap partition
Up until now this hasn't bothered me much. But for my needs right now it does, because I need my root partition to be at the end of the disk, so it can be expanded later on.
Anyone knows how I can prevent Anaconda from switching my root and swap partitions? What I'm doing right now is switching to a text console with Ctrl-Alt-F5, manually partition using fdisk, switch back to Anaconda and then rescan the disk, but it's quite a PITA.
These are the moments where I miss the good old bone-headed Slackware installer. :o)
Cheers,
Since you are doing manual vs kickstart, you need to do additional steps Before you go into the disk system in the UI
Control-Alt-F2 fdisk (or gfdisk or parted depending on your prefs and needs) clear the disk and set it up how you want it with the types set on each partition. go back into the UI and do the things you wanted. have it reread the disks and have it use the existing partitions versus anything else
Option 2 is to go into the advanced partitioning tool blivet and see if it can be done through that.. but I think you still need to do a 'slackware/arch' setup first
On 3/31/21 11:10 AM, Nicolas Kovacs wrote:
Hi,
More often than not, when installing CentOS, I choose manual partitioning and then apply the KISS principle, with a very simple partitioning scheme that looks more or less like this:
- /boot partition: 500 MB, ext2
- swap partition: equivalent to amount of RAM
- root partition: available space, ext4
Now when I do this, Anaconda insists on switching my swap and root partitions, so instead of this:
- /dev/sda1: boot partition
- /dev/sda2: swap partition
- /dev/sda3: root partition
... I get this:
- /dev/sda1: boot partition
- /dev/sda2: root partition
- /dev/sda3: swap partition
Up until now this hasn't bothered me much. But for my needs right now it does, because I need my root partition to be at the end of the disk, so it can be expanded later on.
Anyone knows how I can prevent Anaconda from switching my root and swap partitions? What I'm doing right now is switching to a text console with Ctrl-Alt-F5, manually partition using fdisk, switch back to Anaconda and then rescan the disk, but it's quite a PITA.
an alternative could be to NOT create any swap partition, and set up a swap file instead. man mkswap man swapon
----- On Apr 7, 2021, at 2:39 PM, Nicolas Thierry-Mieg Nicolas.Thierry-Mieg@univ-grenoble-alpes.fr wrote:
On 3/31/21 11:10 AM, Nicolas Kovacs wrote:
Hi,
More often than not, when installing CentOS, I choose manual partitioning and then apply the KISS principle, with a very simple partitioning scheme that looks more or less like this:
- /boot partition: 500 MB, ext2
- swap partition: equivalent to amount of RAM
- root partition: available space, ext4
Now when I do this, Anaconda insists on switching my swap and root partitions, so instead of this:
- /dev/sda1: boot partition
- /dev/sda2: swap partition
- /dev/sda3: root partition
... I get this:
- /dev/sda1: boot partition
- /dev/sda2: root partition
- /dev/sda3: swap partition
Up until now this hasn't bothered me much. But for my needs right now it does, because I need my root partition to be at the end of the disk, so it can be expanded later on.
Anyone knows how I can prevent Anaconda from switching my root and swap partitions? What I'm doing right now is switching to a text console with Ctrl-Alt-F5, manually partition using fdisk, switch back to Anaconda and then rescan the disk, but it's quite a PITA.
an alternative could be to NOT create any swap partition, and set up a swap file instead. man mkswap man swapon
Or you can use kickstart to install OS. So partitions will be in right order.