• Re: Is my locate broken?

    From tomas@tuxteam.de@21:1/5 to Haines Brown on Sun Apr 27 20:00:01 2025
    On Sun, Apr 27, 2025 at 01:32:45PM -0400, Haines Brown wrote:
    I did a new installation of Debian and installed the locate pachage. But when I use it,
    nothing is retured:

    $ which tlmgr
    /usr/bin/tlmgr

    $ locate tlmgr
    [nothing returnsd]

    $ locate bin
    [isued to get a lot, nothing on this machine

    I know locate can be slow, but I waited a sufficient time. I suspect locate has to build
    a database, but my system has been running a week.

    sudo updatedb

    (If that helps, next step would be to find out why it isn't being run automatically; if it doesn't... different next step ;-)

    Cheers
    --
    t

    -----BEGIN PGP SIGNATURE-----

    iF0EABECAB0WIQRp53liolZD6iXhAoIFyCz1etHaRgUCaA5vfQAKCRAFyCz1etHa RlEDAJ92Ueb9coi6mZ2uMwW/uMExq1DIWQCfQepWJNA4FwSrnjuBo9LMcvIEyq8=
    =+X7P
    -----END PGP SIGNATURE-----

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Haines Brown@21:1/5 to All on Sun Apr 27 19:40:01 2025
    I did a new installation of Debian and installed the locate pachage. But when I use it,
    nothing is retured:

    $ which tlmgr
    /usr/bin/tlmgr

    $ locate tlmgr
    [nothing returnsd]

    $ locate bin
    [isued to get a lot, nothing on this machine

    I know locate can be slow, but I waited a sufficient time. I suspect locate has to build
    a database, but my system has been running a week.

    --
    Haines Brown

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Charles Curley@21:1/5 to Haines Brown on Sun Apr 27 20:10:01 2025
    On Sun, 27 Apr 2025 13:32:45 -0400
    Haines Brown <haines@histomat.net> wrote:

    I did a new installation of Debian and installed the locate pachage.
    But when I use it, nothing is retured:

    Did you install locate, or plocate? The latter is much faster, so
    preferable.

    --
    Does anybody read signatures any more?

    https://charlescurley.com
    https://charlescurley.com/blog/

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Charles Curley@21:1/5 to Haines Brown on Sun Apr 27 20:20:01 2025
    On Sun, 27 Apr 2025 13:32:45 -0400
    Haines Brown <haines@histomat.net> wrote:

    I know locate can be slow, but I waited a sufficient time. I suspect
    locate has to build a database, but my system has been running a week.

    If things are working correctly, and you installed plocate rather than
    locate, you should see something like:

    root@testing:/media/installer# journalctl -b | grep -i updatedb
    Apr 24 23:44:17 testing systemd[1]: Started plocate-updatedb.timer - Update the plocate database daily.
    Apr 25 03:35:39 testing systemd[1]: Starting plocate-updatedb.service - Update the plocate database...
    Apr 25 03:35:40 testing systemd[1]: plocate-updatedb.service: Deactivated successfully.
    Apr 25 03:35:40 testing systemd[1]: Finished plocate-updatedb.service - Update the plocate database.
    Apr 25 03:35:40 testing systemd[1]: plocate-updatedb.service: Consumed 526ms CPU time, 168.7M memory peak.
    Apr 26 03:48:39 testing systemd[1]: Starting plocate-updatedb.service - Update the plocate database...
    Apr 26 03:48:39 testing systemd[1]: plocate-updatedb.service: Deactivated successfully.
    Apr 26 03:48:39 testing systemd[1]: Finished plocate-updatedb.service - Update the plocate database.
    Apr 26 03:48:39 testing systemd[1]: plocate-updatedb.service: Consumed 361ms CPU time, 153.1M memory peak.
    Apr 27 03:23:39 testing systemd[1]: Starting plocate-updatedb.service - Update the plocate database...
    Apr 27 03:23:39 testing systemd[1]: plocate-updatedb.service: Deactivated successfully.
    Apr 27 03:23:39 testing systemd[1]: Finished plocate-updatedb.service - Update the plocate database.
    Apr 27 03:23:39 testing systemd[1]: plocate-updatedb.service: Consumed 434ms CPU time, 153.2M memory peak.
    root@testing:/media/installer#


    --
    Does anybody read signatures any more?

    https://charlescurley.com
    https://charlescurley.com/blog/

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Haines Brown@21:1/5 to All on Sun Apr 27 21:30:01 2025
    The second tine I ran $ updatedb perfored as it should now
    it serves to locate a file.

    Thankd for the help


    --
    Haines Brown

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Teemu Likonen@21:1/5 to Haines Brown on Mon Apr 28 15:40:01 2025
    * 2025-04-27 13:32:45-0400, Haines Brown wrote:

    I did a new installation of Debian and installed the locate pachage.
    But when I use it, nothing is retured:

    I know locate can be slow, but I waited a sufficient time. I suspect
    locate has to build a database, but my system has been running a week.

    Some automatic services don't run when the computer is on laptop's
    battery, instead of AC power. For example:

    # /lib/systemd/system/plocate-updatedb.service
    [Unit]
    Description=Update the plocate database
    ConditionACPower=true

    That ConditionACPower=true line is on many service units. The associated
    timer event triggers normally the service unit does nothing on laptop's
    battery power.

    I usually override those ConditionACPower=true conditions with an
    override file like this:

    # /etc/systemd/system/plocate-updatedb.service.d/override.conf
    [Unit]
    ConditionACPower=

    --
    /// Teemu Likonen - .-.. https://www.iki.fi/tlikonen/
    // OpenPGP: 6965F03973F0D4CA22B9410F0F2CAE0E07608462

    --=-=-Content-Type: application/pgp-signature; name="signature.asc"

    -----BEGIN PGP SIGNATURE-----

    iIYEARYIAC4WIQQL23klfGMkeOvdGCt57xklfWtWWwUCaA+EbRAcdGxpa29uZW5A aWtpLmZpAAoJEHnvGSV9a1ZbruUBAL+W+gEkBU/xxzCELuNgJIZfjAHDaekJqxuL PgCTlCGUAP43wrLeLH1Ie4TaRfQVpkkl4MUhl4/vsel1ahY8Ao1iDg=í28
    -----END PGP SIGNATURE-----

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