Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
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.
Introduction to Linux - A Hands on Guide
This guide was created as an overview of the Linux Operating System, geared toward new users as an exploration tour and getting started guide, with exercises at the end of each chapter.
For more advanced trainees it can be a desktop reference, and a collection of the base knowledge needed to proceed with system and network administration. This book contains many real life examples derived from the author's experience as a Linux system and network administrator, trainer and consultant. They hope these examples will help you to get a better understanding of the Linux system and that you feel encouraged to try out things on your own.
Click Here to receive this Complete Guide absolutely free.
OBR_PC is linked to OSR_PC (address 172.18.0.20)
The OSR_PC is linked to OSR_IP(address: 169.254.101.2)
The software is to send the commands to the OSR_IP through the OSR_PC from the OBR_PC but I cannot get a link with this line and nether can my IT tech.
He wants to create an entire new configuration.
I can ssh into the OSR_PC and then ssh onto the OSR_IP.
Can I make the above script work without rewriting the entire program which is quite extensive?
If I were in your shoes, for the sake of testing where the failure is, I would take out the variables that reference known IP's, I would also setup ~/.ssh/config files on each machine that you are ssh'ing into to pre configure the "connecttimeout" options, and if possible I would even configure a passwordless ssh key for root@$OSR_IP to get rid of the "sshpass" command (BTW I had never heard of that till your post). That should leave you with a very minimalist command. Assuming that all works, you could back out of those changes to find the one that breaks.
The software is setting frequency and bandwidth parameters on two systems to establish communication between the two.
The OBR unit, controlled from OBR_PC, is not a problem and works fine.
The software control of the OSR_IP does not report any error. The program continues to run but the parameters on OSR_IP are not changed. This results in a "Test Failure".
Entering the command line in Terminal,
I am unable to reach the command prompt of OSR_IP.
I have tried symplfing the line to : ssh root@$OSR_PC "sshpass -p default ssh root@$OSR_IP"
The return shows that the OSR_IP address has been added but nothing more happens.
I have been searching for a reason for this. As I have said earlier, I can ssh into OSR_PC and then ssh into OSR_IP and from what I know so far – this should work.
Is there a Good reference document that would help my understanding of using ssh in this manner?
sshpass is not recommended for the reasons stated on the man page http://linux.die.net/man/1/sshpass.
I would indeed go with post#4; simplify the code (at least for debugging the issue) and use ssh auth-keys instead of sshpass.