Chinaunix首页 | 论坛 | 博客
  • 博客访问: 570031
  • 博文数量: 57
  • 博客积分: 842
  • 博客等级: 准尉
  • 技术积分: 772
  • 用 户 组: 普通用户
  • 注册时间: 2009-04-22 21:20
个人简介

大家可以邮件交流哈

文章分类

全部博文(57)

文章存档

2021年(1)

2018年(2)

2017年(3)

2016年(8)

2015年(1)

2014年(8)

2013年(7)

2012年(9)

2011年(5)

2010年(2)

2009年(11)

我的朋友

分类: 系统运维

2016-11-03 16:25:53

yum install -y tftp tftp-server


vi /usr/lib/systemd/system/tftp.service

[Unit]
Description=Tftp Server
Requires=tftp.socket
Documentation=man:in.tftpd


[Service]
ExecStart=/usr/sbin/in.tftpd -u root -c -s /var/lib/tftpboot    //此处要修改,添加-u root -c ,否则不能上传文件
StandardInput=socket


[Install]
Also=tftp.socket

防火墙开放端口

firewall-cmd --permanent --zone=public --add-service=tftp
firewall-cmd --reload
更改selinux设置
chcon -t tftpdir_rw_t /var/lib/tftpboot
setsebool -P tftp_anon_write 1 setsebool -P tftp_home_dir 1 

启动tftp server
systemctl restart tftp
测试tftp server

tftp localhost
put file
get file





阅读(1665) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~