LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This 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!

Notices


Closed Thread
  Search this Thread
Old 02-28-2018, 01:40 AM   #1
Anna$9
LQ Newbie
 
Registered: Nov 2017
Posts: 24

Rep: Reputation: Disabled
Not able to ssh from one base server to another server


Not able to ssh from one base server to another server:
It prompts for username and password, the password is asked thrice.
After that, it prompts for the password of the submachine that I want to connect. Once that is entered, it says
Code part:
read -p "Enter username: " usr
read -s -p "Enter Password: " pswd \n
echo
$ExportFileLocation "/tmp/Outputfile.txt"
IFS=","
while read f1 f2
do
echo "PrivateIP is : $f1"
echo "Hostname is : $f2"
done < Inputfile.txt
for HOST in $(cat Inputfile.txt ) ; do ssh $HOST "yum install httpd -y"; done
OUTPUT :
[root@asdfggg tmp]# ./test.sh
Enter username: abcd
Enter Password:
PrivateIP is : xx.xx.xx.xx
Hostname is : asdfggg
Password:
Password:
Password:
root@xx.xx.xx.xx's password:
Permission denied, please try again.
root@xx.xx.xx.xx's password:
 
Old 02-28-2018, 01:49 AM   #2
jsbjsb001
Senior Member
 
Registered: Mar 2009
Location: Earth, unfortunately...
Distribution: Currently: OpenMandriva. Previously: openSUSE, PCLinuxOS, CentOS, among others over the years.
Posts: 3,881

Rep: Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063
You have posted two threads asking the same question - I've reported this thread to be closed.

Use your other thread here: https://www.linuxquestions.org/quest...er-4175624608/
 
  


Closed Thread

Tags
linux, shell, shell scripting, ssh



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] scp/ssh to cygwin server from linux server without password prompt... blainemiller Linux - Server 7 05-18-2011 02:04 PM
[SOLVED] Configuring the Linux server to login to Windows server without password using SSH srajeshkumar Linux - Server 2 03-09-2011 09:49 PM
ssh connexion problem from AIX server to Windows 2003 Server TIAHA David Linux - Newbie 7 03-25-2010 08:04 AM
How to discover if Redhat 5 server is Advanced or Base server yakov1975 Linux - Server 1 08-21-2009 09:58 PM
Unable to access my ssh server and ftp server from the Internet, but smtp works foxone Linux - Networking 1 05-28-2004 05:17 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 02:33 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration