I have fixed it thanks to a colleague of mine. I moved rsh to /root/bin/ and then made the script below in /usr/bin/ named rsh.
It even catches the script name from which it is started with the variable $PPID. Be sure to put #!/usr/bin/ksh to your scripts and it works.
#!/usr/bin/ksh...
Thank you for your reply. It is very useful but there is still one thing. If the rsh command is executed from within a script I would like to log the name of that script.
On our systems are many scripts that execute rsh or ftp commands. I would like to log what script calls rsh or ftp. I've tried to catch it with $$ and $0 at the moment a script starts but they only return the PID from ksh and the last run command which is rsh or ftp.
Is there someone who has an...
Yes thank you, I know that I can see the network status with `netstat -a` and then I can do an `lsof -i :[portnr or servicename]` to see what kind of PID is behind that port or service.
But that just a snapshot of one moment in time. I could run the commands on different times and days but...
Hello i'm quite new to AIX and Unix in general. And I have a question.
How can I monitor which network services are being used and unused. And how can I determine what or who uses it.
For example I would like to disable rsh and replace it by ssh. How can I see who is using rsh and what they...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.