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
Computer viking
May 30, 2011
Now with less breakage.

If you just want things to eventually work themselves out, I guess you could use cron (or whatever the systemd equivalent is) to run the apt-key command once a week?

Adbot
ADBOT LOVES YOU

F_Shit_Fitzgerald
Feb 2, 2017



OK, thanks! Both good ideas. I might go the cron route, honestly, so that I don't have to worry about this again.

Mr. Crow
May 22, 2008

Snap City mayor for life
It should prompt you when there is a new key? E.g. when you distro-upgrade?

F_Shit_Fitzgerald
Feb 2, 2017



It might be (probably is) something I hosed up. My auto-update script was not sudo apt-get upgrade && sudo apt-get dist-upgrade; I think I left off the 'apt-get' because I'm still a relative noob. So without the escalated privileges it just tried to upgrade, failed, and left it alone.

Computer viking
May 30, 2011
Now with less breakage.

Is "apt <verb>" the recommended form these days, or is that still in beta with apt-get and apt-cache and the rest still preferred?

E: To clarify this is neither part of the problem nor the solution, both should work fine. I'm just curious how far the replacement project has come.

Tesseraction
Apr 5, 2009

The standard has been apt <word> but at this point even as someone who uses other distros daily, typing 'apt-" and then putting what's needed to tab-complete is in my muscle memory.

waffle iron
Jan 16, 2004
https://gitlab.com/volian/nala

Lately on my debian systems I've been using nala as my package manager. It's not quite full featured yet, but that it has a history is excellent. It lets you undo any change in packages. Another convenience is that by default nala upgrade implicitly updates all repos before running.

https://linuxiac.com/nala-apt-command-frontend/

waffle iron fucked around with this message at 03:47 on Jan 7, 2023

Satire Forum Mom
Oct 4, 2003
MY CUNT DRIPS BROWN REFUSE LIKE A DIRTY HOOKAH. PS. THE BACK OF MY THIGHS ARE RIDICULOUS - COTTAGE CHEESE ANYONE?

F_Shit_Fitzgerald posted:

It might be (probably is) something I hosed up. My auto-update script was not sudo apt-get upgrade && sudo apt-get dist-upgrade; I think I left off the 'apt-get' because I'm still a relative noob. So without the escalated privileges it just tried to upgrade, failed, and left it alone.

Instead of running a script (which I suspect is causing the problems), look into the unattended-upgrades package. You can set a quick cron job to run it on a schedule, too.

uguu
Mar 9, 2014

I updated my user and root password yesterday on my Linux mint 21 laptop and since then I can't get any domains to resolve. I can ping IP addresses, but DNS requests fail.

I'm suspecting keyrings, not that I really know what that is. Once in a while I would be asked to unlock a keyring to access the internet, if it didn't happen at startup. edit that's not it.Currently trawling the web, but maybe someone here can help me.

uguu fucked around with this message at 17:19 on Jan 7, 2023

Tesseraction
Apr 5, 2009

If you open up your network settings has your DNS server been un-set for some reason?

uguu
Mar 9, 2014

Tesseraction posted:

If you open up your network settings has your DNS server been un-set for some reason?

My protonvpn killswitch was messing things up!

acetcx
Jul 21, 2011
I had an Ubuntu 20.04 server that dumped weekly tar.gz backups of various directories in /media/backups. I was using this script on my desktop to pull down the most recent backups:

code:
#!/bin/bash
rsync -avz remote:'$(find /media/backups/ -ctime -7 -type f)' "/home/username/backups"
This was working fine last year but some time ago I wiped the server and rebuilt it with Ubuntu 22.04 server. After that the script stopped working:

code:
receiving incremental file list
rsync: [sender] change_dir "/home/username/$(find /media/backups" failed: No such file or directory (2)

sent 8 bytes  received 8 bytes  10.67 bytes/sec
total size is 0  speedup is 0.00
rsync error: some files/attrs were not transferred (see previous errors) (code 23) at main.c(1861) [Receiver=3.2.7]
rsync: [Receiver] write error: Broken pipe (32)
So I did some research and rewrote the script as follows:

code:
#!/bin/bash
ssh remote 'find /media/backups/ -maxdepth 1 -ctime -7 -type f -printf "%P\n"' | rsync -avz --files-from=- remote:/media/backups/ "/home/username/backups"
This works again so everything's good, I'm just wondering why the old script stopped working - my shell scripting game is very weak and I'm curious.

Mr. Crow
May 22, 2008

Snap City mayor for life

acetcx posted:

I had an Ubuntu 20.04 server that dumped weekly tar.gz backups of various directories in /media/backups. I was using this script on my desktop to pull down the most recent backups:

code:
#!/bin/bash
rsync -avz remote:'$(find /media/backups/ -ctime -7 -type f)' "/home/username/backups"
This was working fine last year but some time ago I wiped the server and rebuilt it with Ubuntu 22.04 server. After that the script stopped working:

code:
receiving incremental file list
rsync: [sender] change_dir "/home/username/$(find /media/backups" failed: No such file or directory (2)

sent 8 bytes  received 8 bytes  10.67 bytes/sec
total size is 0  speedup is 0.00
rsync error: some files/attrs were not transferred (see previous errors) (code 23) at main.c(1861) [Receiver=3.2.7]
rsync: [Receiver] write error: Broken pipe (32)
So I did some research and rewrote the script as follows:

code:
#!/bin/bash
ssh remote 'find /media/backups/ -maxdepth 1 -ctime -7 -type f -printf "%P\n"' | rsync -avz --files-from=- remote:/media/backups/ "/home/username/backups"
This works again so everything's good, I'm just wondering why the old script stopped working - my shell scripting game is very weak and I'm curious.

I would guess rsync (or whatever ends up processing the find command) changed behavior with how it handles string literals, based on the output.

Also there is a lot of easy to setup backup software out there that will do this for you more efficiently and effectively.

CaptainSarcastic
Jul 6, 2013



Just to send an intention into the void, I think I might go back to Tumbleweed on my machine and let root be btrfs so I can use snapshots. 15.4 has been okay, but I think I might have hosed something up while trying to get Miracast working and am getting a few different minor annoyances. I also have new enough hardware it might benefit from being closer to the cutting edge. Next step is to find :effort:

Mr. Crow
May 22, 2008

Snap City mayor for life
Am I the only one still using XFS + LVM? btrfs is slow as poo poo last I looked, LVM snapshots are super easy.

xzzy
Mar 5, 2009

We use both extensively, data volumes get xfs and the OS is on lvm.

We don't bother with lvm on user areas, they get the whole disk anyways.

Klyith
Aug 3, 2007

GBS Pledge Week

Mr. Crow posted:

Am I the only one still using XFS + LVM? btrfs is slow as poo poo last I looked, LVM snapshots are super easy.

btrfs is slow as poo poo for things that you shouldn't use a copy-on-write FS for, like database and vm images and other stuff that does lots of small writes

it's fine for an OS root that does very little of those things, especially on a personal desktop

KozmoNaut
Apr 23, 2008

Happiness is a warm
Turbo Plasma Rifle


Klyith posted:

btrfs is slow as poo poo for things that you shouldn't use a copy-on-write FS for, like database and vm images and other stuff that does lots of small writes

it's fine for an OS root that does very little of those things, especially on a personal desktop

And where snapshots can come in very handy in case of botched upgrades. Plus the built-in redundancy and backup functions, and dynamic grow/shrink. I use it on my server for the storage pool and it just does its thing, snapshots and all.

Not directly related to btrfs, but related to root FS stability, I'm in the process of moving to a Steam Deck as a replacement for my aging desktop and equally aging laptop, the dock works great for any desktop stuff with my 4K monitor etc.

It runs a read-only root FS (ext4, I believe) and OverlayFS where only /home is writeable. Apps are installed preferably via Flatpak or Appimages, or similarly directly in the user's home folder. I'm curious as to how restricting that is going to feel in normal desktop use.

For real, the Deck is the best Linux-based prebuilt device I've ever used. Valve really did a great job on integration and drivers. Everything just works, including suspend/resume while in the middle of a game, even stuff running via Proton. It resumes in seconds right into gameplay.

There are definite benefits to keeping an immutable root FS – and fixed hardware configuration – like that.

KozmoNaut fucked around with this message at 13:28 on Jan 8, 2023

Kibner
Oct 21, 2008

Acguy Supremacy
The Steam Deck is one of the most interesting and best executed tech gadgets to be released in quite some time.

KozmoNaut
Apr 23, 2008

Happiness is a warm
Turbo Plasma Rifle


I genuinely hope it sells well enough to become the established baseline system spec for PC game developers to target, ie. target the deck for a good playable experience, but feel free to go hog wild with optional graphics features beyond that. Hopefully it will also lead to efficiency improvements like we see through every console generation because the hardware stays the same, instead of the constantly moving target that exists in PC gaming.

Then release new decks maybe every 5 years or so when the improvements in PC hardware can justify it. Then you'd have 2022 spec, 2027 spec and so on, for easy hardware generations.

I hope it also helps a push towards immutable base systems for everyday computing, it would prevent so many security issues to have a read-only system and sandboxed applications.

Kibner
Oct 21, 2008

Acguy Supremacy
I would love for that dream to become true.

I got my mom a surface laptop for Christmas (touch screen and solid keyboard were requirements) and setup the app install settings on it to only allow Windows Store apps to install since she has/had a habit of installing all kinds of random stuff from clicking on ads and I'm no longer close enough to home to clean a virus-ridden machine for her.

So, a more locked down device would do wonders.

Tesseraction
Apr 5, 2009

acetcx posted:

I had an Ubuntu 20.04 server that dumped weekly tar.gz backups of various directories in /media/backups. I was using this script on my desktop to pull down the most recent backups:

code:
#!/bin/bash
rsync -avz remote:'$(find /media/backups/ -ctime -7 -type f)' "/home/username/backups"
This was working fine last year but some time ago I wiped the server and rebuilt it with Ubuntu 22.04 server. After that the script stopped working:

code:
receiving incremental file list
rsync: [sender] change_dir "/home/username/$(find /media/backups" failed: No such file or directory (2)

sent 8 bytes  received 8 bytes  10.67 bytes/sec
total size is 0  speedup is 0.00
rsync error: some files/attrs were not transferred (see previous errors) (code 23) at main.c(1861) [Receiver=3.2.7]
rsync: [Receiver] write error: Broken pipe (32)
So I did some research and rewrote the script as follows:

code:
#!/bin/bash
ssh remote 'find /media/backups/ -maxdepth 1 -ctime -7 -type f -printf "%P\n"' | rsync -avz --files-from=- remote:/media/backups/ "/home/username/backups"
This works again so everything's good, I'm just wondering why the old script stopped working - my shell scripting game is very weak and I'm curious.

It looks like as a security feature it doesn't let you run commands in an rsync source command anymore. It might be related to the behaviour mentioned in this update: https://download.samba.org/pub/rsync/NEWS#3.2.4

v1ld
Apr 16, 2012

KozmoNaut posted:

I genuinely hope it sells well enough to become the established baseline system spec for PC game developers to target, ie. target the deck for a good playable experience, but feel free to go hog wild with optional graphics features beyond that. Hopefully it will also lead to efficiency improvements like we see through every console generation because the hardware stays the same, instead of the constantly moving target that exists in PC gaming.

Then release new decks maybe every 5 years or so when the improvements in PC hardware can justify it. Then you'd have 2022 spec, 2027 spec and so on, for easy hardware generations.

I hope it also helps a push towards immutable base systems for everyday computing, it would prevent so many security issues to have a read-only system and sandboxed applications.

Do you have Gabe's email address?

xzzy
Mar 5, 2009

It's a valve product. They'll make two versions and then ignore it forever.

KozmoNaut
Apr 23, 2008

Happiness is a warm
Turbo Plasma Rifle


I know, but maybe this time it's different, right? :pray:

At least the immutable OS idea is catching hold*, OpenSUSE MicroOS is looking very promising.

* E: not that it originates from the Steam Deck, but it's a good showcase of why it's a solid idea for consumer devices.

v1ld posted:

Do you have Gabe's email address?

There's this form, but I don't know whether he reads everything he gets.

https://www.valvesoftware.com/en/contact?contact-person=Gabe%20Newell

KozmoNaut fucked around with this message at 18:13 on Jan 8, 2023

Nitrousoxide
May 30, 2011

do not buy a oneplus phone



Kibner posted:

The Steam Deck is one of the most interesting and best executed tech gadgets to be released in quite some time.

Steam for Linux has gotten a lot better over the past ~7 years lol

https://github.com/ValveSoftware/steam-for-linux/issues/3671

v1ld
Apr 16, 2012

Nitrousoxide posted:

Steam for Linux has gotten a lot better over the past ~7 years lol

https://github.com/ValveSoftware/steam-for-linux/issues/3671

lol at this bit of quoted code from steam.sh:
code:
rm -rf "$STEAMROOT/"*
That trailing "/*" is deadly if STEAMROOT is empty: it converts a buggy but benign "rm -rf" into "rm -rf /*"!

And for no real purpose if they're trying to blow away the directory as the /* isn't needed.

Subjunctive
Sep 12, 2006

✨sparkle and shine✨

I think they were trying to delete the contents but leave the directory, but deleting the directory and then recreating it would be a fine approach.

v1ld
Apr 16, 2012

Or a guard: [ -z "$STEAMROOT" ] || rm -rf etc

Good point on leaving the folder being the intent.

E: Though I'd write that in a real script as an invariant and not pepper the check everywhere:
[ -z "$STEAMROOT" ] && die "help, fubar"

v1ld fucked around with this message at 05:42 on Jan 9, 2023

pseudorandom name
May 6, 2007

iirc there was no way for STEAMROOT to be empty at that point unless you were running on a malfunctioning ntfs-3g FUSE mount.

ExcessBLarg!
Sep 1, 2001

KozmoNaut posted:

It runs a read-only root FS (ext4, I believe) and OverlayFS where only /home is writeable. Apps are installed preferably via Flatpak or Appimages, or similarly directly in the user's home folder.
The Deck supports "system" level flatpaks in /var/lib/flatpak, although since it's a single user device the difference is minimal in practice.

KozmoNaut posted:

I'm curious as to how restricting that is going to feel in normal desktop use.
I've mentioned this elsewhere, but the Deck isn't intended to be a desktop replacement. Yes, it has a "Desktop Mode" but that's more to facilitate making the desktop Steam client available (since not everything can be done in the native Steam client) as well as a full-blown web browser if you might need that. Everything else though is YMMV and I've seen some brokenness in the KDE installation (namely broken xdg-desktop-portal) that nobody cares about.

Also, Steam Linux-runtime applications are minimally sandboxed. They can (and do) scribble all over the filesystem wherever the single "deck" user has write permissions.

If you want a cheap Linux desktop replacement I recommend getting a Chromebox and using the built-in Linux environment (Crostini) when needed.

KozmoNaut posted:

I hope it also helps a push towards immutable base systems for everyday computing, it would prevent so many security issues to have a read-only system and sandboxed applications.
Both Chrome OS and Android have been doing this for a decade now. The former really got it right out of the gate too by having two identical read-only system partitions, where updates can be performed against the opposite partition from the one currently booted, so the only downtime experienced with an update is the 15 or so seconds it takes to reboot.

Subjunctive posted:

I think they were trying to delete the contents but leave the directory, but deleting the directory and then recreating it would be a fine approach.
It would make sense to me if they were trying to support (and preserve) STEAMROOT optionally being a symlink but I think that makes other parts of the script suspect.

KozmoNaut
Apr 23, 2008

Happiness is a warm
Turbo Plasma Rifle


ExcessBLarg! posted:

I've mentioned this elsewhere, but the Deck isn't intended to be a desktop replacement.

I know it's not the intention, but I aim to try it out anyway.

E: or at least as a laptop replacement. All I need on the go is games, video playback, an SSH client and a web browser. Come to think of it, that's 99% of what I do on my desktop, too.

KozmoNaut fucked around with this message at 16:02 on Jan 9, 2023

ExcessBLarg!
Sep 1, 2001
I mean, that's fine, I've just seen more than one person read more into the Deck's desktop support than Valve intended it to be.

Like they didn't decide to support flatpaks as the preferred third-party distribution platform due to its superior sandboxing capabilities, but because it was the easiest/popular thing for which they could shoehorn in support.

v1ld
Apr 16, 2012

ExcessBLarg! posted:

I mean, that's fine, I've just seen more than one person read more into the Deck's desktop support than Valve intended it to be.

As we've discussed before, I don't know where you came up with the emphasized bits. Valve's actual statement on using Desktop mode is in their FAQ, as pointed out before:

quote:

What if I want to do more than what’s available by flatpak?

Totally fine, though it comes with several caveats. Make sure you know what you’re doing and be careful about running random commands / scripts you find on the internet - you may get your Steam Deck into a bad state or compromise your data. In addition, anything you install outside of flatpak (via pacman for instance) may be wiped with the next SteamOS update.

With that out of the way, if you are going outside flatpak and need to edit the read-only image, you can enable that with the following command:

sudo steamos-readonly disable

See below for instructions on using sudo with Steam Deck. One more warning to complete the warning sandwich – don’t do the above unless you know what you’re doing.

I can see legitimately disagreeing with how to use the Deck on a personal basis, but to say that Valve's intent is contrary to their own FAQ is too strong.

OP, it's a fine desktop. I used it as such a lot when modding Skyrim - just stayed in Steam Deck desktop mode connected to kbm + monitor while doing other stuff. There's no practical difference from a laptop.

I've gone through multiple SteamOS updates in that period and once in a very rare while - certainly not on ever major update even - you may have to toggle ro again and reinstall a package or two. It's not even every package, nor do you have to reinitialize Arch keyrings for example. They're not blowing away the whole os. It's pretty comfy.

Nitrousoxide
May 30, 2011

do not buy a oneplus phone



v1ld posted:

As we've discussed before, I don't know where you came up with the emphasized bits. Valve's actual statement on using Desktop mode is in their FAQ, as pointed out before:

I can see legitimately disagreeing with how to use the Deck on a personal basis, but to say that Valve's intent is contrary to their own FAQ is too strong.

OP, it's a fine desktop. I used it as such a lot when modding Skyrim - just stayed in Steam Deck desktop mode connected to kbm + monitor while doing other stuff. There's no practical difference from a laptop.

I've gone through multiple SteamOS updates in that period and once in a very rare while - certainly not on ever major update even - you may have to toggle ro again and reinstall a package or two. It's not even every package, nor do you have to reinitialize Arch keyrings for example. They're not blowing away the whole os. It's pretty comfy.

You could install distrobox to your home directory and get access to a container with whatever flavor distro you like to run things that cannot be done with flatpaks.

https://github.com/89luca89/distrobox/blob/main/docs/posts/install_rootless.md

v1ld
Apr 16, 2012

Not a bad idea because I was -><- close to installing zsh/neovim/my dotfiles. Held back because there's a perfectly good Arch laptop next to the Deck and I found out I'm not a fan of some bits of KDE Plasma.

CaptainSarcastic
Jul 6, 2013



v1ld posted:

I found out I'm not a fan of some bits of KDE Plasma.

Heresy.

v1ld
Apr 16, 2012

^^^ It's only a few bits. The least significant bits you could say.

Since I mentioned it, if anyone's looking for an easy bootstrap into NeoVim with pre-packaged Telescope, automatic Language Server Protocol support, modern completion and bunch of the newer bells and whistles: https://github.com/nvim-lua/kickstart.nvim

I switched over to NeoVim last year, but migrated my few configs into kickstart last week. Everything is configured nicely, especially if you're a coder. The Mason package will auto-compile and install language servers under ~ for you, so you can get on with coding.

Install ripgrep and fd-find, Telescope will use them if available. That you don't have to even understand how to configure it is nice. Just works.

kickstart calls out to a couple of other files, which is where I moved my personal configs. .config/nvim/lua/custom/plugins.lua for any packages you may have beyond those in kickstart. .config/nvim/after/plugin/defaults.lua is run after kickstart finishes, so I override kickstart's choice from there. Makes it easy to follow kickstart's updates if init.lua is untouched by me.

Quite impressed by NeoVim even as a long-time Emacser who used viper-mode for Vi bindings within it. Always been a heretic.

Another unasked for link: https://github.com/yuk7/ArchWSL is neat if you want Arch as your WSL2 distro. It's very lightweight, just the basics so you can customize as you need yourself. Even had to compile yay to bootstrap into AUR land. Runs Linux 5.15.79, recent enough for me.

ExcessBLarg!
Sep 1, 2001

v1ld posted:

As we've discussed before, I don't know where you came up with the emphasized bits.
Desktop Mode on the Deck is clearly second class. It doesn't get nearly as much QA as Game Mode. It's not Valve's primary focus.

It's there. It usually works. If stuff breaks and is sufficiently raised to their attention they may fix it. However, the vast majority of their engineering effort goes into making Game Mode as polished as possible--simple as that.

Adbot
ADBOT LOVES YOU

Twerk from Home
Jan 17, 2009

This avatar brought to you by the 'save our dead gay forums' foundation.
Are swapfiles appreciably slower than swap partitions? Looks like swapfiles bypass all the normal kernel I/O management and just hit the disk directly no matter what, but apparently Linus recently mentioned that "most normal systems" are using swap partitions and should continue to. If I wanted to give a whole disk to swap, I should just make the whole thing a swap partition, right?

https://wiki.archlinux.org/title/swap

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