« first day (3677 days earlier)      last day (1281 days later) » 

12:00 AM
I have a helpful "kick this out of HNQ" flag on physics, but 1. that doesn't mean the mod complied, 2. it was handled 2 days after the flag, so it's possible that it had already expired on its own by then.
 
Ahh, a kick would create an event: "When moderators kick a post off the HNQ list there will be a delay of up to fifteen minutes or so as the list is cached but the question will be removed the next time it runs. In addition, an event will be logged in the post timeline and edit history that indicates when it was removed and by whom. "
 
@JeffSchaller I can try, although it's still unclear whether the linked questions are exact dupes (because the whole UPnP thing might mean that one of their output devices is not actually an output device)
@JeffSchaller neat
 
@AndrasDeak ahh, then vote your conscience -- my only point was that closed Q's are removed from the list
 
I see. Yeah, I think I'll abstain for now. Thanks for the feedback :)
 
Surely!
 
 
9 hours later…
9:20 AM
@AndrasDeak Thank you for the clarification/update. It looks like I didn't respond to this.
I'll look at it when I'm feeling a bit more awake.
 
9:57 AM
Will there be any difference/discrepancy if sigaction(SIHCHLD) is called 1. before or 2. after forkpty?
Linux x86_64
 
 
4 hours later…
Tim
1:30 PM
Happy Monday!
I have some questions, and appreciate if someone could enlighten me
Does anyone know some books or other references that explain how to understand the order between request (or releases) of different mutexes in a synchronized multiprocess or multithread program?
Thanks in advance!
p.s. Is it just me that it is very hard to reason about a program with multiple mutexes
 
1:46 PM
Tim, you've been told (as have others) that dumping questions in /dev/chat from other sites is not kosher. Willing visitors to Software Engineering will see the questions there.
 
 
2 hours later…
4:01 PM
@AndrasDeak Yes, looking at that now.
 
 
1 hour later…
5:01 PM
Surely there's a better approach for this than the monstrosity I came up with:
1
Q: How can I list all currently logged-in users?

Chris RobisonI have a system I'm managing (running RHEL 8) that has multiple users in our small office, who log into it in various ways -- locally at the console, remotely via SSH and NoMachine Workstation. When I do updates that include a new kernel, or for some other reason I need to reboot the machine, I'd...

 
5:51 PM
@AndrasDeak Great, glad it was useful!
 
@terdon off-the-cuff: `ps -eo pid,uid | awk '$2 >= 1000' -- is empty-ish, or not
 
@terdon Can't you just use last?
@AndrasDeak Is "This sort of article thinks I should follow Glenn Greenwald more closely" a tablet thing?
 
6:07 PM
@FaheemMitha sorry, I didn't get that at all
 
@AndrasDeak Eek. Incorrect paste.
@AndrasDeak Is "the default tool's pressure profile" a tablet thing?
 
Ah. Yeah, these wacom-like tablets have pressure-sensitive styli
So the drawing tools in graphic programs (like pencil vs airbrush etc.) make use of that
 
@AndrasDeak Does that integrate with software on Debian?
 
Yes, and well
 
I.e. do the default Debian drivers support whatever hardware handles the pressure stuff?
 
6:10 PM
Apparently yes, because I didn't do anything to it :)
 
@AndrasDeak Unexpected, but good to know. Do you know what drivers are being used?
 
@JeffSchaller hmm... will that work well with LDAP users? Can we always assume that they''ll have a UID >1000? Also, that rules out root, of course,but the OP might be OK with it
 
Well, except I can't see anything in the settings, as I mentioned earlier. But Krita has a config menu where you can play around and see debug info (x, y coordinates and pressure percentages)
 
@AndrasDeak Which settings?
 
@FaheemMitha how will that help me know the currently logged in users?
 
6:12 PM
@terdon last has options to restrict users by time.
 
@FaheemMitha you know, the screenshot where there was no stylus found... The gnome settings.
 
@terdon yes; it's "just" a ps; the 1000 was my MIN_UID from /etc/login.defs; may need local adjusting
 
@AndrasDeak Oh, that. So, do you see modules loaded for the tablet?
 
@FaheemMitha xhci_hcd, apparently
 
@AndrasDeak That's a pretty generic module. Nothing else?
Just USB support I think. There must be something that is supporting the tablet. That pressure sensitive stuff won't just work by itself.
 
6:15 PM
digging through messages...
ugh, can't copy from terminal
Using input driver 'libinput' for 'Genius MousePen i608X Pen (0)'
Does that help?
 
@AndrasDeak Possibly. Are you using Wayland, then?
 
nope
Wayland broke months ago. I read that Krita has two cursors on wayland: one for the mouse and one for the stylus. Sounds confusing.
 
@AndrasDeak So you were using it for a while? I didn't realise it was ready for production use.
 
6:31 PM
You mean wayland?
 
@AndrasDeak Yes, Wayland.
 
It was the default on my debian testing I think. But after a few months it just broke. I switched to X11 and everything's been working since.
It said "broken atomic modeset userspace detected"
 
@FaheemMitha but I need to know who's here now, not who was here a millisecond ago. Also, I don't think that will help with the LDAP issue.
@JeffSchaller I hadn't realized the 1000 was so widespread these days. That might work!
Wanna post an answer?
 
@terdon I'm not sure; I posted a comment on the Q asking why the aversion to ps; I haven't checked back to see
 
@JeffSchaller I don't think they're averse, as such. They just don't want to do it manually. They were open to my approach.
In any case, the next person might be more willing to go the ps route so you may as well.
 
6:43 PM
@terdon fair enough; the ps ... is a pretty simple solution; doesn't take into account 'interactive'
 
You kinda have to. At this point, you're the only mod with <100k rep...
:P
 
wow, lame
measly 56k :P
 
I'm not the sharpest crayon in this box :)
 
@AndrasDeak Probably fixable.
 
6:53 PM
Probably. But I don't care what makes my gnome work as long as it works. Call me uncultured swine :)
And as usual I had work to do...
It's even possible that if I switched back wayland it would work again
 
@AndrasDeak I wouldn't dream of it. And I wasn't suggesting that you try to switch back to Wayland either.
Anyway, it's possible the libinput driver is doing the heavy lifting, though if that is the case, it's mildly surprising.
Because specific devices generally require specific device drivers. Though maybe it's using some abstraction protocol.
 
I don't even have the tablet plugged in right now. If you have someting I should type in next time I'm using it to help figure it out, I can do that
All I know is that whatever drivers I had out of the box recognized the tablet by name
 
@AndrasDeak Don't worry about it. It's not important. I was just curious.
@AndrasDeak That's a good thing. Generally speaking, it's not worth knowing the details of these things, unless you're being paid for it.
 
That has been my strategy with computers :) I told you that after 15 years of use I'm still a linux noob. This is what I mean when I say that.
 
@AndrasDeak Learning about computer stuff is worthwhile in general. But one has to be selective. To be more specific, learning about hardware device drivers is rarely worthwhile, because that knowledge is very specific and particular, and not something that is more generally useful as part of a broader corpus of knowledge.
But it makes sense if that's your job, of course.
 
7:02 PM
yeah
 
Some other things are worth learning about, because then you understand them better. And computer stuff is usually easy to learn, because it's simple and predictable, though humans are good at making it all much more complicated than it needs to be.
 
7:36 PM
@terdon I posted an answer, despite not yet hearing back from the OP
getting close to my average of 1 Answer per month here; sure hope no ed questions come up for a few weeks
 
lol
@JeffSchaller Note that the OP wants to get a list of logged in user names. Your ps will return processes, not names.
You probably want something like:
    ps -eo user,uid | awk 'NR>1 && $2 >= 1000 && ++seen[$2]==1{print $1}'
 
7:53 PM
Ugh, that awk predicate throws a warning in my cognitive linter :)
 
I added that to your question, but you might want to remove the others since they don't seem to be addressing the question asked.
 
I didn't realize you can just throw those together with no bracketing
 
Ah yes. Awk's really strange that way. It gets worse, you could just do this:
 
noooo :D
 
    ps -eo user,uid | awk 'NR>1 && $2 >= 1000 && ++seen[$2]==1'
That would print all lines that match the conditions. Not a curly brace in sight!
 
7:55 PM
Yeah, I know about implicit print
 
boo, and here I was hoping to impress you :P
 
Also just a p would do the same, maybe? I read these in the manpage once but whenever I tried to use something like it (without looking it up) it never works (read: I misremember)
but I prefer readable code anyway :P
 
@terdon "Of course, you could adjust the ps columns to taste, perhaps to add the translated username and process start time (ps -eo pid,uid,user,start,args)" ...
my assumption (!) is that they're looking for evidence of interactive user processes. Just seeing a username isn't as informative for a reboot as "4-day old idle bash process"
 
That question badly needs a crystal ball
 
@AndrasDeak or a shutdown -r now + 30 minutes :)
if you're interactive, you'll see it, save & exit!
 
7:58 PM
ha
 
(plus maybe a regular maintenance schedule/window, so people know to avoid Mondays at lunchtime, or whatever)
 
The lengths people go to avoid talking to each other...
 
what? just because I name my systems "reboots-weekly-on-Tuesdays-at-1700-GMT"?
 
I meant OP, but I don't judge
 
@JeffSchaller hmm. Maybe. I understood them to need a drop in replacement for who that includes LDAP users.
 
8:05 PM
They have an edit that says it's not about LDAP
 
@JeffSchaller eeeek! Please don't ever do that!
 
It's not like someone would just see that suggestion in chat and do it ( ͡° ͜ʖ ͡°)
 
 
1 hour later…
9:19 PM
@FaheemMitha I found another book on C++ that seems excellent and well suited for experienced programmers; it's called "C++ Crash Course" and it's from 2019.
No Starch Press.
 
10:18 PM
@Wildcard I don't think you can "Crash Course" C++, but thanks for the reference.
Hmm, looks relatively advanced, actually. Probably usable, at least as a reference.
 
10:37 PM
Yeah, it's 700 pages.
Very readable, but based on this comment (the reason it's not on the stackoverflow list of C++ books) I probably won't continue. Reading easily the wrong info isn't much help.
Still might look at it for syntax questions, it seems good for that. So yeah, as a reference, maybe.
 
the UB and new remarks (in chat) do sound scary
Although looking at the sample, the "use after dealloc" remarks seem benign to me (but I'm a C noob)
 

« first day (3677 days earlier)      last day (1281 days later) »