Package: cifs-utils
Version: 2:6.7-1
Owner: d...@genunix.com

The following demonstrates that a read only mount is requested : 

deb9# USER="validusername"
deb9# export USER

deb9# PASSWD="validuserpassword"
deb9# export PASSWD

deb9# SERVERNAME="WIN2012R2BOX"
deb9# export SERVERNAME

deb9# CLIENTNAME="SOMEBOX"
deb9# export CLIENTNAME

deb9# SERVERIP="192.168.1.5"
deb9# export SERVERIP

deb9# DOMAINAME="WINDOMAIN"
deb9# export DOMAINAME

deb9# mount.cifs //$SERVERNAME/G\$ /backup/foo/G \
> --verbose -o
> username=$USER,password=$PASSWD,uid=0,gid=0,servernetbiosname=$SERVERNAME,netbiosname=$CLIENTNAME,ip=$SERVERIP,domain=$DOMAINAME,ro,cache=strict,sec=ntlmssp,serverino,rsize=32768,wsize=65536
deb9#


deb9# mount -v | grep cifs
//WIN2012R2BOX/G$ on /backup/foo/G type cifs
(rw,relatime,vers=1.0,cache=strict,username=validusername,domain=WINDOMAIN,uid=0,noforceuid,gid=0,noforcegid,addr=192.168.1.5,file_mode=0755,dir_mode=0755,nounix,serverino,mapposix,rsize=61440,wsize=16580,echo_interval=60,actimeo=1)
deb9#

deb9# touch /backup/foo/G/test
deb9# ls -la /backup/foo/G/test
-rwxr-xr-x 1 root root 0 Mar 31 19:48 /backup/foo/G/test
deb9# rm /backup/foo/G/test

Clearly this is a read write mount when "ro" was requested. 

Reply via email to