On Fri, Mar 06, 2015 at 08:14:19AM GMT, Zhi-Qiang Lei wrote:

> Now it is weird that it is read only. According to exports manual, it should
> be read / write as default:
> 
>      The -ro option specifies that the filesystem should be exported
> read-only
>      (default read/write).  The option -o is a synonym for -ro in an effort
> to
>      be backward compatible with older export file formats.
> 
> My exports doesn???t contain a -ro.
> 
> # cat /etc/exports
> /nfs -mapall=nfs -alldirs -network=192.168.1 -mask=255.255.255.0
> 
> I cannot write even on the server (192.168.1.1):
> 
> # mount -t nfs -o rw 192.168.1.1:/nfs /mnt
> # df -h
> Filesystem          Size    Used   Avail Capacity  Mounted on
> /dev/wd0a           3.9G   52.3M    3.7G     1%    /
> /dev/wd0k           9.9G    4.0K    9.4G     0%    /home
> /dev/wd0l           1.7T    8.0K    1.6T     0%    /nfs
> /dev/wd0d           3.9G    4.0K    3.7G     0%    /tmp
> /dev/wd0f           9.8G    310M    9.0G     3%    /usr
> /dev/wd0g           3.9G    2.0K    3.7G     0%    /usr/X11R6
> /dev/wd0h           9.8G    216K    9.3G     0%    /usr/local
> /dev/wd0j           9.8G    2.0K    9.3G     0%    /usr/obj
> /dev/wd0i           9.8G    2.0K    9.3G     0%    /usr/src
> /dev/wd0e           9.8G    5.4M    9.3G     0%    /var
> 192.168.1.1:/nfs    1.7T    8.0K    1.6T     0%    /mnt
> # touch /mnt/h.txt
> touch: /mnt/h.txt: Permission denied

Looks like permissions issue. Does the user have write permissions to
the NFS-exported filesystem? Please run:

id

and, after making sure the export is mounted:

ls -n /mnt

Raf

Reply via email to