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
sb hermit
Dec 13, 2016





probably hardware or drivers in a bad state

and frankly, with graphics, it could be either

Adbot
ADBOT LOVES YOU

Truga
May 4, 2014
Lipstick Apathy
also, wine especially is an odd collection of software emulating an even weirder thing. if you're having trouble with it, do ps x | grep wine, there's probably a wineserver or some other poo poo still running that's waiting on something to happen, which sometimes prevents you from killing wine itself. i find "killall -9 wine wineserver winedevice.exe" works 100% reliably so far, but i'm sure there's other edge cases.

my homie dhall
Dec 9, 2010

honey, oh please, it's just a machine

Sapozhnik posted:

ideally firefox would support dbus activation, that way it could run as a user unit under systemd and have resource limits and io and vm prioritization applied to it.

gnome on fedora does have some "cgroupify" thing that makes it run inside a unit anyway but it's not quite as discoverable as having a /usr/lib/systemd/user/org.mozilla.Firefox.service

the distribution really ought to set a reasonable resource policy for firefox though, that way whenever firefox has a Little Moment and decides to start dirtying as many pages as it can allocate as quickly as possible it doesn't bring the entire user session down with it.

is there a reason it would need to run as a systemd unit? like, couldn't the launcher set up all the cgroups and stuff?

Sapozhnik
Jan 2, 2005

Nap Ghost
it needs to run outside the cgroup of the desktop shell or whatever else launched it. you don't want web browser vm exhaustion to lock up your desktop shell as well. so there needs to be a way to tell systemd "hey, launch this application in a separate cgroup outside of my own". dbus activation is the standard way of doing that for interactive applications.

my homie dhall
Dec 9, 2010

honey, oh please, it's just a machine

Sapozhnik posted:

it needs to run outside the cgroup of the desktop shell or whatever else launched it. you don't want web browser vm exhaustion to lock up your desktop shell as well. so there needs to be a way to tell systemd "hey, launch this application in a separate cgroup outside of my own". dbus activation is the standard way of doing that for interactive applications.

:tipshat:

Beeftweeter
Jun 28, 2005

a medium-format picture of beeftweeter staring silently at the camera, a quizzical expression on his face

Truga posted:

also, wine especially is an odd collection of software emulating an even weirder thing. if you're having trouble with it, do ps x | grep wine, there's probably a wineserver or some other poo poo still running that's waiting on something to happen, which sometimes prevents you from killing wine itself. i find "killall -9 wine wineserver winedevice.exe" works 100% reliably so far, but i'm sure there's other edge cases.

tbqh `killall -9 wineserver` works just as well

so does `killall -9 firefox` when it decides to poo poo all over your memory pages

e: too many l's!

Beeftweeter fucked around with this message at 15:22 on May 18, 2022

Beeftweeter
Jun 28, 2005

a medium-format picture of beeftweeter staring silently at the camera, a quizzical expression on his face
also ps auxwww supremacy

Truga
May 4, 2014
Lipstick Apathy
2 ws is wide, unlimited, 3 does nothing lol

but yes

Beeftweeter
Jun 28, 2005

a medium-format picture of beeftweeter staring silently at the camera, a quizzical expression on his face

Truga posted:

2 ws is wide, unlimited, 3 does nothing lol

but yes

lol true. i just use it because aux/www is very easy to remember

same with ls -halF

Share Bear
Apr 27, 2004

Captain Foo posted:

who needs they cpuuy ate

outhole surfer
Mar 18, 2003

NihilCredo posted:

kill -9 is more of a gentle suggestion than anything

kill -9 is a pretty hardcore "gently caress-off and go home" that will kill any process not blocked on io.

unfortunately if you're swapping, you're probably also frequently blocking on that swap disk io

pseudorandom name
May 6, 2007

processes blocked by IO have been killable for like 15 years now

Mr. Crow
May 22, 2008

Snap City mayor for life
I've had games loving up but can say hitting "cancel" in steam almost always closes it; otherwise you can (need) to trace all the processes proton is spawning to kill it properly with just 'kill'. Grepping for the game isn't enough, its usually like 5 or 6 processes to low, same with wine though usually wine is enough for steam to reap the rest of the processes :shrug:

Sapozhnik
Jan 2, 2005

Nap Ghost
i enjoy the level of commitment to os compatibility that makes Proton put frozen direct3d applications on top of every other application, including any applications you might use to kill them

fortunately it is possible to switch virtual desktops at least.

outhole surfer
Mar 18, 2003

pseudorandom name posted:

processes blocked by IO have been killable for like 15 years now

killable in that you can fire off the sigkill and it will eventually be processed, but the process won't actually be killed, and you won't get back system resources until it exits that uninterruptible sleep. the big change in the last 15 years is that everyone has an ssd and you're way less likely to see processes in a D state unless hardware is hosed

pseudorandom name
May 6, 2007

no, TASK_KILLABLE was introduced to be a TASK_UNINTERRUPTIBLE that accepted lethal signals

the reason why TASK_UNITERRUPTIBLE didn't take signals was purely an issue of backwards compatibility -- applications didn't expect to receive signals in uninterruptible sleep, so the kernel didn't deliver them, but applications can't handle lethal signals to begin with so there's no compatibility issue

Antigravitas
Dec 8, 2019

Die Rettung fuer die Landwirte:
Or unless you have an NFS mount. I had really some old system that some dolt had configured hard NFS mounts on (no intr either) and when the NFS server became unavailable entire trees on the file system became tar pits that I had to carefully avoid because even an accidental tab complete would lock the shell forever.

The infrastructure I encountered when I started that job still infuriates me. One part of the infra also used LDAP, a single Windows DC, Samba localdb, and motherfucking NIS, all in the same lab.

outhole surfer
Mar 18, 2003

pseudorandom name posted:

no, TASK_KILLABLE was introduced to be a TASK_UNINTERRUPTIBLE that accepted lethal signals

the reason why TASK_UNITERRUPTIBLE didn't take signals was purely an issue of backwards compatibility -- applications didn't expect to receive signals in uninterruptible sleep, so the kernel didn't deliver them, but applications can't handle lethal signals to begin with so there's no compatibility issue

code:
[nnt@computar linux]$ grep -r TASK_UNINTERRUPTIBLE drivers/ | wc -l
186
[nnt@computar linux]$ grep -r TASK_KILLABLE drivers/ | wc -l
1
plenty of places for a process to still get hung up on io. a solid chunk of those are in md, usb, and scsi

pseudorandom name
May 6, 2007

you need to grep for _killable

Jonny 290
May 5, 2005



[ASK] me about OS/2 Warp
i most certainly do not

Captain Foo
May 11, 2004

we vibin'
we slidin'
we breathin'
we dyin'

sigkill no.5

outhole surfer
Mar 18, 2003

pseudorandom name posted:

you need to grep for _killable

fair enough, that brings in 95 instances of it being used (compared with 300 now for _uninterruptible).

my point stands that io through chunks of usb, md, scsi, and other common io subsystems can in fact leave a process uninterruptible.

sure, there may be a better way for those drivers to do it, but they aren't yet.

Captain Foo
May 11, 2004

we vibin'
we slidin'
we breathin'
we dyin'

just stop scheduling the process what could go wrong

sb hermit
Dec 13, 2016





also if a process triggers a kernel oops then killing it does nothing.

you have to reboot the system to clear it out.

Beeftweeter
Jun 28, 2005

a medium-format picture of beeftweeter staring silently at the camera, a quizzical expression on his face

nudgenudgetilt posted:

fair enough, that brings in 95 instances of it being used (compared with 300 now for _uninterruptible).

my point stands that io through chunks of usb, md, scsi, and other common io subsystems can in fact leave a process uninterruptible.

sure, there may be a better way for those drivers to do it, but they aren't yet.

this is true and since most chromebooks use eMMC it loving blows

luckily my newest one uses a (replaceable) nvme ssd :getin:

Poopernickel
Oct 28, 2005

electricity bad
Fun Shoe
cron:

hmm, yase let me just google which magic * does the thing I want in my crontab.

I sure do love not knowing if the job succeeded. And manual triggering my task??? Who would ever want that.

Also it rules when I have to go hunting for the stdout/stderr in whatever random place they wind up. Maybe I can have cron helpfully email me the results.

systemd timers: just works. Boring and easy.

Mr. Crow
May 22, 2008

Snap City mayor for life
Maybe you just need to read the 15 man pages again, cron has been a rock solid platform since Jared Bedwetter wrote it for UNIX 1.3 in 1964

:smuggo:

Beeftweeter
Jun 28, 2005

a medium-format picture of beeftweeter staring silently at the camera, a quizzical expression on his face
hmm yeah let me just google "how to do my job". that'll show those idiot nerds,

Sapozhnik
Jan 2, 2005

Nap Ghost
the unix philosophy is when you have a bunch of tools written 50 years ago for what would today be considered a microcontroller, none of which have any sort of consistency or overarching design philosophy whatsoever.

BattleMaster
Aug 14, 2000

you don't need consistency when you can pipe them through a dozen different plaintext processing programs to extract what you need

sb hermit
Dec 13, 2016





there is a crontab man page, op.

also, if you configure it right, cron e-mails you the standard output. So you can easily write a script that is quiet unless an error occurs.

cron is like vi. not everyone likes it, but it just works and it has its fans.

outhole surfer
Mar 18, 2003

sb hermit posted:

there is a crontab man page, op.

also, if you configure it right, cron e-mails you the standard output. So you can easily write a script that is quiet unless an error occurs.

cron is like vi. not everyone likes it, but it just works and it has its fans.

email. as the primary mechanism to report the output and status of scheduled jobs. in 2022. email.

email.

WHAT THE gently caress IS WRONG WITH YOU?

Jonny 290
May 5, 2005



[ASK] me about OS/2 Warp
nothing involving emailing me can be considered "properly configured"

efb

FlapYoJacks
Feb 12, 2009
You can also write a tiny python script that sends you a Slack message. :v:

Edit* You can also use bash + curl to send Slack messages.

FlapYoJacks fucked around with this message at 17:14 on May 19, 2022

Captain Foo
May 11, 2004

we vibin'
we slidin'
we breathin'
we dyin'

Jonny 290 posted:

nothing involving emailing me can be considered "properly configured"

efb

we’ll just hook it into your pagerduty notifications

Jonny 290
May 5, 2005



[ASK] me about OS/2 Warp
you just lost a friend, foo

Beeftweeter
Jun 28, 2005

a medium-format picture of beeftweeter staring silently at the camera, a quizzical expression on his face

FlapYoJacks posted:

You can also write a tiny python script that sends you a Slack message. :v:

Edit* You can also use bash + curl to send Slack messages.

or sms, or a mobile notification, or... yeah, there's a lot of poo poo you can script

Best Bi Geek Squid
Mar 25, 2016
unwinding after a long day by reading email reports about my scheduled computer tasks

Mr. Crow
May 22, 2008

Snap City mayor for life
Love to reinvent the wheel for 5 decades janitoring my cron jobs just to get notified my yospos archiver is a piece of poo poo

Adbot
ADBOT LOVES YOU

Truga
May 4, 2014
Lipstick Apathy
in my experience, usually when poo poo fails it's because a network's down somewhere and postfix will still deliver your message to the mailbox when it's back up, while you're python/curl script won't

that's not to say you shouldn't try sending not-mail notifications, but mail is the perfect fallback

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