Why would NFS-mounted rootfs be "read-only"?

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 
已解决

Why would NFS-mounted rootfs be "read-only"?

跳至解决方案
7,741 次查看
EdSutter
Senior Contributor II

I have been in the process of reworking the SABRESD linux to run on our custom hardware.

I have been primarily runing with my rootfs NFS-mounted and that has been fine.

Something has changed that has caused my board to boot up with rootfs now read-only.

I have no idea what caused this to change.

My /etc/exports file entry for this is:

/Full_path_to_my_rootfs_directory/my_rootfs *(rw,no_root_squash)

I've run exportfs -a, and my kernel command line is:

console=ttymxc0,115200 ip=dhcp root=/dev/nfs nfsroot=${serverip}:/Full_path_to_my_rootfs_directory/my_rootfs,v3,tcp

Then at bootup, I see this message:

VFS: Mounted root (nfs filesystem) readonly on device 0:11.

I am able to log in however, everything is readonly.

This used to work.

Same server, same client, nothing obvious (related to NFS) has changed.

Any idea what might cause this?

标签 (2)
0 项奖励
回复
1 解答
2,906 次查看
EdSutter
Senior Contributor II

Got the answer at linuxquestions.org...

Apparently my previous kernel defaulted to a read/write mode for nfs-mounted rootfs,

but this kernel does not.  Adding "rw" to my kernel command line fixed this.

So the full command line is:

console=ttymxc0,115200 ip=dhcp root=/dev/nfs nfsroot=${serverip}:/Full_path_to_my_rootfs_directory/my_rootfs,v3,tcp rw

在原帖中查看解决方案

1 回复
2,907 次查看
EdSutter
Senior Contributor II

Got the answer at linuxquestions.org...

Apparently my previous kernel defaulted to a read/write mode for nfs-mounted rootfs,

but this kernel does not.  Adding "rw" to my kernel command line fixed this.

So the full command line is:

console=ttymxc0,115200 ip=dhcp root=/dev/nfs nfsroot=${serverip}:/Full_path_to_my_rootfs_directory/my_rootfs,v3,tcp rw