使用NFS作为根文件系统来启动
2014-09-01 21:06
330 查看
bootargs=noinitrd root=/dev/mtdblock3 init=/linuxrc console=ttySAC0
set bootargs noinitrd root=/dev/nfs nfsroot=192.168.1.102:/nfsboot/tmp/fs_mini_mdev ip=192.168.1.108:192.168.1.102:192.168.1.1:255.255.255.0::eth0:off init=/linuxrc console=ttySAC0
在内核目录下有个nfsboot.txt文件
/work/linux-2.6.22.6/Documentation/nfsboot.txt
内容如下:
root=/dev/nfs
This is necessary to enable the pseudo-NFS-device. Note that it's not a
real device but just a synonym to tell the kernel to use NFS instead of
a real device.
nfsroot=[<server-ip>:]<root-dir>[,<nfs-options>]
If the `nfsroot' parameter is NOT given on the command line,
the default "/tftpboot/%s" will be used.
<server-ip> Specifies the IP address of the NFS server.
The default address is determined by the `ip' parameter
(see below). This parameter allows the use of different
servers for IP autoconfiguration and NFS.
<root-dir> Name of the directory on the server to mount as root.
If there is a "%s" token in the string, it will be
replaced by the ASCII-representation of the client's
IP address.
<nfs-options> Standard NFS options. All options are separated by commas.
The following defaults are used:
port = as given by server portmap daemon
rsize = 4096
wsize = 4096
timeo = 7
retrans
= 3
acregmin
= 3
acregmax
= 60
acdirmin
= 30
acdirmax
= 60
flags = hard, nointr, noposix, cto, ac
ip=<client-ip>:<server-ip>:<gw-ip>:<netmask>:<hostname>:<device>:<autoconf>
This parameter tells the kernel how to configure IP addresses of devices
and also how to set up the IP routing table. It was originally called
`nfsaddrs', but now the boot-time IP configuration works independently of
NFS, so it was renamed to `ip' and the old name remained as an alias for
compatibility reasons.
If this parameter is missing from the kernel command line, all fields are
assumed to be empty, and the defaults mentioned below apply. In general
this means that the kernel tries to configure everything using
autoconfiguration.
The <autoconf> parameter can appear alone as the value to the `ip'
parameter (without all the ':' characters before) in which case auto-
configuration is used.
<client-ip> IP address of the client.
Default: Determined using autoconfiguration.
<server-ip> IP address of the NFS server. If RARP is used to determine
the client address and this parameter is NOT empty only
replies from the specified server are accepted.
Only required for for NFS root. That is autoconfiguration
will not be triggered if it is missing and NFS root is not
in operation.
Default: Determined using autoconfiguration.
The address of the autoconfiguration server is used.
<gw-ip> IP address of a gateway if the server is on a different subnet.
Default: Determined using autoconfiguration.
<netmask> Netmask for local network interface. If unspecified
the netmask is derived from the client IP address assuming
classful addressing.
Default: Determined using autoconfiguration.
<hostname> Name of the client. May be supplied by autoconfiguration,
but its absence will not trigger autoconfiguration.
Default: Client IP address is used in ASCII notation.
<device> Name of network device to use.
Default: If the host only has one device, it is used.
Otherwise the device is determined using
autoconfiguration. This is done by sending
autoconfiguration requests out of all devices,
and using the device that received the first reply.
<autoconf> Method to use for autoconfiguration. In the case of options
which specify multiple autoconfiguration protocols,
requests are sent using all protocols, and the first one
to reply is used.
set bootargs noinitrd root=/dev/nfs nfsroot=192.168.1.102:/nfsboot/tmp/fs_mini_mdev ip=192.168.1.108:192.168.1.102:192.168.1.1:255.255.255.0::eth0:off init=/linuxrc console=ttySAC0
在内核目录下有个nfsboot.txt文件
/work/linux-2.6.22.6/Documentation/nfsboot.txt
内容如下:
root=/dev/nfs
This is necessary to enable the pseudo-NFS-device. Note that it's not a
real device but just a synonym to tell the kernel to use NFS instead of
a real device.
nfsroot=[<server-ip>:]<root-dir>[,<nfs-options>]
If the `nfsroot' parameter is NOT given on the command line,
the default "/tftpboot/%s" will be used.
<server-ip> Specifies the IP address of the NFS server.
The default address is determined by the `ip' parameter
(see below). This parameter allows the use of different
servers for IP autoconfiguration and NFS.
<root-dir> Name of the directory on the server to mount as root.
If there is a "%s" token in the string, it will be
replaced by the ASCII-representation of the client's
IP address.
<nfs-options> Standard NFS options. All options are separated by commas.
The following defaults are used:
port = as given by server portmap daemon
rsize = 4096
wsize = 4096
timeo = 7
retrans
= 3
acregmin
= 3
acregmax
= 60
acdirmin
= 30
acdirmax
= 60
flags = hard, nointr, noposix, cto, ac
ip=<client-ip>:<server-ip>:<gw-ip>:<netmask>:<hostname>:<device>:<autoconf>
This parameter tells the kernel how to configure IP addresses of devices
and also how to set up the IP routing table. It was originally called
`nfsaddrs', but now the boot-time IP configuration works independently of
NFS, so it was renamed to `ip' and the old name remained as an alias for
compatibility reasons.
If this parameter is missing from the kernel command line, all fields are
assumed to be empty, and the defaults mentioned below apply. In general
this means that the kernel tries to configure everything using
autoconfiguration.
The <autoconf> parameter can appear alone as the value to the `ip'
parameter (without all the ':' characters before) in which case auto-
configuration is used.
<client-ip> IP address of the client.
Default: Determined using autoconfiguration.
<server-ip> IP address of the NFS server. If RARP is used to determine
the client address and this parameter is NOT empty only
replies from the specified server are accepted.
Only required for for NFS root. That is autoconfiguration
will not be triggered if it is missing and NFS root is not
in operation.
Default: Determined using autoconfiguration.
The address of the autoconfiguration server is used.
<gw-ip> IP address of a gateway if the server is on a different subnet.
Default: Determined using autoconfiguration.
<netmask> Netmask for local network interface. If unspecified
the netmask is derived from the client IP address assuming
classful addressing.
Default: Determined using autoconfiguration.
<hostname> Name of the client. May be supplied by autoconfiguration,
but its absence will not trigger autoconfiguration.
Default: Client IP address is used in ASCII notation.
<device> Name of network device to use.
Default: If the host only has one device, it is used.
Otherwise the device is determined using
autoconfiguration. This is done by sending
autoconfiguration requests out of all devices,
and using the device that received the first reply.
<autoconf> Method to use for autoconfiguration. In the case of options
which specify multiple autoconfiguration protocols,
requests are sent using all protocols, and the first one
to reply is used.
相关文章推荐
- JZ2440设置从开发板启动或使用NFS作为根文件系统启动
- 使用nfs作为根文件系统启动
- 使用nfs作为根文件系统启动遇到的问题
- zedboard使用nfs挂载根文件系统-linux内核启动参数bootargs详解
- S5PV210210使用网络文件系统nfs作为根文件系统
- 210支持nfs作为根文件系统启动
- 使用Initramfs或yaffs2作为根文件系统启动成功,但是Ramdisk作为根文件系统有问题
- 详解-使用nfs作为根文件系统启动,(3)
- 虚拟机通过把nfs作为根文件系统来启动mini2440开发板
- mini6410基于linux2.6.36内核通过NFS启动根文件系统总结(五 内核测试 四 通过NFS成功启动根文件系统)
- (转)使用Java Service Wrapper将java程序作为linux服务并且开机自动启动
- mini6410基于linux2.6.36内核通过NFS启动根文件系统总结(一搭建开发环境——安装交叉工具连)
- mini6410基于linux2.6.36内核通过NFS启动根文件系统总结(五内核测试 二 VFS: Cannot open root device "ubi0:FriendlyARM-root" )
- Tiny6410基于linux2.6.36内核通过NFS启动根文件系统总结(成功挂载nfs根文件系统)
- 使用友善之臂6410开发板NFS启动时打印乱码
- NFS作为根文件系统时server not responding问题的解决
- VirtualBox 使用 img 作为启动硬盘
- tiny6410基于SDBOOT通过NFS启动根文件系统
- mini6410基于linux2.6.36内核通过NFS启动根文件系统总结(五 内核测试 三 通过bootargs设置根文件系统的启动位置)
- mini6410基于linux2.6.36内核通过NFS启动根文件系统总结(三编译linux内核)