Linux ln cannot be used after creating a soft connection and cannot whereis

Linux creates an indexer that can be called directly, but cannot be called after creation, indicating that it does not exist.

File location ~ / sphinx-3.0.3/bin/indexer
Target Link / usr/local/bin/indexer
execute Code:

www:~ nginx$ ln -s sphinx-3.0.3/bin/indexer /usr/local/bin/indexer
www:~ nginx$ whereis indexer
www:~ nginx$ which indexer
www:~ nginx$ indexer
-bash: /usr/local/bin/indexer: No such file or directory
www:~ nginx$ ls -la /usr/local/bin/indexer
lrwxr-xr-x  1 nginx  admin  24  7 21 10:11 /usr/local/bin/indexer -> sphinx-3.0.3/bin/indexer

question:

  • this script does exist, but cannot be executed
  • there are files in the / usr/local/bin directory, but whereis has no results
www:~ nginx$ sphinx-3.0.3/bin/indexer
Sphinx 3.0.3 (commit facc3fb)
Copyright (c) 2001-2018, Andrew Aksyonoff
Copyright (c) 2008-2016, Sphinx Technologies Inc (http://sphinxsearch.com)

Usage: indexer [OPTIONS] [indexname1 [indexname2 [...]]]

Options are:
-v, --version        show version and build options
--config <file>        read configuration from specified file
            (default is sphinx.conf)
--all            reindex all configured indexes
--quiet            be quiet, only print errors
--verbose        verbose indexing issues report
--noprogress        do not display progress
            (automatically on if output is not to a tty)
--rotate        send SIGHUP to searchd when indexing is over
            to rotate updated indexes automatically
--sighup-each        send SIGHUP to searchd after each index
            (used with --rotate only)
--buildstops <output.txt> <N>
            build top N stopwords and write them to given file
--buildfreqs        store words frequencies to output.txt
            (used with --buildstops only)
--merge <dst-index> <src-index>
            merge "src-index" into "dst-index"
            "dst-index" will receive merge result
            "src-index" will not be modified
--merge-dst-range <attr> <min> <max>
            filter "dst-index" on merge, keep only those documents
            where "attr" is between "min" and "max" (inclusive)
--dump-rows <FILE>    dump indexed rows into FILE
--print-queries        print SQL queries (for debugging)
--keep-attrs        retain attributes from the old index
Examples:
indexer --quiet myidx1    reindex "myidx1" defined in "sphinx.conf"
indexer --all        reindex all indexes defined in "sphinx.conf"
www:~ nginx$ 
Mar.28,2021

in this case, you should use the absolute path

ln -s $(pwd)/sphinx-3.0.3/bin/indexer /usr/local/bin/indexer
MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1e4631b-44320.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1e4631b-44320.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?