Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Post
  • Reply
Subjunctive
Sep 12, 2006

✨sparkle and shine✨

there have been VNC ones for a long time, so hosting a browser VNC client seems straightforward for them to add

Adbot
ADBOT LOVES YOU

cruft
Oct 25, 2007

:frogsiren: :frogsiren: :frogsiren: :frogsiren: :frogsiren: :frogsiren:

LINUX THREAD PAGE 2^10

:frogsiren: :frogsiren: :frogsiren: :frogsiren: :frogsiren: :frogsiren:

ExcessBLarg!
Sep 1, 2001

cruft posted:

:frogsiren: :frogsiren: :frogsiren: :frogsiren: :frogsiren: :frogsiren:

LINUX THREAD PAGE 2^10

:frogsiren: :frogsiren: :frogsiren: :frogsiren: :frogsiren: :frogsiren:
It’s OK, the page boundary is at 4 kB (8 kB on Alpha) so nothing weird should happen.

Wibla
Feb 16, 2011

cruft posted:

:frogsiren: :frogsiren: :frogsiren: :frogsiren: :frogsiren: :frogsiren:

LINUX THREAD PAGE 2^10

:frogsiren: :frogsiren: :frogsiren: :frogsiren: :frogsiren: :frogsiren:

Well, poo poo :haw:

Klyith
Aug 3, 2007

GBS Pledge Week

ExcessBLarg! posted:

It’s OK, the page boundary is at 4 kB (8 kB on Alpha) so nothing weird should happen.

Only if you're using the SLAB, SLOB, or SLUB allocators.


Lemme tell you about my new super-high-performance kernel memory allocator, SLURP (for Simply Lots of Unordered Random Places).

You know how everyone has at least 32gb of memory these days, and you only use like 6 if you don't have Chrome open? SLURP takes advantage of this by avoiding all those old-fashioned blocks and stacks that slow other memory allocators down. Here's how it works:
1. a program asks to allocate memory
2. SLURP picks a random number between 0 and MAXMEM, and hands that to the program as a pointer
3. ok that's your memory, go nuts

SLURP is blazingly fast and never gets bogged down with memory fragmentation or reference counting! It cuts the allocation / deallocation overhead by 50%, using the simple trick of never deallocating anything. And best of all, it encourages small and efficient programming, for self-defense! Because if your program uses 50mb of memory, it is 50 times more likely to crash some other bloated program that uses 2.5GB, than to be crashed by it.


Just, uh, don't open Chrome.

cruft
Oct 25, 2007

Klyith posted:

Only if you're using the SLAB, SLOB, or SLUB allocators.


Lemme tell you about my new super-high-performance kernel memory allocator, SLURP (for Simply Lots of Unordered Random Places).

You know how everyone has at least 32gb of memory these days, and you only use like 6 if you don't have Chrome open? SLURP takes advantage of this by avoiding all those old-fashioned blocks and stacks that slow other memory allocators down. Here's how it works:
1. a program asks to allocate memory
2. SLURP picks a random number between 0 and MAXMEM, and hands that to the program as a pointer
3. ok that's your memory, go nuts

SLURP is blazingly fast and never gets bogged down with memory fragmentation or reference counting! It cuts the allocation / deallocation overhead by 50%, using the simple trick of never deallocating anything. And best of all, it encourages small and efficient programming, for self-defense! Because if your program uses 50mb of memory, it is 50 times more likely to crash some other bloated program that uses 2.5GB, than to be crashed by it.


Just, uh, don't open Chrome.

This post is giving me traumatic memories of Desqview.

mekyabetsu
Dec 17, 2018

Is it a good idea to setup a separate group/user for accessing Samba shares? I'm setting up a new file server/home lab, and I've just installed and configured Samba so I can access a ZFS pool from my Windows machines. Currently, I'm just allowing access from my sole admin user because I wasn't sure if dealing with file permissions and ownership issues with a separate user would cause me headaches when copying files from different systems. However, I keep hearing "principle of least privilege" in the back of my mind and wondering if this is a security issue, even though this is a home server that only I have access to. Even if it's not a major security risk in my case, I'm using this as an opportunity to better familiarize myself with Linux admin, so I'd like to follow best practices.

mekyabetsu fucked around with this message at 10:48 on Apr 20, 2024

Klyith
Aug 3, 2007

GBS Pledge Week

mekyabetsu posted:

Is it a good idea to setup a separate group/user for accessing Samba shares? I'm setting up a new file server/home lab, and I've just installed and configured Samba so I can access a ZFS pool from my Windows machines. Currently, I'm just allowing access from my sole admin user because I wasn't sure if dealing with file permissions and ownership issues with a separate user would cause me headaches when copying files from different systems. However, I keep hearing "principle of least privilege" in the back of my mind and wondering if this is a security issue, even though this is a home server that only I have access to. Even if it's not a major security risk in my case, I'm using this as an opportunity to better familiarize myself with Linux admin, so I'd like to follow best practices.

If the admin for the server is just a standard sudoer user, it's not a direct security problem. You can't elevate through samba, so it can't write anything that your admin can't write without sudo. So this is just like sharing stuff on windows with your admin user without it being a massive hole. Not best practice, but fine for a single-user environment.


However, as a general NAS setup, having multiple users is a good idea even for a single-user home network. Principle of least privilege doesn't just apply to securing the server itself, it's also great for securing the data on the server. That includes security from bugs and mistakes!

For example, if your NAS is where your backups go imagine you get hit by crypto ransomware on a windows machine. If the user on that machine has r/w permission over all shares, nothing stops the malware from encrypting all your backups too. Plenty of less extreme examples. Windows Defender had a long-standing bug where if it tried to quarantine a file it believed was a virus on a NAS, it would just delete it because the move to quarantine didn't work.

So you could have a setup with user "mekyabetsu" having read access to everything on the NAS, and write access to your working data directories. And then make a "nasbackup" user that has write access to the backups folders. I would consider using this type of system to partition off any software or device that needed autonomous write access to the NAS.

This is a modest step up in complexity for a big step up in protection from "oh poo poo" events.



Linux ownership & permissions are much easier to manage than in windows, and are strictly local to the machine. If you add a new user using a specific UID # (normally between 1000-60000), later on you can move the ZFS pool to a new OS and make users with the same IDs and it will slot right in.

Pablo Bluth
Sep 7, 2007

I've made a huge mistake.

Klyith posted:

Linux ownership & permissions are much easier to manage than in windows, and are strictly local to the machine.
Many years ago at work I inherited responsibility for a small collection of linux servers used for HPC workloads. It had long been configured to use Yellowpages/NIS for user accounts; it was a mystery how it ever worked except it would randomly break. I don't have that role at work any more but recently, I've experimented with FreeIPA at home. It's simple to setup and add a server to the domain, and so far it's been trouble free.

xzzy
Mar 5, 2009

Pablo Bluth posted:

it was a mystery how it ever worked except it would randomly break.

That's a core feature of NIS.

Klyith
Aug 3, 2007

GBS Pledge Week

Pablo Bluth posted:

Many years ago at work I inherited responsibility for a small collection of linux servers used for HPC workloads. It had long been configured to use Yellowpages/NIS for user accounts; it was a mystery how it ever worked except it would randomly break.

Perhaps I should phrase that as "Linux / traditional unix ownership & permissions are much easier to manage than in windows, when dealing with individual computers and a handful of user accounts." Because yeah, that system was not made to scale up.


That is in comparison to Windows where the SID system does scale, but is kinda annoying to deal with on single-user / home-network basis. When moving a drive or cloning a partition between machines, or just carrying forward existing FSes into a fresh install during a upgrade, the "klyith" on machine A is not the same "klyith" on machine B. The SID of the two users is different, and changing SIDs is non-trivial. Easier to just change ownership of all the files.

Whereas on linux I'm UID 1000 everywhere, ownership is very simple, and as long as your only multi-user system is a single server/NAS type thing it's pretty nice.


Pablo Bluth posted:

I don't have that role at work any more but recently, I've experimented with FreeIPA at home. It's simple to setup and add a server to the domain, and so far it's been trouble free.

Is that experimenting just to gently caress around with, or are you getting some functionality in a home network that's a big payoff? (Or is your home network complicated enough to need centrally managed identities?)

Pablo Bluth
Sep 7, 2007

I've made a huge mistake.
I installed it to gently caress around with and have at least basic knowledge of it in my repertoire. But it was that easy to get going, I've stuck with it despite it being overkill (I'm not using 99.99% of the functionality). I do have a bunch of VMs so going forward it does make it easy to have consistency across them. I'm not bothering to change my existing VMs due to username/UID conflicts, but all new VMs will be added to the domain.

FAT32 SHAMER
Aug 16, 2012



Anyone know why my system crashes when the inactivity screen blanking occurs? At first I just thought it was my screen locking, but then I noticed whatever I had open would be closed on relogin, and any downloads I had going wouldn’t be completed

Edit: currently running gnome bazzite on an i7-7700k with a 3080ti ftw3

Well Played Mauer
Jun 1, 2003

We'll always have Cabo
Check to make sure you don’t have auto-sleep running.

Nitrousoxide
May 30, 2011

do not buy a oneplus phone



FAT32 SHAMER posted:

Anyone know why my system crashes when the inactivity screen blanking occurs? At first I just thought it was my screen locking, but then I noticed whatever I had open would be closed on relogin, and any downloads I had going wouldn’t be completed

Edit: currently running gnome bazzite on an i7-7700k with a 3080ti ftw3

If you haven't updated in a week or so, there was a kernel bug recently that impacted Fedora and Fedora derivatives like Bazzite to cause them to crash on sleep/boot sometimes.

It seems to be fixed for me on the current version, though at least one person is claiming it's still an issue.
https://github.com/ublue-os/bazzite/issues/960

If you poke around the github issues there seem to be a few other issues that may be related and have the same root cause.

FAT32 SHAMER
Aug 16, 2012



Nitrousoxide posted:

If you haven't updated in a week or so, there was a kernel bug recently that impacted Fedora and Fedora derivatives like Bazzite to cause them to crash on sleep/boot sometimes.

It seems to be fixed for me on the current version, though at least one person is claiming it's still an issue.
https://github.com/ublue-os/bazzite/issues/960

If you poke around the github issues there seem to be a few other issues that may be related and have the same root cause.

Aha! Thanks! As it happens, the bug appears to be alive in bazzite-gnome but not bazzite-kde, just based on me reinstalling to make sure it wasn’t a user error somehow lol

Kevin Bacon
Sep 22, 2010

uhhhhhh ok how do i start. How the heck do I work linux and audio interfaces and daws? Im on my laptop running opensuse tw kde 6 wayland, using an old scarlett 2i2.

scarlett2i2 supported by default. great. cursory google search tells me to use alsa or jack. i tried alsa. it works but i cant get the buffer size below like 128 or 64 i think before it becomes completely unusable (this same laptop can do 32 or 16 in windows just fine). i tried jack by installing pipewire-jack, then i run "pw-jack ./reaper", same issue. just can't do a decent buffer-size, leading to high latency audio :(

anything im missing here or does linux (or maybe just my laptop with linux) just suck for audio production?

Kibner
Oct 21, 2008

Acguy Supremacy
I’m still learning about this myself but do you have pipewire set to use the “ProAudio” profile? That supposedly lets you manage the device directly.

Judging by this post, you might already be in that mode if you are adjusting sample buffer and such: https://stackoverflow.com/questions...toring%20audio.

So, I got nothing. I’m still trying to figure out how to change the profile such that the OS does not see the the 32 channels or whatever on my interface as I think that is loving up some games as they can’t handle that many and just disable sound entirely.

Kevin Bacon
Sep 22, 2010

hmm not sure if it matters how pipewire is set up on a system level since i believe(?) it's being managed by pipewire-jack right from my daw (reaper). i can change the settings just fine, it just does not work as well as it would in windows. my laptop is in its performance mode or whatever too, no issues running games on it. i feel like either my cpu is just not being utilized like it should or there are some settings somewhere i'm missing.

thanks either way though!

Klyith
Aug 3, 2007

GBS Pledge Week
Pro Audio mode does more than just expose extra modes:

https://gitlab.freedesktop.org/pipewire/pipewire/-/wikis/FAQ#what-is-the-pro-audio-profile
such as

quote:

All devices from a card are assumed to share the same clock and so the adaptive resamplers are disabled.

Since 0.3.81 this profile will use IRQ based scheduling with linked devices when there is 1 capture and 1 playback device. This results in the same latency as can be achieved with JACK on the device. Devices with more than 1 capture and playback device will not be using IRQ scheduling because these devices typically don't allow running all devices at the same time and will fail to start when linked.

OTOH every time I've seen people talking about professional audio production on linux they're talking about pure JACK-only setups.

edit:

Kevin Bacon posted:

i believe(?) it's being managed by pipewire-jack right from my daw (reaper)
note that pipewire-jack isn't pipewire on jack, it's pipewire providing a jack interface

Klyith fucked around with this message at 22:24 on Apr 22, 2024

Combat Pretzel
Jun 23, 2004

No, seriously... what kurds?!
Sometimes I wonder what's wrong with people that build Docker containers. Put the loving ping tool in there for debugging.

xzzy
Mar 5, 2009

Combat Pretzel posted:

Sometimes I wonder what's wrong with people that build Docker containers. Put the loving ping tool in there for debugging.

We're all spinning 6tb+ hard drives and container builders fret over shaving a couple megabytes off their image.

A shell with tab completion, curl, netcat, and the host command are all required features for me.

Combat Pretzel
Jun 23, 2004

No, seriously... what kurds?!
Can't be that, if there's things like dumpe2fs and blkzone.

Subjunctive
Sep 12, 2006

✨sparkle and shine✨

xzzy posted:

We're all spinning 6tb+ hard drives and container builders fret over shaving a couple megabytes off their image.

A shell with tab completion, curl, netcat, and the host command are all required features for me.

It’s not about storage space, it’s about traffic to deploy a thousand of them.

Twerk from Home
Jan 17, 2009

This avatar brought to you by the 'save our dead gay forums' foundation.

xzzy posted:

We're all spinning 6tb+ hard drives and container builders fret over shaving a couple megabytes off their image.

A shell with tab completion, curl, netcat, and the host command are all required features for me.

It's about security more than disk space savings. If you want tools, have a debug variant of your image around that you use for that: https://github.com/GoogleContainerTools/distroless

Subjunctive
Sep 12, 2006

✨sparkle and shine✨

Twerk from Home posted:

It's about security more than disk space savings. If you want tools, have a debug variant of your image around that you use for that: https://github.com/GoogleContainerTools/distroless

And hope that all your issues are completely reproducible so you can deploy the debug container to find out what happened!

(You’ll just end up with the debug container in production soon enough anyway because someone will build a dependency on the debug stuff during an incident response and then whelp, other stuff to fix.)

xzzy
Mar 5, 2009

We have a site firewall, obviously I don't have to worry about any security considerations. :science:

Nitrousoxide
May 30, 2011

do not buy a oneplus phone



Combat Pretzel posted:

Sometimes I wonder what's wrong with people that build Docker containers. Put the loving ping tool in there for debugging.

If you absolutely need that poo poo just make your own dockerfile which uses the container you want as the base image and add on whatever tools you need for debugging. There's no reason to have that stuff in there for an operational service.

mawarannahr
May 21, 2019

Just mount a statically compiled ping binary. Ping bong, so simple

Subjunctive
Sep 12, 2006

✨sparkle and shine✨

just debug by writing down all the configuration of the relevant components and deriving the behaviour from first principles

mawarannahr
May 21, 2019

My containers are like 16 GiB compressed

cruft
Oct 25, 2007

mawarannahr posted:

My containers are like 16 GiB compressed

My most popular image, with 5.4k downloads, is 20 megabytes :smug:

mawarannahr
May 21, 2019

cruft posted:

My most popular image, with 5.4k downloads, is 20 megabytes :smug:
I saw it. I appreciate the high resolution and your inclusion of the ring 👍

cruft
Oct 25, 2007

mawarannahr posted:

I saw it. I appreciate the high resolution and your inclusion of the ring 👍

LOL

Dyscrasia
Jun 23, 2003
Give Me Hamms Premium Draft or Give Me DEATH!!!!

mawarannahr posted:

I saw it. I appreciate the high resolution and your inclusion of the ring 👍

It's my base image.

Dyscrasia fucked around with this message at 02:23 on Apr 24, 2024

FAT32 SHAMER
Aug 16, 2012



Another kind of dumb Bazzite/atomic desktop question:

I figured out that kde global themes were failing to install because it’s an image and the sddm folder is read only. I then read that sddm2rpm resolves the issue, but when I use dnf it throws a warning that seems kinda spooky. Is building stuff with cmake common for linux tools and apps? I mostly remember tarballs executing install scripts and assumed it’d be moving to apps more like flatpaks.

I just generally can’t wrap my head around some of the limitations and decisions. It’s definitely kept me from doing something dumb while fuckin around with kde and various tweaks and things I was doing, but it was real annoying when I hit speed bumps like this. It’s strange that they didn’t do something for it at least similar to when you don’t have root on macOS you’ll have a user level Apps folder that the App Store downloads to and has whatever pre installed root level apps

Also I’m starting to suspect that the crash issue I was having on Bazzite gnome may have been an issue with the Rufus boot stick I used, because I’ve installed Bazzite kde twice now after burning with Fedora media writer and both are stable as can be. Rufus kept throwing errors and having to do weird settings to get it to write correctly

Mantle
May 15, 2004

I'm using Fedora and on a recent dnf update, Chrome stopped working in Sway.

I think it's this issue because there is a workaround to set an envvar on the cli that works. However, I want to use the launcher in Sway.

https://issues.chromium.org/issues/329678163?pli=1

I tried to downgrade to the last known good Chrome but I'm getting some error that there is no version found. Alternatively I don't know how to add the command line flag to the launcher.

What else can I try?

Voodoo Cafe
Jul 19, 2004
"You got, uhh, Holden Caulfield in there, man?"

Mantle posted:

I'm using Fedora and on a recent dnf update, Chrome stopped working in Sway.

I think it's this issue because there is a workaround to set an envvar on the cli that works. However, I want to use the launcher in Sway.

https://issues.chromium.org/issues/329678163?pli=1

I tried to downgrade to the last known good Chrome but I'm getting some error that there is no version found. Alternatively I don't know how to add the command line flag to the launcher.

What else can I try?

copy chrome's .desktop file from /usr/share/applications to $HOME/.local/share/applications/ , then you can edit the lines starting with 'Exec=' to include the flag you want

so change

code:
Exec=/path/to/google/chrome 
to something like

code:
Exec=/path/to/google/chrome --my-commandline-flag
There may be multiple 'Exec' lines so you would have to change them all.

In addition, i don't know if Sway reloads these files automatically on changes, so you might have to log out and log back in for changes to take effect

Nitrousoxide
May 30, 2011

do not buy a oneplus phone



FAT32 SHAMER posted:

Another kind of dumb Bazzite/atomic desktop question:

I figured out that kde global themes were failing to install because it’s an image and the sddm folder is read only. I then read that sddm2rpm resolves the issue, but when I use dnf it throws a warning that seems kinda spooky. Is building stuff with cmake common for linux tools and apps? I mostly remember tarballs executing install scripts and assumed it’d be moving to apps more like flatpaks.

I just generally can’t wrap my head around some of the limitations and decisions. It’s definitely kept me from doing something dumb while fuckin around with kde and various tweaks and things I was doing, but it was real annoying when I hit speed bumps like this. It’s strange that they didn’t do something for it at least similar to when you don’t have root on macOS you’ll have a user level Apps folder that the App Store downloads to and has whatever pre installed root level apps

Also I’m starting to suspect that the crash issue I was having on Bazzite gnome may have been an issue with the Rufus boot stick I used, because I’ve installed Bazzite kde twice now after burning with Fedora media writer and both are stable as can be. Rufus kept throwing errors and having to do weird settings to get it to write correctly

What spooky warning? OSTree does need to use RPMs if you're looking to change anything in the read-only directories, so it can revert it later when/if needed. As I understand it, SDDM puts themes in:
/usr/share/sddm/themes

only /var and /etc are r/w in OSTree. Many traditional root level directories are symlinked to spaces in there to retain compatibility.
https://docs.fedoraproject.org/en-US/fedora-silverblue/technical-information/

Adbot
ADBOT LOVES YOU

alnilam
Nov 10, 2009

I'm looking to get a crappy old computer from the thrift store and set it up with linux to be my 5 year old's babby's first computer. Mainly a learn-to-type/use a computer, a homework station, and maybe some simple games (I'm thinking maybe an NES emulator and gamepad). Probably will have internet browsing locked for the time being and slowly introduce the web as we go along.

I use Linux Mint so I was gonna do that since it's what I'm familiar with, and my general plan was to make it pretty bare bones, make her a non admin account, maybe even make it so games have no shortcuts and must be launched from terminal for bonus computer learningness?

Anyway I'm posting here wondering if anyone here has done something similar and has any advice based on their experience.

  • 1
  • 2
  • 3
  • 4
  • 5
  • Post
  • Reply