Telnet installed but does not run

I’ve got a puzzle related to using telnet with Alma 9. Initially it was not installed so I did a dnf install of it. However even though dnf sees it it is not found at the CL. Any clues as to what is happening?

 dnf install telnet
Last metadata expiration check: 0:53:06 ago on Fri 30 Aug 2024 10:15:27 AM MDT.
Dependencies resolved.
======================================================================================================================================================
 Package                          Architecture                     Version                                  Repository                           Size
======================================================================================================================================================
Installing:
 telnet                           x86_64                           1:0.17-85.el9                            appstream                            63 k

Transaction Summary
======================================================================================================================================================
Install  1 Package

Total download size: 63 k
Installed size: 121 k
Is this ok [y/N]: y
Downloading Packages:
telnet-0.17-85.el9.x86_64.rpm                                                                                          12 kB/s |  63 kB     00:05    
------------------------------------------------------------------------------------------------------------------------------------------------------
Total                                                                                                                 6.1 kB/s |  63 kB     00:10     
Running transaction check
Transaction check succeeded.
Running transaction test
Transaction test succeeded.
Running transaction
  Preparing        :                                                                                                                              1/1 
  Installing       : telnet-1:0.17-85.el9.x86_64                                                                                                  1/1 
  Running scriptlet: telnet-1:0.17-85.el9.x86_64                                                                                                  1/1 
  Verifying        : telnet-1:0.17-85.el9.x86_64                                                                                                  1/1 

Installed:
  telnet-1:0.17-85.el9.x86_64                                                                                                                         

Complete!

------------------
429 dunwellguitar3:/var/log 
> telnet 192.168.1.21 25
telnet: Command not found.
430 dunwellguitar3:/var/log 
> dnf list installed |grep telnet
telnet.x86_64                                    1:0.17-85.el9                      @appstream
------------

What is in that package?

rpm -ql telnet
dnf rq -l telnet

First one works on installed package. Second one also for packages that have not been installed.


Why telnet?

Thanks for the response jlehtone, server is down just now but I’ll check on Sunday when it is back. telnet mostly for testing ports.

You can also try running these:

env telnet 192.168.1.21 25
env /usr/bin/telnet 192.168.1.21 25
\telnet 192.168.1.21 25
/usr/bin/telnet 192.168.1.21 25

You can also run dnf install https://repo.almalinux.org/almalinux/9/AppStream/x86_64/os/Packages/telnet-0.17-85.el9.x86_64.rpm to get it fresh from the mirror, and I confirmed it has /usr/bin/telnet.

Sorry for posting and then being long about keeping up. Life got in the way.

I’d like to report that this is SOLVED by MWT (Magical Wishful Thinking) Once the server was up again I did an rpm check and it showed as expected in /usr/bin/telnet. A test with that explicitly worked. A test without the specific path also worked. So all is working w/o any actual intervention, also known as the MWT fix. :slightly_smiling_face:

Thanks to all who helped out.

1 Like

If anyone has a similar problem later, I wonder if this is something a hash telnet or rehash would have fixed.