Назад | Перейти на главную страницу

Ошибка монтирования Samba на cifs

Клиент Debian, сервер Windows 2019.
Даже этот DNS разрешился нормально, я добавил орлиный глаз на / etc / hosts, также изменен /etc/samba.smb.conf, добавив:

   client min protocol = SMB2
   client max protocol = SMB3

Я могу просматривать общий ресурс с помощью smbclient:

#> smbclient  -V
Version 4.2.14-Debian

#> smbclient -L eagleeye -Uuuu%ppp -Wdom
Domain=[DOM] OS=[] Server=[]

        Sharename       Type      Comment
        ---------       ----      -------
        ADMIN$          Disk      Remote Admin
        C$              Disk      Default share
        IPC$            IPC       Remote IPC
        ...
        Repo            Disk

#> smbclient  //eagleeye/repo -Uusername%admin -Wdom
Domain=[DOM] OS=[] Server=[]
smb: \> ls
  .                                   D        0  Thu Aug  1 17:56:27 2019
  ..                                  D        0  Thu Aug  1 17:56:27 2019
  Autodiscover                        D        0  Fri Apr 20 13:30:00 2018
  gitupdate                           D        0  Tue Aug  6 22:45:33 2019
  SharedModules                       D        0  Tue Aug  6 22:47:17 2019
...
...
                26085631 blocks of size 4096. 8936156 blocks available
smb: \>

однако я не могу монтировать как долю как

mount -t cifs //eagleeye/repo ~/share
mount: wrong fs type, bad option, bad superblock on //eagleeye/repo,
       missing codepage or helper program, or other error
       (for several filesystems (e.g. nfs, cifs) you might
       need a /sbin/mount.<type> helper program)

       In some cases useful info is found in syslog - try
       dmesg | tail or so.

#> lsmod | grep cifs
cifs                  546304  0
dns_resolver           12641  1 cifs
fscache                45304  2 nfs,cifs

# adding vers=2.0
#> mount -t cifs -o vers=2.0 //eagleeye/repo ~/share
mount: wrong fs type, bad option, bad superblock on //eagleeye/repo,
       missing codepage or helper program, or other error
       (for several filesystems (e.g. nfs, cifs) you might
       need a /sbin/mount.<type> helper program)

       In some cases useful info is found in syslog - try
       dmesg | tail or so.

#> dmesg | tail -n10
...
[226622.680227] Key type dns_resolver registered
[226622.733361] FS-Cache: Netfs 'cifs' registered for caching
[226622.781716] Key type cifs.spnego registered
[226622.828384] Key type cifs.idmap registered
[226622.872472] Unable to determine destination address.

Не знаю о Debian, но на CentOS mount.cifsпо умолчанию использует SMB1, поэтому вы должны использовать vers возможность принудительно установить SMB2 / 3: mount -t cifs -o vers=2.0 //eagleeye/repo ~/share Другие возможные значения в CentOS: 2.1, 3.0.