Suppose we want to check whether the web server is running or not, but we don't have any browsers ( lynx, IE, Netscape ...), then there is a simple way of doing that. Just telnet to that machine on the http port ( port no 80 in general).
% telnet <ip addr> <port no>
And then, say "get /" (without quotes). If the webserver is running, it displays the HTML script of the homepage or basic info and closes the connection to the remote host.
% telnet yahoo.com 80
Connected to yahoo.com.
Escape character is '^]'.
HTTP/1.0 302 RD
Connection closed by foreign host.
Return to : Unix System Administration
Hints and Tips