Installing Debian without non-free firmware

29 risposte [Ultimo contenuto]
Avron

I am a translator!

Offline
Iscritto: 08/18/2020

I did not manage to do this as suggested in https://trisquel.info/fr/forum/system-32-bit-intel-pentium-m-computer#comment-173583, the way I managed is using the "expert" option (without "graphical") in the netinstaller. This shows the list of steps for installation, they are nearly the same like the non-expert options except that one needs to select them one by one, until "finish installation".

In the configuration of apt, there are questions whether to use non-free firmware, non-free software and contrib, of course one should say "no" to each.

I did this in order to use freedombox. Although the freedombox package is available in Trisquel, it wasn't tested with Trisquel and I suspect it won't work without issues. As I need an easily working system for emails, I am using Debian now. But I will try with Trisquel at some point. I did this with a virtual machine and I configured it to connect to a VPN from FDN (France Data Networks) that provides me a fixed IP address, which makes it nicely portable.

Avron

I am a translator!

Offline
Iscritto: 08/18/2020

I tried again on an old i386 machine, even so it is installing i386 microcode at the final step, without any choice. This is disappointing.

In the virtual machine case, I did not pay enough attention during the installation, so I am not sure.

Alice Wilton
Offline
Iscritto: 03/17/2023

After searching the web about alternative methods of installing Debian, I've discovered an existence of a fully manual method called debootstrap. It seems, using that method, you can configure /etc/apt/sources.list prior to install, thus avoiding installing any non-free components.
Link: https://ivanb.neocities.org/blogs/y2023/debootstrap

Avron

I am a translator!

Offline
Iscritto: 08/18/2020

Well, the situation is strange: /etc/apt/sources.list does not include non-free-firmware. Yet, dpkg -l intel-microcode says it is installed, and according to https://packages.debian.org, this package is from non-free-firmware.

So either apt was run looking at something else than /etc/apt/sources.list, or /etc/apt/sources.list was modified, or some other tool installed this package.

Thanks for the link on debootstrap. I was aware of that tool but the documentation I read so far about was less clear that what is on your link, so I may try it. In general, learning to use debootstrap might also be a good idea to install Trisquel on ARM boards. The steps looks very similar like the installation of Parabola. I will certainly try.

EDIT: There was also firmware-misc-nonfree. So the "expert" installation method really can't be trusted.

Alice Wilton
Offline
Iscritto: 03/17/2023

I'm glad you've found the link useful! Can Trisquel be debootstraped? I thought debootstrap is Debian's special feature.

jxself
Offline
Iscritto: 09/13/2010

With the new Debian version there's a new repo called nonfreefirmware. Now, instead of the old style triplet of main, contrib, and nonfree you have a quadruplet of main, contrib, nonfree, nonfreefirmware. The installer asks only about the nonfree repo, not nonfreefirmware - That's always enabled as long as the installer somehow thinks it's "needed."

Avron

I am a translator!

Offline
Iscritto: 08/18/2020

In the "expert" install, there is a question on non-free firmware first, set to "yes" by default but I have set it to "no" (after, there are two questions on non-free and on contrib, set to "no" by default). In spite of that, non-free firmware was installed, even though the non-free firmware is not in /etc/apt/sources.list.

I have checked this on i386. I will check on the amd64 virtual machine.

prospero
Offline
Iscritto: 05/20/2022

> intel-microcode

Rumor has it that some do not consider microcode as software. Maybe Debian is among them?

Avron

I am a translator!

Offline
Iscritto: 08/18/2020

That package is listed as part of the non free firmware repository in https://packages.debian.org.

https://wiki.debian.org/Microcode qualifies it as opaque and non-free, but this only comes after a recommendation to use microcode updates.

prospero
Offline
Iscritto: 05/20/2022

This is most probably a happenstance, but I just noticed that they are not mentioning it any more in their DSAs. Compare these two for instance:

https://www.debian.org/security/2019/dsa-4444 -> "only available in Debian non-free"
https://www.debian.org/security/2023/dsa-5474 -> nothing about non-free-firmware

Anyway, I had missed your edit above about firmware-misc-nonfree also being installed. It looks like their non-free-firmware switch is broken. The switch itself is free software, so someone should be able to have a look and suggest a fix. Not everyone voted for the inclusion of non-free firmware to become default.

Other_Cody
Offline
Iscritto: 12/20/2023

https://www.gnu.org/distros/common-distros.html
and
https://lists.debian.org/debian-devel-announce/2022/10/msg00001.html

have information about the Debian policy change, as well as

https://en.wikipedia.org/wiki/Debian

showing
"
Since its founding until 2022
"

so now it may not be possible to install Debian without installing non-floss things.

Unless somehow you edit it out of the source code, if you still can.

With Trisquel, and other floss operating systems you can change it to work for you.

Though at Debian 9.6.0 I think I found a non-floss city building game, even according to Debian's policy at the time in it's main repository.

https://trisquel.info/en/forum/missing-program-and-other-problems

Shows that as the reason I switched to Trisquel.

I think it had an
Artistic License
though I think on it's screenshot of the main game it had a non-floss copying policy, for commercial use, or something like that. That even broke Debian policy at that time.

Than I switched to Trisquel.

Other_Cody
Offline
Iscritto: 12/20/2023

https://www.hyperbola.info/

may have information about a 32-bit OS as well as a new HyperbolaBSD that is being made.

I think

https://www.parabola.nu/

and

https://www.gnu.org/software/guix/

may also have an operating system that works on a 32-bit machine.

Maybe also some 32-bit Trisquel things, though I do not remember what 32-bit it was that it works on.

Other_Cody
Offline
Iscritto: 12/20/2023

https://www.gnu.org/distros/free-distros.html
and
https://www.gnu.org/distros/free-non-gnu-distros.html

have all the floss operating systems I know though I also heard of gnuinos from https://trisquel.info/en/forum/gnuinos
I think and

from https://distrowatch.com/search.php?category=Free+Software#distrosearch

There is Uruk GNU/Linux based on Trisquel, I think.

Though I do not know about gnuinos and Uruk

at https://www.gnuinos.org/ and https://urukproject.org/dist/

tonlee
Offline
Iscritto: 09/08/2014

Following instructions should stop getting
non free firmware installed
on debian 12 x86 64bit. I do not know about debian 32bit.

https://www.debian.org/releases/bookworm/amd64/ch02s02.en.html

Start debian 12 iso
Press e
Enter
firmware=never
Press ctrl+x.

After installing debian you may search for non
free firmware with this command:
apt policy *nonfree

Avron

I am a translator!

Offline
Iscritto: 08/18/2020

> Start debian 12 iso
> Press e
> Press enter

With the netinstaller for 12.4, whether on i386 or in an x86 virtual machine, I first have a menu to choose between "Graphical Install", "Install", "Advanced options", "Accessible dark contrast installer menu", "Help" and "Install with speech synthesis". If I press e, nothing happens. If I press Enter, the install starts.

tonlee
Offline
Iscritto: 09/08/2014

> menu to choose between "Graphical Install", "Install", "Advanced options", "Accessible dark contrast installer menu", "Help" and "Install with speech synthesis"

In that menu press
the escape key on your keyboard.

Then you should get a boot prompt.
In the boot prompt write command: firmware=never
Then return to the installation. It appears
you are installing in legacy mode. In legacy mode you
get to the boot prompt by pressing the
escape key.
If you are installing debian in
uefi mode, then
you press e in order to get to the boot
prompt.

prospero
Offline
Iscritto: 05/20/2022

You may want to visit the Debian forums for such inquiries about the Debian installer:

https://forums.debian.net/viewtopic.php?t=156355
https://forums.debian.net/viewtopic.php?t=156525
https://forums.debian.net/viewtopic.php?t=154837

The general mood there seems to be that users who do not wish to use non-free firmware are on their own, but the first link above has a very detailed explanation of the inner working of the installer regarding the "firmware=never" boot parameter. If the issue you got with the expert install is confirmed, you should probably report it there.

rlux
Offline
Iscritto: 04/21/2024

Beware of "firmware=never". It doesn't always work, and you won't be warned if it didn't work. The following is my experience, and the reasons why I believe Debian must update all their installers to respect user choice regarding installation of non-free-firmware OR NOT:

I'm a 10+ year Debian user, and a longtime Free Software supporter. Two weeks ago I was shocked to discover 29 non-free components in the Debian desktop I'd been using for the last couple months. There hadn't been any opt-in or even a notice about Debian's major policy change during the installation process (I use the Debian installer via the Live images), so I was completely unaware.

In my initial attempts to figure out what was going on, I also didn't find any prominent announcement of the major policy change on Debian.org's homepage. Moreover, the "Our Philosophy" and "Why Debian" homepage links still give the impression that Debian is Free-Software-Friendly. That's extremely misleading now (automatically installing 29 non-free components with neither permission nor warning is not Free Software friendly).

If Debian is going to continue promoting itself with those "Our Philosophy" and "Why Debian" pages, there should at least be opt-ins during the installation process of every Debian download, as well as prominent warnings of the new policy on the download pages. Until that's done, the "Our Philosophy" and "Why Debian" pages (and perhaps others) should be re-worded so as to not be so misleading.

I was disappointed to eventually read of Debian's "vote" on non-free-firmware. Though I do understand the desire to make Debian more friendly to new users, doing so by misleading and alienating many existing users doesn't make a lot of sense IMO:

After reading of this change, I then spent the next week trying to figure out how to re-install Debian without the non-free firmware. That's when I discovered that Debian has suddenly become very Free-Software-UNfriendly. Even when I used the "firmware=never" method on the Debian installer (Live image dvd), the 29 non-free components were still installed! Without warning. That "firmware=never" method is what Debian.org itself is recommending (on a rather deep link sadly), but it doesn't even work!

So I eventually abandoned that longtime favorite method of installing my preferred desktop, and switched to the NON-Live DVD installation... But then discovered that using "firmware=never" method there also blocks FREE-firmware that used to get installed. So now my Wifi adapter didn't work, whereas it always worked with Debian 11/Bullseye and earlier installations.

Ultimately it took me about a week, and about a dozen Debian Bookworm re-installations, and even hiring a developer, to get an installation via DVD that was similar to what was previously installed by default. I've provided some tips below to others who are struggling. However, Debian needs to change all it's installers to provide "opt-in" for anything non-free. Even if that "opt-in" is checked by default, it should be easy to opt-out. Debian's current leadership may have lost sight of their own "Why Debian" and "Our Philosophy" and "Who we are and what we do" claims, but Free Software philosophy is still important to many people. Actually, it's still important, period. But whether the current leader/"voters" agree or understand or not, there should be choice for users.

Until the installers are updated, the Debian.org homepage and "Why Debian" and "Our Philosophy" and download pages should all be changed. Keeping them as they are is worse than misleading IMO (false advertising? bait-and-switch? negligent?). While an attorney could be consulted, why not just be responsible, and honest, and inclusive, by adding simple opt-in/out options on all Debian's installers?

Until the Debian installers are fixed, hopefully the tips below help some Free Software supporters who wish to continue using Debian. Note that I'm not a developer, so there may be mistakes in these instructions. If you find any mistakes, or have suggestions for improvement on these instructions, please post your suggestions in a reply:

1) Above all, avoid Debian 12 Bookworm's "Live image" installations. Those will install non-free firmware on your system no matter what you do. Even when I followed Debian.org's instructions for adding "firmware=never" before installing the OS, I still ended up with 29 non-free components on my system. That's exactly the same number as without "firmware=never", which means this method of blocking non-free-firmware doesn't work with Debian's live images. Therefore, avoid Debian Bookworm's live images completely.

2) If you're a technical person and want to support Free Software, you could install from Debian 12's "NON-Live" DVD. Adding "firmware=never" before installing with that DVD will block non-free-firmware (How to do that: on the DVD's opening "Boot Menu", scroll to "Start Installer" or "Graphical Install", hit Tab, and enter "firmware=never" to that line. I'm not sure if position matters, but I added it just before the "---" and that worked). UNFORTUNATELY, this method also blocks some FREE-firmware that Debian 11/Bulleye's Live image would have installed. Because of that, my WiFi adapter didn't work after installing Debian 12/Bookworm using this method, whereas my Wifi always worked immediately after installing Debian 11 with purely free firmware.

3) If you're a non-technical (casual) Debian user who wishes to support Free Software, you could revert to Debian 11's "Live DVD". While Debian 11's Live image DVD may also ignore "firmware=never", Debian 11 doesn't include non-free-firmware in the first place, so it doesn't matter that "firmware=never" get ignored. On the other hand, what was great about Debian 11's Live DVD installer is that it always recognized what free firmware my WiFi adapter needed, and installed it automatically. Therefore, my WiFi adapter (and everything else on my system) works immediately after installing Debian 11 with its 100% free firmware. That's longer the case with Debian 12/Bookworm.

4) Advanced: If you want a Debian DVD that installs the free-firmware, but not the non-free-firmware (ie. a Debian 12 DVD that installs the way Debian 11 did): You can use the program ISOMaster (FOSS in "main" Debian repository) to remove the folders /dists/bookwork/non-free-firmware/, /dists/bookwork/contrib/, /pool/non-free-firmware/, /pool/contrib/, as well as everything non-free in /firmware/. Unfortunately, that's a rather time consuming and tedious process. It would be easy for Debian to provide such an image for everyone, but it's challenging for casual Free Software supporters to perform individually. Also, this only works on Debian's non-Live images. To remove non-free-components from the the Live images, I believe would require modifying the squashfs file, which was beyond my abilities. Perhaps someone could post how to do that?

As a casual Debian user, it took me a week to figure this all out. The conclusion is that Debian 12/Bookworm is much, much less friendly for Free Software supporters than Debian 11/Bullseye was. The stuff about "Our Philosophy" and "Why Debian" and "Who We Are" on the Debian.org homepage is now very misleading IMO. There's not even a warning during Debian Bookworm's live image installation to warn people about this major change to Debian! Even worse, the hard-to-find instructions being provided by Debian.org for how to block non-free-firmware don't even work for the Live image installs. In either case (whether a user is aware of Debian's policy change and "firmware=never" instructions, or not), people who think they're avoiding non-free-firmware are actually getting non-free-firmware.

While I'm glad to have discovered workarounds to continue using Debian while also supporting Free Software, it was challenging, and I'm very disappointed to see how unimportant Free Software principles (on which Debian was built) are to Debian's current leadership. Supporting Free Software shouldn't require being a developer, nor hiring a developer, but Debian 12 took me a week to figure out. Debian 11 and previous releases were always super easy.

Again, it really doesn't make sense to try to make Debian accessible to more users by taking away what made it appealing to many of its existing users. That's trying to make Debian more popular by taking away what makes it special. It wouldn't be hard for Debian leadership to provide more Free-Software-Friendly installers. Individual users shouldn't have to go through what I went through (a week!).

I really hope something changes. In the meantime, I'm personally reverting to Debian 11 since it still has a few years of support. Trisquel is probably be a better option for most people who want to stay up-to-date. But as a web developer who wants my desktop OS to match my work OS, I'll stick with the workarounds for as long as I can.

By the way, for anyone who values Free Software principles, going forward it seems like a good idea to always check your Debian installations for non-free components immediately after installation. To do that:
a) as root, update your /etc/apt/sources.list and remove any non-free or contrib entries.
b) do: sudo apt-get update
c) install the FOSS application "apt-show-versions" by doing: apt-get install apt-show-versions
d) do this command: sudo apt-show-versions | grep "No available version in archive"
If nothing is listed, you're good. If something is listed, those are non-free, which means something wasn't done correctly during your installation. Some people may suggest just uninstalling those non-free components, but because those components are closed-source (aka. non-free(dom)), there's no way to know for sure what they've already done in your system now that you've booted up. Therefore, if anything is listed, my opinion is that it's best to re-install Debian.

Ironically, Debian 12 was the first time I ever experienced instability on Debian (my Wifi was breaking every couple hours). I have no way of knowing if it was the non-free-firmware causing a conflict, but my guess is yes because there was a conflicting non-free-firmware package. And now that I'm back to Debian 11, all is stable again.

Links referenced:
• Debian 12 Live install images to AVOID: https://www.debian.org/CD/live/
• Better option for Debian 12, where "firmware=never" works, and where you'll still be able to select your preferred desktop, but you may need to manually add free firmware after installation, which is annoying: https://www.debian.org/CD/
• Best option as of April 2024 in my opinion is to revert to Debian 11's Live install images: https://cdimage.debian.org/mirror/cdimage/archive/11.9.0-live/
• Instructions being provided by Debian.org (see section 2.2) that don't work with Live images, which is very misleading IMO: https://www.debian.org/releases/bookworm/amd64/

jxself
Offline
Iscritto: 09/13/2010

Improved suggestion: It's best to steer clear of Debian altogether. When things like Trisquel exist, we can recommend it instead to those people that want all free software, thus sidestepping any potential complications or uncertainties.

Avron

I am a translator!

Offline
Iscritto: 08/18/2020

For a desktop computer, I fully agree, but unfortunately, something like Freedombox is not made to work on Trisquel.

What I can think of is making a Trisquel version of Freedombox or making a Freedombox installer that will only take things from Debian main. While the first option sounds nice, it could require a lot more work than the second option.

Ark74

I am a member!

I am a translator!

Offline
Iscritto: 07/15/2009

AFAIK the freedombox package on trisquel works correctly.

Using arm SBC that's another story.

nparafe

I am a member!

Offline
Iscritto: 10/20/2020

I can confirm your observations.

Installing Debian GNU/Linux 12.5.0 using "expert install", selecting not to install "non-free firmware", even skipping entirely the part "select and install software" and going straight to grub-install, hw-detect runs and installs intel-microcode package automatically without any user input.
This is really sad...

Thank you for your guide.

prospero
Offline
Iscritto: 05/20/2022

Debian has long become an artifact of archeological interest, but whatever happened to that script should probably be reported:
https://sources.debian.org/src/hw-detect/1.160/check-missing-firmware.sh/#L361

Otherwise unsuspecting users are going to get non-free firmware installed, since they may not be reading the Trisquel forum, which is sad. Of course, this was to be expected ever since the policy change, and jxself's improved suggestion is indeed the safer one.

Psion
Offline
Iscritto: 12/29/2023

I don't know whether I still think what I thought before regarding, this,

But I will say three things at least:

Non-free firmware if available should have an opt out button appear during loading the installation ISO.

I originally thought it would be better for the landscape as a whole to include it but with one exception, they should bring attention to why its needed and how a free driver is desperately needed and say something like you can help this happen!

the next thing if anything, is that it is not acceptable to have it installed without the user's input nor is it okay for free drivers to be blocked when your only intending to block the non-free. That level of bugged thinking sounds absurd and is very bad.

Devuan has done and still does the same thing in the past and now probably too. Although its usually easy to correct, but its annoying. There really is no good reason to have it be opt in. And at bare minimum, I would hope they would mark it on the package manager as being non-free packages.

I don't know if they do that, but they very much should. So its easy to remove. Anywho I would prefer non-free stuff not exist. Problem being, some users would rather have some freedom, then none and aren't willing to go full freedom friendly like you guys would suggest. There needs to be a thought of:

no backdoors vs freedom which says, the main goal is to disable all backdoors to where they cannot turn on or misbehave without the user being a really stupid person and going out of their way to turn it back on through hoops of work, etc...

Some people just want backdoors turned off and that's enough for them and anything beyond is too much to entertain due to the limitations it causes.

Giving people some freedom is always better than giving none.

Case in point, some distros do this, give some freedom.

Where as windows, google and apple give almost none.

Magic Banana

I am a member!

I am a translator!

Offline
Iscritto: 07/24/2010

Non-free firmware if available should have an opt out button appear during loading the installation ISO.

Didn't you want to write "opt-in" (hence 100% free by default)? In your post, you then deem "it is not acceptable to have it installed without the user's input", what suggests an "opt-in".

how a free driver is desperately needed

The firmware is the problem. The driver is free, distributed under the GNU GPLv2 (or it is in violation of Linux's license).

Devuan has done and still does the same thing in the past and now probably too.

https://www.devuan.org/os/install#non-free-firmware says:

To avoid the automatic installation and loading of needed non-free firmware, choose the Expert install option during the installation process.

The desktop-live and minimal-live images have non-free firmware packages pre-installed. These packages may be removed after boot using the remove_firmware.sh script available under /root.

Well, that is something. However, it is still steering users towards non-free firmware: it is automatically installed by default (with no warning, apparently) and the live system loads it (does executing the rather-hidden shell script even change anything?; As far as I understand, the non-free firmware has already been sent to the device...).

I wonder what Gnuinos does. Is the free firmware loaded by the live system? Is it installed? If one wants to find out and report it here: https://www.gnuinos.org/mirror/daedalus/

no backdoors vs freedom

Without the freedom to study the software, you do not know if it includes a backdoor (probably only exploited on-demand).

prospero
Offline
Iscritto: 05/20/2022

Gnuinos uses Linux-libre, which I believe should answer your question about loading blobs, assuming that by "free firmware" you meant "non-free firmware".

As things stand, Xorg crashes when trying to boot the gnuinos live image if a blob dependent nvidia GPU is present. Devuan desktop-live does summon the blobs without questions.

Trisquel elegantly defaults to llvmpipe. Removing that blobbed nvidia card and using the integrated graphics is still the best course of action, obviously.

Magic Banana

I am a member!

I am a translator!

Offline
Iscritto: 07/24/2010

Gnuinos uses Linux-libre, which I believe should answer your question about loading blobs, assuming that by "free firmware" you meant "non-free firmware".

I meant "free firmware". Indeed, Gnuinos Daedalus is based on Debian 12, I assume it uses the Debian installer, and rlux reported:

But then discovered that using "firmware=never" method there also blocks FREE-firmware that used to get installed.
https://trisquel.info/forum/installing-debian-without-non-free-firmware#comment-176132

prospero
Offline
Iscritto: 05/20/2022

Humph. What a thick mess indeed.

Note that gnuinos is using its own version of the Debian installer. In fact, it should be called the gnuinos installer.

del111
Offline
Iscritto: 08/23/2023

I don't recommend using debian's netinst cd or dvd if you want to totally avoid non-free-firmware (including the unconditionally installed microcode mentioned above). I recommend instead you use debootstrap(1) to bootstrap the system so you *know* what packages are installed. Of course this may require some expertise at your end to finish configuring the bootstrapped system, but it's fun!

andyprough
Offline
Iscritto: 02/12/2015

>"I recommend instead you use debootstrap(1) to bootstrap the system so you *know* what packages are installed."

Why not just build Linux from Scratch? Then you'll really really really REALLY really really KNOW what packages are installed, since you compiled them all yourself individually.

Or you could just do the smart thing and install Trisquel.