Skip to main content
Topic: Custom Artix Linux install script (Read 2759 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

Custom Artix Linux install script

Hello,

I’ve been working on making an install script for Artix Linux that either can be launched interactively or automated, if an answerfile is given. That’s together with a script to make an customised ISO for Artix Linux, which can autostart my install script, but that can be customised to point to an another git-repo containing a script. I’ve tested it extensively and there should be no bugs, so I thought I wanted to share it with you - and if you have any improvements or feature that you want added, then just reply here  :)

https://gitlab.com/FabseGP02/artix-install-script
https://gitlab.com/FabseGP02/artix-linux-iso-maker


Re: Custom Artix Linux install script

Reply #2
Yep good job and useful idea.  :)

Re: Custom Artix Linux install script

Reply #3
Just now builded a "new" PC from old used parts i had lay around.

And now testing your script.

First issue i got with last base openrc ISO:
Code: [Select]
localhost:[root]:/home/artix# git clone https://gitlab.com/FabseGP02/artix-install-script.git
git: /usr/lib/libc.so.6: version `GLIBC_2.34' not found (required by git)

Because of:

Code: [Select]
localhost:[root]:/home/artix# pacman -Ss glibc
system/glibc 2.36-3 [Installiert: 2.33-5]
    GNU C Library

So had first to install latest glibc too.

And i cant check "Replace elogind with seatd".

and to make a little advertisement hehe, if you offer doas as sudo alternative, i recommend following two packages created by me:

https://aur.archlinux.org/packages/vidoas
https://aur.archlinux.org/packages/vidoas-visudo

it delivers a tool like visudo for sudo, but for doas.

But until now, you did a great work! Only sad that until now im forced to use btrfs. but for testing no problem.

For me self, i prefer ext4 and xfs (snapshots i do with borg).

Re: Custom Artix Linux install script

Reply #4
Thanks a lot everyone - it was my first time making such a script, so that’s great to hear that you liked it. I plan to include some extra stuff - most noticeably a pacman hook to reinstall grub, when it’s updated, so that the current regression with the new version of grub shouldn’t affect anyone using my script (in theory at least); I was affected yesterday and haven’t been able to boot my system since :(

Just now builded a "new" PC from old used parts i had lay around.

And now testing your script.

First issue i got with last base openrc ISO:
Code: [Select]
localhost:[root]:/home/artix# git clone https://gitlab.com/FabseGP02/artix-install-script.git
git: /usr/lib/libc.so.6: version `GLIBC_2.34' not found (required by git)

Because of:

Code: [Select]
localhost:[root]:/home/artix# pacman -Ss glibc
system/glibc 2.36-3 [Installiert: 2.33-5]
    GNU C Library

So had first to install latest glibc too.

And i cant check "Replace elogind with seatd".

and to make a little advertisement hehe, if you offer doas as sudo alternative, i recommend following two packages created by me:

https://aur.archlinux.org/packages/vidoas
https://aur.archlinux.org/packages/vidoas-visudo

it delivers a tool like visudo for sudo, but for doas.

But until now, you did a great work! Only sad that until now im forced to use btrfs. but for testing no problem.

For me self, i prefer ext4 and xfs (snapshots i do with borg).


Just out of curiosity, what’s the spec of the used system now? I only have my 8th gen i5 laptop with 8GB of soldered memory, so it may still be faster than my system :D

Also thanks for testing my script, but the issue with git on the base ISO is unfortunately not within my control - if I recall, then Artix’ base ISO doesn’t contain git, so maybe installing git required a newer version of glibc than the one installed. There’s two way to mitigate this:

1. Use my other script to make a custom ISO that points to this script (maybe also supplying answerfiles, while you’re doing it)
2. Or ask @Artist (or whoever on the team that is responsible for the ISO’s) to include git from now on in the ISO’s ;)

And I should probably then take a look on why you weren’t able to choose “Replace elogind with seatd”, though seatd (at least for me now) has the issue that it doesn’t create a seatd-group; I’m not sure if that’s a bug or because of a change, but I’m not able to use it for now. Also, is there any specific reason to use the packages of yours for vidoas? I don’t have any issue including them in my script - as long as I get paid to do it :D - buuut doas.conf is already really simple; maybe I’m just missing something too :)

But great to hear that the installation went flawlessly, at least in my opinion - for me, BTRFS is the best file system :D Though I can understand wanting to install a specific file system, so if it isn’t too much to ask, can you then tell me if there’s anything else to do than mkfs.ext4 / mkfs.xfs? And what about encryption for both file systems, including how to handle it with Grub? Also, what exactly is Borg? If you reply back today, then I should be able to include options for ext4 and xfs :)

Re: Custom Artix Linux install script

Reply #5
Just now builded a "new" PC from old used parts i had lay around.

And now testing your script.

First issue i got with last base openrc ISO:
Code: [Select]
localhost:[root]:/home/artix# git clone https://gitlab.com/FabseGP02/artix-install-script.git
git: /usr/lib/libc.so.6: version `GLIBC_2.34' not found (required by git)

Because of:

Code: [Select]
localhost:[root]:/home/artix# pacman -Ss glibc
system/glibc 2.36-3 [Installiert: 2.33-5]
    GNU C Library

So had first to install latest glibc too.

And i cant check "Replace elogind with seatd".

and to make a little advertisement hehe, if you offer doas as sudo alternative, i recommend following two packages created by me:

https://aur.archlinux.org/packages/vidoas
https://aur.archlinux.org/packages/vidoas-visudo

it delivers a tool like visudo for sudo, but for doas.

But until now, you did a great work! Only sad that until now im forced to use btrfs. but for testing no problem.

For me self, i prefer ext4 and xfs (snapshots i do with borg).


Hmm, the only way I can recreate not being able to replace elogind with seatd in the script is when NetworkManager is not replaced by connman, which is by design - NetworkManager requires elogind and so far I haven’t been able to make it work with seatd. Have you maybe been able to make it work with seatd? Or do you rather still have the option to replace elogind with seatd, even though it may mean that NetworkManager will not work? :)

I read a bit about Borg in the meantime and it seems smart - I’m now trying to use it with my Raspberry Pi 4 server - so now I’m also working on replacing snapper with btrbk for snapshots, which has support for both local and remote backups as well; that’s in a separate branch though ;)

Re: Custom Artix Linux install script

Reply #6
Quote
Just out of curiosity, what’s the spec of the used system now? I only have my 8th gen i5 laptop with 8GB of soldered memory, so it may still be faster than my system :D

lol, you 8th gen is way newer what i have lay around here and im using.

The of boredom builded pc:
Code: [Select]
                   '                       user@mediapc
                  'o'                      ------------
                 'ooo'                     OS: Artix Linux x86_64
                'ooxoo'                    Kernel: 5.19.3-zen1-1-zen
               'ooxxxoo'                   Uptime: 4 mins
              'oookkxxoo'                  Packages: 691 (pacman)
             'oiioxkkxxoo'                 Shell: bash 5.1.16
            ':;:iiiioxxxoo'                Resolution: 1920x1080 @ 60Hz
               `'.;::ioxxoo'               DE: KDE Plasma 5.25.4
          '-.      `':;jiooo'              WM: KWin (X11)
         'oooio-..     `'i:io'             WM Theme: Breeze
        'ooooxxxxoio:,.   `'-;'            Theme: Breeze (Dark) [QT], Breeze [GTK2/3]
       'ooooxxxxxkkxoooIi:-.  `'           Icons: breeze-dark [QT], breeze-dark [GTK2/3/4]
      'ooooxxxxxkkkkxoiiiiiji'             Font: Noto Sans (10pt) [QT], Noto Sans (10pt) [GTK2/3/4]
     'ooooxxxxxkxxoiiii:'`     .i'         Cursor: breeze (24px)
    'ooooxxxxxoi:::'`       .;ioxo'        Terminal: konsole
   'ooooxooi::'`         .:iiixkxxo'       CPU: Intel Core i7-3820 (8) @ 5.7GHz
  'ooooi:'`                `'';ioxxo'      GPU: Nvidia GeForce GTX 1070
 'i:'`                          '':io'     Memory: 1190MiB / 15936MiB (7%)
'`                                   `'    Disk (/): 7.0 GB / 425GiB (1%)
                                           Locale: de_DE.UTF-8


My Desktop:
Code: [Select]
                   '                       user@polis
                  'o'                      ----------
                 'ooo'                     OS: Artix Linux x86_64
                'ooxoo'                    Host: MS-7B92 1.0
               'ooxxxoo'                   Kernel: 5.19.3-zen1-1-zen
              'oookkxxoo'                  Uptime: 16 mins
             'oiioxkkxxoo'                 Packages: 1419 (pacman)
            ':;:iiiioxxxoo'                Shell: bash 5.1.16
               `'.;::ioxxoo'               Resolution: 3840x2160 @ 60Hz
          '-.      `':;jiooo'              DE: KDE Plasma 5.25.4
         'oooio-..     `'i:io'             WM: KWin (X11)
        'ooooxxxxoio:,.   `'-;'            WM Theme: Breeze
       'ooooxxxxxkkxoooIi:-.  `'           Theme: Breeze (Dark) [QT], Breeze [GTK2/3]
      'ooooxxxxxkkkkxoiiiiiji'             Icons: breeze-dark [QT], breeze-dark [GTK2/3/4]
     'ooooxxxxxkxxoiiii:'`     .i'         Font: Noto Sans (10pt) [QT], Noto Sans (10pt) [GTK2/3/4]
    'ooooxxxxxoi:::'`       .;ioxo'        Cursor: breeze (48px)
   'ooooxooi::'`         .:iiixkxxo'       Terminal: konsole
  'ooooi:'`                `'';ioxxo'      CPU: AMD Ryzen Threadripper 1950X (32) @ 3.4GHz
 'i:'`                          '':io'     GPU 1: Nvidia GeForce GTX 1080 Ti
'`                                   `'    GPU 2: Nvidia GeForce GTX 1080 Ti
                                           Memory: 3630MiB / 64269MiB (5%)
                                           Disk (/): 793 GB / 911GiB (87%)
                                           Locale: de_DE.UTF-8

My Server
Code: [Select]
         .://:`              `://:.            root@capsule 
       `hMMMMMMd/          /dMMMMMMh`          ------------
        `sMMMMMMMd:      :mMMMMMMMs`           OS: Proxmox VE 7.2-7 x86_64
`-/+oo+/:`.yMMMMMMMh-  -hMMMMMMMy.`:/+oo+/-`   Kernel: 5.15.39-4-pve
`:oooooooo/`-hMMMMMMMyyMMMMMMMh-`/oooooooo:`   Uptime: 5 days, 22 hours, 6 mins
  `/oooooooo:`:mMMMMMMMMMMMMm:`:oooooooo/`     Packages: 930 (dpkg)
    ./ooooooo+- +NMMMMMMMMN+ -+ooooooo/.       Shell: bash 5.1.4
      .+ooooooo+-`oNMMMMNo`-+ooooooo+.         Resolution: 1680x1050
        -+ooooooo/.`sMMs`./ooooooo+-           Terminal: /dev/pts/0
          :oooooooo/`..`/oooooooo:             CPU: Intel i7-6700K (8) @ 4.200GHz
          :oooooooo/`..`/oooooooo:             GPU: Intel HD Graphics 530
        -+ooooooo/.`sMMs`./ooooooo+-           GPU: NVIDIA GeForce GTX 1070
      .+ooooooo+-`oNMMMMNo`-+ooooooo+.         Memory: 23155MiB / 31971MiB
    ./ooooooo+- +NMMMMMMMMN+ -+ooooooo/.
  `/oooooooo:`:mMMMMMMMMMMMMm:`:oooooooo/`                            
`:oooooooo/`-hMMMMMMMyyMMMMMMMh-`/oooooooo:`                          
`-/+oo+/:`.yMMMMMMMh-  -hMMMMMMMy.`:/+oo+/-`
        `sMMMMMMMm:      :dMMMMMMMs`
       `hMMMMMMd/          /dMMMMMMh`
         `://:`              `://:`

And finaly, my offline server for storing backups:
Code: [Select]
                   -`                    user@backup 
                  .o+`                   -----------
                 `ooo/                   OS: Arch Linux x86_64
                `+oooo:                  Host: GA-MA790XT-UD4P
               `+oooooo:                 Kernel: 5.16.12-arch1-1
               -+oooooo+:                Uptime: 11 mins
             `/:-:++oooo+:               Packages: 336 (pacman)
            `/++++/+++++++:              Shell: bash 5.1.16
           `/++++++++++++++:             Resolution: 1024x768
          `/+++ooooooooooooo/`           Terminal: /dev/pts/1
         ./ooosssso++osssssso+`          CPU: AMD Phenom II X6 1100T (6) @ 3.537GHz
        .oossssso-````/ossssss+`         GPU: NVIDIA GeForce 210
       -osssssso.      :ssssssso.        Memory: 184MiB / 7945MiB
      :osssssss/        osssso+++.
     /ossssssss/        +ssssooo/-                              
   `/ossssso+/:-        -:/+osssso+-                            
  `+sso+:-`                 `.-/+oso:
 `++:.                           `-/+/
 .`                                 `/



Quote
Also, is there any specific reason to use the packages of yours for vidoas? I

No :) This is only needed, if you want to be sure that the "workflow" with doas is the same like on sudo.

For that is following needed:

https://aur.archlinux.org/packages/opendoas-sudo << alias sudo -> doas
https://aur.archlinux.org/packages/vidoas << same like visudo, but for doas.
https://aur.archlinux.org/packages/vidoas-visudo << alias visudo -> vidoas

i would make them optional.

Quote
Also, what exactly is Borg?

You already read something about that like you said  :)  Its a nice program to make backups, especially incremental ones.

And the best thing is, the repo could be anywhere. Mine is on a NFS Share for example.

Re: Custom Artix Linux install script

Reply #7
>  There is no ISO in /ISO/base, I've tried running the program through SU and regular with the same issue.

Re: Custom Artix Linux install script

Reply #8
==> WARNING: Continue squash: buildiso -p base -sc ...
sed: can't read /home/root/BUILDISO/buildiso/base/artix/rootfs/etc/dinit.d/tty1: No such file or directory
cp: cannot create regular file '/home/root/BUILDISO/buildiso/base/artix/rootfs/etc/profile.d/startup_choice.sh': No such file or directory
mkdir: cannot create directory ‘/home/root/BUILDISO/buildiso/base/artix/rootfs/scripts’: No such file or directory
mkdir: cannot create directory ‘/home/root/BUILDISO/buildiso/base/artix/rootfs/.nothing’: No such file or directory
mkdir: cannot create directory ‘/home/root/BUILDISO/buildiso/base/artix/rootfs/.encrypt’: No such file or directory
mkdir: cannot create directory ‘/home/root/BUILDISO/buildiso/base/artix/rootfs/.decrypt’: No such file or directory
cp: target '/home/root/BUILDISO/buildiso/base/artix/rootfs/scripts': No such file or directory
sed: can't read /home/root/BUILDISO/buildiso/base/artix/rootfs/scripts/keymap.sh: No such file or directory
cp: cannot create regular file '/home/root/BUILDISO/buildiso/base/artix/rootfs/etc/NetworkManager/conf.d/wifi_backend.conf': No such file or directory
cp: target '/home/root/BUILDISO/buildiso/base/artix/rootfs/': No such file or directory
cp: cannot create regular file '/home/root/BUILDISO/buildiso/base/artix/rootfs/': No such file or directory
==> ERROR: Can't create chroot on non-directory /home/root/BUILDISO/buildiso/base/artix/rootfs/
==> Start building [base]
==> Generating SquashFS image for /var/lib/artools/buildiso/base/artix/rootfs
Parallel mksquashfs: Using 8 processors
Creating 4.0 filesystem on /var/lib/artools/buildiso/base/iso/LiveOS/rootfs.img, block size 131072.
[=======================================================================================================================================================================================================================\ ] 67149/67436  99%
Unrecognised xattr prefix system.posix_acl_default
[========================================================================================================================================================================================================================\] 67436/67436 100%

Exportable Squashfs 4.0 filesystem, zstd compressed, data block size 131072
        compressed data, compressed metadata, compressed fragments,
        compressed xattrs, compressed ids
        duplicates are removed
Filesystem size 694025.97 Kbytes (677.76 Mbytes)
        44.43% of uncompressed filesystem size (1562022.27 Kbytes)
Inode table size 586024 bytes (572.29 Kbytes)
        20.99% of uncompressed inode table size (2792288 bytes)
Directory table size 786945 bytes (768.50 Kbytes)
        39.29% of uncompressed directory table size (2002730 bytes)
Xattr table size 50 bytes (0.05 Kbytes)
        41.67% of uncompressed xattr table size (120 bytes)
Number of duplicate files found 13792
Number of inodes 81664
Number of files 68594
Number of fragments 4729
Number of symbolic links 6872
Number of device nodes 0
Number of fifo nodes 0
Number of socket nodes 0
Number of directories 6198
Number of hard-links 2029
Number of ids (unique uids + gids) 11
Number of uids 5
        root (0)
        rpcuser (34)
        ntp (87)
        rpc (32)
        nbd (978)
Number of gids 10
        root (0)
        cups (209)
        polkitd (102)
        ftp (11)
        tty (5)
        dbus (81)
        games (50)
        rpcuser (34)
        rpc (32)
        nbd (978)
  -> Creating md5sum ...
==> WARNING: Continue boot: buildiso -p base -bc ...

----------------------------------------------------------------
------YOUR CUSTOM ISO CAN BE FOUND AT /home/root/ISO/base------
----------------------------------------------------------------

Re: Custom Artix Linux install script

Reply #9
Great job first of all.

I have also idea to make my own ISO but less experience to do it by myself. Installed arch three times and no one Artix without GUI.
I'm interested on testing but would prefer to partition manually by myself (let some empty space at end of carrier), if I remember well, partitioning the root as ext4 for btrfs, formatting vfat by myself, by btrfs should overtake the install-script the task.

The change you made point to the future and I like this. Well, I don't know if it's interesting for you and want remain short, hence I will make a minimal list of what I think could be better:
  • File-System: vfat (FAT 32) for EFI and ext4 for root don't really understand 4k-block-size. What's about ZFS?
  • Partitioning-Tools: well there is only one group of tools gptfdisk (sgdisk, gdisk) make the job right, sadly.
  • Kernel-maintained-app/-drivers: that's a pain, I tried to make an Arch-ISO with ZFS on board but the kernel was newer than the available ZFS-package, maybe was my fold but I abandon the idea.
  • Boot-Loader: grub cause me also pains since *buntu 10.4, rEFInd at least don't let you with a black screen & the ZFS-drivers are available as for grub too, easy to modify.
  • Themes: there are very few complete themes, the adjustment in plasma are difficult, breeze-dark should be the default, gtk3 with rounded and bigger scroll-bars, sadly the Qt-Version is hard-coded and not changeable, I like the Artix-Kick-Off with favorites as symbols left-side but the rest not.
  • LC: I don't know if COLLATE=C is ISO-8601 or not but COLLATE & TIME should be ISO in the system and for all for files-managers.
  • Shell & Prompt: ZSH is my wish, with colors, auto-completion, syntax-highlight and adequate fonts good also for kate, kwriter, etc., the promt of GUI-installed Artix is perfect, first Server-Name, than User-Name, etc., date and time in ISO-format as option could be a nice thing.

Zen-Kernel coming from/for Debian, True-NAS-Scale based  on Debian, Artix-ZFS = ZFS on Linux without systemd.

Are there detailed instruction for an non-expert like me for installing this iso?

Thanks and greetings.

Re: Custom Artix Linux install script

Reply #10
Sorry for being gone for so long - I've been a bit busy since starting my first semester as an electronics engineer, so I took a break from the script; except from smaller commits ;)

But thanks for all the feedback and questions too - I'm happy to hear that some of you have use for it! I plan to reply back (and perhaps also implementing some of your suggestions) this weekend :)

Re: Custom Artix Linux install script

Reply #11
@fabseman  I create the partitions but then I can not move forward? I press enter and nothing... it stays there.

Re: Custom Artix Linux install script

Reply #12
@fabseman  I create the partitions but then I can not move forward? I press enter and nothing... it stays there.

we must detect exactly the carrier before partitioning and formatting if it's a 512 or 4k otherwise we come in to trouble.
If the carrier have a PBS (physical block size) of 512, must the LBS (logical block size) formatted to 512 too and not 512e (like samsung do), if the PBS is 4k than we can use the 4k without any complication.

The Linux-Kernel assume the carrier is 4k by default, ext4 must be forced to accept/use 4k (see my link above https://github.com/Advantaged/4Kn-Formatting), other FS (eg. btrfs, zfs) use 4k by default.

So we are forced to detect the PBS and use the right LBS and/or convert the PBS like in Corsair carrier possible.