|
配置文件:
[PHP]#
# /etc/hosts: static lookup table for host names
#
#<ip-address> <hostname.domain.org> <hostname>
127.0.0.1 localhost.localdomain localhost
#End of file
[/PHP]
[PHP]#
# /etc/resolv.conf
#
#search <yourdomain.tld>
#nameserver <ip>
nameserver 202.98.96.68
# End of file
[/PHP]
[PHP]#
# /etc/rc.conf - Main Configuration for Arch Linux
#
#
# Localization
#
# HARDWARECLOCK: set to "UTC" or "localtime"
# TIMEZONE: timezones are found in /usr/share/zoneinfo
# KEYMAP: keymaps are found in /usr/share/kbd/keymaps
# CONSOLEFONT: fount in /usr/share/kbd/consolefonts (only needed for non-us)
# USECOLOR: use ANSI color sequences in startup messages
#
HARDWARECLOCK="localtime"
TIMEZONE=Asia/Shanghai
KEYMAP=us
CONSOLEFONT=
USEcolor="yes"
# Scan for LVM volume groups at startup, required if you use LVM
USELVM="no"
#
# Networking
#
HOSTNAME="myhost"
#
# Module to load at boot-up (in this order)
# (prefix a module with a ! to disable it)
#
MODULES=(8139too snd-cs46xx !usbserial !ide-scsi)
#
# Interfaces to start at boot-up (in this order)
# Declare each interface then list in INTERFACES
# (prefix an interface in INTERFACES with a ! to disable it)
#
# Note: to use DHCP, set your interface to be "dhcp" (eth0="dhcp")
#
lo="lo 127.0.0.1"
eth0="eth0 192.168.1.21 netmask 255.255.255.0 broadcast 192.168.1.255"
INTERFACES=(lo eth0)
#
# Routes to start at boot-up (in this order)
# Declare each route then list in ROUTES
# (prefix a route in ROUTES with a ! to disable it)
#
gateway="default gw 192.168.1.1"
ROUTES=(gateway)
#
# Daemons to start at boot-up (in this order)
# (prefix a daemon with a ! to disable it)
#
DAEMONS=(syslog-ng hotplug !pcmcia network !netfs crond)
# End of file[/PHP]
ifconfig
[PHP]eth0 Link encap:Ethernet HWaddr 00:E0:3C:00:1E:94
inet addr:192.168.1.21 Bcast:192.168.1.255 Mask:255.255.255.0
inet6 addr: fe80::2e0:3cff:fe00:1e94/64 Scopeink
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 b) TX bytes:0 (0.0 b)
Interrupt:10 Base address:0x8000
lo Link encapocal Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:79 errors:0 dropped:0 overruns:0 frame:0
TX packets:79 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:7872 (7.6 Kb) TX bytes:7872 (7.6 Kb)[/PHP]
route:
[PHP]Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
192.168.1.0 * 255.255.255.0 U 0 0 0 eth0
default 192.168.1.1 0.0.0.0 UG 0 0 0 eth0[/PHP]
ping 192.168.1.1
[PHP]PING 192.168.1.1 (192.168.1.1) 56(84) bytes of data.
From 192.168.1.21 icmp_seq=2 Destination Host Unreachable
From 192.168.1.21 icmp_seq=3 Destination Host Unreachable
From 192.168.1.21 icmp_seq=4 Destination Host Unreachable
--- 192.168.1.1 ping statistics ---
4 packets transmitted, 0 received, +3 errors, 100% packet loss, time 2998ms, pipe 3[/PHP] |
|