The while loop will cycle through the lines of the input file, where on each line is the name or IP-address of a single host to be inspected. So 10 lines will be 10 ssh connects, one to each host.
If you deploy that script on each host, you'll have to ssh to each one though to get the information. There are different ways to achieve what you want - you could also run that script via cron on each box and have them connect to your central box delivering the info to it in intervals or once a day, whatever.
But to have passwordless communication with ssh between the hosts and your central collection box, you would have to create passwordless ssh-keys and exchange the public ssh keys to your needs.
Hi,
I do not have root user credentials nor do I have the functional id of the process that uses port 80.
How can I find the pid of the process using the port number 80 ?
Operating System: Linux (6 Replies)
Hi,
Is this the most appropriate way of finding the listen port number given the pid is "16659" ?
lsof -Pan -i tcp -i udp | grep 16659 | grep -i "listen"If so, how can I extract "7001" and assign it to a variable say myport=7001 from the below output which happens to be actual port number?
... (1 Reply)
Hi,
I need to find the PID for a given port on the below system.
HP-UX mymachine B.11.31 U ia64 3223107173 unlimited-user license
How can I ? (4 Replies)
Hi
#Testing for file existence
if ; then
echo 'SCHOOL data is available for processing'
else
echo 'SCHOOL DATA IS NOT AVAILABLE FOR PROCESSING'
:
i wrote a script, where it begins by checking if file exists or not.
If it exists, it truncates the database... (2 Replies)
Hello guys,
How to shut down a port number in AIX.
May be first I need to find out what is the process ID of that process that listens to this particular port.. Is there any command to find a process ID from the port number other than "lsof".
thanks (1 Reply)
Hi,
I am working on HP-UX Release 11i.
I want to find the process id (PID) of the process running on a particular port.
lsof command fuser does not work on this system.
Please suggest some alternative.
Thanks (6 Replies)
1. If I use an software application(which connects to the database in the server) in my local pc, how many PID should be registered? Would there be PID for the session and another PID for socket connection?
2. I noticed (through netstat) that when I logged in using the my software application,... (1 Reply)