- 论坛徽章:
- 0
|
我是新手,才开始练习用redhat 8.0 装服务器。
使用完全安装。
先配置 iptables
iptables -L 显示如下:
Chain INPUT (policy ACCEPT)
target prot opt source destination
RH-Lokkit-0-50-INPUT all -- anywhere anywhere
Chain FORWARD (policy ACCEPT)
target prot opt source destination
ACCEPT all -- 192.168.1.0/24 anywhere
ACCEPT all -- anywhere 192.168.1.0/24
DROP all -- !192.168.1.0/24 anywhere
Chain OUTPUT (policy ACCEPT)
target prot opt source destination
Chain RH-Lokkit-0-50-INPUT (1 references)
target prot opt source destination
ACCEPT udp -- 61.134.2.9 anywhere udp spt:domain dpts:1025:65535
ACCEPT udp -- dns.sn.cninfo.net anywhere udp spt:domain dpts:1025:65535
ACCEPT udp -- anywhere anywhere udp spts:bootps:bootpc dpts:bootps:bootpc
ACCEPT udp -- anywhere anywhere udp spts:bootps:bootpc dpts:bootps:bootpc
ACCEPT all -- anywhere anywhere
REJECT tcp -- anywhere anywhere tcp dpts:0:1023 flags:SYN,RST,ACK/SYN reject-with icmp-port-unreachable
REJECT tcp -- anywhere anywhere tcp dpt:nfs flags:SYN,RST,ACK/SYN reject-with icmp-port-unreachable
REJECT udp -- anywhere anywhere udp dpts:0:1023 reject-with icmp-port-unreachable
REJECT udp -- anywhere anywhere udp dpt:nfs reject-with icmp-port-unreachable
REJECT tcp -- anywhere anywhere tcp dpts11:6009 flags:SYN,RST,ACK/SYN reject-with icmp-port-unreachable
REJECT tcp -- anywhere anywhere tcp dptfs flags:SYN,RST,ACK/SYN reject-with icmp-port-unreachable
用该机器做为路由使用,正常。
后配 dhcp 服务,编辑/etc/dhcpd.conf 文件如下:
ddns-update-style interim;
ignore client-updates;
subnet 192.168.1.0 netmask 255.255.255.0{
range 192.168.1.20 192.168.1.200;
default-lease-time 7200;
max-lease-time 86400;
option subnet-mask 255.255.255.0;
option broadcast-address 192.168.1.255;
option routers 192.168.1.10;
option domain-name-servers 202.134.229.4;
}
用 dhcpd restart 命令重新启动 dhcp 服务。
然后用另一台计算机(windows 2000 )配置静态地址,能通过 linux 的机器上网。
然后将该机器(windows 2000)作为客户端设置为自动获取 ip 地址 对linux 的dhcp服务进行测试。
确无法获得ip地址。
请问,这个问题的出现和哪些因素有关。能排除 iptables 的配置原因吗?
[ 本帖最后由 happylala 于 2005-12-26 10:53 编辑 ] |
|