Update Debian Deleted by author today
quite the comprehensive list i have been thinking of adding a debian partition to take a look at the progenitor (if i recall correctly) the ubuntu systems i have come to call home. if i finally do so, i will definitely keep your list at hand
On the site, I have covered Linuxmint and Peppermint, both use the Ubuntu platform.
Essentially the same, but Ubuntu based derivative OS’es have firmware their users need, whereas Debain’s FOSS policy, their default installer packages, don’t. But are available for the individual install them afterwards as majority of modern hardware requires the firmware packages to function properly.
Glad I looked at this first as it saved me asking about Mint - thanks
spurred to action by a few debian posts of late (the time bump of this one by @ElectricDandySlider included) , i decided to log back in to my debian partition (inspired to install initially by @Akito’s debian advocacy combined with a general desire to learn new things/distros) and become a bit more familiar with the territory. i decided to follow along with your list to help me in that learning process.
i don’t claim to be either a linux or command line expert (i’d go with enthusiast), so i thought i would inquire about a few things as they popped up. the first was the beginning part of this line
[ -d /sys/firmware/efi ] does that direct the system to look in that location? basically “go see if this directory exists”? type of thing?
the more important question i think is: what the difference is between these two modes? it has been some time since install, but i don’t recall being presented with a choice between legacy and uefi (admittedly debian install was a bit more interactive than my previous ubuntu installs and i may have missed or just not understood the ramifications of any such choice). my system appears to be in legacy mode and i was wondering if that presents any issues since my system is new enough that it is uefi instead of bios, but are those (whole system bios/uefi differentiations) related to what this command is asking?
obviously i could do a quick duckduck and see what pops up, but thought i would get your take since your tutorial mentioned looking into the issue. thanks in advance for any help
suggestions like this (as well as the swap and cache ones below) are where i take pause. i feel like i have been around here long enough and read enough of your posts that i don’t think any of these commands will give you full access to my hidden stash of youtube knitting tutorials, but i am reminded of a warning i have seen a couple times on here as well as linux help subreddits and linuxquestions: don’t blindly run code you don’t understand or have a decent idea what it will do to your system.
i get that in general posts on the internet shouldn’t be ten pages long or people won’t bother to reading all the way through, but for my peace of mind i would need some kind of description as to what this change will do to my system and why that is beneficial. in some other thread @Akito suggested using the hide details feature (see below) so that a post of some system log or other wouldn’t fill the aforementioned ten pages. i think that could be of use if you decide to add any such details.
i hope this doesn’t come across as criticism. obviously your tutorial is yours and you should write it the way you feel is best. these are just my thoughts on how certain parts of it that i don’t understand well enough make me wary of changing my system just because
Identifying if Debian has been installed in UEFI mode
- [ -d /sys/firmware/efi ] && echo “Installed in UEFI mode” || echo “Installed in Legacy mode”
Essentially, it informs you how the OS was installed, either in UEFI or Legacy mode.
It becomes very useful when accessing an unknown computer, as with your other points they relate to a Computer/Laptop that has been installed in UEFI mode and has a SSD drive. You can not put UEFI into Legacy and vice versus.
If memory is correct, the I/O and fstab edits, don’t work in Legacy mode or if using a HDD. Plus the fstrim -v / command won’t work with an old platter style HDD. The terminal will return “Invalid command” or summat.
i hope this doesn’t come across as criticism. obviously your tutorial is yours and you should write it the way you feel is best.
My web site: https://sites.google.com/view/linuxhousekeepingtips/home I included details of my observations of the different distros I tried and prefer, essentially an “aide memoir” for my own benefit and the nuances to get each distro to run smoothly or even function. There is a chasm between well thought out distros that function to forget it.
Debian call it: https://wiki.debian.org/DontBreakDebian
This is a popular put down amongst Debian users with pretension of being the elite: Ubuntu is an ancient African word, meaning “can’t configure Debian”.
Debian I found a challenge, compared to the ease of Ubuntu and its other derivatives, whereas Debian requires a lot post install fettling to configure it properly. Once, achieved, I had the following feelings of being, content, satisfied or just plain relieved. But an achievement realised.
It is a continuous learning curve, the DIY project that will never end. As I seem to grasp this, it appears that it, is saying, hey boy, you know nought.
Hope this helps
I read a reply in another topic, you were experiencing wifi driver issues with your Debian partition. By editing the /etc/apt/sources.list file, this will enable the necessary non-free firmware, that could include your specific wifi driver.
Edit your /etc/apt/sources.list
deb http://ftp.uk.debian.org/debian/ stretch main
deb-src http://ftp.uk.debian.org/debian/ stretch main
deb http://security.debian.org/debian-security stretch/updates main
deb-src http://security.debian.org/debian-security stretch/updates main
# stretch-updates, previously known as 'volatile'
deb http://ftp.uk.debian.org/debian/ stretch-updates main
deb-src http://ftp.uk.debian.org/debian/ stretch-updates main
deb http://ftp.uk.debian.org/debian/ stretch main contrib non-free
deb-src http://ftp.uk.debian.org/debian/ stretch main contrib non-free
deb http://security.debian.org/debian-security stretch/updates main contrib non-free
deb-src http://security.debian.org/debian-security stretch/updates main contrib non-free
# stretch-updates, previously known as 'volatile'
deb http://ftp.uk.debian.org/debian/ stretch-updates main contrib non-free
deb-src http://ftp.uk.debian.org/debian/ stretch-updates main contrib non-free
Important to run this command after saving file:
If you require specific Deb help, PM me.
Under the hood, there are a lot of differences, but most of them are especially relevant to advanced/power users. The most obvious difference to everyone beyond beginner level of understanding is that you can create up to 128 primary partitions on the GPT/UEFI scheme as opposed to only 4 with the MBR/BIOS scheme.
To summarize the differences in a single sentence:
The GPT/UEFI scheme is more than 1000 times better than the old MBR/BIOS scheme.
The BIOS or UEFI, respectively, are extremely low level applications, on purpose. Even the full name for BIOS already presents this pretty clearly: Basic Input Output System
Which implies, that you can’t just choose which mode you are using. You have to set your UEFI to boot into the mode you want to use. In your case I would propose to set it to UEFI entirely, by also turning off CSM, which is the compatibility module so that you can use old MBR partitioned HDDs still with a UEFI. It is just for compatability, but if you can you should go for a GPT/UEFI combination. You in your case can, since you are doing a fresh installation anyway and your hardware has a UEFI.
Here’s how to do it:
Prepare HDD to be used with UEFI
- Open gParted.
WARNING: The following operation will seemingly delete the entire selected medium i.e. SSD, HDD…
- In the top menu bar select Create Partition Table, choose GPT and confirm.
The HDD is now ready.
Prepare machine to serve UEFI properly
- Reboot your machine.
- Enter UEFI by repeatedly presssing F2 or DEL, until you get into the UEFI menu.
- Navigate to boot options or whatever it is called on your machine.
- Enable UEFI mode, whereever possible.
WARNING: The following step will disable booting from old MBR based disks, in case you have some in use now that you didn’t prepare as explained above.
- Disable CSM. Sometimes this is called something like Legacy Mode or Legacy Support or just Legacy or BIOS compatibility or something like that.
- Reboot into your USB medium, that is also UEFI enabled.
- Install the distribution, as usual, but this time it will happen in UEFI mode.
As Akito rightly points out the benefit of UEFI over Legacy.
This can be overcome by using extended partitions with logical volume partitions, about 60 being attainable.
The main advantage UEFI is its ability to run larger disks of 3TB or more. These disks have to be formatted with GPT partition tables. Up to 128 primary partitions.
Legacy using MBR partition tables has a max ceiling of 2TB disks, 4 primary partitions and 60ish logical volume partitions.
You said you did not require a 10 page essay.
Forgot about this one, which is even more important and obvious than the partition amount. Nowadays, it’s not too hard to surpass this limit, at all. Yesterday, I got the new replacement hard drive for my previous 8TB one…
this helps. thank you for increasing my understanding
thank you for including this information as well. i was aware that i have an intel wifi card and had seen while debian was loading as well as looking at system logs that it was telling me i would need the same iwlwifi driver that ubuntu uses. a fairly quick search took me to the page below which listed the following steps:
Debian 9 “Stretch”
- Add a “non-free” component to /etc/apt/sources.list, for example:
# Debian 9 "Stretch"
deb http://httpredir.debian.org/debian/ stretch main contrib non-free
- Update the list of available packages and install the firmware-iwlwifi package:
apt-get update && apt-get install firmware-iwlwifi
- As the iwlwifi module is automatically loaded for supported devices, reinsert this module to access installed firmware:
modprobe -r iwlwifi ; modprobe iwlwifi
- Configure your wireless interface as appropriate.
the first two and fourth were fairly straightforward and went off without a hitch. modprobe, on the otherhand kept telling me it wasn’t installed and wouldn’t do so with a simple
apt install. that took a bit more searching. eventually i found the second link below which basically said use
that (and maybe sudo?) allowed both commands to run, but i still wasn’t able to see the wireless interface in wicd (i am using lxde with debian just because i hadn’t used it before. i don’t know if wicd is specific to lxde or not. it is simply the one that shows up in the system tray). i rebooted to see if that would make a difference.
while rebooting i noticed i didn’t get the message about wifi drivers not being installed before the login screen. i thought that was a good sign. it still didn’t show in wicd so it occurred to me to
apropos nm which led me to
nm-applet. sure enough, there it was. mission (one among many): complete
Is the next generation WiFi-manager, that everyone is supposed to use now.
That said, it is weird that Debian didn’t provide support for this device instantly.
I’m not overly fond of wicd as a network manager, though I’m currently using it with Debian LXDE, it does not display the network list I’m accustom to with the Gnome Network Manager. Spartan, but functional.
With my Dell laptops, by editing the /etc/apt/sources.list and updating it loads the appropriate Intel wifi firmware and driver.
Good hear that you managed to source your wifi firmware and driver.
That said, it is weird that Debian didn’t provide support for this device instantly.
Debian rarely provide firmware for modern equipment, due to their FOSS policy. wifi firmware has to be added at the install stage, something I’ve not successfully managed to do.
To overcome this issue, I use the Unofficial Firmware NetInstaller, and still have to edit the /etc/apt/sources.list file to activate Plymouth and Intel firmware, then install firmware-linux-nonfree to make it function correctly, along with post fettling tweaks.
It’s definitely weird to read such statement, as neither my friend nor me, who installed stock Debian on their laptops, respectively, had to fiddle around with WiFi drivers, at all. And it’s not like we have mainstream laptops or anything. He did an automatic installation, I do manual ones and we didn’t have a problem, yet.
Not weird, it’s how Debian distribute their OS, because of their stance with their FOSS policy, but allow Unofficial repos, such as the firmware-9.7.0-amd64-netinst.iso for modern day hardware.
Debian wifi wiki, see quote below.
Debian’s Social Contract mandates the freeing of the distribution. In practice this means manufacturers are required to cooperate by releasing specifications and free drivers that can be worked on by the community. Newer versions of Debian (6+) do not include non-free drivers or firmware.
Debian quote below
Which devices are scanned and which file systems are supported depends on the architecture, the installation method and the stage of the installation. Especially during the early stages of the installation, loading the firmware is most likely to succeed from a FAT-formatted floppy disk or USB stick. On i386 and amd64 firmware can also be loaded from an MMC or SD card.
Still, Debian isn’t specifically known to have unavailable WiFi, once installed.
@anon56357095 is this why some printer drivers aren’t installed ? When I tried it the other day they were not and it couldn’t even find the printer, an HP one which every other Distribution has found and installed. That was a pity as I quite liked what I saw and would have liked to have tried it longer.