cannot access apache server from other machines?
I have apache running a redhat machine. DHCP is used to get a IP address for the machine.
There's no problem using either "localhost" or dhcp assigned IP address to access some pages on the machine. But when I tried LYNX dhcp address of the machine from other machines, it failed by showing this: BEGIN---> Looking up #.#.#.# first Looking up #.#.#.# Making HTTP connection to #.#.#.# Alert!: Unable to connect to remote host. lynx: Can't access startfile http://#.#.#.#/ <---END "#.#.#.#" is dhcp address obtained for the machine. I tried ssh account@#.#.#.#, it prompts to ask password things. So, I think ssh should work. Also, in httpd.conf, there's a line "Listen *:80". And there's no problem with browsing internet from mazilla. What's going wrong? Maybe some low level network settings? To find out the problem, I also tried to allow "ALL:ALL" in hosts.allow and deny nothing in hosts.deny. Thanks. For your reference, Lynx.trace from "lynx -trace http://#.#.#.#/index.html" is attached below: Lynx Trace Log (2.8.3rel.1) lynx_setup_colors lynx_map_color(0) lynx_map_color(1) lynx_map_color(2) lynx_map_color(3) lynx_map_color(4) lynx_map_color(5) lynx_map_color(6) lynx_map_color(7) LYNX_SIG_FILE set to '/usr2/student/j/jianmao/.lynxsig' Loading cfg file '/usr/local/lib/lynx.cfg'. HTParse: aName:`http://lynx.browser.org/' relatedName:`' HTParse: (ABS) HTParse: result:http://lynx.browser.org/ HTMLDTD: Copying DTD element info of size 5236, 119 * 44 HTMLSetCharacterHandling: LYRawMode changed OFF -> ON ProcessMailcapFile: Loading file '/usr/local/lib/mosaic/mailcap'. ProcessMailcapFile: Could not open '/usr/local/lib/mosaic/mailcap'. ProcessMailcapFile: Loading file '.mailcap'. ProcessMailcapEntry Setting up conversion video/mpeg : /opt/SUNWsmtv/bin/showmetv %s >/dev/null ProcessMailcapEntry Setting up conversion video/x-mpeg2 : /opt/SUNWsmtv/bin/showmetv %s >/dev/null ProcessMailcapEntry Setting up conversion video/quicktime : /opt/SUNWsmtv/bin/showmetv %s >/dev/null ProcessMailcapEntry Setting up conversion video/x-msvideo : /opt/SUNWsmtv/bin/showmetv %s >/dev/null ProcessMailcapEntry Setting up conversion audio/basic : /opt/SUNWsmtv/bin/showmetv %s >/dev/null ProcessMailcapEntry Setting up conversion audio/x-wav : /opt/SUNWsmtv/bin/showmetv %s >/dev/null HTFormat: Looking up presentation for text/plain to www/present FindPresentation: found exact match: text/plain HTFormat: Looking up presentation for text/html to www/present FindPresentation: found exact match: text/html HTFileInit: Loading default (HTInit) extension maps. HTLoadExtensionsConfigFile: Loading file '/usr/local/lib/mosaic/mime.types'. HTLoadExtensionsConfigFile: Could not open '/usr/local/lib/mosaic/mime.types'. HTLoadExtensionsConfigFile: Loading file '/usr2/student/j/jianmao/.mime.types'. HTLoadExtensionsConfigFile: Could not open '/usr2/student/j/jianmao/.mime.types'. Window size changed from (24,80) to (17,100) start_curses: done. HTParse: aName:`http://#.#.#.#/index.html' relatedName:`' HTParse: (ABS) HTParse: result:http://#.#.#.#/index.html LYMain: User in REMOTE domain Entering mainloop, startfile=http://#.#.#.#/index.html getfile: getting http://#.#.#.#/index.html HTParse: aName:`http://#.#.#.#/index.html' relatedName:`' HTParse: result:#.#.#.# HTParse: aName:`http://#.#.#.#/index.html' relatedName:`' HTParse: result: Entered HTAnchor_findAddress New anchor 18ab00 has hash 57 and address `http://#.#.#.#/index.html' HTAccess: loading document http://#.#.#.#/index.html HTParse: aName:`http://#.#.#.#/index.html' relatedName:`file:' HTParse: result:http HTParse: aName:`http://#.#.#.#/index.html' relatedName:`' HTParse: result:#.#.#.# HTParse: aName:`http://#.#.#.#/index.html' relatedName:`' HTParse: result:http HTParse: aName:`http://#.#.#.#/index.html' relatedName:`' HTParse: result:#.#.#.# Looking up #.#.#.# HTParseInet: parsing `#.#.#.#'. HTParseInet: Parsed address as port 80, IP address #.#.#.# Making HTTP connection to #.#.#.# TCP: Error 150 in `SOCKET_ERRNO' after call to this socket's first connect() failed. Operation now in progress TCP: Error 150 in `SOCKET_ERRNO' after call to this socket's first select() failed. Operation now in progress TCP: Error 146 in `SOCKET_ERRNO' after call to confirm-ready connect() failed. Connection refused HTTP: Unable to connect to remote host for `http://#.#.#.#/index.html' (errno = 146). Alert!: Unable to connect to remote host. HTAccess: status=-29999 HTAccess: `http://#.#.#.#/index.html' has been accessed, No data loaded. stop_curses: done. LYCleanupTemp removing /tmp//6UaW.V |
Firewall settings maybe? Try running iptables -L and see if there's a firewall rule blocking inbound HTTP traffic.
|
Thanks a lot! Yeah, its iptables. And I add a rule for passing through port 80 packets. Should read more about those commands for configuring network security:-)
|
All times are GMT -5. The time now is 11:27 PM. |