Live data from Hacker News

A Linux Evening

fabiensanglard.net

11–20 of 330 posts

Re: A Linux Evening

#11

Yes, sometimes you land in these situations in Linux, but many times are self inflicted by unnecesary tinkering. I cannot see why dealing with all the … unwanted things from windows can ever be better. With mac if it is too new it will not be supported and after a few years you need to upgrade your hardware or are left to die. Apart from being an exclusive system for the rich.

This is why I run Fedora Silverblue. My Linux is now an appliance that upgrades atomically. If something breaks, I rollback. Once in a while, I pin a version that is known to work so it never gets garbage collected.

The other day I changed /etc/ld.so.conf and the system would not boot—my fault. I choose the previous deployment in GRUB and I had a working system back.

Re: A Linux Evening

#12
Side note: I've been working on creating a new blog now that I've completed my name change (and whatever other aspects of my transition affect my public persona). This blog's minimalism is still distinctively styled and I'd like to do something visually similar. The choice to make it black-on-light-gray is somewhat pleasing. Has a consensus been reached on dark styling affecting readability?

Re: A Linux Evening

#13
I mean it's obviously a kernel bug. Now I wonder if it's nice to have a way to work around them, or if these work arounds are detrimental to them ever getting fixed properly.

Re: A Linux Evening

#14

Side note: I've been working on creating a new blog now that I've completed my name change (and whatever other aspects of my transition affect my public persona). This blog's minimalism is still distinctively styled and I'd like to do something visually similar. The choice to make it black-on-light-gray is somewhat pleasing. Has a consensus been reached on dark styling affecting readability?

Some like it, some overdo it. Apparently many live in darkened caves and use dark mode all day. And for me too much contrast in dark mode means harder to read because the white bleeds into the background. YMMV.

Re: A Linux Evening

#15
Thunderbolt devices appear in the OS as a PCIe switch, so you need two additional bus numbers (one for the Switch Upstream Port and one for the Switch Downstream Port). If the device is hotplugged to a port which has run out of bus numbers, you'll get this error message.

Mika Westerberg is constantly fine-tuning the allocation of PCI resources in the Linux kernel to avoid such scenarios. Some recent patches:

https://lore.kernel.org/linux-pci/20220905080232.36087-1-mik...

https://lore.kernel.org/linux-pci/20221130112221.66612-1-mik...

On macOS, it's possible to pause the PCI bus, reallocate resources and unpause the bus:

https://developer.apple.com/library/archive/documentation/Ha... (search for "Supporting PCIe Pause")

We don't have that on Linux unfortunately, so we depend on getting the initial resource allocation right.

Sergei Miroshnichenko has worked on such a reallocation feature for Linux but it hasn't been accepted into mainline yet and he hasn't posted a new version of his patches for almost two years, so the effort seems stalled:

https://lore.kernel.org/linux-pci/20201218174011.340514-1-s....

Re: A Linux Evening

#16
I said linux was fragile the other day and someone replied "in what way", this post is a good answer. In the past also I had similar critiques to my own criticism of Linux.

Who knows how many total days and weeks I spent on random things like this and all the obstacles I had to overcome. Just to get secure boot working on debian, I had to overcome their block of my vpn IP on their wiki, and the sign-tool which is impossible to find and after a lot of googling found an ubuntu post suggesting a weird kernel version speicific path that worked but the builtin vbox kernel module signing thing can't find it during apt update so at each kernel update I have to manually sign vbox modules (which means making the privkey readily available and defeating the whole point but whatever), at least I made a small script that only needs my secureboot pin/pass now. And then I decided to use apparmor, which is nicer than selinux but it took weeks to lockdown two apps and have them work and I am still not confident I did it right.

Ok,ok... let me pause there because I could go on. In my current day job, I attribute my success to two things: 1) Using linux for many years and fighting these "stupid" battles 2) I learned C which made learning a lot of other stuff a lot easier. I work in security now, so when there is a linux or container/k8s related incident it is easier for me than for my colleagues. I also don't shy away from difficult technically complex incidents or problems because I am battle-hardened in the art of figuring out seemingly random problems in topics I know nothing about with the sheer power of search engines, docs and random internet posts.

When I worked my first k8s incident, I knew nothing about it. I was watching talks by google people on one window while reading docs on another and poking around in the gke node scratching my head on why the hell a k8s node is running chromeos and everything is readonly. But all of that is a piece of cake. Try random browser crashes because weird grsec/pax patches (before they closed it off) that were messing with jit or untangling a dependency mess on a gentoo install neglected for years which doesn't even have a supported python version now. The brutality and fragility of Linux has given me a lot of mental muscles that has helped me immensly and it has forced me to be distrustful of software in general and learn a lot of stuff from programming languages to permission models, os architecture and gnu tools like sed,grep,awk and the like.

But yeah, I love linux so much but let's not pretend it is easy to use or user friendly. But hey, 2023 will be the year of the Linux desktop so we'll see.

A lot if *nix philosophy and mentality like "RTFM" and defaults not being a big deal I think are from an era where the ecosystem was much less complex and the userbase was much smaller. I attribute many of these pain points to that undying mindset.

Re: A Linux Evening

#17
post #7
post #5

Earlier quoted context omitted.

How is your comment related to the article? The only connection I can see is bad quality of some hardware and drivers.

It’s a reappearing issue with Linux that you run into problems other operating systems don’t have to this degree. Which is sad, because seeing the direction Windows 11 is heading towards, I’d like for Linux to achieve widespread adoption.

If you want that, then use it and contribute. That's the only way widespread adoption will happen.

Contribution does not necessarily mean code. It can be documentation, design, UX, sharing information, or just working getting people familiar with Linux.

Re: A Linux Evening

#18
I had a similar experience recently. Updated my Manjaro setup, rebooted, and was greeted with text mode. X just didn't load. 1 hour of reading logfiles and pondering about why the kernel module wouldn't load, it turns out I needed to add an obscure boot parameter (I think it was something like "ibp=off") to my kernel command line to make the nvidia module load again.

Easy solution if you know how to solve it, 1 hour searching for that solution, and about 0% chance of that knowledge ever being useful again in the future.

In the end I was still satisfied because at least I learned something (no matter if it's useful or not), and I was under no pressure to get that particular Linux system working again (I could still dual-boot Windows for example).

Re: A Linux Evening

#19
Kernel parameters are usually documented in the kernel-parameters.txt file in the source. See https://github.com/torvalds/linux/blob/master/Documentation/...:

  hpbussize=nn The minimum amount of additional bus numbers
    reserved for buses below a hotplug bridge.
    Default is 1.
The way to get from the error "No bus number available for hot-added bridge" at https://github.com/torvalds/linux/blob/master/drivers/pci/pr... to this specific kernel param is still a bit involved.
Post reply on HN