w2k19srv windows sunucusunun paylasimindaki bolumu /w2k19srv/sharedfs olarak kullanilmasi;
0. yum -y install cifs-utils autofs
1. # cat /etc/auto.master.d/sharedfs.autofs
/w2k19srv /etc/sharedfs.autofs
sharedfs -fstype=cifs,credentials=/etc/samba/smb.creds,multiuser,sec=ntlmssp,vers=3.0 ://w2k19srv.ms.lan/sharedfs
3. # cat /etc/samba/smb.creds
username=varsayilan-kullanici
password=parola
domain=ms.lan
4. $ cifscreds add -u remzi -d ms.lan w2k19srv.ms.lan
[remzi@ms.lan@centos7 ~]$ cd /w2k19srv/sharedfs
[remzi@ms.lan@centos7 sharedfs]$ ls
ls: reading directory .: Permission denied
[remzi@ms.lan@centos7 sharedfs]$ cifscreds add -u remzi -d ms.lan w2k19srv.ms.lan
Password:
[remzi@ms.lan@centos7 sharedfs]$ ls -al
total 5
drwxr-xr-x. 2 remzi@ms.lan domain users@ms.lan 4096 Feb 20 01:12 .
drwxr-xr-x. 3 root root 0 Feb 20 01:10 ..
-rwxr-xr-x. 1 remzi@ms.lan domain users@ms.lan 8 Feb 20 01:12 testfile.txt
[remzi@ms.lan@centos7 sharedfs]$ echo Merhaba Dunyali >> testfile.txt
[remzi@ms.lan@centos7 sharedfs]$ cat testfile.txt
MErhaba
Merhaba Dunyali
Yorumlar
Yorum Gönder