• 0 Posts
  • 43 Comments
Joined 2 years ago
cake
Cake day: October 4th, 2023

help-circle

  • Depends pretty wildly on what you like.

    Some things that I do:

    I never want automatic locking — I always lock my machine manually when leaving it, with Super-\ (Super normally being the Windows key). I also want my monitor to power off after a few seconds in that mode, and then wake back up if I start typing. I also want to use a black screen rather than swaylock’s default white.

    in my ~/.config/sway/config:

    set $mod Mod4
    
    # Handle session-locking triggered by stuff like loginctl lock-session
    exec_always swayidle -w \
                 lock 'myscreensaver.sh'
    
    # Bind Super-backslash to trigger a session lock
    bindsym $mod+backslash exec "loginctl lock-session""
    

    in ~/bin/myscreensaver.sh:

    #!/bin/bash
    # Script that handles things necessary to "lock" the system when I'm away
    
    # Pause any music that mpd is playing
    mpc pause
    
    swayidle \
        timeout 5 'swaymsg "output * dpms off"' \
        resume 'swaymsg "output * dpms on"' &
    swaylock -c 000000
    kill %1
    

    By default, X11 (and Wayland, apparently, though I’ve spent less time looking at Wayland’s APIs) don’t “store” clipboard state – they just facilitate transferring copied data from one application to another application where it’s being pasted. This means that if one copies data in one application and then closes that application, the clipboard contents go away. I don’t really like this behavior. One way to avoid it is to use a “clipboard manager” — a piece of software that saves a copy of the data itself. If you install clipman and wl-clipboard, you can do this:

    In ~/.config/sway/config:

    # Make clipboard persist after application termination
    exec_always flock -n $XDG_RUNTIME_DIR/$WAYLAND_DISPLAY-wl-paste wl-paste --watch clipman store
    

    I want to get notifications when my laptop battery is low. Install poweralertd, and then in ~/.config/sway/config:

    # Power notification support
    exec_always flock -n $XDG_RUNTIME_DIR/$WAYLAND_DISPLAY-poweralertd poweralertd
    

    I don’t use it that much, but Sway has a “scratchpad”, where one can stuff a window that one is working with. With this, I send the current window there with Super-Shift-minus then make it pop back up as a floating window with Super-minus:

    # Scratchpad
    bindsym $mod+shift+minus move window to scratchpad
    bindsym $mod+minus scratchpad show
    

    I have a mute button on my laptop’s keyboard. I make that mute the default PipeWire sound sink. In ~/.config/sway/config:

    bindsym XF86AudioMute exec "wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle"
    

    I swap Caps Lock and left Control. This is how traditional Unix keyboards worked, and is generally more-friendly if you are using the Control key a lot more than Caps Lock. I’d consider this almost a precondition to use emacs without making your left pinky miserable. In ~/.config/sway/config:

    input "type:keyboard" {
          xkb_options ctrl:swapcaps,compose:menu,compose:ralt
    }
    

    That also sets my menu key (on my desktop) and right Alt key (on my laptop, which doesn’t have a menu key) to be Compose. That way I can do things like type “ö” by hitting Compose o and then the double-quote key, or an em-dash (“—”) with Compose hyphen hyphen hyphen.

    I don’t like keeping my mouse pointer visible unless I’m actually moving it. In my ~/.config/sway/config, this will hide it after three seconds:

    # Hide mouse cursor after a period of inactivity.
    seat seat0 hide_cursor 3000
    

    I like to have a way to, using the keyboard, hide the latest notification shown by swaync, the default Sway notification manager. In ~/.config/sway/config:

    bindsym $mod+grave exec "swaync-client --hide-latest"
    

    Then Super-backtick will hide the most recent notification to show up.


  • One thing that I’ve found that I like is having my waybar not normally visible. When I need to glance at the bar, I can just hold the Sway modifier key to make it temporarily show up.

    in ~/.config/sway/config:

    bar {
        swaybar_command waybar
        mode hide
    }
    

    More screen space for whatever I’m actually doing. If something is so critical that it needs to grab my attention (e.g. battery low on a laptop) then I have it set up to send a message to the notification manager.


  • Not what you asked, but regardless of whatever else you’re doing, I would take any really critical data you need, encrypt it, put it on a laptop or other portable device, and bring it with you. Trying to throw together some last-minute setup that you rely on and can’t easily resolve remotely is asking for trouble.

    Another fallback option, if you have a friend who you trust and can call and ask them to type stuff in – give 'em a key before you go and call 'em and ask 'em to type whatever you need if you get into trouble.


  • Of course, another option is for people to dramatically curb their use of social media, or at a minimum, regularly delete posts after a set time threshold.

    Deletion won’t deal with someone seriously-interested in harvesting stuff, because they can log it as it becomes available. And curbing use isn’t ideal.

    I mentioned before the possibility of poisoning data, like, sporadically adding some incorrect information about oneself into one’s comments. Ideally something that doesn’t impact the meaning of the comments, but would cause a computer to associate one with someone else.

    There are some other issues. My guess is that it’s probably possible to fingerprint someone to a substantial degree by the phrasing that they use. One mole in the counterintelligence portion of the FBI, Robert Hanssen, was found because on two occasions he used the unusual phrase “the purple-pissing Japanese”.

    FBI investigators later made progress during an operation where they paid disaffected Russian intelligence officers to deliver information on moles. They paid $7 million to KGB agent Aleksander Shcherbakov[48] who had access to a file on “B”. While it did not contain Hanssen’s name, among the information was an audiotape of a July 21, 1986, conversation between “B” and KGB agent Aleksander Fefelov.[49] FBI agent Michael Waguespack recognized the voice in the tape, but could not remember who it was from. Rifling through the rest of the files, they found notes of the mole using a quote from George S. Patton’s speech to the Third Army about “the purple-pissing Japanese”.[50] FBI analyst Bob King remembered Hanssen using that same quote. Waguespack listened to the tape again and recognized the voice as Hanssen’s. With the mole finally identified, locations, dates, and cases were matched with Hanssen’s activities during the period. Two fingerprints collected from a trash bag in the file were analyzed and proved to be Hanssen’s.[51][52][53]

    That might be defeated by passing text through something like an LLM to rewrite it. So, for example, to take a snippet of my above comment:

    Respond with the following text rephrased sentence by sentence, concisely written as a British computer scientist might write it:

    Deletion won’t deal with someone seriously-interested in harvesting stuff, because they can log it as it becomes available. And curbing use isn’t ideal.

    I mentioned before the possibility of poisoning data, like, sporadically adding some incorrect information about oneself into one’s comments. Ideally something that doesn’t impact the meaning of the comments, but would cause a computer to associate one with someone else.

    I get:

    The deletion of data alone will not prevent a determined party from gathering information, as they may simply record the information as it becomes available prior to its deletion. Moreover, restricting usage is not an ideal solution to the problem at hand.

    I previously mentioned the possibility of introducing deliberate errors or misinformation into one’s own data, such as periodically inserting inaccurate details about oneself within comments. The goal would be to include information that does not significantly alter the meaning of the comment, but which would cause automated systems to incorrectly associate that individual with another person.

    That might work. One would have to check the comment to make sure that it doesn’t mangle the thing to the point that it is incorrect, but it might defeat profiling based on phrasing peculiarities of a given person, especially if many users used a similar “profile” for comment re-writing.

    A second problem is that one’s interests are probably something of a fingerprint. It might be possible to use separate accounts related to separate interests — for example, instead of having one account, having an account per community or similar. That does undermine the ability to use reputation generated elsewhere (“Oh, user X has been providing helpful information for five years over in community X, so they’re likely to also be doing so in community Y”), which kind of degrades online communities, but it’s better than just dropping pseudonymity and going 4chan-style fully anonymous and completely losing reputation.




  • Note that on current, systemd-based systems, one probably wants sudo journalctl -kb to show kernel messages for the current boot.

    dmesg reads from the in-memory kernel ring buffer. That can be desirable in some cases, but as the name suggests, the “ring buffer” is a “ring” — it has a finite amount of space and eventually, the old stuff gets overwritten by the new stuff. The idea is that a userspace logging daemon, like journald (or syslogd on most older systems) has time to pull the data from the ring buffer out to (potentially much larger) log files on disk.

    journalctl will also post-process the output to do things like convert the time-from-boot to a wall clock time, which is generally more useful for correlating with other things.



  • If you don’t want it, you can hide it — most distros have some way to just show a splash screen that hides it. I always unhide it, as I can see hints of things going wrong.

    The messages are from a wide variety of kernel subsystems (and, later in the boot process, daemons) and most people aren’t going to be familiar with everything. I could tell you what a lot of lines mean, but there are always new ones showing up as new software is written.

    They’re more-likely to be useful if something breaks and then you go examine a specific, suspicious-looking message and learn what it means. You probably won’t be constantly trying to stay up on all kernel subsystems.




  • It doesn’t matter if you’re, say, Debian, because they’ll just put up some symbolic “not intended for use in state X” and then continue doing whatever they were doing, but if you’re Red Hat and actually selling something like Red Hat Enterprise Linux to companies in the state, stuff like this is actually a pain in the ass.

    And to reiterate a previous comment, the Democrats have a trifecta in both California and Colorado, and the legislation here is something that they are squarely to blame for. I’d really rather that they knock this kind of horseshit off so that I can go back to being upset with the Republican Party.



  • If it happens again and you have Magic Sysrq enabled, you can do Magic Sysrq-t, which may give you some idea of what the system is doing, since you’ll get stack traces. As long as the kernel can talk to the keyboard, it should be able to get that.

    https://en.wikipedia.org/wiki/Magic_sysrq

    You maybe can’t see anything on your monitor, but if the system is working enough to generate the stack traces and log them to the syslog on disk (like, your kernel filesystem and disk systems are still functional), you’ll be able to view them on reboot.

    If it can’t even do that, you might be able to set up a serial console and then, using another system running screen or minicom or something like that linked up to the serial port, issue Magic Sysrq to that and view it on that machine.

    Some systems have hardware watchdogs, where if a process can’t constantly ping the thing, the system will reboot. That doesn’t solve your problem, but it may mitigate it if you just want it to reboot if things wedge up. The watchdog package in Debian has some software to make use of this.


  • I’m not sure that memory — and I’m speaking more-broadly than HBM, even — optimized for running neural nets on parallel compute hardware and memory optimized for conventional CPUs overlap all that much. I think that, setting aside the HBM question, that if we long-term wind up with dedicated parallel compute hardware running neural nets, that we may very well wind up with different sorts of memory optimized for different things.

    So, if you’re running neural nets, you have extremely predictable access patterns. Software could tell you what its next 10 GB of accesses to the neural net are going to be. That means that latency is basically a total non-factor for neural net memory, because the software can request it in huge batches and do other things in the meantime.

    That’s not the case for a lot of the memory used for, say, playing video games. Part of the reason, aside from hardware vendors using price discrimination that PCs (as opposed to servers) don’t use registered memory (which makes it easier to handle more memory) is because it increases latency a little bit, which is bad when you’re running software where you don’t know what memory you’re going to need next and have a critical path that relies on that memory.

    On the other hand, parallel compute hardware doing neural nets are extremely sensitive to bandwidth. They want as much as they can possibly get, and that’s where the bottleneck is today for them. Back on your home computer, a lot of software is oriented around doing operations in serial, and that’s more prone to not saturate the memory bus.

    I’d bet that neural net parallel compute hardware does way more reading than writing of memory, because edge weights don’t change at runtime (on current models! That could change!).

    searches

    Yeah.

    https://arxiv.org/html/2501.09605v1

    AI clusters today are one of the major uses of High Bandwidth Memory (HBM). However, HBM is suboptimal for AI workloads for several reasons. Analysis shows HBM is overprovisioned on write performance, but underprovisioned on density and read bandwidth, and also has significant energy per bit overheads. It is also expensive, with lower yield than DRAM due to manufacturing complexity.

    But there are probably a lot of workloads where your CPU wants to do a ton of writes.

    I’d bet that cache coherency isn’t a huge issue for neural net parallel compute hardware, because it’s going to be a while until any value computed by one part of the hardware is needed again, until we reach the point where we can parallel-compute an entire layer at one go (which…I suppose we could theoretically do. Someone just posted something that I commented on about someone making an ASIC with Llama edge weights hard-coded into the silicon, which probably is a step in that direction). But with CPUs, a big problem is making sure that a value written by one CPU core reaches another CPU core, that the second doesn’t use a stale value. That’s gonna impact the kind of memory controller design that’s optimal.


  • I think that it’s fair to say that AI is not the only application for that hardware, but I also think that carpelbridgesyndrome’s point was that they aren’t really well-suited to replace conventional servers, where all local computing just moves to a server, which is the sort of thing that ouRKaoS was worried about. Maybe for some very specialized use cases, like cloud gaming in some genres. I’d also add that the physical buildings have way more cooling capacity than is necessary for conventional servers, so they probably wouldn’t be the most-cost-effective approach even if you replaced the computing hardware in the buildings.




  • While it’s very fair to point out that non-tariff barriers to trade are a real and consequential thing, and that they probably throttle trade in the EU, it’s also not really an apples-to-apples comparison to compare intra-EU NTBs to US tariff-only barriers, as the US will also have its own NTBs.

    My understanding is that NTBs became the more-substantial form of barrier quite some time back. They’re harder to crack down on (e.g. is a food standard in place because there’s actual concern about sanitary concerns or is it actually there to create protectionist policy? Advocates of it will swear the former).