tftp烧录系统固件

1.配置服务器端
安装TFTP服务:
apt-get install tftp-hpa tftpd-hpa xinetd

2.修改配置文件
在/etc/default下修改tftp服务的配置文件tftpd-hpa:
sudo vim /etc/default/tftp-hpa
TFTP_USERNAME=”tftp”
TFTP_DIRECTORY=”/tftpboot”
TFTP_ADDRESS=”0.0.0.0:69”
TFTP_OPTIONS=”-l -c -s”
说明:修改项,其中TFTP_DIRECTORY处可以改为你的tftp-server的根目录,参数-c指定了可以创建文件。
创建文件夹/tftpboot,修改权限为666

3、sudo service tftpd-hpa restart

4、把文件放到/tftpboot下

5、tftp 127.0.0.1

6、确保板子连的网络和linux主机在同一个网络

7、uboot进入,选2:2: Load system code then write to Flash via TFTP

8、改client ip (可随便设,但是必须在同一个网段)、seriver ip、 文件名字

9、开始烧录

2: System Load Linux Kernel then write to Flash via TFTP.
Warning!! Erase Linux in Flash then burn new one. Are you sure?(Y/N)
Please Input new ones /or Ctrl-C to discard
Input device IP (192.168.199.208) ==:192.168.1.150
Input server IP (192.168.1.108) ==:192.168.1.108
Input Linux Kernel filename () ==:ndbj.bin
netboot_common, argc= 3
NetTxPacket = 0x83FE6B40
KSEG1ADDR(NetTxPacket) = 0xA3FE6B40
NetLoop,call eth_halt !
NetLoop,call eth_init !
Trying Eth0 (10/100-M)
Waitting for RX_DMA_BUSY status Start… done
ETH_STATE_ACTIVE!!
TFTP from server 192.168.1.108; our IP address is 192.168.1.150
Filename ‘ndbj.bin’.
TIMEOUT_COUNT=10,Load address: 0x80100000
Loading: Got ARP REPLY, set server/gtwy eth addr (00:0c:29:3a:3d:bb)
Got it

#########################Got ARP REQUEST, return our IP
#
 #################################################################
 #################################################################
 #################################################################
 #################################################################
 #################################################################
 #################################################################
 #################################################################
 #################################################################
 ##############################################################Got ARP REQUEST, return our IP

#

 #################################################################
 #################################################################
 #################################################################
 #################################################################
 #################################################################
 #################################################################
 #################################################################
 #################################################################
 ########

done
Bytes transferred = 6029316 (5c0004 hex)
NetBootFileXferSize= 005c0004
………………………………………………………………………………..
………………………………………………………………………………..
.
.
Done!
Booting image at bc050000 …
Image Name: MIPS OpenWrt Linux-3.18.45
Image Type: MIPS Linux Kernel Image (lzma compressed)
Data Size: 1155483 Bytes = 1.1 MB
Load Address: 80000000
Entry Point: 80000000
Verifying Checksum … OK
Uncompressing Kernel Image … OK
No initrd
Transferring control to Linux (at address 80000000) …
Giving linux memsize in MB, 64
Starting kernel …
[ 0.000000] Linux version 3.18.45 (linsijia@urdc) (gcc version 4.8.3 (OpenWrt/Linaro GCC 4.8-2014.04 unknown) ) #221 Wed Feb 28 19:57:49 CST 2018
[ 0.000000] Board has DDR2

  • 0
    点赞
  • 3
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值