General Q&A about Linux and Unix-like operating systems
Filters (None)
On my current setup (running Linux Mint 20.3 Cinnamon), I have an administrative user and several ordinary users. I intend for all of these users to be in the same group, which happens to have the ...
Sometimes I share Unix commands online, and people chastise me for "useless use of cat" (UUOC) or "cat abuse". My cat is quite comfy and doing very well, thank you. What are they talking about?
Do any of the cron implementations allow you to manually trigger cron jobs (stuff in your crontab) right now, in the exact same manner as they would have when triggered on their usual schedule, exc...
I'm trying to containerize an application that currently uses apparmor to confine Python. This allows sandboxing of user-submitted code. How can I get docker and apparmor to play well together? Cu...
How to lookup user-id with the user's name? E.g. What's the UID of user linus?
How to ignore server certificate when using ldapsearch command-line tool? Of course this isn't something you should be doing regularly, but it would be a handy asset for troubleshooting.
How does the init process play a role in the booting of Linux?
When hardening my system with Lynis I had information about /etc/issue and /etc/issue.net being found weak. Lynis redirects me to Enterprise, which is a paid product and a bit overkill for my home...
I use unrar to extract rar archives sometimes: UNRAR 6.24 freeware Copyright (c) 1993-2023 Alexander Roshal Sometimes the archive root has several files, so if I do unrar x foo.rar it will...
I am trying to debug an issue with audio playback in MuseScore. During this process, I realised that I had/have no clue about audio playback in Linux (or in general for that matter). I already le...
How can I remap buttons on my mouse, especially for more exotic ones like MMO mice?
Suppose I have a PDF which is 2x3 in. I want to create a PDF with a single page, which has multiple copies of this. For example, if the small pieces are in landscape, and the large page is in portr...
I have a systemd unit that does some stuff on the internet. Sometimes this gets fired at startup. I want to make sure it's delayed until the computer is connected to the internet. In my notes I fo...
I want to switch hard drives. How do I migrate my root FS from the drive it's on, to the new one, so that everything is exactly as it is?
When I create the initramfs, I sometimes see messages like: ==> WARNING: Possibly missing firmware for module: 'xhci_pci' I get many for different modules. What do they mean? Should I in...
Motivating example: my Mint 20.3 distribution offers long-term support until April 2025, which matches the "standard support" offered for the upstream Ubuntu (20.04 "Jammy Jellyfish"). However, the...
In i3, is there a way to move an entire workspace to another monitor, including all windows it contains?
ip a command will conveniently show the addresses assigned to your network interfaces, but oftentimes this is not what the internet sees your machine as. So how to find your public IP address from...
For some time pacman used to have a problem where: Occasionally Arch maintainers introduce new GPG keys They start signing packages with the keys Your local pacman doesn't receive these until ...
When formatting drives with Gnome Disks, there is an option to "Erase". The help text says this takes longer, but "completely" erases data. What exactly does this option do? Is there a CLI equival...
A little while ago I was helping someone with running Python in a virtual environment, as root, for some specific purpose. I determined easily enough that this requires explicitly specifying the pa...
When you first connect to a host, ssh asks you about saving its fingerprint. If you do, on subsequent connections it will check the fingerprint and refuse to connect if it changed. I get that this...
My primary drive is partitioned basically like so (only roughly to scale): / /home junk v v v |xx###############...
I am trying to run Solr 9.5.0 on Windows Subsystem For Linux 2. It crashes with a Segmentation Fault and does not start. I can run it on Windows without an issue. Java version on WSL2: 17 Java ve...
I wrote a filter program to overwrite each line with the next one. $ cat /usr/local/bin/ovr #!/bin/sh sed '2,$s/^/\x1B[1A\x1B[K/'; Here's the behavior: $ echo | ovr $ echo 'foo' | ovr ...
My VISUAL setup interferes with my cron jobs. crontab -l works all right, I see my previous jobs. crontab -e, crontab -e -u user-here - opens GVIM on an empty file checked cron.allow or .deny,...
Desktop files always have either %u or %U as an argument for the program being launched. E.g. here's a line from my firefox.desktop: Exec=/usr/lib/firefox/firefox %u What does it mean?
My goal is to use a french AZERTY keyboard layout with Arch linux and Gnome desktop environment but use US English as "OS language". Note that I am also open to a "working" solution on any other d...
Neomutt (and probably Mutt too, but I didn't try) seems to be hiding header fields from email, such as the Message-ID field, and fields that are added by SMTP servers when they receive the message....
I am unable to create new tablespaces on a fresh Postgres 15.3 installation on Ubuntu 22.04. I tried the following so far: re-install Postgres fully loosen file system permission disabled SELi...
Will the overall unit status be failed if either ExecStop or ExecStopPost fail? I would expect it to be so, but the documentation isn't very explicit about it.
Guix is a rolling release distro. Another well known rolling release distro is Arch Linux. In Arch, you are expected to frequently do system updates. Partial updates are not supported. In my exper...
I am running X on Arch Linux without a desktop environment, only i3. Sometimes I need to switch between typing in different languages. How do I switch my keyboard layout?
Of course every language has some kind of random library... But can you generate custom random strings with just basic CLI tools? For example, we have /dev/random which provides a stream of random...
BTRFS is capable of spanning over multiple drives. How to add one more to an existing filesystem?
Suppose I have a directory structure like ├── src │ ├── folder_a │ │ ├── file_w │ │ └── file_x │ ├── folder_b │ │ ├── file_y │ │ └── file_z and I back it up using rsyn...
If I have an email in EML format, how can I determine its spam status from the terminal? My mail provider appears to insert a X-Acme-Spam-Status header. It looks like X-Acme-Spam-Status: v=1; e=b...
Unix is very permissive with filenames, and this can sometimes lead to a bunch of annoying corner cases when printing files. A well known example is when you put a newline in a filename, and it bre...
Suppose I have a list of files on standard input. These may be the output of find, cat filelist.txt or something else. How can I run a command on each file in turn?
With Debian 12, it seems that mysql-server is not available in the "default" package distribution and thus, cannot be installed with sudo apt install mysql-server or sudo apt-get... (I know that ma...
I want to connect to my university network via OpenVPN under Fedora GNOME. I imported the openvpn configuration provided by the university in the Network Manager GUI and specified the user certifi...
How to configure ZSH shell to print a timestamp on the right hand side of the prompt line when executing a command? I don't want to display the time prior to executing a command. Here's about how ...
I am using Linux Mint 20.3, with Cinnamon as a window manager. I have a folder named .pytest_cache on my Desktop: $ ls -1A | grep '^\.' .pytest_cache I know that if I open a Nemo window, navi...
How to convert a json file to yaml? Technically json is already valid yaml, but I'm talking about the characteristic easy-to-read yaml formatting with indentation and minimal quotes.
Why does XDG_DATA_HOME default to ~/.local/share? Why not something less cryptic, like ~/.data? Why did they decide use that path?
I store my address book with abook(1). https://manpages.debian.org/bookworm/abook/abook.1.en.html Let's say I want to introduce some contact in some field that accepts the usual name <email>...
When I try to start MariaDB server (same problem with MySQL) on a fresh Debian 11 install in a Windows Subsystem Linux (WSL) I got the following error: $ sudo systemctl start mariadb System has n...
I have a directory filled with Flac audio files and I would like to convert them all to Mp3. How do I go about this using FFmpeg? I am using the git FFmpeg and Slackware -current.
In gpg(1), one normally adds recipients of an encrypted message with --recipient. Those recipients will be able to decrypt the message, and their key ID will appear unencrypted, so anyone will kno...