How to pass password in Shell Script
I am creating a shell script (bach/csh), which I will use to fetch some info. from some application servers. Script will login into each server one by one and will invoke the commands mentioned in it, but I have a problem that how can I pass password for each server?
Let's say scrpit has a line: ssh username@$hostname
Where $hostname is varialbe containing many diferent hosts. But when I am invoking the script, it asks for the password again & again for each server. So is there any way that I can mention that password in script itself and i dont need to type it again and again? Moreover, my appication servers only accept "ssh" connection. and "sshpass" is lso not available.
Thanks in advance.