Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Recently installed telnet on Fedora 6. I am unable to telnet localhost. Before I get a bunch of responses about not using telnet, this machine is offline and I only installed telnet so that I could access port 2947. I am trying to use gpsd, and the instructions for using it are to telnet that port once the daemon is running. If anyone knows another way to use gpsd, I'd gladly do that instead:
-All firewalls are disabled
-telnet file in xinetd.d is set to disable = no
well you appear to just want to use the telnet *client* for other purposes. in that case, this has nothing at all to do with telnet itself. as such there aren't the security risks... as far as what problems you have, well firstly ignore anythign at all about a telnet server, xinetd etc... as it's irrelevant. i'd be looking to see if anythign is actually listening on port 2947 in the first place...
Mmm, looks like it is listening. Not sure what the problem is then. The mask 0.0.0.0 means it should accept connections coming from anywhere. I'm not sure what is going on. Presumably what you would expect is that when you telnet you either see some sort of gpsd protocol output, or simply nothing (if the gpsd protocol expects the client to send data first before any response).
Is there a way to use ssh to do what I'm trying to do with telnet?
You didn't really describe what you are trying to accomplish in enough detail at the start of the thread - I assumed it was just a connection test.
It is not uncommon as a quick check of daemons which listen on TCP ports to check if they are installed properly and running with a quick telnet to the port they listen to. The "connection refused" which you are getting suggests something is not right in the gpsd setup.
If you managed to get a connection, and the gpsd communication protocol is textual, it should be possible not only to connect but also to issue some commands and get some sort of response back as further proof that the program is running. You can do a similar thing to check a web server is running by telnetting to port 80 and doing a "GET www.yourdomain.com" just to make sure it's running.
ssh isn't a good substitute for this sort of check as it requires a lot more interacting with the other end before it will complete the connection, and will generally drop connections to anything other than sshd demons on the other end.
netcat (command = nc) can be used as an alternative to telnet for these simple checks, but if you are getting "connection refused" responses from telnet, I don't think the problem is the program - the cannot successfully open the port, so it doesn't really matter which program you are using, you will probably get the same response.
The question is: why does gpsd not accept connections (since it does appear to be listening to the right port). I am out of ideas. Maybe there is a gpsd setup and troubleshooting guide somewhere?
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.