创建文件提示
root@hap1:/test>mkdir kk mkdir: 无法创建目录"kk": 只读文件系统 root@hap1:/test>mount ..... mqueue on /dev/mqueue type mqueue (rw,relatime) debugfs on /sys/kernel/debug type debugfs (rw,relatime) hugetlbfs on /dev/hugepages type hugetlbfs (rw,relatime) sunrpc on /var/lib/nfs/rpc_pipefs type rpc_pipefs (rw,relatime) nfsd on /proc/fs/nfsd type nfsd (rw,relatime) /dev/sdb1 on /test type ext4 (ro,relatime,data=ordered) /dev/sda1 on /boot type xfs (rw,relatime,attr2,inode64,noquota) tmpfs on /run/user/1000 type tmpfs (rw,nosuid,nodev,relatime,size=1625328k,mode=700,uid=1000,gid=1000) root@hap1:/test>cat /proc/mounts ... mqueue /dev/mqueue mqueue rw,relatime 0 0 debugfs /sys/kernel/debug debugfs rw,relatime 0 0 hugetlbfs /dev/hugepages hugetlbfs rw,relatime 0 0 sunrpc /var/lib/nfs/rpc_pipefs rpc_pipefs rw,relatime 0 0 nfsd /proc/fs/nfsd nfsd rw,relatime 0 0 /dev/sdb1 /test ext4 ro,relatime,data=ordered 0 0 /dev/sda1 /boot xfs rw,relatime,attr2,inode64,noquota 0 0 tmpfs /run/user/1000 tmpfs rw,nosuid,nodev,relatime,size=1625328k,mode=700,uid=1000,gid=1000 0 0
解决办法
使用 mount –o remount,rw /test 命令可以将文件系统修改为读写属性,然后就可以随意修改了!