Install Garuda on 4Kn Drive

Hello,

i use Linux since a wile, not yet installed Garuda (no "inxi") but i want to, actually using Artix-Plasma-OpenRC.

My question is very simple:
Do Garuda-Installer (Calamares) will recognize my 4Kn disk/nvme?
e.g.:

nvme id-ns /dev/nvme0n1 -H | grep LBA

and format at least UEFI & System Partition as follow?

mkfs.vfat -F32 -s 2 -S 4096 -v /dev/nvme0n1p1

mkfs.ext4 -F -b 4096 -F /dev/nvme0n1p2

See, please, additional info and "konsole"-outputs here GitHub - Advantaged/4Kn-Formatting: Convert & Format drives whith 4096 PBS/LBS (phisical/logical-block-size

An alternative solution could be...
You, gently, communicate me a step-by-step instructions:

  1. How to boot and install LTS-Kernel from USB-Install
  2. How to partition & format & create subvolumes that can be overtaken from Installer

Thank in advance and best regard.

P.S.: This "problem" is known by all distros or Unix-Like systems and i want not make any negative assumption to Garuda or any else.

Garuda doesn’t come with LTS kernel in it’s ISO by default for any version other than XFCE however devs do sometimes compile the ISO with LTS kernel for people facing issue on forum at times like here:

If you are using a ISO that has been compiled with LTS kernel it is going to include that in it’s final installation as well.

So, with that out of the way if you are able to boot into the Live ISO with the “normal” ISO having the zen kernel then sure you can install the LTS kernel into your garuda installation on the disk though you must know that calamares doesn’t provide you with some “way” to define what additional packages you want in your system so to download this:

  1. First finish installing garuda on your disk
  2. once done installing don’t simply hit reboot open the terminal and use garuda-chroot to access the installed OS on the disk following this post:

Please note that it goes on to explain how to install grub you don’t need to do that just enter the garuda-chroot.

  1. Once inside the chroot use pacman to download the lts kernel
pacman -S linux-lts linux-lts-headers
  1. Once done exit the chroot session with
exit
  1. Now you can reboot into your baremetal install and on the grub screen choose advanced options for garuda and use the LTS kernel to boot. Otherwise by default it uses the zen kernel.

Calamares provides the option of manual partitioning if you want to manually configure the partitions but most people just go with automatic and let calamares do it’s job. Apart from this if you are unsatisfied with what calameres offers in terms of partitioning, creating subvolumes etc.

You can create these partitions outside of calamares, even use some other file system while doing so and feed them to calamares installer.

Though do know that garuda uses btrfs snapper to roll back snapshots in case you have bad upgrades. By default, it exclude the home and log directories so only the relevant system parts get saved so knowing that be careful if you wish to use some other filesystem in garuda.

I don’t know about this but won’t you be able to find that out easily by booting with a live usb?

3 Likes

There is also the chroot tool in garuda-welcome and the possibility in the terminal.

garuda-chroot -a
2 Likes

Thank first for your quick reply.

I don’t want a special solution for me alone but a generic-solving solution for everybody, so no need of special iso just for me.

Do Garuda upgrade grub automatically? If not, do Garuda use a special command for that?

It’s possible to priorize LTS before rebooting and get just the right Kernel at reboot?
Do you know the command for prioritizing kernel?

I will not comment the next three chapter of your answer because:

  1. Is not a step-by-step instruction as I gently ask.
  2. I don’t know how to partition manually for btrfs specific for Garuda.
  3. I don’t know which subvolumes and how are mounted in Garuda, Garuda-Gamer, etc…
  4. At which point of the process can Calamares overtake is also not clear.

The “problem” is NOT if I can detect it, I know that all my nvme’s are 4Kn, the “problem” is… do Calamares detect it and format properly or will just use mkfs.fat instead of mkfs.vfat and don’t force twice ext4 to format properly.

As I know Calamares use Kpart or Gpart to make partition + formatting and both don’t understand anything about 4Kn.

The solution of all those troubles were –> Calamares have a script that detect PBS+LBS and use sgdisk & mkfs.vfat mkfs.ext4 mkswap as on my github shown. Till now neither the Calamares developer want to do, nor any other distros have done, I hoped on Garuda, that make all very simple, can accomplish to this/that.

Yes

Use garuda-boot-options

We try to help in this forum, we are not spoon-feeding.

Just test it. We are not the calamares developer, just open an isuue there. Please.

2 Likes

Servus SGS,

that mean, after the installation, before reboot, the target "disk" is still mounted and I can just garuda-chroot -a to access the fresh installed system?

After LTS-installation have I to update Grub (I suppose), do you know the command for Garuda to do this or the kernel-install-script will update grub by themself without my intervention?

Nevertheless I would know how to prioritize lts-kernel in grub or the above-mentioned kernel-install-script will prioritize last installed kernel automatically?

Can you help me with the partitions-topics or can you redirect me somewhere I can find the necessary instructions?

Yes

This forum is not a general technical support forum.
Did you whoogle about?
image

Before opening a new help request, please search the Arch and Garuda Wiki’s, and read any relevant sections related to your issue. Also, thoroughly search any error messages in the forum’s search engine and on the web. For in depth information on how to search for answers to Linux issues effectively read the tips on the Garuda Wiki:

3 Likes

There is a hook automatically regenerating the grub configuration after a kernel installation or update (by-the-way the command would be sudo update-grub).

Unfortunately, no prioritization and a strange situation. If for whatever reason you cannot use the tool garuda-boot-options, you could use this manual procedure, which I used many times, and was also successful for others.

The problem here for you is that at that time, you would not be able to know the “position” of the linux-lts kernel (this you will see the first time you reboot), so my suggestion in this case, since you need only the linux-lts kernel would be that you also remove the linux-zen kernel before rebooting. So the linux-lts would be the only one and default.

sudo pacman -R linux-zen linux-zen-headers
4 Likes

after rebooting, it’s like “Grub-Customizer”?

Sorry, I’m not searching for spoon-feeder nor for coffee-conversation, a link to manual partition for Garuda is enough and/or to the list of subvolumes with mount- (fstab) options.

As I already to other mate answered, I know that Calamares OOTB (till now) don’t support 4Kn cause of using kpart.
Just test it is a very bad idea, look, at certain point of installation Calamares want install Grub on EUFI partition that he cannot find anymore because of bad formatting (fat instead of vfat) will Calamares grab the first available/accessible UEFI-Partition on the system? Probably!

Well, I have four nvme on an pci-e–>nvm-e expander card, from which has two running operating system on it, could you imagine what happen if Garuda-Installed will replace one of thei UEFI-partitions?

This is the reason why I ask before in the forum ;-).
I know, these are “new problems” for the Linux-community and will take a wile before get resolved.
Just do not fall into patterns of behavior when someone don’t know a solution, ok? Try so solve together the issue, please.

Not at all, that should be avoided like the plague! :slight_smile:
It’s a Garuda application.

I’m just linking a thread with some pictures because I’m no more on the system:

3 Likes

I searched in the internet already and due the fact I forget many things, I “store” them on github, see link in my first post.

Sincerely, I feel a bit offended now and would like to ask you if you searched the internet before you answered me. I have done it, btw. since a couple of years I’m in contact with Calamares and rEFInd developer about 4Kn-“problem”. Even True-NAS, Synology & Co. have “problem” with 4Kn.

I just thought: Garuda made so many nice things, maybe have solved this topic and i can install a nice OS with no manual intervention.
Was I maybe wrong?

Linux has supported 4Kn since like 2010 and most modern file systems default to 4k, so I am not sure what the fuss is all about here?

2 Likes

Grazie di Cuore Filo, most professional answer till now, thanks.

Linke in Debian & derivate, perfect.

Wen booting from Live-Installer, I suppose, the garuda-boot-options will not work on mounted target-system, but, I can be wrong.

That’s best solution instead flickering in grub-boot-priorities, after remove the kernel, grub will be updated automatically, finish, no headaches.

Thanks again.

Please don’t take me wrong, but for us this is currently “unsupported HW” (unless it turns out to be a false problem, but that seems unlikely. I honestly don’t know anything about it).
We are a small distribution, with a small team, so we have to focus on what is in our area of responsibility (the apps we developed and the configurations we ship), and we have to stimulate the users writing in to search as much as we can (because of the above, we don’t have to do it ourselves).
I wouldn’t want to and couldn’t do statistics, but I think 3/4 of the new threads are on topics that have almost nothing to do with Garuda: often shamelessly application issues and even for non-default applications (but even if they are default packages, if we include them as-is, without ever customizing anything, we can’t get into troubleshooting and especially application fixes, this is an upstream aspect).
Now I have gotten away with SW-only considerations :slight_smile: , but similarly with particular HWs: we cannot support any possible combination of HWs in the market, it would really be too much.
Then maybe, I don’t know, one day this becomes an important topic (this is really the first time it has appeared since the forum has existed, 4Kn had never appeared until now) and then we will have to consider it.
TL:DR: we have to necessarily put some boundaries…

4 Likes

The LTS kernel is not available on the download page because then the latest hardware won’t be able to boot using that ISO plus that increases the dev’s work hence I linked you a LTS compiled ISO that was recently made for another user.

https://cloud.garudalinux.org/s/mrgSgCpayxJQj9p

You can download the ISO and use it.

The generic solution for all would be using the zen kernel that supports allmost all hardware.

Yes it’s done via pacman hooks you will see message at the end of installation that your initramfs is being rebuilt and that grub is being updated but you can still use the manual commands after installation is finished and before exiting chroot.

dracut-rebuild

To build your initramfs
And,

update-grub

To update your grub.

Yes it is but that requires editing your grub files. There are two ways to achieving this but what you are asking requires quite a bit of time and is quite easily achieved by either following this alternative method (linked message)

Or

You can always boot into your OS and then use garuda boot options a GUI app pre-installed in garuda to set this easily.

Or if you have decided to go the extra mile here is another linked article for you.

Again all these commands need to be inside chroot for them to affect your actual installed OS.

2 Likes

Here is my /etc/fstab file

# <file system>             <mount point>  <type>  <options>  <dump>  <pass>
UUID=XXXX-XXXX                            /boot/efi      vfat    umask=0077 0 2
UUID=XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX /              btrfs   subvol=/@,defaults,noatime,compress=zstd,discard=async,ssd 0 0
UUID=XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX /home          btrfs   subvol=/@home,defaults,noatime,compress=zstd,discard=async,ssd 0 0
UUID=XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX /root          btrfs   subvol=/@root,defaults,noatime,compress=zstd,discard=async,ssd 0 0
UUID=XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX /srv           btrfs   subvol=/@srv,defaults,noatime,compress=zstd,discard=async,ssd 0 0
UUID=XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX /var/cache     btrfs   subvol=/@cache,defaults,noatime,compress=zstd,discard=async,ssd 0 0
UUID=XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX /var/log       btrfs   subvol=/@log,defaults,noatime,compress=zstd,discard=async,ssd 0 0
UUID=XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX /var/tmp       btrfs   subvol=/@tmp,defaults,noatime,compress=zstd,discard=async,ssd 0 0
UUID=XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX swap           swap    defaults,noatime 0 0
tmpfs                                     /tmp           tmpfs   defaults,noatime,mode=1777 0 0

This was generated by calameres automatically I made no attempt to manually partition my disk nor do I use multiboot

Garuda is based on archlinux so anything that works for archlinux works for garuda as well.
You can look at this archwiki article for more info

https://wiki.archlinux.org/title/Partitioning

3 Likes

Ah! How could I miss my daily Arch wiki link? :wink:
https://wiki.archlinux.org/title/Advanced_Format#Advanced_Format_hard_disk_drives

5 Likes

Thanks for answering, also very professional, thanks again.

Advance Format is " Advanced Format 512e logo", you will find this just under the logo on Wikipedia.
That doesn't mean 4096 (4K) but only 512e*8. That does mean there are 8 blocks a 512 byte + start+stop bit, checksum etc., etc. and is much longer than a 4096 block having only one time "additional block information"

The disk-manufacturer build their storage all in 4K even some manufacturer that not permit to change the LBS. Also almost all disk are manufactured in 4K PBS-blocks.

Some Manufacturer like Corsair, Crucial and I think also WD permit to convert the LBS in native 4K ==> Advanced Format is NOT native 4Kn.

The "problem" is also not Btrfs or ZFS but fat & ext4 both to old, swap in contrary use by default 4096=4K block-format, hence take directly 8x512e and group them in one block or just take 1x4096.

If you visited my link on github you will recognize the special options must be assigned to UEFI- & ROOT-partition (if a ext4) to work:

mkfs.vfat -F32 -s 2 -S 4096 -v /dev/nvme0n1p1

mkfs.ext4 -F -b 4096 -F /dev/nvme0n1p2

As I (from Arch-Linux) regarding Btrfs know.
Make the partitions with sgdisk = ef00 for UEFI, 8300 for ROOT & 8200 for SWAP
Format vfat, encrypt Root, format Swap ==> encrypt Root

# cryptsetup --cifer aes-xts-plain64 --hash sha512 --use-random --verify-passphrase luksFormat /dev/nvme0n1p2

Open and format encypted Root:

# cryptsetup luksOpen /dev/nvme0n1p2 root

# mkfs.btrfs /dev/mapper/root

Mount Root & create subvolums:

# mount /dev/mapper/root /mnt

# cd /mnt

# btrfs subvolume create @

# btrfs subvolume create @home

# btrfs subvolume create @??? /missing list of Garuda & Garuda-Game subvolumes

Umount /mnt and mount Root-subvolum from which I have neither the list of all subvolumes nor the mount-options.

Also, a formatting with mkfs.ext4 is not necessary, ergo, only mkfs.fat instead of mkfs.vfat make problems that also the newest arch-linux-official-script has not yet solved.

That all mean, if I don't persist on better encryption, I can create and format EUFI and SWAP with the hope Calamares will overtake.

Can someone confirm my supposition or revise it?
Where is the mount-point of ef00? on /boot/efi or just in /boot?

Thanks all again.

Garuda defaults to the BTRFS filesystem, though it is my understanding it can use others. Garuda is built around BTRFS and several of the components that make Garuda, Garuda, will not otherwise function properly.

This is an opinionated, boutique-style Linux distribution, and best used as its developers have designed it.

Thanks Filo for answering again.

Please don't take me wrong too, but to tell that the standard 4Kn that exist since 20-25 years as unsupported HW (see also links of Kayo), that a very hard sentence.

I can understand that you want to protect my compatriot and you colleague SGS but I'm not ready to digest some subtle insinuations. I respect at most everybody work and specially the work of you team, you made already a great job and my little questions will not diminish your merits.

I can understand if someone say "I don't know" but please, before you made some affirmation like boundaries, special HW, not supported HW, etc. consider that 512 is gone, 512e (Advance Formatting) is dying and the only format remain for everybody (all unixoides= Btrfs & ZFS) is 4Kn= 4096 PBS/LBS.
Even etx4 is dying as you and many other distros almost don't use it anymore.

For solving problems are emotions often counterproductive, do you think so?
I prefer, if you are d'accord, getting technical information that helps solving topics.

Thanks again.