samb liunx和windows共享设置

mb 文件共享设置,红色字体解决samba无法访问软连接的问题

1)scp /home/daisy/full.tar.gz root@172.19.2.75:/home/root
2)创建dbstar账号
useradd dbstar
passwd dbstar
3)添加smb虚拟用户
smbpasswd  -a dbstar     //这里smb的共享密码可以设置成与dbstar用户CRT登陆密码不一样
4)修改:/etc/fstab
//10.251.3.32/mnt/sdb1 /mnt/sdb1 cifs defaults,username=dbstar,password=dbstar 0 0 
#0 0代表不做开机自检
然后mount -a  使生效
5)软连接
ln -s /mnt/sdb2/contentEncrypt pushfile    //如果名称没要求,不需要特意输入名称;这样软连接名称是一样的;
vim /etc/samba/smb.conf             //在全局变量里添加加粗的字

[global]
        follow symlinks = yes
        wide links = yes
        unix extensions = no
举例:
[global]
        workgroup = WORKGROUP
        passdb backend = tdbsam
        printing = cups
        printcap name = cups
        printcap cache time = 750
        cups options = raw
        map to guest = Bad User
        include = /etc/samba/dhcp.conf
        logon path = \\%L\profiles\.msprofile
        logon home = \\%L\%U\.9xprofile
        logon drive = P:
        usershare allow guests = Yes
        follow symlinks = yes
        wide links = yes
        unix extensions = no

[profiles]
        comment = Network Profiles Service
        path = %H
        read only = No
        store dos attributes = Yes
        create mask = 0600
        directory mask = 0700

[dbstar]
        comment = sdb1 
        path = /
        browseable = yes
        writable = yes
        #guest ok = yes
        valid users = dbstar
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 4
    评论
评论 4
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值