The officially official Devuan Forum!

You are not logged in.

#1 2017-08-22 09:03:58

HextorBRX
Member
Registered: 2017-08-20
Posts: 106  

Manual partitioning: boot partition, dual boot

- GPT table
- Legacy

Hello

I might create partitions manually with ascii for security reasons. I wonder whether a boot partition needs to be created with a GPT table. Last time I created partitions manually on a recent computer (Calculate Linux: SingleBoot/GPT/Legacy), I was prompted to create a boot partition.

This is how I would proceed:

Single boot (Devuan only)
/boot primary ext4
/root primary ext4
                          /home logical ext4
swap primary swap

Dual Boot Windows10/Devuan (no boot partition needed as I install Windows first and Linux after)
2 primary NTFS partitions for Windows 10

/root primary ext4
                           /home logical ext4
                           swap logical swap

1) Can you confirm that a boot partition is not needed for a dual boot installation (Windows10/Devuan)?

2) Do I need to create a boot partition for a single boot (Devuan only)?
3) Where should I place the boot partition? I know it needs to be primary and I would place it at the very beginnning.

Thanks

Last edited by HextorBRX (2017-09-03 12:53:52)

Offline

#2 2017-08-22 10:53:41

fsmithred
Administrator
Registered: 2016-11-25
Posts: 2,486  

Re: Manual partitioning: boot partition, dual boot

If your root partition is encrypted, you need a separate /boot partition. It has nothing to do with the number or type of operating systems on the computer. It does not have to be the first partition, but I think that's where it usually goes. And since you're using gpt, there's no need for logical partitions unless you're using lvm. You can have more than four primary partitions.

You didn't ask about this, but I'll mention that the /boot partition does not need to be flagged as bootable.

I will also mention that if you were using uefi instead of legacy bios, you would need an efi partition, which would be flagged as bootable and would not be the same thing as a separate /boot partition. You can have both of those. The efi partition (fat32 with flags 'boot,esp') would be required, and the /boot partition is optional.

Offline

#3 2017-08-22 11:28:27

Somewhat Reticent
Member
Registered: 2017-04-06
Posts: 103  

Re: Manual partitioning: boot partition, dual boot

For those who insist on multi-booting with Windows, consider the grub2win project at SourceForge.
Saves on stress and hassle when a Microsoft update affects the MBR. Perhaps it should be S.O.P.?

Offline

#4 2017-08-22 15:45:39

HextorBRX
Member
Registered: 2017-08-20
Posts: 106  

Re: Manual partitioning: boot partition, dual boot

Gparted via Calculate Linux live CD, then I create a GPT table.
Devuan: boot, root, home, swap (primary X 4)
Windows 10: NTFS (primary X 2)

Encryption gives me headaches and it takes time. I only wanted to encrypt the home partition but the installer prompts me to encrypt the swap area as well. Then, I guess I need to encrypt them both!

Somewhat Reticent: I cannot launch live CDs (except Calculate Linux and BunsenLabs) so grub2win is the way to go. Should I install Linux first and Windows after?

Offline

#5 2017-08-24 00:32:25

Somewhat Reticent
Member
Registered: 2017-04-06
Posts: 103  

Re: Manual partitioning: boot partition, dual boot

HextorBRX wrote:

Somewhat Reticent: I cannot launch live CDs (except Calculate Linux and BunsenLabs) so grub2win is the way to go. Should I install Linux first and Windows after?

Most people I've met bought their computers with Windows pre-installed; they use its partition management tools to (defrag and) shrink partitions, then gPartEd to add partitions for Linux, either before or during install - making sure to either prevent bootloader (usually grub2) installation or confining it to a partition (say, /dev/sda3), not the MBR (say, /dev/sda).

Most versions of Windows become very cross (deliberate obfuscation, InMyOpinion) after a Linux install (just as arrogantly) takes over the MBR (Master Boot Record of drive) bootloader, which terrorizes newbies. (Is W'10 better-behaved? More testing needed?)

If you haven't installed either, it's likely up to you - just remember that Windows wants to take over the MBR bootloader, and any update may try again.

In any event, add grub2win to Windows before you let Windows connect to the internet (and attempt an update), especially if you've just installed Linux/Android. (You should have plenty of time to "authenticate".)

I believe the requirement of a separate EFI boot partition is related to newer computers with UEFI firmware; most older hardware BIOS doesn't care about GPT or EFI. When experimenting, I usually make no more partitions than necessary.

As I became more informed about my hardware, I found that careful USB drive setup made many ISOs acceptable to the usual BIOS (becoming a retro thing). If your can't boot from USB (or CD) at all, the tiny Plop distro is designed just for that situation, and fits on a tiny CD - or a floppy!

(Sorry if this seems a bit long - a short answer simply wouldn't be complete, or safe.)

Last edited by Somewhat Reticent (2017-08-24 00:38:24)

Offline

#6 2017-08-24 14:35:20

HextorBRX
Member
Registered: 2017-08-20
Posts: 106  

Re: Manual partitioning: boot partition, dual boot

Thank you for your exhaustive answer, I shall read it in detail when I have Internet at home.

From what I understand, I should prevent grub2 installation by any means necessary! Windows was not pre-installed on my computer, I had no OS.

add grub2win to Windows before you let Windows connect to the internet

I will keep that in mind.

I would like Linux to be my first option at boot so I will install Windows first.

Last edited by HextorBRX (2017-08-24 14:39:47)

Offline

#7 2017-08-25 14:59:55

Somewhat Reticent
Member
Registered: 2017-04-06
Posts: 103  

Re: Manual partitioning: boot partition, dual boot

HextorBRX wrote:

… From what I understand, I should prevent grub2 installation by any means necessary! …

Only because you will be booting Windows on the same computer.  But relax! You' have ways to keep grub2 under control.

HextorBRX wrote:

… I would like Linux to be my first option at boot so I will install Windows first. …

Good plan, that will keep Win#'s ego happy. One step at a time. (Hey, there may be a tutorial from this!)

(You may want to adjust the subject of this thread (by editing your initial post) to note Windows dual-boot)

Last edited by Somewhat Reticent (2017-08-25 15:02:40)

Offline

#8 2017-08-25 17:16:32

alluredbit
Member
From: Chicago, IL
Registered: 2017-08-18
Posts: 24  
Website

Re: Manual partitioning: boot partition, dual boot

If you share the hardware, and have the UEFI I would consider booting into Devuan from a USB stick, and leave the MBR for Windows.

You may have a perfectly fine system running on detached external storage, in case you want to leave the internal hardware entirely for Windows. Create the / on the fastest storage you have, like a USB3, put the /boot on a USB2 stick and /home on something you can carry around. Your most important stuff is probably going into your /home anyways - unlike on Windows where you have them all over the place.

The swap partition is also optional, you may create swap file(s) later or use no swap. Linux is not using swap the same way Windows does. Linux is going to lock up as soon as you are just about to run out of RAM, in place of grinding at your swap endlessly. Just restart it an try not to load it up so much. Automated installs always create a swap partitions but you can use expert install and not create any other partitions besides /, /boot and /home.

On a single-user Linux system you have less disk activity vs. Windows so it is better suited for non-optimal configurations, and it is more flexible regarding file systems and partitions. Of course it is not going to perform optimal, but it is going to work. On busy systems it is recommended to keep /var separate from /, but again, on a single-user system no part of the system is really busy.


start.webtechbazaar.com
Describe whats important, what seldom or never change - then give it away!

Offline

#9 2017-08-25 20:16:29

greenjeans
Member
Registered: 2017-04-07
Posts: 541  
Website

Re: Manual partitioning: boot partition, dual boot

alluredbit wrote:

If you share the hardware, and have the UEFI I would consider booting into Devuan from a USB stick, and leave the MBR for Windows.

You may have a perfectly fine system running on detached external storage, in case you want to leave the internal hardware entirely for Windows. Create the / on the fastest storage you have, like a USB3, put the /boot on a USB2 stick and /home on something you can carry around. Your most important stuff is probably going into your /home anyways - unlike on Windows where you have them all over the place.

The swap partition is also optional, you may create swap file(s) later or use no swap. Linux is not using swap the same way Windows does. Linux is going to lock up as soon as you are just about to run out of RAM, in place of grinding at your swap endlessly. Just restart it an try not to load it up so much. Automated installs always create a swap partitions but you can use expert install and not create any other partitions besides /, /boot and /home.

On a single-user Linux system you have less disk activity vs. Windows so it is better suited for non-optimal configurations, and it is more flexible regarding file systems and partitions. Of course it is not going to perform optimal, but it is going to work. On busy systems it is recommended to keep /var separate from /, but again, on a single-user system no part of the system is really busy.

Great post!

I agree this is a great option, have played around with USB3 and it is gratifyingly fast to load a liveusb session, load it all into ram and watch your machine fly.


https://sourceforge.net/projects/vuu-do/
Vuu-do GNU/Linux, minimal Devuan-based openbox systems to build on, maximal versions if you prefer your linux fully-loaded.

Please donate to support Devuan and init freedom! https://devuan.org/os/donate

Offline

#10 2017-08-25 20:19:23

greenjeans
Member
Registered: 2017-04-07
Posts: 541  
Website

Re: Manual partitioning: boot partition, dual boot

Somewhat Reticent wrote:

(Is W'10 better-behaved? More testing needed?)

Oh hell no. Not long ago MS pushed an update that not only wiped out everybody's linux installs, it went so far as to actually delete the extra partitions.

You can't NOT know that's gonna happen, Microshit did it on purpose just purely out of spite.


https://sourceforge.net/projects/vuu-do/
Vuu-do GNU/Linux, minimal Devuan-based openbox systems to build on, maximal versions if you prefer your linux fully-loaded.

Please donate to support Devuan and init freedom! https://devuan.org/os/donate

Offline

#11 2017-08-25 23:19:19

alluredbit
Member
From: Chicago, IL
Registered: 2017-08-18
Posts: 24  
Website

Re: Manual partitioning: boot partition, dual boot

I installed Linux in a lot of different ways, and my main home server is my latest:
Its a dedicated box, but for your information it has 4x1 TB GBs in RAID 10 for /home, 1x256GB SSD for /root and swap, another 1x256 GB SSD for UFEI /boot, /svr to hold Windows swap files for the VirtualBox clients, and a second swap.

I cannot boot from RAID10 since UEFI cannot read it, so I needed a separate /boot partition.

I also needed something FAST for Windows swap partitions so I separated /svr for it.

Just to show, when VirtualBox consumes around 95% of the installed 32 GB RAM Linux (currently Debian) locks up and I have to hard-reboot. Yet, none of the two swap partitions on the SSD are touched. For VirtualBox using swap is pointless, and Linux is not going to force it so it locks up instead. If I had VirtualBox on a Windows server this would be different, as Windows would start swapping pages used by VirtualBox, to preserve RAM allocated to Windows itself. You decides wich is better - i prefer the Linux way.

You might want to add separate /boot, add any (or more swap) when your use case warrants it, this is also how you optimize and fine-tune a Linux system. Most of my background is in Windows, so it took me some time to realize this about Linux.

My two swaps are created for the host Debain OS, as it is also my proxy to cache apt files, my MariaDB to host the databases of virtualBox web isntallations and so on.. they are not being used by VirtualBox but they are used by other software.

And so on, as I said this box is my most recent, and I applied all my experience when I bought the parts and built it for the specific purpose to be a VirtualBox sandbox.


start.webtechbazaar.com
Describe whats important, what seldom or never change - then give it away!

Offline

#12 2017-08-25 23:45:41

Somewhat Reticent
Member
Registered: 2017-04-06
Posts: 103  

Re: Manual partitioning: boot partition, dual boot

greenjeans wrote:

… Not long ago MS pushed an update … on purpose just purely out of spite.

(Please be careful how you phrase that!)
Perhaps you refer to the flap about …  KB3193494 to fix KB3189866 to fix Windows 10 Anniversary Update … ?
Some reports said roll-back (withing 10 days?) could fail … I learned long ago to never trust any OS's "update".

Yet many dual-booter Linuxistas had no problem. Go figure. Of those, many didn't trust their internet connection to handle a large file perfectly; they download updates separately, then validate with checksums. Other reports noted problems with "store" apps, Skype, and other issues.

One approach is to put each OS on a separate drive, and use firmware (BIOS/UEFI) options to choose which drive to boot. Nice if you can.
I remember one setup with an external A/B switch from a single drive cable to two separate drives.
And then, of course, there's putting two separate operating systems on two separate machines.

Wayback item:  one old bootloader can hide/unhide partitions per script.

Last edited by Somewhat Reticent (2017-08-25 23:47:11)

Offline

#13 2017-08-26 02:49:40

fungus
Member
From: Any witch way
Registered: 2017-07-12
Posts: 497  
Website

Re: Manual partitioning: boot partition, dual boot

Not that windows7 is any good, but it was the last of non-destructive windows that could peacefully cohabitate with linux.
The rest might as well be considered a dummy terminal connected to Gates' mainframe.
I fail to understand the logic of paying for hardware and then handing it out to ms to control.

If this is a trend in things (past 6-7 years) we should maybe skip the agony, give our money to NSA and ask for a terminal login connection to their systems to get all our computing and communicating needs met.  I am serious, we are all spinning down the same hole, we might as well take a dive to the center and get it done with.  Globally, not just the US.
We don't need no stinking privacy, we definetely should not have a say on who gets elected as it doesn't get any worse worldwide, skip all the hypocricy and diplomacy trickery, and exterminate all the people you are going to exterminate anyway to get their oil and water, ....  and hope there is an afterlife after all.

What were we talking about?
Ohh wwwinnndoze.

Offline

#14 2017-09-03 12:48:50

HextorBRX
Member
Registered: 2017-08-20
Posts: 106  

Re: Manual partitioning: boot partition, dual boot

I didn't know Windows could delete my Linux partitions but I'll take my chances! I don't want to use Windows as main OS on my best computer anymore. I just need to take precautions: cloud, external hard drive etc.

There is also PCI passthrough but I don't have the requirements.

I intended to reinstall the grub bootloader from the live cd

 aptitude install mtools os-prober
grub-install /dev/sda
grub-install --recheck /dev/sda
update-grub

Offline

#15 2017-09-04 04:00:56

Somewhat Reticent
Member
Registered: 2017-04-06
Posts: 103  

Re: Manual partitioning: boot partition, dual boot

HextorBRX wrote:

I didn't know Windows could … but I'll take my chances! … I just need to take precautions: cloud, external hard drive etc. … I intended to reinstall the grub bootloader from the live cd …

… and suppress Microsoft "updates" (notify, maybe download, but NEVER automatically install), right? That's how earlier versions were brought to heel. (Does this still work for 8/8.1/10?)
That said, if some other user (family, "friend"?) can "accept" an update, the grub2win approach is less troublesome.

Last edited by Somewhat Reticent (2017-09-04 04:02:26)

Offline

Board footer