Re: Multi seat. Was Debian versions

2024-11-12 Thread Stefan Monnier
> With multi-seat (ISTR the term originated at Redhat), people started
> to re-invent what a "user session" means. In a confusingly and quite
> irritatingly new manner, mind you. So you now (yay!) can have two Gnome
> sessions. But you pay the price that a Gnome session is quite a different
> beast from an X session, with an own DBUS thingy, an own Systemd
> thingy, yadda, yadda (same goes for KDE).

AFAIK this is orthogonal to multi-seat, e.g. the above issues already
arise with multiple concurrent logins on a single-seat setup, via
virtual-consoles.

Multi-seat issues have to do with the fact that monitors, keyboards,
mouses, etc... are connected "separately", so from a hardware point of
view there's no way for the machine to know which set of devices should
be used together and which set corresponds to a "new seat".
At least, not without extra manual configuration.

Contrast this to the old TTY days where all the devices connected to
a "seat" (monitor, keyboard, occasionally mouse, even sometimes
printers) where physically connected together via a single serial port.

[ Plus the fact that multiple monitors can be connected to the same
  graphics card, but if you want to use them in a "multi-seat" setup,
  they each want to run a separate Xorg server yet those servers need
  to share the graphics card, as you mentioned.  ]


Stefan



Re: Opening a URL with NetSurf from another application

2024-11-05 Thread Stefan Monnier
>>> On 05/11/2024 11:08, Stefan Monnier wrote:
>>>> default browser: how would you get it to open a new tab in an existing
>>>> window when, e.g. `xdg-open` needs it?

Max Nikulin [2024-11-05 23:51:21] wrote:
> Is your problem that new window is opened instead of new tab in response to
> "xdg-open https://debian.org";?

Yup.

> Looking into the man page, I am in doubts if
> the command may communicate with an earlier launched instance.

That's also my conclusion from reading the doc, but the doc seems
sufficiently minimalist that I'm hoping the feature is there, just not
documented properly.


Stefan



Re: Opening a URL with NetSurf from another application

2024-11-05 Thread Stefan Monnier
Max Nikulin [2024-11-05 23:04:16] wrote:
> On 05/11/2024 11:08, Stefan Monnier wrote:
>> But I'd like to be able to send URLs to NetSurf and can't figure out how
>> to do it.  Am I missing something?  Say you'd like to install it as your
>> default browser: how would you get it to open a new tab in an existing
>> window when, e.g. `xdg-open` needs it?
>
> <https://wiki.debian.org/DefaultWebBrowser#GUI_Applications>

That's the part with which I'm familiar.  My question is about NetSurf.

> and proper CLI options

That's my question.


Stefan



Re: XOFF (C-s) on ptys works by default

2024-11-05 Thread Stefan Monnier
Nicolas George [2024-11-05 12:11:39] wrote:
> Marc SCHAEFER (12024-11-05):
>> It could have been handy on a real tty
> It is very handy on emulated ttys too. You never had the output of
> tcpdump / tail -f /var/log/… / make you wanted to pause to inspect
> something?

I always use `C-z` for that.


Stefan



Opening a URL with NetSurf from another application

2024-11-04 Thread Stefan Monnier
Someone mentioned NetSurf recently here and I'm trying it out.
It's an interesting "halfway" point between TUI browsers like Lynx/EWW,
and monsters like Firefox.

But I'd like to be able to send URLs to NetSurf and can't figure out how
to do it.  Am I missing something?  Say you'd like to install it as your
default browser: how would you get it to open a new tab in an existing
window when, e.g. `xdg-open` needs it?


Stefan



Re: Minimalist HTML 4 viewer available?

2024-11-04 Thread Stefan Monnier
>>> Frames were current up through HTML 4[7] but are non-conformant in
>>> HTML 5[8], although interestingly enough still described[9].
>> Not sure if we're talking about the same "frames", but uMatrix has
>> a column dedicated to frames and I see it used fairly frequently for
>> captchas and online credit card payment elements.
> That probably includes iframes (inline frames). I was talking about
> the HTML pre-5  and related tags.

Ah, thanks, makes sense!


Stefan



Re: Debian 12 installation - installation USB stick boots to grub prompt

2024-11-04 Thread Stefan Monnier
> If I boot from the USB stick (isohybrid image) in Legacy mode then it
> all **appears** to work, installation completes, but then the system
> won't boot.

What kind of boot loader did you install?  `grub-efi`, `grub-pc`,
something else?
Does your Debian install's boot fail in exactly the same way if you ask
your firmware to boot using legacy BIOS?

> I don't see how I can opt to either "Always boot using legacy BIOS
> mode" or "Always boot using UEFI".

In my firmware, I can/could choose which boot mode to activate.
So on the Debian side I installed `grub-pc` and on the firmware side
I activated the legacy mode.  That made it boot successfully using
legacy BIOS mode.

> How would I "Boot the install using legacy BIOS, then manually change
> the install to use grub-efi", I can't see anywhere in the installation
> process that would allow me to do this.

That's why I said "manually".


Stefan



Re: Minimalist HTML 4 viewer available?

2024-11-04 Thread Stefan Monnier
> Frames were current up through HTML 4[7] but are non-conformant in
> HTML 5[8], although interestingly enough still described[9].

Not sure if we're talking about the same "frames", but uMatrix has
a column dedicated to frames and I see it used fairly frequently for
captchas and online credit card payment elements.


Stefan



Re: Debian 12 installation - installation USB stick boots to grub prompt

2024-11-04 Thread Stefan Monnier
> I suspect that this is why, when I boot from the USB stick in BIOS
> compatibility mode the resulting installation doesn't work.

Last time I did an install on a UEFI machine (most of my machines are
too old, and of the two that aren't, one is running Coreboot 🙂),
I found out that if the installation media is booted in "legacy BIOS"
mode, then it can't do an install that boots via UEFI.
IOW I had 3 choices:

- Always boot using legacy BIOS mode.
- Always boot using UEFI.
- Boot the install using legacy BIOS, then manually change the install
  to use grub-efi, then reboot into my EFI config to "activate" the
  right `.efi` installed into the EFI partition.

I started with the first choice, and then a few months later went
through the trouble of the third which required more fiddling and
reboots than I care to admit.


Stefan



Re: printer problem

2024-10-30 Thread Stefan Monnier
> You could try asking Kyocera for support (if they offer such an option), or
> perhaps someone from the IT department of your university (some other linux
> user might have had the same problem). Unfortunately your options are
> not great.

Maybe it's worth looking into how it works for people printing from
Android/ChromeOS devices (which may(?) be more numerous than GNU/Linux users).


Stefan



Re: X server blocked by SecureBoot

2024-10-29 Thread Stefan Monnier
>> NVIDIA is a major pain in the ass with Linux.  Which is why I do not
>> use them.
> Actually this is more Linux being a major pain in the ass to Nvidia.

Hmm... I haven't seen any sign that Nvidia suffers much, so I think it's
more clearly a pain inflicted on Linux.


Stefan



Re: battery tester

2024-10-29 Thread Stefan Monnier
> Yep, after thinking a bit and poking the interwebs for good measure, I'm
> convinced now that you are right.

Miscreant!


    Stefan



Re: battery tester

2024-10-29 Thread Stefan Monnier
>> The CH340 is a well-known device, and the usbserial module along with
>> something like cp210x should deal with multiple devices, assigning them
>> ttyUSBx device numbers.
[...]
> I doubt all that baud rate, stop bits and parity dance we know and love
> from the RS232s of yore are necessary with TTYUSBs. We are talking to
> an abstraction layer in the kernel anyway.

The CH340 is a real USB<->serial converter, so somewhere inside the
device is a real serial connection which speaks at a specific speed and
the CH340 probably has to match that speed if we want to get valuable
output, I suspect.  IOW, I think it's not "just an abstraction layer".


Stefan



Re: need .md reader that can print ONLY tha page being viewed

2024-10-27 Thread Stefan Monnier
> Seems to me we should not have to print a 90 page document to get the one
> page/paragraph of interest.

I agree, but I wonder why you think it needs to be stated.
What tool are you using and what part of it makes you think it really
wants you to print all 90 pages of a document?

FWIW, nowadays I basically never print to paper from anything else than
my favorite PDF viewer (which does offer me to print any selected
subset of the pages).  For everything else, I "print to PDF" (and then
use my PDF viewer to print to paper the parts I need, if that's
what I want).


Stefan



Re: USB flash with varying VendorID:ProductId

2024-10-19 Thread Stefan Monnier
> lsusb -vt
> /:  Bus 02.Port 1: Dev 1, Class=root_hub, Driver=xhci_hcd/2p, 1M
> ID 1d6b:0003 Linux Foundation 3.0 root hub
> |__ Port 2: Dev 5, If 0, Class=Mass Storage, Driver=usb-storage, 5000M
> ID 8564:1000 Transcend Information, Inc. JetFlash
>
> however it may accidentally become
>
> usb 3-3: Product: SM3265AB MEMORY BAR
> usb 3-3: Manufacturer: Silicon Motion,Inc.
>
> |__ Port 3: Dev 8, If 0, Class=Mass Storage, Driver=usb-storage, 480M
> ID 090c:3265 Silicon Motion, Inc. - Taiwan (formerly Feiya
> Technology Corp.)

Hmm... I'm way out of my depth here, but the one thing that I notice
that the the Transcend state is using USB3 (hence xHCI) whereas the
Silicon Motion state uses USB2 speed (and presumably the EHCI).

> It seems, attempt of booting live system is a reliable way to put the device
> into its "Silicon Motion" state.

My guess is that the boot code (BIOS?  Grub?) doesn't support USB3 (it
doesn't have a driver for the xHCI controller, only for the EHCI
controller).


Stefan



Re: Bug in 'more' command

2024-10-17 Thread Stefan Monnier
> (I do use less, FWIW).

FWIW, I do use less more as well, but I also use more, tho less so.


    Stefan



Re: Streaks on screen. maybe OT

2024-10-14 Thread Stefan Monnier
> Not much of a film director but here a short video of the phenomenon.

Ah, that doesn't looks like a software problem, indeed.


    Stefan



Re: Streaks on screen. maybe OT

2024-10-13 Thread Stefan Monnier
> A couple of days ago it starts up with a flurry, relatively dark screen with
>   streaks. After about 10 minutes hooked by HDMI to a monitor for tv it
>   becomes more distinct and brighter though not so much as before, streaks
>   are gone. (I think it may be getting darker. The image on the tv is as
>  bright and distinct as ever.)

Does the "dark screen with streaks" still show something useful?
Maybe a photo would help diagnose the problem.

If the "dark screen with streaks" does not show anything resembling the
windows&text you expect to see, then it reminds me of a thing I've seen
on some laptops when the driver fails to initialize the
display properly (i.e. a software problem).  Does it happen right away
at boot, or only later on (say, when the DRM driver is loaded, or when
X11 or Wayland is launched)?


Stefan



Re: Debian and open source scroungers

2024-10-11 Thread Stefan Monnier
>> [...]
>> Please, tell me what are your thoughts on this.  Am I too pessimistic?
>> Are you, like me, thinking these companies as open source "scroungers"?
> I think it's more that "companies" tend to need assurances (i.e. someone
> to call and blame when [insert solution here] doesn't do something in an
> expected manner).

Yup, the Free Software world needs more companies who sell support
contracts and collaborate between them to lower their costs and
strengthen their offering (so as to be competitive with larger
corporations).

But of course, there's still the issue that "noone was fired for buying
", so any human-scale company offering support contracts
will tend to be overlooked, even if its bid is competitive.


Stefan "whose employer (Université de Montréal) spends >$10M
yearly on an Oracle support contract 🙁"



Re: Refugee from [x]ubuntu, a few initial questions

2024-10-10 Thread Stefan Monnier
> 2 - Can I easily make a 'server' type installation without a GUI? This
> is for a backup system in my garage which is (usually) headless.  Even
> better can I do the installation via ssh?

Assuming you have enough disk space, you can install into a new
LV/partition while the old system is still running (via `deboostrap`
and then `chroot`).  It's more fiddly than using the normal Debian
installer, but that's my second favorite choice (my first choice is to
just clone some existing install, e.g. via `dd`).


Stefan



Re: backup of backup or alternating backups?

2024-10-09 Thread Stefan Monnier
> Like I say I like and use rsnapshot in some places, but speed and
> resource efficiency are not its winning points.

I have never used Rsnapshot, but I used Rsync backups for many years and
then moved to Bup.  The time to perform backups has been *very*
substantially shortened by moving to Bup.

The size of the backup repository is also nicely reduced (probably a mix
of compression and of deduplication between files on different hosts
that are backed up to the same repository).

It is also much less demanding on the backup server, both in terms of
RAM use and CPU time (I use low-power SBCs for that job).

A full restore from Bup can be fairly slow, OTOH.  Luckily, I've only
ever had to fetch a few files from the backup (via `fuse`), but it does
make it more costly to *use* your backup (e.g. I used to have a script
which tracked the size of the last set of backed up files, as a way to
detect unexpected changes in this size, but that is now impractical).


    Stefan



Re: Debian 12: need nvidia-settings to join 2 2560x1440 into a 2880x2560

2024-10-08 Thread Stefan Monnier
> I took the risk, clicked on "apply", watched the packages load but during
> the installation got the message "Free nouveau kernel module conflicts with
> non free nvidia module.  Reboot". I saw several messages of the form:

Hmm... maybe I'm wrong but this gives me the impression you were not
using nvidia's proprietary drivers, which which case you don't/didn't
need `nvidia-settings` because `xrandr` (and the various front-ends for
it) should have worked fine.

Am I missing something?


Stefan



Re: Reading an old HDD

2024-10-05 Thread Stefan Monnier
> When I unplugged the transformer just now to store it, I
> discovered that on the back it is labeled to output 12 volts
> and 2.0 amps.  That is 24 watts, which might not be enough to
> spin up some hard drives.  I'm not sure; it seems borderline.

It should be OK and in any case it should be easy to diagnose simply by
listening to the drive.


Stefan



Re: Synaptic Problem

2024-10-03 Thread Stefan Monnier
> Just one non-problem Stefan, Brother seems to be our friend AND their
> drivers JUST WORK!  I can't say the same for cups.

Some weird friends you have, who don't let you see the code they force
you to run to use the tools you buy from them.

Also "just works" doesn't mean "isn't full of security holes" 


Stefan



Re: Synaptic Problem

2024-10-03 Thread Stefan Monnier
>   1. (sudo) dpkg -i brscan4-0.4.11-1.amd64.deb
>   2. (sudo) apt-get update && apt-get -f install

Of course, such manual install of `.deb` files means that you won't
automatically get future updates, e.g. to fix security bugs.
To add insult to injury, such `.deb` files often contain proprietary code,
of course.


Stefan



Re: Which subdirectory for a usedr-specific executable?

2024-10-03 Thread Stefan Monnier
> Is there standard/recommended location for an executable to be used by only
> a one user?
> In my case it should be under /home/richard/ .
> But where?

I'd put it in ~/bin


Stefan



Re: backup of backup or alternating backups?

2024-10-01 Thread Stefan Monnier
> Also why I would not want all backup-storage devices connected
> simultaneously. All it takes is one piece of software going haywire
> and you may have a situation where both the original and all backups
> are corrupted simultaneously.

You can minimize this risk by having them both connected simultaneously
but to different machines (this is also necessary if you want A and B to
be in different physical locations, e.g. to survive disasters), and then
make sure the machine which copies from A to B doesn't have write access
to A.


Stefan



Re: ext4 file system corruption - again

2024-09-23 Thread Stefan Monnier
> root has been mounted 13 times without being checked, check forced.
> root: Inode 10748715, i_blocks is 281474976710631, should be 5. FIXED.
^^^
AKA -25

> root: Inode 10751288, i_blocks is 281474976710647, should be 3. FIXED.
^^^
AKA -9

It's odd that it looks like -N².  Maybe it's just happenstance, but I'd
be curious to see if you have other "data points".


Stefan



Re: Circumventing keyboard problem on Lenovo R64

2024-09-12 Thread Stefan Monnier
i Ricard,

> It has a keyboard failure - the "h" key is intermittent and my primary
> account is "Richard" ;/

[ I presume you know tat tis kind of failure can often (sadly not
  always) be fixed by cleaning.  ]

> I have no problem logging in as root.
>
> Two primary questions:
> 1. is there someway that I can use a USB connected keyboard
>as workaround while root?

I can't tink of any reason wy tat wouldn't "just work".
ave you tried?

> 2. is there some way to switch from "root" to "Richard" without
>having to type to the pop-up that shows when using
>System->Logout... ?

Probably, and tat probably depends on wat you mean by "switc" and on te
kind of "display manager" you're using (many of tem give you a list of
users from wic you can select by clicking).
You can also (as root) cange your user's name to remove tat pesky
`` letter.


Stefan



Printer recommendations for Debian (was: Just a simple question)

2024-09-11 Thread Stefan Monnier
> I am great friend of "Brother" printers. They are cheap and reliable and they 
> are well supported  by linux. Brother is offering deb packages for installing 
> or a linu script, which is downloading and installing these packages 
> automatically.

Of course, that means you're at the mercy of Brother providing the
drivers which work for your printer&computer and those deb packages
typically aren't as nicely integrated into your Debian system as if
they'd been packaged by Debian.

E.g. do they provide armhf builds?  Are they for Ubuntu?  Debian?
Stable?  Testing?  Sid?  Oldstable?  Do they risk messing up other parts
of your config?  Can you determine that they can't send confidential
info back to Brother or act as puppets after they've been hacked
because of an undisclosed security hole somewhere?

If the drivers (print&scan) are not distributed in Debian's main
archive, I can't recommend it.

> Before you buy: Be sure, the manufacturer is sopporting linux.

Where "supporting" means that it provides code as Free Software, so it
can be adapted to any other OS and architecture you like.

Luckily, nowadays most printers support the standard APIs for
"driverless" printing and scanning, so the nasty proprietary code is
confined to the actual printer, but you might still prefer to put that
printer on a separate non-routed subnetwork so *you* control it rather
than the manufacturer.


Stefan



Re: hibernate area

2024-09-10 Thread Stefan Monnier
> I have an NVME drive as well as a spinning-rust drive.  I've got swap on the
> spinning drive, but I'd like to put the hibernate area on the NVME.  Is that
> possible, to have swap on one and hibernate on another?

Of course.  Just tell your hibernation about the partition you want to
use for it (it usually defaults to using the swap partition).
IIRC the relevant file is `/etc/suspend.conf`.

You may also need to rebuild your `/boot/initrd.img` file since it
usually contains a copy of that information.


Stefan



Re: Why are module parameters under /etc/modprobe.d not respected?

2024-09-09 Thread Stefan Monnier
>> > options snd_hda_intel id=[HDMI,PCH] index=1,0
>> Might be you need to write with dashes, as the module files is named
>> with dashes.
> Thank you for the reply. However, dashes and underscores can be
> interchanged in these files.

FWIW: That's been my experience for the `modprobe` command argument, but
*not* for the `modprobe.d` config files.


Stefan



Re: MAC filter

2024-09-02 Thread Stefan Monnier
> And if you're interested in only the interface name and MAC address, pipe
> that result to awk, so...
>
> ip -br l | awk '{print $1,$3}'

Note that the $3 won't always be a MAC address:

% ip --brief link
lo   UNKNOWN00:00:00:00:00:00  
[...]
tun0 UNKNOWN 
%


- Stefan



Re: Laptop screen dim on battery power

2024-09-01 Thread Stefan Monnier
> Lenovo R61 ThinkPad
[...]
> The screen automatically dims when AC removed.
> System->Hardware->Power Management->OnBatteryPower->Display
> "Reduce backlight brightness" & "Dim display when idle" unchecked
> Any where else to look?

I'd look at the BIOS settings.


Stefan



Re: DEBIAN documentation: which 64 bit processors run current release?

2024-08-27 Thread Stefan Monnier
> Will the OS linked to by https://www.debian.org/ run on all three?

Yes, on all three, both using the i386 (which is being phased out) or
the amd64 ports.


    Stefan



Re: Debian hardware: coping with Windows

2024-08-26 Thread Stefan Monnier
> a flash drive or CD-ROM are suddenly nontrivial: I need
> to get Debian's netinst using Windows, with whatever
> browser is there, then write it with Windows tools.  So:

In the past I've successfully used

https://www.goodbye-microsoft.com/

tho I'm not sure if it's still working (it doesn't look
well-maintained), or if there's a better replacement.


Stefan



Re: need help killing screen blanker

2024-08-26 Thread Stefan Monnier
> - most of the desktop environments incorporate some element of screen
>   blanking for security (or power saving).

There's also "burn in" for some monitor technologies.


Stefan



Re: need help killing screen blanker

2024-08-26 Thread Stefan Monnier
> S, what do I remove to absolutely, permanently disable the screen
> blanker?  And I mean no chance it can ever do that to me again.

IME, this is a bit of an uphill battle, sadly.
Basically, lots of tools can request/cause some kind of "screen
blanking" so you can never be sure you've disabled all of them.

Assuming you have a very vanilla installation, I'd look at
the XFCE power manager settings where you can turn off the "display
power management".

Another option might be to set the "presentation mode" when the lathe is
in use.  You can do that manually by right-clicking on the power icon in
the tray (assuming you have enabled "System tray icon" in the XFCE power
manager settings) but that can be done programatically as well (I hope
someone here can tell us how).


Stefan




Re: tbird hot keys.

2024-08-25 Thread Stefan Monnier
> Well, i'll be typing along, have most assuredly not done a ctl+a, but all
> the text will high light, and the next keystroke deletes it all. Sometimes

In Emacs we have the `view-lossage` command to see what keys have been
received recently so you can find out which funny key sequence you
accidentally typed.

I'd hope other environments provide something similar.


Stefan



Re: wait until swapoff is *actually* finished (it returns too early)?

2024-08-22 Thread Stefan Monnier
> Not the right condition though… it’s absent there but still in use.
> I am looking for the right thing to check…

How 'bout checking the success of `cryptdisks_stop`?


    Stefan



Re: What tool(s) reports OS buss width, which processor present?

2024-08-22 Thread Stefan Monnier
> cross-graded to amd64 only as far as running the amd64 kernel while
> leaving all of the user land and the primary dpkg architecture as
> i386.  This is a supported configuration.

It's not just "supported": it's basically the recommended setup for an
i386 install, since the support for the i386 kernels is being EOL'd.


Stefan



Re: edu-debian net-install autopartition /boot to 500MB

2024-08-21 Thread Stefan Monnier
Ruslanas Gžibovskis [2024-08-21 16:16:54] wrote:
> Just wondering if you have a problem when doing automated partitioning
> during the debian deployment using edu-net-install iso?
>
> the problem I face is too small partition size, which is 500 MB, when a
> simple kernel now has the size of 234 MB, each time it needs to regenerate

234MB?  On this here machine it's more like 8MB for the kernel and 12MB
for the initrd:

-rw-r--r-- 1 root root 11557440 Dec 10  2023 initrd.img-6.1.0-13-amd64
-rw-r--r-- 1 root root 11668751 Jul 17 01:04 initrd.img-6.1.0-23-amd64
[...]
-rw-r--r-- 1 root root  8135584 Sep 29  2023 vmlinuz-6.1.0-13-amd64
-rw-r--r-- 1 root root  8173504 Jul 15 03:42 vmlinuz-6.1.0-23-amd64

FWIW, I have

MODULES=dep
COMPRESS=lzma

in `/etc/initramfs-tools/initramfs.conf`, which helps keep the size of
the initrd in check.


Stefan



Re: wait until swapoff is *actually* finished (it returns too early)?

2024-08-21 Thread Stefan Monnier
> Just adding a “sleep” is no proper fix anyway, so the question
> is, how to wait in a shell script until the swap device is
> *really* swapoff’d when the syscall returns too early, and
> (someone from the Linux kernel maintainers reading this?) should
> I report the latter as a bug against the kernel?

I'd file a bug report against the `mount` package (the one that
provides `swapoff`).


Stefan



Re: Firefox doesn't want to see Pulseaudio

2024-08-16 Thread Stefan Monnier
>> I do have it installed.  I also tried to install `libavcodec-extra` at
>> some point (when I saw that `mp4a-latm` 🙂), but it made no difference
>> of course.
> You do not have AAC in the list of supported codecs and I am unsure if it is
> due to alsa backend or due to a missed package (libfdk-aac2,
> gstreamer1.0-fdkaac?).

I'm not too worried about that for now.  The lack of audio device was the
more pressing concern 🙂

>>> Firefox exposes some codec info in about:support#media
>> Thanks.  When I "disable sandboxing" (by setting the three vars
>> I mentioned in my answer to Tomas) it says:
> I would revert these settings to defaults unless you have confirmed that
> they are really necessary.

Of course.

>>  Audio Backend:  alsa
> I have pulse-rust here.

Same for me when things work 🙂

> If you still have motivation to debug i386 vs. amd64 issue, have you
> tried to start firefox with a clean profile (--profile /some/dir)?

Yup, no difference.

> I would check if there are earlier messages related to audio backend, maybe
> during firefox startup. Perhaps verbosity of some component should be
> increased
>
> https://firefox-source-docs.mozilla.org/xpcom/logging.html

Thanks for the pointer!


Stefan



Re: Cross-platform contacts program/app recommendations?

2024-08-16 Thread Stefan Monnier
> You can use davical[1]. While it focuses on caldav, it also supports carddav.

AFAIU there's also `radicale` (which, contrary to `davical` is also
supported by FreedomBox).


    Stefan



Re: Firefox doesn't want to see Pulseaudio

2024-08-15 Thread Stefan Monnier
I have not found the real source of the problem, but I have found out
why it worked on other machines and not on this one: some months
(years?) ago I made this i386 machine use `firefox-esr:amd64` because
Firefox tabs kept crashing (even for fairly simple pages).

[ I've been using the i386 version of `firefox-esr` without problem on
  other machines, so I don't know why it crashed on this one, but
  switching to the amd64 version did "solve" the problem back then.
  My crystal ball told me that it was probably due to the relatively
  large about of RAM (24G) available in this machine confusing Firefox
  into the illusion that it can allocate a lot more memory than the i386
  architecture really allows, and thus getting memory allocation
  failure.  ]

I had completely forgotten about this detail.

I have now switched back to `firefox-esr:i386` and the audio works again
(and it looks like the old problem I had with it has disappeared in the
mean time).  I guess it's time I switch this machine to an amd64-only install.

Thank you all for your help.


Stefan


Stefan Monnier [2024-08-14 15:32:31] wrote:

> I have a machine here running a freshly updated and rebooted Debian
> testing where I can't get Firefox (more specifically `firefox-esr`) to
> use audio.  E.g. I go to
>
> https://tekeye.uk/html/html5-video-test-page
>
> and none of the videos give me any audio output.
>
> I'm using pipewire and it generally works fine with other applications.
> E.g. `paplay` successfully plays my music files, and `chromium` on the
> same web page gives me audio output just fine.
>
> When I have `pavucontrol` open, I can "see" that Firefox does not appear
> in the "Playback" tab, contrary to `paplay` and `chromium`.
>
> When I try `firefox -P` and use a fresh new profile, the same
> problem occurs.  Also I can see errors in the output such as:
>
> [Child 13905, MediaDecoderStateMachine #1] WARNING: Decoder=7fe182f6a100 
> Decode error: NS_ERROR_DOM_MEDIA_FATAL_ERR (0x806e0005) - Error no decoder 
> found for audio/mp4a-latm: file 
> ./dom/media/MediaDecoderStateMachineBase.cpp:164
> [Child 13905, MediaDecoderStateMachine #1] WARNING: Decoder=7fe182875800 
> Decode error: NS_ERROR_DOM_MEDIA_FATAL_ERR (0x806e0005) - Error no decoder 
> found for audio/mp4a-latm: file 
> ./dom/media/MediaDecoderStateMachineBase.cpp:164
> [Child 13905, MediaDecoderStateMachine #1] WARNING: Decoder=7fe181797300 
> Decode error: NS_ERROR_DOM_MEDIA_FATAL_ERR (0x806e0005) - Error no decoder 
> found for audio/mp4a-latm: file 
> ./dom/media/MediaDecoderStateMachineBase.cpp:164
> [Child 13905, MediaDecoderStateMachine #1] WARNING: Decoder=7fe181797300 
> Decode error: NS_ERROR_DOM_MEDIA_FATAL_ERR (0x806e0005) - Error no decoder 
> found for video/avc: file ./dom/media/MediaDecoderStateMachineBase.cpp:164
> [Child 13905, MediaDecoderStateMachine #1] WARNING: Decoder=7fe181797c00 
> Decode error: NS_ERROR_DOM_MEDIA_FATAL_ERR (0x806e0005) - Error no decoder 
> found for audio/mp4a-latm: file 
> ./dom/media/MediaDecoderStateMachineBase.cpp:164
> [Child 13905, MediaDecoderStateMachine #1] WARNING: Decoder=7fe181796a00 
> Decode error: NS_ERROR_DOM_MEDIA_FATAL_ERR (0x806e0005) - Error no decoder 
> found for audio/mp4a-latm: file 
> ./dom/media/MediaDecoderStateMachineBase.cpp:164
> [Child 13905, MediaDecoderStateMachine #1] WARNING: Decoder=7fe181797c00 
> Decode error: NS_ERROR_DOM_MEDIA_FATAL_ERR (0x806e0005) - Error no decoder 
> found for video/avc: file ./dom/media/MediaDecoderStateMachineBase.cpp:164
> [Child 13905, MediaDecoderStateMachine #1] WARNING: Decoder=7fe181796a00 
> Decode error: NS_ERROR_DOM_MEDIA_FATAL_ERR (0x806e0005) - Error no decoder 
> found for video/avc: file ./dom/media/MediaDecoderStateMachineBase.cpp:164
> [Child 13905, MediaDecoderStateMachine #1] WARNING: Decoder=7fe181797f00 
> Decode error: NS_ERROR_DOM_MEDIA_FATAL_ERR (0x806e0005) - Error no decoder 
> found for audio/mp4a-latm: file 
> ./dom/media/MediaDecoderStateMachineBase.cpp:164
> [Child 13905, MediaDecoderStateMachine #1] WARNING: Decoder=7fe181797f00 
> Decode error: NS_ERROR_DOM_MEDIA_FATAL_ERR (0x806e0005) - Error no decoder 
> found for video/avc: file ./dom/media/MediaDecoderStateMachineBase.cpp:164
> [Child 13905, BackgroundThreadPool #1] WARNING: 7fe1838484c0 OpenCubeb() 
> failed to init cubeb: file ./dom/media/AudioStream.cpp:281
> [Child 13905, MediaDecoderStateMachine #1] WARNING: Decoder=7fe17c60cd00 
> [OnMediaSinkAudioError]: file ./dom/media/MediaDecoderStateMachine.cpp:4604
>
> The last two lines occur when I click on the "unmute" button in the
> video (on the above web page) which is muted by default.
>
> Any idea what might be going on and/or how to track it down further?
>
>
> Stefan



Re: Firefox doesn't want to see Pulseaudio

2024-08-15 Thread Stefan Monnier
> If you have libavcodec installed (from "Recommends") then it might be some
> testing issue.  There is no problem in bookworm.

I do have it installed.  I also tried to install `libavcodec-extra` at
some point (when I saw that `mp4a-latm` 🙂), but it made no difference
of course.

> Firefox exposes some codec info in about:support#media

Thanks.  When I "disable sandboxing" (by setting the three vars
I mentioned in my answer to Tomas) it says:

Audio Backend:  alsa
Max Channels:   0
Preferred Sample Rate:  44100
Roundtrip latency (standard deviation): ...
Codec Support Information:
VP8 SW
VP9 SW
AV1 SW
Theora SW
FLAC SW
MP3 SW
Opus SW
Vorbis SW
Wave SW

with no input nor output devices.

So it looks like the codecs are found in that case, but the audio
backend is wrong (it should be Pulse, AFAIK) and the max channels shows
that there's really no output.

If I leave the sandboxing options at their default setting, then I get
a similar result except that the list of codecs is empty.


Stefan



Re: Firefox doesn't want to see Pulseaudio

2024-08-15 Thread Stefan Monnier
>> I have no idea what sandbox settings you're referring to.
>> How/where can I find those to "tinker" with?
> [1a] also: about:config -> security.sandbox.*

Hmm... I set both `security.sandbox.socket.process.level` and
`security.sandbox.content.level` to 0 as well as `media.cubeb.sandbox`
to false (and restarted Firefox) but it didn't help.

My current test is to open

firefox file:///my/music/storage/

and click on an Ogg file.

[Child 17314, MediaDecoderStateMachine #1] WARNING: 7f92bdd47ee0 
OpenCubeb() failed to init cubeb: file ./dom/media/AudioStream.cpp:281
[Child 17314, MediaDecoderStateMachine #1] WARNING: Decoder=7f92beb9cf00 
[OnMediaSinkAudioError]: file ./dom/media/MediaDecoderStateMachine.cpp:4604
[Child 17314, MediaDecoderStateMachine #1] WARNING: Decoder=7f92beb9cf00 
Decode error: NS_ERROR_DOM_MEDIA_MEDIASINK_ERR (0x806e000b) - 
OnMediaSinkAudioError: file ./dom/media/MediaDecoderStateMachineBase.cpp:164


- Stefan



Re: Firefox doesn't want to see Pulseaudio

2024-08-15 Thread Stefan Monnier
>> Error no decoder found for audio/mp4a-latm
> It relies on non-free AAC codec that you likely do not have installed.

That's a side-issue: the web page I pointed to has various videos in
various formats and none of them work (hence the error messages
mentioning other "decoder not found" mime types).


Stefan



Re: Firefox doesn't want to see Pulseaudio

2024-08-15 Thread Stefan Monnier
> Aha -- so you are using pipewire's pulseaudio emulation?

Yes.

> Search engineering (hah) turns up some noises like this [1] which at
> least suggest to tinker with sandbox settings. They might have painted
> themselves again into a corner by not allowing some processes to see
> some paths in the file system. Granted, this is just a thin thing to
> go by, sorry.

I have no idea what sandbox settings you're referring to.
How/where can I find those to "tinker" with?


Stefan



Re: Firefox doesn't want to see Pulseaudio

2024-08-14 Thread Stefan Monnier
>> I have a machine here running a freshly updated and rebooted Debian
>> testing where I can't get Firefox (more specifically `firefox-esr`) to
>> use audio.
>
> Check if installing apulse helps. It's supposed to make obstinate apps like
> Firefox act as though pulseaudio is installed, dead technology, which is not
> needed when pipewire and wireplumber are working.

Hmm... let's see.
Hmm... no, didn't make a difference: after installing `apulse` the same
`firefox -P` still behaves identically (with the same error messages),
and so does `apulse firefox -P`.


Stefan



Firefox doesn't want to see Pulseaudio

2024-08-14 Thread Stefan Monnier
I have a machine here running a freshly updated and rebooted Debian
testing where I can't get Firefox (more specifically `firefox-esr`) to
use audio.  E.g. I go to

https://tekeye.uk/html/html5-video-test-page

and none of the videos give me any audio output.

I'm using pipewire and it generally works fine with other applications.
E.g. `paplay` successfully plays my music files, and `chromium` on the
same web page gives me audio output just fine.

When I have `pavucontrol` open, I can "see" that Firefox does not appear
in the "Playback" tab, contrary to `paplay` and `chromium`.

When I try `firefox -P` and use a fresh new profile, the same
problem occurs.  Also I can see errors in the output such as:

[Child 13905, MediaDecoderStateMachine #1] WARNING: Decoder=7fe182f6a100 
Decode error: NS_ERROR_DOM_MEDIA_FATAL_ERR (0x806e0005) - Error no decoder 
found for audio/mp4a-latm: file ./dom/media/MediaDecoderStateMachineBase.cpp:164
[Child 13905, MediaDecoderStateMachine #1] WARNING: Decoder=7fe182875800 
Decode error: NS_ERROR_DOM_MEDIA_FATAL_ERR (0x806e0005) - Error no decoder 
found for audio/mp4a-latm: file ./dom/media/MediaDecoderStateMachineBase.cpp:164
[Child 13905, MediaDecoderStateMachine #1] WARNING: Decoder=7fe181797300 
Decode error: NS_ERROR_DOM_MEDIA_FATAL_ERR (0x806e0005) - Error no decoder 
found for audio/mp4a-latm: file ./dom/media/MediaDecoderStateMachineBase.cpp:164
[Child 13905, MediaDecoderStateMachine #1] WARNING: Decoder=7fe181797300 
Decode error: NS_ERROR_DOM_MEDIA_FATAL_ERR (0x806e0005) - Error no decoder 
found for video/avc: file ./dom/media/MediaDecoderStateMachineBase.cpp:164
[Child 13905, MediaDecoderStateMachine #1] WARNING: Decoder=7fe181797c00 
Decode error: NS_ERROR_DOM_MEDIA_FATAL_ERR (0x806e0005) - Error no decoder 
found for audio/mp4a-latm: file ./dom/media/MediaDecoderStateMachineBase.cpp:164
[Child 13905, MediaDecoderStateMachine #1] WARNING: Decoder=7fe181796a00 
Decode error: NS_ERROR_DOM_MEDIA_FATAL_ERR (0x806e0005) - Error no decoder 
found for audio/mp4a-latm: file ./dom/media/MediaDecoderStateMachineBase.cpp:164
[Child 13905, MediaDecoderStateMachine #1] WARNING: Decoder=7fe181797c00 
Decode error: NS_ERROR_DOM_MEDIA_FATAL_ERR (0x806e0005) - Error no decoder 
found for video/avc: file ./dom/media/MediaDecoderStateMachineBase.cpp:164
[Child 13905, MediaDecoderStateMachine #1] WARNING: Decoder=7fe181796a00 
Decode error: NS_ERROR_DOM_MEDIA_FATAL_ERR (0x806e0005) - Error no decoder 
found for video/avc: file ./dom/media/MediaDecoderStateMachineBase.cpp:164
[Child 13905, MediaDecoderStateMachine #1] WARNING: Decoder=7fe181797f00 
Decode error: NS_ERROR_DOM_MEDIA_FATAL_ERR (0x806e0005) - Error no decoder 
found for audio/mp4a-latm: file ./dom/media/MediaDecoderStateMachineBase.cpp:164
[Child 13905, MediaDecoderStateMachine #1] WARNING: Decoder=7fe181797f00 
Decode error: NS_ERROR_DOM_MEDIA_FATAL_ERR (0x806e0005) - Error no decoder 
found for video/avc: file ./dom/media/MediaDecoderStateMachineBase.cpp:164
[Child 13905, BackgroundThreadPool #1] WARNING: 7fe1838484c0 OpenCubeb() 
failed to init cubeb: file ./dom/media/AudioStream.cpp:281
[Child 13905, MediaDecoderStateMachine #1] WARNING: Decoder=7fe17c60cd00 
[OnMediaSinkAudioError]: file ./dom/media/MediaDecoderStateMachine.cpp:4604

The last two lines occur when I click on the "unmute" button in the
video (on the above web page) which is muted by default.

Any idea what might be going on and/or how to track it down further?


Stefan



Re: stop using APT!

2024-08-14 Thread Stefan Monnier
> Stop using apt, apt support for mysql is so poor!

What does that mean?


    Stefan



Re: CrowdStrike and drivers (was Re: why reliable linux hasn't gained more market share?)

2024-07-21 Thread Stefan Monnier
>   - software updates that run as root (including Debian updates)
> can run anything else as root

So, maybe a more relevant discussion is: what will happen when a Debian
stable security update comes with a "big blunder" that crashes the most
machines in early boot?

Admittedly, the wider variety of Debian installs might make the "most"
above much less likely, but it's still something that can
definitely happen.

What does Debian do to try and avoid that, and what do *we* (Debian
users) do to try and mitigate that?


Stefan



Re: small font

2024-07-04 Thread Stefan Monnier
> Compression reduces the size but it's proportionnal so don't negate the
> extra html size. The global size will always be 4-10x.

No, the compression is not proportional.  HTML is naturally very
redundant, and machine-generated HTML like the one seen in Richard's
email tends to be excruciatingly redundant, so it compresses even much
better than plain text.  Plus the part of the plain/text that's in
common with the text/html (i.e. the actual useful part) would usually be
recognized as a redundancy, so all in all you'll typically get a much
smaller size difference after compression.

Of course, that's if compression takes place, which is not necessarily
the case.  In practice, for most emails like the ones exchanged on this
mailing-list, the precise size of the message is largely irrelevant:
even if multiplied by 10x, the cost of the actual content is lost in the
noise of the rest of the protocol.


Stefan



Re: Creating PDF/A from LaTeX source and from existing PDF

2024-07-03 Thread Stefan Monnier
Hi Richard,

I don't see any problem because I'm reading this mailing-list from a MUA
that's mostly text-only and doesn't try to use variable-size fonts, but
looking at the HTML you send I see:

>  style="font-family:arial,helvetica,sans-serif;font-size:small">

repeated several times.  I have no idea why your MUA puts it there, but
I suspect that's the reason some of the readers here find your email's
messages to be hard to read: your mail specifically asks for
`font-size:small`.

This might qualify as a bug in your MUA (it can make sense to require
a small font for some parts of the message, but it seems this style
applies to the whole message, which makes no sense), tho maybe it's due
to some particularity of your configuration, or of the way you use your
MUA's editor.


Stefan



Re: how2 format a flash drive

2024-07-01 Thread Stefan Monnier
> In the more general case, telemetry is not in itself
> considered 'evil'.

I consider it evil if it's opt-out rather than opt-in.


Stefan



Re: How to use Wine, How to get Gecko to install and work

2024-07-01 Thread Stefan Monnier
> As a general rule I am willing to accept RPMs, pacman ?? packages, and
> .debs, when they are from the Distribution's own package libraries, or
> hardware vendor supported, as otherwise I don't know the people providing
> the package. I have this strange belief that when a developer supplies
> a package to the Distribution owner for inclusion in their libraries, the
> Distribution owner does some level of verification/validation that the
> package plays nicely with the distribution and other applications. Maybe
> even some security checking?

I'm with you, here.  AFAIK Debian packaging does not in and of itself
come with any sort of "security checking", tho.  So, if there are
security benefits (personally, I do believe there are) they are mostly
indirect result of the packaging process, e.g. in the presence of extra
eyes, or in the need to investigate the details of the licensing, or the
need to follow the rules about where files are placed, or in the
avoidance of vendoring, or in the "slow" pace of stable releases, ...

For that same reason, I try to stay away from things like Snap/Flatpak
which seem to be a way to skip all that "process" and run effectively
black-boxes, thereby preventing you access to the usual transparency
benefits of Free Software.

It's been a long time since I last used Wine (FWIW, it was to run the
Windows version of Emacs, to try and reproduce a bug locally 🙂), but
IIUC the software you intend to run via Wine will probably be what I'd
usually describe as "proprietary crap" a.k.a black boxes, so it seems to
be one of the cases where the use of Snap/Flatpak should not make things
much worse.


Stefan



Re: balenaEtcher

2024-06-28 Thread Stefan Monnier
> I’ve been tryed to boot a flash usb of 4Gb with
> balenaEtcher-1.19.-21-x64.AppImage and Parrot-home-4.4_i386.iso and gives
> me the Error:(0, h.requestMetadata) is not a function

Who/what gives you this error?  When does it give you this error?

Have you tried to ask your favorite search engine about
"Error:(0, h.requestMetadata) is not a function"?


Stefan



Re: How to use /etc/adjtime

2024-06-28 Thread Stefan Monnier
>> Notice I wrote "sleep".  I'm concerned about the suspend+wakeup case,
>> not the case when you're booting up.
>> [ I thought I'd made it abundantly clear.  ]
> I'm not a laptop person.  I don't know how to fix laptop-specific issues.

FWIW, the offending machine is a desktop.
I `suspend` most of my machines, whether desktops or laptops.
Only servers never sleep.

>  1) You are using a laptop.

It's not the case, but it shouldn't make any difference anyway.
Feel free to assume it's the case.

>  2) Your laptop's hardware clock drifts quite notably.

Right.  Tho, AFAICT the same holds (to a lesser extent) of most machines.

>  3) At times, you perform a "sleep" or "suspend" or whatever it's called.
> This period of not-running-but-not-shut-down-either lasts for long
> enough that your clock drift becomes severe.

At least severe enough that I'd like to reduce it.

>  4) Apparently, the system clock does not advance while in this state.

While suspended, the machine's CPU is completely off.
Only the DRAM is still powered.
[ BTW, I suspect the same problem shows up for "suspend to disk" a.k.a
  hibernate where the machine might be 100% turned off while sleeping,
  but it might go through slightly different routes in the code.  ]

>  5) After going from the not-running state to the running state, your
> system clock is reinitialized from the hardware clock.  Which is
> not accurate enough for your purposes.

Apparently, yes.  I don't actually know how/who reads the RTC to set the
system clock upon wakeup.  Maybe `hwclock` is not involved at all, and
maybe part of this happens directly in the kernel.

>  6) After going from the not-running state to the running state, your
> NTP daemon does not perform a clock synchronization soon enough for
> your purposes.  User programs have already begun to run.  Or continue
> to run?  I have absolutely no idea what goes on here.

Yes they just continue running "as if" the machine had never been turned
off (to them, it's mostly as if the scheduler had given priority to
other tasks for a *long* time).

> Now, for some reason, you have become fixated on the /etc/adjtime file,

Not at all.  I only mention that file because that's the way this
problem used to be handled during shutdown+reboot back in the SysV-init
days using `/etc/init.d/hwclock.sh`.

> It sounds like whatever least-bad solution you end up using is going to
> depend on which NTP daemon you use, and will involve configuration
> thereof.

Actually, I think The Right Solution™ should be independent from any NTP
daemon, since in order to avoid time warps you'd like to drift-adjust
the RTC time before user-level processes (like the NTP daemon) are
woken up.

> It will not be something generic to adjtime_config(5) or
> hwclock(8) or util-linux.  It also won't be something generic to Debian
> systems as a whole, because neither servers nor traditional desktop
> computers have this issue.  It's a laptop issue.

Nowadays, there's not much difference between a desktop and a laptop
(they all use the same power-saving tricks, they all support suspending
the system, ...).

The problem does not affect servers, admittedly.

> David has said that chrony can do fancy things involving the hardware
> clock.  Maybe you should investigate that solution path.

I'm trying to find out how to fix it Right, rather than how to work
around the problem (I already know how to work around the problem).

Fixing it right requires changing the code that reads the RTC time
upon wakeup.  In any case, thank you all for your help.
Apparently none of you have the answer I'm looking for, but you did help
me narrow down the scope and make more precise what I'm after.

Indeed I see now that the time is read from RTC to set system time
directly by the kernel in `kernel/time/timekeeping.c` and
`drivers/rtc/class.c`.
So The Right Solution™ apparently involves changes to the kernel.


Stefan



Re: balenaEtcher

2024-06-28 Thread Stefan Monnier
> I’ve been tryed to boot a flash usb with Parrot and balenaEtcher but gives
> error is there another app for to boot a flash usb but not the rufus app?

Despite some rumors, people here aren't any more clairvoyant than elsewhere.

So you'll probably get better answers if you provide more details, such
as the actual errors you see, the specific way you "flashed" the USB
key, precisely what it is you flashed onto that key, what machine you're
trying to boot, and/or how exactly you tried to boot with that flashed
USB key.


Stefan



Re: How to use /etc/adjtime

2024-06-28 Thread Stefan Monnier
> Yeah, except... you're assuming a workflow that is not real or reliable.
[...]
>> It is if /etc/adjtime is set properly when you go to sleep.
> You cannot assume that adjtime was updated the last time your system
> stopped running, because your system might have stopped running due to
> a crash, instead of a controlled shutdown.

Notice I wrote "sleep".  I'm concerned about the suspend+wakeup case,
not the case when you're booting up.
[ I thought I'd made it abundantly clear.  ]


Stefan



Re: How to use /etc/adjtime

2024-06-28 Thread Stefan Monnier
John Hasler [2024-06-28 09:41:06] wrote:
> Stefan writes:
>> The question remains: how to make use of that info upon wakeup to
>> adjust the "initial" time before NTP takes over.
> hwclock -a can do this.

Indeed, and my question can be thought of as asking how to run
`hwclock -a` when we wake up (as well, as how to run `hwclock --systohc`
just before suspend).

But note that when we wake up ntpsec is already running, so I'm not sure
`hwclock -a` could prove problematic.

BTW, I noticed another instance of my original problem: in my original
problem, after sleeping for many days, the time is off by many seconds
and it stays that way for several minutes before ntpsec to decide to
"step" the clock.  But after sleeping a smaller amount of time, the time
can be off by a small enough offset that ntpsec doesn't step the clock
but slews it instead, so the clock stays off for an even longer period.

Ideally, we'd like to avoid stepping the system clock at all: when
waking up, the system clock should be (re)initialized right away to the
drift-adjusted RTC clock time, so the user processes only see "a long
sleep" rather than "a long sleep followed by a time warp".

While my machine's RTC drift is particularly bad, I since then noticed
that `journalctl| grep stepped` returns many entries on all my machines
(save those that never sleep), so it's a really widespread problem.


Stefan



Re: How to use /etc/adjtime

2024-06-28 Thread Stefan Monnier
> The hardware clock has a time, which is loaded into the system clock
> to initialize it.  That's it.  The only variable factor here is whether
> the hardware clock's time is in UTC or some local time zone.
>
> You can't do anything with drift at this point, because you don't actually
> know how long you were asleep.  All you know is the current HW clock time.

/etc/adjtime complements that info with the expected drift and the last
time the RTC was adjusted to the presumably correct time (which you'd
want to do every once in a while).
So by comparing the RTC time to the last-adjustment time you get to know
how much drift happened and you can correct this initial time estimate.

> It's not like you can say "Oh, I was asleep for 7.5234 hours, so I need
> to adjust the HW clock time forward by X seconds because I know it runs
> a bit slow."  That information is not available to you.

It is if /etc/adjtime is set properly when you go to sleep.
See `hwclock(8)` or `adjtime_config(5)`.


Stefan



Re: How to use /etc/adjtime

2024-06-28 Thread Stefan Monnier
> Do you really run ntp?  You might already be running ntpsec,
> its replacement.

I call it ntp but yes, it's ntpsec.

>> The /etc/adjtime is supposed to be there for such purposes but it seems
>> to be mostly unused: I assume its "UTC" setting is respected but the
>> first and second lines indicate it has not been updated since 2015
>> (i.e. when that Debian install was used in another machine).
> You might find your clock drift in /var/lib/ntpsec/ntp.drift
> or wherever /etc/ntpsec/ntp.conf specifies it.

Oh, indeed, thanks.  I had computed it manually from
`journalctl | grep stepped` and it gave close enough results.
The question remains: how to make use of that info upon wakeup to adjust
the "initial" time before NTP takes over.

> I don't know how to speed up correcting the clock as I use chrony,
> but ntpsec may have similar directives available.

Indeed, I could try and shorten the time before the NTP info takes
precedence over the RTC-derived initial approximation (I haven't found
any way to tell ntpsec to do that, short of limiting the maximum
interval between pollings or maybe killing&restarting the deamon, both
of which seem too crude for my sense of aesthetics), but I'm more
interested in improving the initial approximation.


Stefan



Re: How to use /etc/adjtime

2024-06-28 Thread Stefan Monnier
> I think hwclock(8) has the info you need. On my system (yes, one of
> those) there is an /etc/init.d/hwclock.sh which seems to take care
> of that. No idea how the young'uns do it, though :-)

AFAICT this `hwclock.sh` (which I do have) is not used (I'm using
systemd) and even less so upon suspend/wakeup: it seems targeted at
boot/shutdown.

The hwclock(8) tells me how to use the `hwclock` command but not how to
make other parts of the system run the `hwclock` command at the right
time (or how to get a similar result without running that command, of
course).


Stefan



How to use /etc/adjtime

2024-06-27 Thread Stefan Monnier
I have a machine whose RTC clock is drifting significantly and it is
often suspended for several days.  I run NTP so the drift I see when
I wake the machine up gets fixed by "stepping" the clock after a while,
but that can take a while and I'd like to improve this
intermediate situation.

The /etc/adjtime is supposed to be there for such purposes but it seems
to be mostly unused: I assume its "UTC" setting is respected but the
first and second lines indicate it has not been updated since 2015
(i.e. when that Debian install was used in another machine).

I have two questions:

- How can I get Debian to use this file when waking up the machine from
  suspend (which would presumably change the file by updating the first
  line's "last adjust time")?

- How can I get `ntpd` to adjust the first line's "drift factor" when it
  steps the clock?

The second question is less important (I can write the drift factor by
hand, e.g. in case `ntpd` is not being told when the clock is (re)set
based on the RTC, making it impossible for it to compute a drift factor).


Stefan



Re: mounting external hard drive from rescue mode shell?

2024-06-24 Thread Stefan Monnier
>> - Boot using the Grub on the X30's own HDD, and then ask Grub to boot
>>the kernel+initrd found on the USB key (this is my favorite solution).
> I think this is the path I should follow. It explicitly handles my immediate
> problem and most likely satisfactorily handles issue(s) on other machine(s).
> Where would I find relevant GRUB documentation?

IIRC the main question is whether your Grub comes with support for USB storage.
If it doesn't you're out of luck.
If it does, it should be a small matter of typing

set root=,
linux /
initrd /

where those things can be completed with the help of TAB completion.

But it may depend on what exactly you're booting from that disk, which
may require specific arguments to be passed to the kernel.

>> - Copy the USB key's kernel+initrd to the /boot partition on the X30's
>>HDD and boot from that.
> Can I copy the USB key's kernel+initrd to a currently empty partition and
> then treat it in manner similar to USB key above? [goal being not to mess
> with a currently functioning system ;]

Yes.


Stefan



[OFFTOPIC] Re: About dash as sh

2024-06-24 Thread Stefan Monnier
> Do shells suffer UB? I always thought that was a C thing.

UB is a standard concept when defining programming languages.
Most if not all programming languages have some form of UB or another in
some part of the spec.  C is special w.r.t to UB in two ways:

- UB is not relegated to corner cases that virtually never happen (like
  the UB recommended by Jeffrey for sh), as is usually the case.
  Instead almost all programs in actual use rely on UB during their
  normal execution and in many cases it's somewhere between hard and
  impossible to avoid.
- Modern C compilers like to optimize code based on the assumption that
  UB never happens.

The combination of the two makes it particularly entertaining.


    Stefan



Re: OT - list mail claimed to be "known" spam!

2024-06-23 Thread Stefan Monnier
[ Sent directly to debian-user@lists.  ]

> FWIW, this reply goes to list because I expect high probability Stefan would 
> not
> see it otherwise. Most mailing list posts flow through to me unimpeded. Not so
> with Stefan's. AFAICT, every one of his is captured by Earthlink.net's "known
> spam" folder. The only ways I can see them are via the web archive, and by 
> opening
> webmail, so that I can extract them from "known spam".

My crystal ball suggests it's because I [read and] send them via Gmane,
and of course Gmane can't DKIM-sign my messages (and neither can my NNTP
client).


Stefan



Re: mounting external hard drive from rescue mode shell?

2024-06-23 Thread Stefan Monnier
> Relevant laptop is so old I don't know if it can boot from a physical USB
> device. I was suspecting that simplest thing would be copying suitable image
> to hard drive and let GRUB earn its keep ;}

Indeed my trusty old Thinkpad X30 doesn't boot from USB keys (tho in
theory it can boot from a USB floppy reader), so I use one of two
alternative options:

- Boot using the Grub on the X30's own HDD, and then ask Grub to boot
  the kernel+initrd found on the USB key (this is my favorite solution).

- Copy the USB key's kernel+initrd to the /boot partition on the X30's
  HDD and boot from that.

- Take the HDD out of the X30 and connect it to my desktop via some
  HDD<->USB adapter.  Then do what I need to do to it from the comfort
  of my desktop computer, typically using `chroot` along the way (this
  is the second best).


Stefan



Re: mounting external hard drive from rescue mode shell?

2024-06-22 Thread Stefan Monnier
> Rather than creating a customized Debian Live image, I install Debian onto
> a USB flash drive or onto a 2.5" SATA SSD connected via a USB-SATA adapter
> cable:

+1

It's pretty easy to make a simple Debian install on some old USB key you
have lying around and it comes really handy.


Stefan



Re: System time/timezone, was Re: Maximum size .bash_aliases file

2024-06-22 Thread Stefan Monnier
> Yes, I realise that. The times are being displayed by the gettys,
> controlled by the /etc/issue format string.  Jobs are being run
> by cron, logs written by rsyslogd, and so on. And the term is … ?

Maybe there simply isn't such a term.  The subject is sufficiently
complex/delicate that there can't be a term for every single situation.


Stefan



Re: About dash as sh

2024-06-21 Thread Stefan Monnier
>   When the shell is using standard input and it invokes a command that
>   also uses standard input, the shell shall ensure that the standard
>   input file pointer points directly after the command it has read when
>   the command begins execution.
>
> But I consider this clause is misguided, it should apply only when the
> input is a tty.

And if it's not a tty, you get some kind of Undefined Behavior?
I don't think I'd like that because I don't think the benefit would be worth
the UB troubles.

> Relying on it is a terrible idea.

I'd tend to agree.


Stefan



Re: RTC, was Re: System time/timezone

2024-06-19 Thread Stefan Monnier
> If your system only boots one operating system, and never changes its
> default time zone, then it makes no difference whether the RTC is set
> to UTC or local time.  The OS will use the same assumptions when reading
> and writing to the RTC, so everything will remain correct.

Of course, the famous exception is if your machine is OFF during the
switch to/from DST.  IIUC there are hacks in Windows to try and handle
it "correctly", but I believe they can also misfire in some cases.
Don't know if GNU/Linux bothers with it: it's just a lot simpler and
more sane to use UTC so you never need to worry about it.
And of course, NTP is your friend: several of my machines don't even
have an RTC and I haven't really felt like they are missing something.


Stefan



Re: System time/timezone, was Re: Maximum size .bash_aliases file

2024-06-19 Thread Stefan Monnier
>> It's *theoretically* possible for some daemons to be configured to use
>> a different time zone, or to be hard-coded to use UTC.  I've never seen
>> this, but it could be done.
> In view of that, I think it's reasonable to drop the "default",
> and go with "system time zone", ie the time zone that the system
> clock it set to.

Funny, because I think on the contrary that the word "default" is key:
it conveys the information that this is just the time zone used by
default when converting a time to a human readable form.

You can drop "system" on the other hand, AFAIC.  🙂


Stefan



Re: CD/DVD is obsolete or deprecate at 2025?

2024-06-18 Thread Stefan Monnier
> And some of the BIOSes of old PCs are not able to boot from USB...

Indeed, tho I suspect those machines are 20 years old or more (at least,
all my machines that are <20 years old support booting from a USB key
drive, while of the two older machines I have (both 21 years old), one
of them doesn't support booting from a USB key (tho it supposedly can
boot from USB floppy)).


    Stefan



Re: CD/DVD is obsolete or deprecate at 2025?

2024-06-18 Thread Stefan Monnier
>>> Is there a chance to change in next versions i.e. Debain 13 or other
>>> versions an assembly specifically for a USB flash drive as primary
>>> download?  Do you think the time has come? When do you think this moment
>>> will happen?
>> AFAIK, all the so-called CD/DVD images work just fine when "burned" on
>> a USB flash drive.  So I think the question is whether it's time to
>> change the doc to stop suggesting that those images should be burned
>> onto optical media.
> Just a question : why should we ditch the cd or dvd just because some guys
> said that's it was obsolete or inferior to the usb keys et al ?

AFAICT nobody in this thread suggested to ditch CD or DVD.
Can we stick to the actual discussion, please?


Stefan



Re: CD/DVD is obsolete or deprecate at 2025?

2024-06-17 Thread Stefan Monnier
> No! Some of us want to keep using DVD and not be pushed away

In which sense would it push you away.

I'm not suggesting any change to the ISO files themselves.
Only changes to the doc to clarify that these are images that are
expected to be used on USB flash dirves (and they also work on CD/DVD,
including virtual ones for VMs).

The intention is to avoid confusing those users who intuitively skip the
parts talking about CD/DVD images because they don't have a CD/DVD
reader/writer (or don't want to use it).


Stefan



Re: CD/DVD is obsolete or deprecate at 2025?

2024-06-17 Thread Stefan Monnier
> Is there a chance to change in next versions i.e. Debain 13 or other
> versions an assembly specifically for a USB flash drive as primary
> download?  Do you think the time has come? When do you think this moment
> will happen?

AFAIK, all the so-called CD/DVD images work just fine when "burned" on
a USB flash drive.  So I think the question is whether it's time to
change the doc to stop suggesting that those images should be burned
onto optical media.


Stefan



Re: can't connect to eduroam due to SSL3 unsupported protocol

2024-06-17 Thread Stefan Monnier
> Under Debian/unstable, I can't connect to eduroam due to the following
> reason:

AFAIK, while "the eduroam" looks like one thing it's just a bunch of
local wifi networks, each one administered&managed mostly independently
and with different configurations.  By and large, if you can connect to
eduroam at one place it's likely it'll also work elsewhere but it's not
always the case.


Stefan



Re: NVidia 340 video driver in Bookworm?

2024-06-10 Thread Stefan Monnier
> In real life no one wants to care of it! Nvidia not, because this
> costs money  and the developers not, because this is Nvidia and
> proprietrary (what is not  quite correct, because the kernel-module,
> which is the part, that can not be  build, is open-source).

Since you say it's "open source", then "anyone" should be allowed to
update the code to adapt to the new kernel code.  IOW *you* can fix it,
or if you don't have the time/energy you may be able to find someone
else to fix it (potentially paying them for it).


Stefan



Re: Thinkpad T14 Gen 5, touchpad not detected

2024-06-09 Thread Stefan Monnier
> I just installed Debian Testing on my new Thinkpad T14 Gen 5 and I found out
> that the touchpad is not actually detected by the system.

Maybe it's the same issue as the one posted very recently under the
subject:

Touchpad not detected by kernel on ThinkPad X13 Gen5


- Stefan



Re: What DE to replace GNOME with?

2024-05-31 Thread Stefan Monnier
> while being on old-old-stable still (buster) and preparing for an
> upgrade to bookworm, i noticed, that GNOME once again lost compatibility
> to my preferred extensions, giving me a hard choice to either go on with
> my outdated system as long as possible, or find a replacement and change
> my ways of working.

Not really an answer, just a side note: AFAIK, the concept of "DE"
doesn't exist at a technical level.  You *can* mix and match things from
various "DE"s.  There are occasional dependencies between components of
"DE"s, but each one of them is a PITA which I think should be treated as
a bug.


Stefan



Re: "Repeaters", etc.

2024-05-27 Thread Stefan Monnier
> I'd like to shop for such a device, but I don't know what it's called.

I think it's called a "wireless bridge".

Any device with a wifi card and (at least) an ethernet port can do that.
So "any" wifi router will do the trick, as long as you can get it to run
a firmware that's not hopelessly restricted.

I'd recommend you look at the routers supported by OpenWRT.

Of course, if you can do it with cables (ethernet/powerline/younameit)
it's probably going to work better, but I guess you know that already.


Stefan



Re: Solution for KVM via a cat 5 connection

2024-05-27 Thread Stefan Monnier
> Has anyone had experience using a KVM setup (at least one HDMI and two USB
> ports) and using cat 5/6/7 between user and the computer?  I don’t need to
> handle multiple computers or high-def video movies, just programming and
> office work. I need a bit more distance from my computer which must stay in
> a closet, and conventional KVM equipment won’t work.

You can do it without KVM, but using another computer connected to your
screen/keyboard/etc...

E.g. use some cheap/small/silent local machine (e.g. Banana Pi) which
you connect to your local devices (screen etc...), connect that machine
to your "real" machine in the closet via ethernet, and then use either
a remote X session or some other such "remote desktop" protocol to
connect to the real machine in the closet.

This setup can be described as a [thin
client](https://en.wikipedia.org/wiki/Thin_client)

The advantage is that it's all standard components, can work over any
network config, ...


Stefan



Re: moving some packages back to bookworm stable

2024-05-27 Thread Stefan Monnier
>> > # apt install -t=bookworm db-util db5.3-util libc-bin libc-dev-bin
>> 
>> I can never remember exactly what `-t` really does, but I suspect you'll
>> need things like
>> 
>> apt install libc-bin/bookworm
>
> To install a single backported (or other release) package, 
> apt-get install packagename/releasename
>
> and to install a backported package plus dependencies which
> are also from that specific release, use 
> apt-get -t releasename packagename

But that's not the whole story of what `-t` does since the above does
not explain why his attempt to use `-t` to downgrade some packages
resulted in `apt` saying " is already the newest version".


Stefan



Re: moving some packages back to bookworm stable

2024-05-27 Thread Stefan Monnier
> I needed to install a version of sendmail from testing a while back to
> test it.

Downgrading Debian packages is not well supported, by and large.
So installing `testing` packages into a `stable` install is manageable
(tho it itself can bring trouble) but going back to `stable` afterwards
tends to be a lot more complicated.

Transitions like the t64 transition going on right now in `testing` make
it yet more troublesome.

I recommend the use of snapshots when you want to try such a thing with
the intention of "going back" later.

> # apt install -t=bookworm db-util db5.3-util libc-bin libc-dev-bin

I can never remember exactly what `-t` really does, but I suspect you'll
need things like

apt install libc-bin/bookworm

to state more explicitly what you want.
Maybe you can do something like

apt install $(apt-show-versions | sed -n 's|/testing.*|/stable|p')


- Stefan



Re: Continuous integration with Debian virtual machines

2024-05-26 Thread Stefan Monnier
> Anyone know a hosting service, like GitHub or GitLab, offering recent Debian
> virtual machines to run tests ?

I'd expect most of them do, but at least SourceHut does according to
https://man.sr.ht/builds.sr.ht/compatibility.md#debian


    Stefan



Re: Debian bookwork / grub2 / LVM / RAID / dm-integrity fails to boot

2024-05-22 Thread Stefan Monnier
> I found this [1], quoting: "I'd also like to share an issue I've
> discovered: if /boot's partition is a LV, then there must not be a
> raidintegrity LV anywhere before that LV inside the same VG. Otherwise,
> update-grub will show an error (disk `lvmid/.../...' not found) and GRUB
> cannot boot. So it's best if you put /boot into its own VG. (PS: Errors
> like unknown node '..._rimage_0 can be ignored.)"

Hmm... I've been using a "plain old partition" for /boot (with
everything else in LVM) for "ever", originally because the boot loader
was not able to read LVM, and later out of habit.  I was thinking of
finally moving /boot into an LV to make things simpler, but I see that
it'd still be playing with fire (AFAICT booting off of LVM was still not
supported by U-Boot either last time I checked).  🙁


Stefan



Re: Dovecot correct ownership for logs

2024-05-19 Thread Stefan Monnier
> If you have read permission on a directory but *not* execute permissions,
> then the only thing you can do is read the contents of that directory --
> the filenames and their inode numbers.  You cannot stat() the files,
> so you can't see who owns them or even what kind of files they are.
> Just their names.

Never found a situation where this as useful.

> If you have execute permission but *not* read permission on a directory,
> then you can access the files within the directory, but only if you
> already know their names.  You can't read the directory to get their
> names.

This OTOH is very handy, making the filename into a kind of "passwd" to
access the file's content.


Stefan



Re: Markup in mail messages

2024-05-17 Thread Stefan Monnier
>> Actually I've been tempted to teach my mail reader to transform HTML
>> into some lightweight markup (yeah, you need a bit of heuristics for
>> that ;-) -- say Org, but why not its poor sister Markdown.
> Please don't settle for markdown. I would love a org filter!
> org-mode just handles tabular data admirably :)

Just beware that Org's code is generally written under the implicit
assumption that the Org document is trusted, so if you try to reuse
parts of Org's code to do the rendering be extra mindful of the
potential for security holes.
[ This applies to many other ELisp packages, of course; it's not
  exclusive to Org.  ]


Stefan



Re: Markup in mail messages

2024-05-16 Thread Stefan Monnier
> When this sort of subject comes up (as it does, every so often), I wonder
> why `text/markdown` isn't offered as a mime type for sending emails.

FWIW, last time I tried to send `text/(x-)markdown` messages,
I discovered that many "popular" MUAs do not display those at all (they
treat them as attachments, for example), contrary to what the RFCs say
they SHOULD do.  🙁

So, yes, I encourage you to send more of those, and if your recipients
don't like the result, try and get them to complain to their
MUA's authors (most of those MUAs are of course proprietary and are not
very ... responsive, but that's all we can do).

The stupidest case I bumped into is Github where replying by `plain/text`
email lets you add comments to an issue, but `text/markdown` replies are
simply sent to `/dev/null` even though Markdown is the standard format
they use in the web interface.


Stefan



Re: sudo echo 1 > /proc/sys/net/ipv4/ip_forward [was: How to run automatically a script as soon root login]

2024-05-13 Thread Stefan Monnier
> $ su -
> Password:
> # echo 1 > /proc/sys/net/ipv4/ip_forward
> # ^D
> logout
> $
>
> I don't need no stinkin' sudo :-)

And if you only have `sudo`, but not the root password, of course:

% sudo zsh -l
# echo 1 > /proc/sys/net/ipv4/ip_forward
# ^D
logout
%

🙂


Stefan



Re: How to run automatically a script as soon root login

2024-05-13 Thread Stefan Monnier
> You don't need to, but I definitely think he does. 🙂
^^

[ Oh, bias, when will you leave me alone?  ]


    Stefan



Re: How to run automatically a script as soon root login

2024-05-13 Thread Stefan Monnier
>> > echo 1 > /proc/sys/net/ipv4/ip_forward
>> This doesn't sound right.  Maybe you should investigate why you're
> No need to “investigate”, the answer is obvious: in

You don't need to, but I definitely think he does. 🙂


Stefan



Re: How to run automatically a script as soon root login

2024-05-13 Thread Stefan Monnier
> echo 1 > /proc/sys/net/ipv4/ip_forward
>
> work only if I'm root. It does not work using sudo.

This doesn't sound right.  Maybe you should investigate why you're
seeing this behavior, rather than work around the problem.

`sudo` *is* root.


Stefan



Re: Lightweight Emacs for container?

2024-05-06 Thread Stefan Monnier
> Is there some package, or a simple workaround, that will allow me to use
> a basic Emacs without all the cruft?

I think the usual answers look like:

- Use Zile (or some other small Emacs-inspired editor).
- Use Tramp (i.e. run Emacs outside the container and access the
  container's files as a kind of remote host).


    Stefan



Re: Zoom in the official repo is outdated

2024-04-24 Thread Stefan Monnier
Jeffrey Walton [2024-04-24 20:13:57] wrote:

> On Wed, Apr 24, 2024 at 7:13 PM Van Snyder  wrote:
>
>> On Wed, 2024-04-24 at 16:42 -0300, Luiz Romário Santana Rios wrote:
>>
>> Hello,
>>
>>
>> (Please cc me when replying as I'm not subscribed to the list)
>>
>>
>> Earlier this month, I noticed I was no longer able to login to Zoom
>>
>> meetings using the client installed from the Debian repos. In order to
>>
>> join meetings, I had to uninstall it then install the flatpack Zoom package.
>>
>>
>> I think it should either be updated or outright removed in favor of the
>>
>> flatpack version. What do you think? Should I report a bug?
>>
>>
>> I was expected to use zoom for a meeting. The zoom app didn't work at all
>> in Debian 10, completely refusing even to open a window. I at first started
>> with the zoom support in Firefox, but it didn't have a button to select
>> high resolution for the camera, so the meeting host asked me to run in the
>> app.
>>
>> I re-opened the session on a different computer that is running Debian 12.
>> The app worked OK on that computer.
>>
>
> Related, if you control the venue, then you might consider using Jitsi.
> Jitsi is open source, and it does not have the obscene terms of service
> that companies like Google, Microsoft and Zoom push onto people using their
> service. With Jitsi, your meeting data is yours. It is not used internally
> for other products, and it is not shared with partners like the Big Tech
> companies do.

There's also BigBlueButton (more featureful than Jitsi, but apparently
harder to install/setup/maintain) and I also heard good things about
Galène https://galene.org/ (which is apparently the simplest to
install/setup/maintain and the least demanding on the server).


Stefan



Re: [OFFTOPIC] youtube-dl blocked?

2024-04-23 Thread Stefan Monnier
> The site https://ytdl-org.github.io/youtube-dl/download.html
> is blocked?

Now that you got answers, a question: what made you post this here?
AFAICT this has nothing to do with Debian (if you use Debian, you'd
more naturally install that tool from `apt` which won't fetch it from
Github).


Stefan



  1   2   3   4   5   6   7   8   9   10   >