python
from base_config.config import OpenSMB, SMB
import os, time, calendar, requests, decimal, platform, fs.smbfs
info_dict = SMB.EPDI_dict
info_dict['host'] = ('FS03','10.6.12.182')
info_dict['direct_tcp'] = True
# smb = OpenSMB(info_dict)
print('ok')
# 根据 ip 查询电脑名
import nmb.NetBIOS
nb = nmb.NetBIOS.NetBIOS()
response = nb.queryIPForName("10.167.51.166") # with you IP here obviously
print(response)
python
import fs.smbfs
my_fs = fs.smbfs.SMBFS(("<HOSTNAME>", "<IP>"), ...)