这是我第一次安装Linux/Apache。我在连接到LAN的机器上安装了CentOS和LAMPP。
关闭了 http 和 mysql(因为我不想与 LLAMPP 冲突)
chkconfig httpd off
chkconfig mysqld off
然后 LAMPP 成功启动
/opt/lampp/lampp start
Starting XAMPP for Linux 1.7.3a...
XAMPP: Starting Apache with SSL (and PHP5)...
XAMPP: Starting MySQL...
XAMPP: Starting ProFTPD...
XAMPP for Linux started.
问题:无法连接 - Firefox 无法与 179.16.51.36 的服务器建立连接。
我需要一些指点,以知道下一步该看哪里。
error_log 文件中没有错误(只有一些警告)
我可以 ping 服务器。
httpd.conf 如下所示:
ServerRoot "/opt/lampp"
Listen 80
ServerAdmin [email protected]
ServerName 179.16.51.36
DocumentRoot "/opt/lampp/htdocs"
<Directory />
Options FollowSymLinks
AllowOverride None
</Directory>
<Directory "/opt/lampp/htdocs">
Options Indexes FollowSymLinks ExecCGI Includes
Order allow,deny
Allow from all
</Directory>
ErrorLog logs/error_log
LogLevel warn
<IfModule log_config_module>
LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined
LogFormat "%h %l %u %t \"%r\" %>s %b" common
<IfModule logio_module>
LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\" %I %O" combinedio
</IfModule>
CustomLog logs/access_log common
</IfModule>
<IfModule alias_module>
ScriptAlias /cgi-bin/ "/opt/lampp/cgi-bin/"
</IfModule>
<IfModule cgid_module>
</IfModule>
<Directory "/opt/lampp/cgi-bin">
AllowOverride None
Options None
Order allow,deny
Allow from all
</Directory>
DefaultType text/plain
<IfModule mime_module>
TypesConfig etc/mime.types
AddType application/x-compress .Z
AddType application/x-gzip .gz .tgz
AddHandler cgi-script .cgi .pl
AddType text/html .shtml
AddOutputFilter INCLUDES .shtml
</IfModule>
EnableMMAP off
EnableSendfile off
一旦启动 LAMPP,我就可以远程登录到本地主机,端口 80
telnet localhost 80
[root@lastest /]# telnet localhost 80
Trying 127.0.0.1...
Connected to localhost.localdomain (127.0.0.1).
Escape character is '^]'.
文件 /var/log/messages 包含以下内容。我不确定这里有什么用处。
# cat /var/log/messages
Jan 18 09:09:02 mtlastest kernel: ACPI: Processor [CPU0] (supports 8 throttling states)
Jan 18 09:09:02 mtlastest kernel: Real Time Clock Driver v1.12ac
Jan 18 09:09:02 mtlastest kernel: Non-volatile memory driver v1.2
Jan 18 09:09:02 mtlastest kernel: Linux agpgart interface v0.101 (c) Dave Jones
Jan 18 09:09:02 mtlastest kernel: agpgart: Detected an Intel 845G Chipset.
Jan 18 09:09:02 mtlastest kernel: agpgart: Detected 892K stolen memory.
Jan 18 09:09:02 mtlastest kernel: agpgart: AGP aperture is 128M @ 0xf0000000
Jan 18 09:09:02 mtlastest kernel: Serial: 8250/16550 driver $Revision: 1.90 $ 4 ports, IRQ sharing enabled
Jan 18 09:09:02 mtlastest kernel: serial8250: ttyS0 at I/O 0x3f8 (irq = 4) is a 16550A
Jan 18 09:09:02 mtlastest kernel: 00:08: ttyS0 at I/O 0x3f8 (irq = 4) is a 16550A
Jan 18 09:09:02 mtlastest kernel: brd: module loaded
Jan 18 09:09:02 mtlastest kernel: Uniform Multi-Platform E-IDE driver Revision: 7.00alpha2
Jan 18 09:09:02 mtlastest kernel: ide: Assuming 33MHz system bus speed for PIO modes; override with idebus=xx
Jan 18 09:09:02 mtlastest kernel: ICH4: IDE controller at PCI slot 0000:00:1f.1
Jan 18 09:09:02 mtlastest kernel: PCI: Enabling device 0000:00:1f.1 (0005 -> 0007)
Jan 18 09:09:02 mtlastest kernel: ACPI: PCI Interrupt 0000:00:1f.1[A] -> GSI 18 (level, low) -> IRQ 169
Jan 18 09:09:02 mtlastest kernel: ICH4: chipset revision 1
Jan 18 09:09:02 mtlastest kernel: ICH4: not 100% native mode: will probe irqs later
Jan 18 09:09:02 mtlastest kernel: ide0: BM-DMA at 0xffa0-0xffa7, BIOS settings: hda:DMA, hdb:pio
Jan 18 09:09:02 mtlastest kernel: hda: ST340014A, ATA DISK drive
Jan 18 09:09:02 mtlastest kernel: ide0 at 0x1f0-0x1f7,0x3f6 on irq 14
Jan 18 09:09:02 mtlastest kernel: hda: max request size: 512KiB
Jan 18 09:09:02 mtlastest kernel: hda: 78156288 sectors (40016 MB) w/2048KiB Cache, CHS=16383/255/63, UDMA(100)
Jan 18 09:09:02 mtlastest kernel: hda: cache flushes supported
Jan 18 09:09:02 mtlastest kernel: hda: hda1 hda2
Jan 18 09:09:02 mtlastest kernel: ide-floppy driver 0.99.newide
Jan 18 09:09:02 mtlastest kernel: usbcore: registered new driver hiddev
Jan 18 09:09:02 mtlastest kernel: usbcore: registered new driver usbhid
Jan 18 09:09:02 mtlastest kernel: drivers/usb/input/hid-core.c: v2.6:USB HID core driver
Jan 18 09:09:02 mtlastest kernel: PNP: No PS/2 controller found. Probing ports directly.
Jan 18 09:09:02 mtlastest kernel: serio: i8042 KBD port at 0x60,0x64 irq 1
Jan 18 09:09:02 mtlastest kernel: serio: i8042 AUX port at 0x60,0x64 irq 12
Jan 18 09:09:02 mtlastest kernel: mice: PS/2 mouse device common for all mice
Jan 18 09:09:02 mtlastest kernel: md: md driver 0.90.3 MAX_MD_DEVS=256, MD_SB_DISKS=27
Jan 18 09:09:02 mtlastest kernel: md: bitmap version 4.39
Jan 18 09:09:02 mtlastest kernel: TCP bic registered
Jan 18 09:09:02 mtlastest kernel: Initializing IPsec netlink socket
Jan 18 09:09:02 mtlastest kernel: NET: Registered protocol family 1
Jan 18 09:09:02 mtlastest kernel: NET: Registered protocol family 17
Jan 18 09:09:02 mtlastest kernel: Using IPI No-Shortcut mode
Jan 18 09:09:02 mtlastest kernel: ACPI: (supports S0 S1 S3 S4 S5)
Jan 18 09:09:02 mtlastest kernel: Initalizing network drop monitor service
Jan 18 09:09:02 mtlastest kernel: Freeing unused kernel memory: 228k freed
Jan 18 09:09:02 mtlastest kernel: Write protecting the kernel read-only data: 410k
Jan 18 09:09:02 mtlastest kernel: Time: tsc clocksource has been installed.
Jan 18 09:09:02 mtlastest kernel: ACPI: PCI Interrupt 0000:00:1d.7[D] -> GSI 23 (level, low) -> IRQ 177
Jan 18 09:09:02 mtlastest kernel: ehci_hcd 0000:00:1d.7: EHCI Host Controller
Jan 18 09:09:02 mtlastest kernel: ehci_hcd 0000:00:1d.7: new USB bus registered, assigned bus number 1
Jan 18 09:09:02 mtlastest kernel: ehci_hcd 0000:00:1d.7: debug port 1
Jan 18 09:09:02 mtlastest kernel: ehci_hcd 0000:00:1d.7: irq 177, io mem 0xffa7fc00
Jan 18 09:09:02 mtlastest kernel: ehci_hcd 0000:00:1d.7: USB 2.0 started, EHCI 1.00, driver 10 Dec 2004
Jan 18 09:09:02 mtlastest kernel: usb usb1: configuration #1 chosen from 1 choice
Jan 18 09:09:02 mtlastest kernel: hub 1-0:1.0: USB hub found
Jan 18 09:09:02 mtlastest kernel: hub 1-0:1.0: 6 ports detected
Jan 18 09:09:02 mtlastest kernel: USB Universal Host Controller Interface driver v3.0
Jan 18 09:09:02 mtlastest kernel: ACPI: PCI Interrupt 0000:00:1d.0[A] -> GSI 16 (level, low) -> IRQ 185
Jan 18 09:09:02 mtlastest kernel: uhci_hcd 0000:00:1d.0: UHCI Host Controller
Jan 18 09:09:02 mtlastest kernel: uhci_hcd 0000:00:1d.0: new USB bus registered, assigned bus number 2
Jan 18 09:09:02 mtlastest kernel: uhci_hcd 0000:00:1d.0: irq 185, io base 0x0000e800
Jan 18 09:09:02 mtlastest kernel: usb usb2: configuration #1 chosen from 1 choice
Jan 18 09:09:02 mtlastest kernel: hub 2-0:1.0: USB hub found
Jan 18 09:09:02 mtlastest kernel: hub 2-0:1.0: 2 ports detected
Jan 18 09:09:02 mtlastest kernel: ACPI: PCI Interrupt 0000:00:1d.1[B] -> GSI 19 (level, low) -> IRQ 193
Jan 18 09:09:02 mtlastest kernel: uhci_hcd 0000:00:1d.1: UHCI Host Controller
Jan 18 09:09:02 mtlastest kernel: uhci_hcd 0000:00:1d.1: new USB bus registered, assigned bus number 3
Jan 18 09:09:02 mtlastest kernel: uhci_hcd 0000:00:1d.1: irq 193, io base 0x0000e880
Jan 18 09:09:02 mtlastest kernel: usb usb3: configuration #1 chosen from 1 choice
Jan 18 09:09:02 mtlastest kernel: hub 3-0:1.0: USB hub found
Jan 18 09:09:02 mtlastest kernel: hub 3-0:1.0: 2 ports detected
Jan 18 09:09:02 mtlastest kernel: ACPI: PCI Interrupt 0000:00:1d.2[C] -> GSI 18 (level, low) -> IRQ 169
Jan 18 09:09:02 mtlastest kernel: uhci_hcd 0000:00:1d.2: UHCI Host Controller
Jan 18 09:09:02 mtlastest kernel: uhci_hcd 0000:00:1d.2: new USB bus registered, assigned bus number 4
Jan 18 09:09:02 mtlastest kernel: uhci_hcd 0000:00:1d.2: irq 169, io base 0x0000ec00
Jan 18 09:09:02 mtlastest kernel: usb usb4: configuration #1 chosen from 1 choice
Jan 18 09:09:02 mtlastest kernel: hub 4-0:1.0: USB hub found
Jan 18 09:09:02 mtlastest kernel: hub 4-0:1.0: 2 ports detected
Jan 18 09:09:02 mtlastest kernel: usb 2-2: new low speed USB device using uhci_hcd and address 2
Jan 18 09:09:02 mtlastest kernel: SCSI subsystem initialized
Jan 18 09:09:02 mtlastest kernel: usb 2-2: configuration #1 chosen from 1 choice
Jan 18 09:09:02 mtlastest kernel: input: Darfon USB Combo Keyboard as /class/input/input0
Jan 18 09:09:02 mtlastest kernel: input: USB HID v1.00 Keyboard [Darfon USB Combo Keyboard] on usb-0000:00:1d.0-2
Jan 18 09:09:02 mtlastest kernel: device-mapper: uevent: version 1.0.3
Jan 18 09:09:02 mtlastest kernel: device-mapper: ioctl: 4.11.5-ioctl (2007-12-12) initialised: [email protected]
Jan 18 09:09:02 mtlastest kernel: input: Darfon USB Combo Keyboard as /class/input/input1
Jan 18 09:09:02 mtlastest kernel: input: USB HID v1.00 Device [Darfon USB Combo Keyboard] on usb-0000:00:1d.0-2
Jan 18 09:09:02 mtlastest kernel: device-mapper: dm-raid45: initialized v0.2594l
Jan 18 09:09:02 mtlastest kernel: kjournald starting. Commit interval 5 seconds
Jan 18 09:09:02 mtlastest kernel: EXT3-fs: mounted filesystem with ordered data mode.
Jan 18 09:09:02 mtlastest kernel: type=1404 audit(1295359707.879:2): enforcing=1 old_enforcing=0 auid=4294967295 ses=4294967295
Jan 18 09:09:02 mtlastest kernel: type=1403 audit(1295359708.177:3): policy loaded auid=4294967295 ses=4294967295
Jan 18 09:09:02 mtlastest kernel: ACPI: PCI Interrupt 0000:00:1f.3[B] -> GSI 17 (level, low) -> IRQ 201
Jan 18 09:09:02 mtlastest kernel: parport: PnPBIOS parport detected.
Jan 18 09:09:02 mtlastest kernel: parport0: PC-style at 0x378, irq 7 [PCSPP,TRISTATE,EPP]
Jan 18 09:09:02 mtlastest kernel: i810_smbus 0000:00:02.0: i810/i815 i2c device found.
Jan 18 09:09:02 mtlastest kernel: ACPI: PCI Interrupt 0000:01:03.0[A] -> GSI 19 (level, low) -> IRQ 193
Jan 18 09:09:02 mtlastest kernel: 3c59x: Donald Becker and others. www.scyld.com/network/vortex.html
Jan 18 09:09:02 mtlastest kernel: 0000:01:03.0: 3Com PCI 3c905B Cyclone 100baseTx at f89c2c00.
Jan 18 09:09:02 mtlastest kernel: e100: Intel(R) PRO/100 Network Driver, 3.5.10-k3-NAPI
Jan 18 09:09:02 mtlastest kernel: e100: Copyright(c) 1999-2005 Intel Corporation
Jan 18 09:09:02 mtlastest kernel: ACPI: PCI Interrupt 0000:01:08.0[A] -> GSI 20 (level, low) -> IRQ 209
Jan 18 09:09:02 mtlastest kernel: e100: eth1: e100_probe: addr 0xff8fe000, irq 209, MAC addr 00:03:47:2C:9F:15
Jan 18 09:09:02 mtlastest kernel: ACPI: PCI Interrupt 0000:00:1f.5[B] -> GSI 17 (level, low) -> IRQ 201
Jan 18 09:09:02 mtlastest kernel: intel_rng: Firmware space is locked read-only. If you can't or
Jan 18 09:09:02 mtlastest kernel: intel_rng: don't want to disable this in firmware setup, and if
Jan 18 09:09:02 mtlastest kernel: intel_rng: you are certain that your system has a functional
Jan 18 09:09:02 mtlastest kernel: intel_rng: RNG, try using the 'no_fwh_detect' option.
Jan 18 09:09:02 mtlastest kernel: input: PC Speaker as /class/input/input2
Jan 18 09:09:02 mtlastest kernel: intel8x0_measure_ac97_clock: measured 51010 usecs
Jan 18 09:09:02 mtlastest kernel: intel8x0: clocking to 48000
Jan 18 09:09:02 mtlastest kernel: Floppy drive(s): fd0 is 1.44M
Jan 18 09:09:02 mtlastest kernel: FDC 0 is a post-1991 82077
Jan 18 09:09:02 mtlastest kernel: lp0: using parport0 (interrupt-driven).
Jan 18 09:09:02 mtlastest kernel: lp0: console ready
Jan 18 09:09:02 mtlastest kernel: NET: Registered protocol family 10
Jan 18 09:09:02 mtlastest kernel: lo: Disabled Privacy Extensions
Jan 18 09:09:02 mtlastest kernel: IPv6 over IPv4 tunneling driver
Jan 18 09:09:02 mtlastest kernel: ACPI: Power Button (FF) [PWRF]
Jan 18 09:09:02 mtlastest kernel: ACPI: Sleep Button (CM) [SLPB]
Jan 18 09:09:02 mtlastest kernel: ACPI: Mapper loaded
Jan 18 09:09:02 mtlastest kernel: dell-wmi: No known WMI GUID found
Jan 18 09:09:02 mtlastest kernel: md: Autodetecting RAID arrays.
Jan 18 09:09:02 mtlastest kernel: md: autorun ...
Jan 18 09:09:02 mtlastest kernel: md: ... autorun DONE.
Jan 18 09:09:02 mtlastest kernel: device-mapper: multipath: version 1.0.5 loaded
Jan 18 09:09:02 mtlastest kernel: loop: loaded (max 8 devices)
Jan 18 09:09:02 mtlastest kernel: EXT3 FS on dm-0, internal journal
Jan 18 09:09:02 mtlastest kernel: kjournald starting. Commit interval 5 seconds
Jan 18 09:09:02 mtlastest kernel: EXT3 FS on hda1, internal journal
Jan 18 09:09:02 mtlastest kernel: EXT3-fs: mounted filesystem with ordered data mode.
Jan 18 09:09:02 mtlastest kernel: Adding 4128760k swap on /dev/VolGroup00/LogVol01. Priority:-1 extents:1 across:4128760k
Jan 18 09:09:02 mtlastest kernel: IA-32 Microcode Update Driver: v1.14a <[email protected]>
Jan 18 09:09:02 mtlastest kernel: microcode: CPU0 updated from revision 0xb to 0x1e, date = 06052003
Jan 18 09:09:02 mtlastest kernel: ip6_tables: (C) 2000-2006 Netfilter Core Team
Jan 18 09:09:02 mtlastest kernel: ip_tables: (C) 2000-2006 Netfilter Core Team
Jan 18 09:09:02 mtlastest kernel: Netfilter messages via NETLINK v0.30.
Jan 18 09:09:02 mtlastest kernel: ip_conntrack version 2.4 (8192 buckets, 65536 max) - 228 bytes per conntrack
Jan 18 09:09:02 mtlastest kernel: ADDRCONF(NETDEV_UP): eth0: link is not ready
Jan 18 09:09:02 mtlastest kernel: e100: eth0: e100_watchdog: link up, 100Mbps, full-duplex
Jan 18 09:09:02 mtlastest kernel: ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready
Jan 18 09:09:03 mtlastest rpc.statd[2088]: Version 1.0.9 Starting
Jan 18 09:09:04 mtlastest hcid[2148]: Bluetooth HCI daemon
Jan 18 09:09:04 mtlastest kernel: Bluetooth: Core ver 2.10
Jan 18 09:09:04 mtlastest kernel: NET: Registered protocol family 31
Jan 18 09:09:04 mtlastest kernel: Bluetooth: HCI device and connection manager initialized
Jan 18 09:09:04 mtlastest kernel: Bluetooth: HCI socket layer initialized
Jan 18 09:09:04 mtlastest hcid[2148]: Register path:/org/bluez fallback:1
Jan 18 09:09:04 mtlastest kernel: Bluetooth: L2CAP ver 2.8
Jan 18 09:09:04 mtlastest kernel: Bluetooth: L2CAP socket layer initialized
Jan 18 09:09:04 mtlastest sdpd[2154]: Bluetooth SDP daemon
Jan 18 09:09:04 mtlastest kernel: Bluetooth: RFCOMM socket layer initialized
Jan 18 09:09:04 mtlastest kernel: Bluetooth: RFCOMM TTY layer initialized
Jan 18 09:09:04 mtlastest kernel: Bluetooth: RFCOMM ver 1.8
Jan 18 09:09:05 mtlastest pcscd: pcscdaemon.c:507:main() pcsc-lite 1.4.4 daemon ready.
Jan 18 09:09:05 mtlastest pcscd: hotplug_libusb.c:402:HPEstablishUSBNotifications() Driver ifd-egate.bundle does not support IFD_GENERATE_HOTPLUG. Using active polling instead.
Jan 18 09:09:05 mtlastest pcscd: hotplug_libusb.c:411:HPEstablishUSBNotifications() Polling forced every 1 second(s)
Jan 18 09:09:11 mtlastest kernel: Bluetooth: HIDP (Human Interface Emulation) ver 1.1
Jan 18 09:09:11 mtlastest hidd[2275]: Bluetooth HID daemon
Jan 18 09:09:12 mtlastest automount[2295]: lookup_read_master: lookup(nisplus): couldn't locate nis+ table auto.master
Jan 18 09:09:14 mtlastest gpm[2367]: *** info [startup.c(95)]:
Jan 18 09:09:14 mtlastest gpm[2367]: Started gpm successfully. Entered daemon mode.
Jan 18 09:09:16 mtlastest avahi-daemon[2449]: Found user 'avahi' (UID 70) and group 'avahi' (GID 70).
Jan 18 09:09:16 mtlastest avahi-daemon[2449]: Successfully dropped root privileges.
Jan 18 09:09:16 mtlastest avahi-daemon[2449]: avahi-daemon 0.6.16 starting up.
Jan 18 09:09:16 mtlastest avahi-daemon[2449]: WARNING: No NSS support for mDNS detected, consider installing nss-mdns!
Jan 18 09:09:16 mtlastest avahi-daemon[2449]: Successfully called chroot().
Jan 18 09:09:16 mtlastest avahi-daemon[2449]: Successfully dropped remaining capabilities.
Jan 18 09:09:16 mtlastest avahi-daemon[2449]: No service found in /etc/avahi/services.
Jan 18 09:09:16 mtlastest avahi-daemon[2449]: New relevant interface eth0.IPv6 for mDNS.
Jan 18 09:09:16 mtlastest avahi-daemon[2449]: Joining mDNS multicast group on interface eth0.IPv6 with address fe80::203:47ff:fe2c:9f15.
Jan 18 09:09:16 mtlastest avahi-daemon[2449]: New relevant interface eth0.IPv4 for mDNS.
Jan 18 09:09:16 mtlastest avahi-daemon[2449]: Joining mDNS multicast group on interface eth0.IPv4 with address 169.16.51.36.
Jan 18 09:09:16 mtlastest avahi-daemon[2449]: Network interface enumeration completed.
Jan 18 09:09:16 mtlastest avahi-daemon[2449]: Registering new address record for fe80::203:47ff:fe2c:9f15 on eth0.
Jan 18 09:09:16 mtlastest avahi-daemon[2449]: Registering new address record for 169.16.51.36 on eth0.
Jan 18 09:09:16 mtlastest avahi-daemon[2449]: Registering HINFO record with values 'I686'/'LINUX'.
Jan 18 09:09:17 mtlastest avahi-daemon[2449]: Server startup complete. Host name is mtlastest.local. Local service cookie is 98803198.
Jan 18 09:09:18 mtlastest smartd[2509]: smartd version 5.38 [i686-redhat-linux-gnu] Copyright (C) 2002-8 Bruce Allen
Jan 18 09:09:18 mtlastest smartd[2509]: Home page is http://smartmontools.sourceforge.net/
Jan 18 09:09:18 mtlastest smartd[2509]: Opened configuration file /etc/smartd.conf
Jan 18 09:09:18 mtlastest smartd[2509]: Configuration file /etc/smartd.conf was parsed, found DEVICESCAN, scanning devices
Jan 18 09:09:18 mtlastest smartd[2509]: Problem creating device name scan list
Jan 18 09:09:18 mtlastest smartd[2509]: Device: /dev/hda, opened
Jan 18 09:09:18 mtlastest smartd[2509]: Device: /dev/hda, found in smartd database.
Jan 18 09:09:18 mtlastest smartd[2509]: Device: /dev/hda, is SMART capable. Adding to "monitor" list.
Jan 18 09:09:18 mtlastest smartd[2509]: Monitoring 1 ATA and 0 SCSI devices
Jan 18 09:09:18 mtlastest smartd[2511]: smartd has fork()ed into background mode. New PID=2511.
Jan 18 09:09:19 mtlastest init: open(/dev/pts/0): No such file or directory
Jan 18 09:09:21 mtlastest kernel: [drm] Initialized drm 1.0.1 20051102
Jan 18 09:09:21 mtlastest kernel: ACPI: PCI Interrupt 0000:00:02.0[A] -> GSI 16 (level, low) -> IRQ 185
Jan 18 09:09:21 mtlastest kernel: [drm] Initialized i915 1.8.0 20060929 on minor 0
Jan 18 09:09:23 mtlastest pcscd: winscard.c:304:SCardConnect() Reader E-Gate 0 0 Not Found
[root@mtlastest ~]# Jan 18 09:37:23 mtlastest proftpd[2995]: mtlastest - ProFTPD 1.3.2c (maint) (built Fri Dec 11 08:46:41 CET 2009) standalone mode STARTUP .
netstat .ntlp something looks fishy
here..
Proto Recv-Q Send-Q Local Address Foreign AddState PID/Program name
tcp 0 0 0.0.0.0:998 0.0.0.0:* LISTEN 2088/rpc.statd
tcp 0 0 0.0.0.0:3306 0.0.0.0:* LISTEN 2961/mysqld
tcp 0 0 0.0.0.0:111 0.0.0.0:* LISTEN 2056/portmap
tcp 0 0 127.0.0.1:631 0.0.0.0:* LISTEN 2326/cupsd
tcp 0 0 127.0.0.1:25 0.0.0.0:* LISTEN 2348/sendmail: ace
tcp 0 0 :::80 :::* LISTEN 2813/httpd
tcp 0 0 :::21 :::* LISTEN 2995/proftpd: (ace
tcp 0 0 :::22 :::* LISTEN 2315/sshd
tcp 0 0 :::443 :::* LISTEN 2813/httpd
答案1
从机器上运行telnet localhost 80
。这样有效吗?如果有效,则表明您的 Web 服务器正在端口 80 上运行,这是应该的。但从您的描述来看,这似乎不起作用。
检查/var/log/messages
一下是否打印了任何有用的内容。
这XAMPP 页面有一些进一步的故障排除技巧。不过,我猜你会在 /var/log/messages 中找到一些系统日志消息,它们应该能为你指明正确的方向。
答案2
确保您的 iptables 允许端口 80 上的传入连接。
运行iptables -L -nv
并确保您有如下一行:
2383 138K 接受 tcp -- * * 0.0.0.0/0 0.0.0.0/0 tcp dpt:80
在您的输入表中。
答案3
我看到您正在尝试通过浏览器中的 179.16.51.36 ip 进行连接,并且您正在通过 localhost 检查服务器。您能判断在浏览器中加载 localhost 是否有效吗?如果客户端和服务器是不同的主机。那么您应该检查从客户端到端口 80 上的服务器 ip 的 telnet 是否正常工作?
答案4
在尝试通过网络访问 Apache 之前,您应该验证它是否已正确启动。
netstat -ntlp
在服务器上运行上述程序,它应该列出哪些服务正在运行以及它们“绑定”到哪些端口。
如果没有列出 80,那么您需要排除 apache 启动故障。
apachectl configtest
apachectl start
在初始测试期间暂时关闭服务器的 iptables 防火墙会有所帮助。
/etc/init.d/iptables stop