• Bug#628815: coreutils: pinky makes crazy DNS queries

    From debbug@perkelt.hu@21:1/5 to All on Tue Mar 19 12:30:01 2024
    I looked into this and found that
    pinky tries to canonicalize the information in the "Where" column
    automaticaly, and it has no option to disable this behaviour.
    see line 285 pinky.c:
    if (*ut_host)
    /* See if we can canonicalize it. */
    host = canon_host (ut_host);
    this results in many unnecessary dns queries.
    For example on a debian system with acpi-support, /etc/acpi/lid.sh will
    make many requests to find the host $WAYLAND_DISPLAY every time the lid
    is opened.

    "who" has the --lookup (attempt to canonicalize hostnames via DNS)
    option, and doesn't do it by default.
    Maybe it would be more lightweight to forget about canonicalization
    altogether.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Michael Stone@21:1/5 to you on Tue Mar 19 14:00:02 2024
    On Tue, Mar 19, 2024 at 11:54:30AM +0100, you wrote:
    For example on a debian system with acpi-support, /etc/acpi/lid.sh will
    make many requests to find the host $WAYLAND_DISPLAY every time the lid
    is opened.

    I don't see anything in lid.sh that calls pinky.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From debbug@perkelt.hu@21:1/5 to Michael Stone on Tue Mar 19 15:40:01 2024
    /etc/acpi/lid.sh calls getXuser, that's defined in /usr/share/acpi-support/power-funcs
    which has on line 36
    plist=$(pinky -fw) || pwf_error "pinky lost"


    On Tue, Mar 19, 2024 at 08:50:59AM -0400, Michael Stone wrote:
    On Tue, Mar 19, 2024 at 11:54:30AM +0100, you wrote:
    For example on a debian system with acpi-support, /etc/acpi/lid.sh will make many requests to find the host $WAYLAND_DISPLAY every time the lid
    is opened.

    I don't see anything in lid.sh that calls pinky.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Michael Stone@21:1/5 to you on Tue Mar 19 16:10:01 2024
    On Tue, Mar 19, 2024 at 03:27:52PM +0100, you wrote:
    /etc/acpi/lid.sh calls getXuser, that's defined in >/usr/share/acpi-support/power-funcs
    which has on line 36
    plist=$(pinky -fw) || pwf_error "pinky lost"

    I'd suggest a wishlist bug on acpi-support-base to use "who -us" in
    place of "pinky -fw". who is a posix standard command, pinky is an
    oddball that was hacked up from who years ago because someone liked the
    finger command output and wanted something that would add the full name,
    .plan, .project, etc., to the regular who output (none of which is used
    by acpi). Basically, pinky is simply not the right tool for the task at
    hand and it makes more sense IMO to use the right tool than to try to
    add functionality to a 30 year old special-purpose tool intended to
    replicate the functionality of an information program from another era.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)