this post was submitted on 09 Apr 2024
309 points (98.7% liked)

Linux

48330 readers
799 users here now

From Wikipedia, the free encyclopedia

Linux is a family of open source Unix-like operating systems based on the Linux kernel, an operating system kernel first released on September 17, 1991 by Linus Torvalds. Linux is typically packaged in a Linux distribution (or distro for short).

Distributions include the Linux kernel and supporting system software and libraries, many of which are provided by the GNU Project. Many Linux distributions use the word "Linux" in their name, but the Free Software Foundation uses the name GNU/Linux to emphasize the importance of GNU software, causing some controversy.

Rules

Related Communities

Community icon by Alpár-Etele Méder, licensed under CC BY 3.0

founded 5 years ago
MODERATORS
 

I thought I'll make this thread for all of you out there who have questions but are afraid to ask them. This is your chance!

I'll try my best to answer any questions here, but I hope others in the community will contribute too!

top 50 comments
sorted by: hot top controversial new old
[–] [email protected] 100 points 7 months ago (2 children)

Mods, perhaps a weekly post like this would be beneficial? Lowering the bar to entry with some available support and helping to keep converts.

[–] [email protected] 16 points 7 months ago* (last edited 7 months ago) (4 children)

Agreed. @[email protected], I think this would be a great idea - making a weekly megathread for Linux questions, preferably also stickied for visibility.

load more comments (4 replies)
[–] [email protected] 14 points 7 months ago

Yeah I was thinking the same. Perhaps make a sticky post about it once a week.

[–] [email protected] 32 points 7 months ago (2 children)

Is it difficult to keep your leg shaved and how many pairs of long socks do you have?

[–] [email protected] 10 points 7 months ago

Don't try to shave. Use hair removal creams instead. You get longer lasting results and the skin is actually free from hair stubbles.

I have 6 pairs.

load more comments (1 replies)
[–] [email protected] 29 points 7 months ago (2 children)

OP. Gotta say that this thread is a brilliant idea!

load more comments (2 replies)
[–] [email protected] 25 points 7 months ago (7 children)

How do symlinks work from the point of view of software?

Imagine I have a file in my downloads folder called movie.mp4, and I have a symlink to it in my home folder.

Whenever I open the symlink, does the software (player) understand «oh this file seems like a symlink, I should go and open the original file», or it's a filesystem level stuff and software (player) basically has no idea if a file I'm opening is a symlink or the original movie.mp4?

Can I use sync software (like Dropbox, Gdrive or whatever) to sync symlinks? Can I use sync software to sync actual files, but only have symlinks in my sync folder?

Is there a rule of thumb to predict how software behaves when dealing with symlinks?

I just don't grok symbolic links.

[–] [email protected] 17 points 7 months ago (2 children)

A symlink works more closely to the first way you described it. The software opening a symlink has to actually follow it. It's possible for a software to not follow the symlink (either intentionally or not).

So your sync software has to actually be able to follow symlinks. I'm not familiar with how gdrive and similar solutions work, but I know this is possible with something like rsync

[–] [email protected] 11 points 7 months ago

An application can know that a file represents a soft link, but they don't need to do anything differently to follow it. If the program just opens it, reads it, writes to it, etc, as though it were the original file, it will just work^tm^ without them needing to do anything differently.

It is possible for the software to not follow a soft symlink intentionally, yes (if they don't follow it unintentionally, that might be a bug).

As for hard links, I'm not as certain, but I think these need to be supported at the filesystem level (which is why they often have specific restrictions), and the application can't tell the difference.

load more comments (1 replies)
load more comments (6 replies)
[–] [email protected] 24 points 7 months ago* (last edited 7 months ago) (11 children)

Is there a way to remove having to enter my password for everything?

Wake computer from Screensaver? Password.
Install something? Password.
Updates (biggest one. Updates should in my opinion just work without, because being up to date is important for security reasons)? Password.

I understand sudo needs a password,but all the other stuff I just want off. The frequency is rediculous. I don't ever leave my house with my computer, and I don't want to enter a password for my wife everytime she wants to use it.

[–] [email protected] 18 points 7 months ago (2 children)

I understand sudo needs a password

You can configure sudo to not need a password for certain commands. Unfortunately the syntax and documentation for that is not easily readable. Doas which can be installed and used along side sudo is easier.

For software updates you can go for unattended-upgrades though if you turn off your computer when it is upgrading software you may have to fix the broken pieces.

load more comments (2 replies)
load more comments (10 replies)
[–] [email protected] 22 points 7 months ago (20 children)

Why does it feel that Linux infighting is the main reason why it never takes off? It's always "distro X sucks", "installing from Y is stupid", "any system running Z should burn"

[–] [email protected] 19 points 7 months ago (1 children)

Linux generally has a higher (perceived?) technical barrier to entry so people who opt to go that route often have strong opinions on exactly what they want from it. Not to mention that technical discussions in general are often centered around decided what the "right" way to do a thing is. That said regardless of how the opinions are stated, options aren't a bad thing.

load more comments (1 replies)
[–] [email protected] 15 points 7 months ago

There's no infighting. It just feels that way because you picked an inferior distribution.

load more comments (18 replies)
[–] [email protected] 21 points 7 months ago* (last edited 7 months ago) (14 children)

Why do programs install somewhere instead of asking me where to?

EDIT: Thank you all, well explained.

[–] [email protected] 26 points 7 months ago

Someone already gave an answer, but the reason it's done that way is because on Linux, generally programs don't install themselves - a package manager installs them. Windows (outside of the windows store) just trusts programs to install themselves, and include their own uninstaller.

[–] [email protected] 16 points 7 months ago* (last edited 7 months ago) (1 children)

Because Linux and the programs themselves expect specific files to be placed in specific places, rather than bunch of files in a single program directory like you have in Windows or (hidden) MacOS.

If you compile programs yourself you can choose to put things in different places. Some software is also built to be more self contained, like the Linux binaries of Firefox.

load more comments (1 replies)
load more comments (12 replies)
[–] [email protected] 15 points 7 months ago (5 children)

Maybe not a super beginner question, but what do awk and sed do and how do I use them?

[–] [email protected] 15 points 7 months ago (2 children)

This is 80% of my usage of awk and sed:

"ugh, I need the 4th column of this print out": command | awk '{print $4}'

Useful for getting pids out of a ps command you applied a bunch of greps to.

”hm, if I change all 'this' to 'that' in the print out, I get what I want": command | sed "s/this/that/g"

Useful for a lot of things, like "I need to change the urls in this to that" or whatever.

Basically the rest I have to look up.

load more comments (2 replies)
load more comments (4 replies)
[–] [email protected] 15 points 7 months ago (10 children)

I installed Debian today. I'm terrified to do anything. Is there a single button backup/restore I can depend on when I ultimately fuck this up?

[–] [email protected] 13 points 7 months ago (1 children)

timeshift is pretty good, but bootable btrfs snapshots are even better

load more comments (1 replies)
load more comments (9 replies)
[–] [email protected] 15 points 7 months ago (10 children)

What is the system32 equivalent in linux

[–] [email protected] 15 points 7 months ago

/bin, since that will include any basic programs (bash, ls, cd, etc.).

load more comments (9 replies)
[–] [email protected] 15 points 7 months ago (2 children)

NixOS. I don't get what it really is or does? It's a Linux distribution but with ceavets or something

[–] [email protected] 20 points 7 months ago (10 children)

It's a distribution completely centered around the Nix package manager. This basically allows you to program how your system should look using one programming language. If you want an identical system, just copy that file and you're set.

load more comments (10 replies)
load more comments (1 replies)
[–] [email protected] 14 points 7 months ago (3 children)

Is there an Android emulator that you can actually game on? I've tried a number of them (Android x86, Genymotion, Waydroid), but none of them can install a multitude of games from the Google Play store. The one thing keeping me on Windows is Android emulation (I like having one or two idle games running at any given time).

[–] [email protected] 21 points 7 months ago* (last edited 7 months ago) (3 children)

Waydroid works, but there's three main things you need to get things going to replicate a typical Android device:

  • OpenGapps: For GApps/Play Store. You'll also need to register your device to get an Android ID.
  • Magisk: Mainly to pass SafetyNet / Play Integrity basic checks.
  • libndk / libhoudini: For ARM > x86 translation. libndk works better on AMD.
  • Widevine: (optional) L3 DRM for things that need it, eg Netflix

There are some automated scripts that can set this all up. I used this one in the past with some success.

Also, stay away from nVidia. From what I recall, it just doesn't work, or there are other issues like crashes. But if you're serious about Linux in general, then ditching nVidia is generally a good idea.

Finally, games that use anti-cheat can be a hit-or-miss (like Genshin Impact, which crashed when I last tried it). But that's something that you may face on any emulator, I mean, any decent anti-cheat system would detect the usage of emulators.

load more comments (3 replies)
load more comments (2 replies)
[–] [email protected] 13 points 7 months ago (22 children)

In the terminal, why can't i paste a command that i have copied to the clipboard, with the regular Ctrl+V shortcut? I have to actually use the mouse and right click to then select paste.

(Using Mint cinnamon)

[–] [email protected] 10 points 7 months ago

The terminal world has Ctrl+C and Ctrl+(many other characters) already reserved for other things before they ever became standard for copy paste. For for this reason, Ctrl+Shift+(C for copy, V for paste) are used.

[–] captain_aggravated 10 points 7 months ago

In Terminal land, Ctrl+C has meant Cancel longer than it's meant copy. Shift + Insert does what you think Ctrl+V will do.

Also, there's a separate thing that exists in most window managers called the Primary buffer, which is a separate thing from the clipboard. Try this: Highlight some text in one window, then open a text editor and middle click in it. Ta da! Reminder: This has absolutely nothing to do with the clipboard, if you have Ctrl+X or Ctrl+C'd something, this won't overwrite that.

load more comments (20 replies)
[–] [email protected] 13 points 7 months ago* (last edited 7 months ago) (10 children)

On Android, when an app needs something like camera or location or whatever, you have to give it permission. Why isn't there something like this on Linux desktop? Or at least not by default when you install something through package manager.

[–] [email protected] 17 points 7 months ago

Android apps are sandboxed by default while packages on Linux run with the users permission.

There is already something like this with Flatpak since it also sandboxes every installed program and only grants requested permissions.

load more comments (9 replies)
[–] [email protected] 12 points 7 months ago* (last edited 7 months ago) (5 children)

Why in Linux, Software uses a particular version of a library? Why not just say it's dependent on that library regardless of version? It become pain in ass when you are using an ancient software it required old version of newer library so you have to create symlinks of every library to match old version.

I know that sometimes newer version of Library is not compatible with software but still. And what we can do as a software developer to fix this problem? Or as a end user.

[–] [email protected] 21 points 7 months ago (15 children)

Software changes. Version 0.5 will not have the same features as Version 0.9 most of the time. Features get added over time, features get removed over time and the interface of a library might change over time too.

As a software dev, the only thing you can do is keep the same API for ever, but that is not always feasible.

load more comments (15 replies)
load more comments (4 replies)
[–] [email protected] 12 points 7 months ago (4 children)

I want to start with Btrfs and snapshots, is there a good, beginner friendly tutorial for those coming from a ext* filesystem?

[–] [email protected] 11 points 7 months ago* (last edited 7 months ago)

If you try a distro that does it by default then it is no more complicated then ext4 for the user. The distro will setup things for you. I know that opensuse Tumbleweed and Fedora Workstation set this up by default. Manually configuring is how ever a bit more complicated.

load more comments (3 replies)
[–] [email protected] 10 points 7 months ago (3 children)

How can I install non-free drivers on fedora like Debian and Ubuntu

load more comments (3 replies)
[–] [email protected] 10 points 7 months ago (11 children)

Thank you for this nice thread! My question: what is Wayland all about? Why would I want to use it and not any of the older alternatives?

[–] [email protected] 10 points 7 months ago

Because there is only one alternative (Xorg/X11), and it’s pretty outdated and not really maintained anymore.

For now it’s probably still fine, but in a couple of years everything will probably use Wayland.

load more comments (10 replies)
[–] [email protected] 10 points 7 months ago (8 children)

I am still blowing up my install pretty often.

Other than the user folder, what else should I back up for a fast and painless reinstall next time I get too adventurous?
What should I break next?
Dose Nvidia hate me?
How do I stop Windows from fucking up my BIOS boot order every time?

[–] [email protected] 27 points 7 months ago* (last edited 7 months ago) (2 children)
load more comments (2 replies)
[–] [email protected] 11 points 7 months ago (3 children)

Timeshift will save you soooooo much pain. Set it up to auto backup a daily image. You can also manually create as many snapshots as you want.

Timeshift has turned system-destroying mistakes I've made into mere 5-10 minute inconveniences. You can use it in the command line, so even if you blow up your whole desktop environment/window manager, you can still restore back to a known gold state.

I create a snapshot before any major updates or customizations.

load more comments (3 replies)
load more comments (6 replies)
[–] [email protected] 10 points 7 months ago* (last edited 7 months ago) (4 children)

Considering switching to Linux, but don't know what to choose/what will work for my needs. I want to be able to play my steam games, use discord desktop application, and use FL Studio. I need it to work with an audio interface and midi controller too. I am not interested in endless tweaking of settings, simple install would be nice. What should I go for?

[–] [email protected] 13 points 7 months ago (1 children)

Mint would probably work for you. Some stuff is outdated, but it has flatpak which is a package manager with more up to date apps. If you're willing to put in the time though, I'd recommend trying some of the more common distros out (Mint, Debian, Ubuntu, Fedora). You can use a liveusb to test them without installing.

Steam is available anywhere so that's not a problem.

Discord officially only has a .deb package, so that's only for Debian based distros (Debian, Ubuntu, Mint). There are other options for almost all distros though - I personally use Webcord

Fl studio might be tricky - supposedly it runs through wine but you might have to do a bit of work. I've personally used Reaper and I works great.

load more comments (1 replies)
load more comments (3 replies)
load more comments
view more: next ›