Skip to content

Make Arch base even lighter?

Hey Arch Community,

I haven't been on Arch Linux for long, but I am already very enthusiastic about this distro and its capabilities. I mainly use it in a VirtualBox as I often implement various projects with it. However, something I would wish for is an even lighter version of Arch. Currently, even with the basic package without Linux firmware, you end up with over 1.4GB of space. Does anyone have experience with building an even more minimal system with Arch, including basic network/Wi-Fi support and essential tools? I think English language packages would suffice. I would be very pleased to hear your answers and ideas.

12 points49 comments
Open on Reddit
About this post
Posted
Archived
Score
12 · 66% up
Kind
Text
ID
172fgpy

Author

3
posts
6
comments
1
media
View profile

49 comments

Have you considered Alpine? the distro is originally designed to run in containers with very little resourse overhead, i think the base install is around 100mb

23 points

While installing Arch without all the dependencies of the base meta package is not officially supported, you can pick what packaged you want. You can also recompile the different packaged with fewer features. That said, if you want a smaller distro, you should just switch to a distro that is designed for small install size.

14 points

Try Alpine Linux for light weight.

10 points

Exactly my thought. There's a reason why so many dockers run it, I bet.

5 points

Yeah it’s my main distro now because it’s so well made and has so many nice common sense features built into it. But it’s super light weight. You literally add everything you need as you go. And it has the ability to be stable or rolling release with a simple command. The init system is OpenRC instead of systemd which is really nice too. The only problem is it uses Musl c library instead of glibc so proprietary Nividia drivers are difficult to get working. But I use it on a laptop with Intel so it’s fine for me.

I still think Arch is better in a lot of ways but Alpine is kind of brilliant.

2 points

Arch is going to use a ton of disk space because packages are built with a lot of options enabled and they don't split them up into -lib, -bin, -dev, etc. like a lot of distros do.

Pretty much anything else can achieve a smaller base. Gentoo can be tiny but you have to build from spurce, or your usual Debian/Fedora/OpenSUSE typically can have smaller base images.

Void is also pretty similar to Arch but I think splits packages more. I haven't used it much.

5 points

they don't split them up into -lib, -bin, -dev, etc. like a lot of distros do.

That is actually a feature.

Arch can be very slow. Op should probably post a list over stuff they have installed, and then we can give him some advice.

3 points

I just took a look at Alpine and it's indeed incredibly small for an installed system with network functionality. I'll definitely be taking a closer look at it. But for now, I'll still stick with Arch.

5 points

You can use pacstrap(8) to fine tune what gets pulled in as "base".

It sounds slow going but once you know what you want, you can script it for later installs.

I highly recommend doing this for i.e Debian (debootstrap) / Red Hat (dnf) too.

3 points

Gentoo is unfortunately not an alternative for me because I like to keep things simple. I also don't lack storage space. ;-) I was just wondering if it would be possible.

2 points

Gentoo or Linux from Scratch?

Arch is already pretty lightweight, and while I am a fan, if you want something lighter than you really need to invest into Gentoo (at least).

2 points

Strip down an installation to what you minimally need, make in image out of it.

Alternatively learn a different way to install arch, the wiki is your friend. 1st you need a partition, then a way to install pacman, and a shell, but they come together. At this point you can chroot into the installation, add the least amount needed to make it boot, kernel, bootloader. You need network, is dhcpcd and wpa_supplicant enough for you?

Now you can log-in, edit, connect, install. If you are not going to be building software what do you need base-devel for?

Trim trim trim, as long as you can boot and connect in any machine/situation you encounter. That is as minimal as you need. If you can boot without linux-firmware any place you try, then you don't need linux-frimware.

Arch makes an image so it can boot and provide basic utilities for nearly all situations and setups. To some people that is TOO much.

2 points

Artix

1 points

Thanks for the tip. I'm not quite sure if I've tried Artix yet, but I'll give it another shot.

2 points

welcome. im rurprised that many rqacomended gento and nobody artix... ok it comes from arch so will not be a huge improvement, but should be lighter, smaller. Pick dinit as init. or openrc if u want to be safer...

1 points

Alpine (Arch based) image on Docker is literally 7MB and comes with the basics.

1 points

I think the default install is like 500mb, but yeah. If I wanted something more minimalistic than Arch I would use Alpine. And I do.

2 points

kernel(drivers) is fat it takes about 1 gb

1 points

In VirtualBox, at least, you don't need different drivers for GPU/CPU/NETWORK-drivers, etc.

1 points

Consider Debian (with debootstrap install you get a minbase variant with just not more than 200MB), this is because Debian does separate -dev, dbg, lib, etc from regular pkg. Alpine is also a good option (apk -X ${mirror}/latest-stable/main -U --allow-untrusted -p ${chroot_dir} --initdb add your_pkgs).

1 points

Actually because of the Arch features described to you, minimalistic visual desktop environments like dwm or xmonad are so popular. In my opinion, the minimalism of window managers results in increased CPU utilization, but this is a debatable issue.

Gentoo as a "browser loader" will be a minimal system and take up 1.2-1.5 gigabytes of disk space. Gentoo with all necessary programs, virtual machine, IDE, etc. will take about 20 gigabytes on disk. Further everything will depend on how often you will update your system(world) and install programs.

Void can claim to be a minimalist system, but the most minimalism is found in the environment of peculiar independent distributions like NixOS, Guix or LFS. After installation, most of these systems don't even have an Internet browser. But the problem is not minimalism per se, but what will be installed in the system.

1 points

Thank you for your response. I'll take a look at Void-linux. I wasn't familiar with it, but it sounds promising.

1 points

You could do custom builds with ABS but at that point, just use Gentoo. Portage is the right tool for that type of job.

1 points

ArcoLinux is based off Arch and has a minimal edition (XD edition I think).

1 points

Since you are in a VM and you only need English as a language, take a look at file exclusion lists in pacman.conf from Arch's docker image. It greatly reduces the space that is required while having a functional system.

1 points

Guys, wait until he discovers containers :)

1 points

Thank you for all your great ideas. Currently, I'm trying it with Alpine Linux and am already very impressed with the possibilities and the slim system. However, I've also been quite taken with Arch and will continue to use it as well.

If someone can give me a good example of using containers that could apply to me, then I will give it a try. My main system is Windows 11 and I need Linux for some projects, where I prefer a slim, tidy system. When I finish, I want to remove the system again. I think it's very easy with VDI drives.

1 points

Wow, I hadn't looked at the base package contents in a while -- it is quite extensive. The pacman wiki explains how you can choose packages within a group to install while not installing the entire group Installing package groups That's probably your best bet.

1 points

Keyboard shortcuts

Move and act

jork
Next / previous post or comment
Enteroro
Open the post
f
Open the media viewer
s
Save
h
Hide (the toast has Undo)
Tab
Right after an action: the toast's Undo
x
Collapse the comment
v
Next layout: cards, compact, grid

Go to

/
Search
gthenh
Home
gthena
All
gthens
Subreddits
gthenl
Library
?
This list
Esc
Close a menu or this list

In the viewer

←or→
Previous / next file
↑or↓
Previous / next post
korj
Previous / next post
Space
Play / pause
m
Mute
z
Zoom
s
Save
o
Open the post (on its own page: back to it)
Esc
Close

Keys do nothing while you type in a box.