从网络启动loongson盒子

原文: http://www.lemote.com/bbs/viewthread.php?tid=23362


假定你已经配置好了所需要的tftp, dhcp, nfs服务。//参见:配置tftp,dhcp, nfs服务 

假定你已经安装好了可用于loogson盒子的交叉编译的工具链//参见:在gentoo上安装 mips64el-st-linux-gnu-交叉编译工具链

假定已经编译好了可用的文件系统//参见:使用 busybox 为 龙芯2f 创建 文件系统


 1. 配置linux内核
 
 Networking support
  Networking options
 
                                  <*> Packet socket                                                                                         
                                  <*> Unix domain sockets                                                                               
                                  < > PF_KEY sockets                                                                                      
                                  [*] TCP/IP networking                                                                                    
                                  [ ]   IP: multicasting                                                                               
                                  [ ]   IP: advanced router                                                                                  
                                  [*]   IP: kernel level autoconfiguration                                                                  
                                  [*]     IP: DHCP support                                                                                  
                                  [*]     IP: BOOTP support  
 
 
 
     [*] Network File Systems  --->
 
                                   --- Network File Systems                                                                                  
                                   <*>   NFS client support                                                                                 
                                   [ ]     NFS client support for NFS version 3 (NEW)                                                       
                                   [ ]     NFS client support for NFS version 4 (NEW)                                                         
                                   [*]   Root file system on NFS  
 
2. 准备

现在我们配置好了tftp服务,dhcp服务和nfs服务
tftp服务的共享文件夹为/srv/tftp
nfs服务的共享文件夹为/srv/loongson
将我们制作好的文件系统//参见
拷贝到/srv/loongson
将内核文件vmlinuz拷贝到/srv/tftp, 我为了区分其他内核,把它改名为vmlinuz-v1
宿主机IP:192.168.1.222
和龙芯盒子用网线直接连起来。

3. 启动loongson 2f盒子

开机按住del键,进入PMON
PMON> devls
Device  name    Type
rtk0                          IFNET//可用的网卡,有多个网卡的盒子,请把网线插到离VGA接口最近的口
wd0                         DISK
PMON> ifaddr rtk0 192.168.1.151   //龙芯盒子的ip
bootp=80000b968
rtl_chip_info: RTL8169s/8110s, 4
r8110: link up: PHY status: 0xb

PMON>  load tftp://192.168.1.222/vmlinuz-v1  // 192.168.1.222宿主机的IP
PMON>  g root=/dev/nfs rw nfsroot=192.168.1.222:/srv/loogson ip=192.168.1.151:192.168.1.222:192.168.1.222:255.255.255.0:Joseph:eth0 console=tty

含义:更多请参考这里:http://fscked.org/writings/clusters/nfsroot.txt
ip=<client-ip>:<nfssever-ip>:<gateway-ip& gt;:<netmask>:<host-name>:<device>:<auto-conf>

 正常情况下,应该可以启动了。
如果错误提示: Sending DHCP requests .... timed out! 检查你的ip地址是否有误


评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值