CentOS 5.8 建立 TFTP 服务

win7 32bit
CentOS 5.8 i386
vmware 8.0 虚拟机
IP 192.168.1.103

先安装服务器
# yum install xinetd tftp tftp-server

默认的服务器目录是 /tftpboot
# vim /etc/xinetd.d/tftp

service tftp
{
socket_type = dgram
protocol = udp
wait = yes
user = root
server = /usr/sbin/in.tftpd
server_args = -s /tftpboot
disable = no
per_source = 11
cps = 100 2
flags = IPv4
}

重启服务器
# service xinetd restart

测试
# tftp localhost
>get hello.c
>q

主机是win7的话,需要先打开tftp功能。方法是 控制面板--> 程序--> 打开或关闭window功能
选择 TFTP 客户端

centOS 需要允许FTP服务
# setup
Firewall configuration --> customize
Trusted Device 选择 eth0 ,然后下面选择能通过防火墙的服务,FTP,其他端口设置为 69:UDP

win7 的防火墙也关闭了,方便测试

可以在windows 下访问测试
tftp 192.168.1.103 get hello.c

Etual
2012-12-12

你可能感兴趣的:(linux,linux,linux,centos,centos,centos)