- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Script to check the connections.
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-27-2006 08:06 AM
09-27-2006 08:06 AM
I have to check the connections to 4 IP addresses on 10 different ports. Can I get the output in script. Has anybody tried this before.
Thanks .
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-27-2006 08:17 AM
09-27-2006 08:17 AM
Re: Script to check the connections.
Invoke as ping.pl -u for full usage but it's no more difficult than this:
ping.pl -I hostname
STAT=${?}
if [[ ${STAT} -eq 0 ]]
then
echo "OK"
else
echo "failed; status ${STAT}" >&2
fi
If the "echo" service is enabled in /etc/inetd.conf then regular users can use -T (for tcp) or (-U) for udp to attempt to reach the host. -I (ICMP) requires that the script nbe run by root.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-27-2006 08:27 AM
09-27-2006 08:27 AM
Re: Script to check the connections.
Thanks !
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-27-2006 09:12 AM
09-27-2006 09:12 AM
Re: Script to check the connections.
http://hpux.connect.org.uk/hppd/hpux/Networking/Admin/nmap-3.93/
With nmap, you can check what ports are open on a remote host.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-27-2006 10:09 AM
09-27-2006 10:09 AM
Solutionhttp://search.cpan.org/~jrogers/Net-Telnet-3.03/lib/Net/Telnet.pm
and then:
checktelnet.pl -t 15 -P 5555 mickey 2>/dev/null
STAT=${?}
if [[ ${STAT} -ne 0 ]]
then
echo "Could not contact host mickey on tcp port 5555; status ${STAT}." >72
fi
Invoke as checktelnet.pl -u for full usage.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-28-2006 02:49 AM
09-28-2006 02:49 AM