㈠ linux如何挂载samba目录
1、utf-8替换成utf8试试
2、其他方法
i)如果已经安装samba,可用smbmount
例:smbmount //192.168.1.1/share /mnt
-o username=user,password=pw,iocharset=utf8,codepage=cp936
ii)mount.cifs等效于mount -t cifs,mount.cifs需要内核支持,使用时比较方便。
例:mount.cifs //192.168.1.1/somedir dir -o username=xx,password=xxxx
iii)mount.smbfs需要注意中文目录,需要加上 参数 codepage=cp936,iocharset=utf8,而且有的系统下挂载速度迟钝。等效于smbmount或 mount -t smbfs
例:mount.smbfs //192.168.1.1/somedir dir -o username=xx,password=xxxx
iv)smbclient登录后操作类似于ftp登录
例:smbclient //192.168.1.1/d -U username%password
㈡ 如何解决linux mount cifs 挂window 网盘问题
在centos mount cifs 挂window 网盘容易出现问题如下:
一、挂载时,用户/密码错误
mounterror(13):Permissiondenied
Refertothemount.cifs(8)manualpage(e.g.manmount.cifs)
对应/var/log/message记录
Oct1216:20:01localhostkernel:_STATUS_LOGON_FAILURE
Oct1216:20:01localhostkernel:CIFSVFS:SenderrorinSessSetup=-13
Oct1216:20:01localhostkernel:CIFSVFS:cifs_mountfailedw/returncode=-13
二、没有分享目录
mounterror(6):Nosuchdeviceoraddress
Refertothemount.cifs(8)manualpage(e.g.manmount.cifs)
对应/var/log/message记录
Oct1216:20:06localhostkernel:CIFSVFS:cifs_mountfailedw/returncode=-6
Oct1216:20:17localhostkernel:CIFSVFS:cifs_mountfailedw/returncode=-6
Oct1216:20:17localhostkernel:CIFSVFS:cifs_mountfailedw/returncode=-6
目前遇到的问题就是这些
补充一句,格式一定要写正确:
mount-tcifs-ousername=administrator,password=****//192.168.1.1/分享目录/linux/share
㈢ 如何解决linux mount cifs 挂window 网盘问题
在centos mount cifs 挂window 网盘容易出现问题如下:
一、挂载时,用户/密码错误
mount error(13): Permission denied
Refer to the mount.cifs(8) manual page (e.g. man mount.cifs)
对应/var/log/message记录
Oct 12 16:20:01 localhost kernel: Status code returned 0xc000006d NT_STATUS_LOGON_FAILURE
Oct 12 16:20:01 localhost kernel: CIFS VFS: Send error in SessSetup = -13
Oct 12 16:20:01 localhost kernel: CIFS VFS: cifs_mount failed w/return code = -13
二、没有分享目录
Retrying with upper case share name
mount error(6): No such device or address
Refer to the mount.cifs(8) manual page (e.g. man mount.cifs)
对应/var/log/message记录
Oct 12 16:20:06 localhost kernel: CIFS VFS: cifs_mount failed w/return code = -6
Oct 12 16:20:17 localhost kernel: CIFS VFS: cifs_mount failed w/return code = -6
Oct 12 16:20:17 localhost kernel: CIFS VFS: cifs_mount failed w/return code = -6
目前遇到的问题就是这些
补充一句,格式一定要写正确:
mount -t cifs -o username=administrator,password=**** //192.168.1.1/分享目录 /linux/share
㈣ 关于linux挂载nas网络存储
NAS 的中文名称是网络附加存储,是基于硬盘的专业存储技术。它可以直接接入计算机网络,为各种操作系统的客户端提供集中式的数据存取服务。
NAS支持NFS协议,Linux操作系统也是支持NFS协议的,可以直接在Linux里面挂载NAS共享出来的NFS目录,把数据直接拷贝到NAS上。
比如NAS服务器的地址是10.0.0.111,在Linux上:
# mount 10.0.0.111:/sharefolder /mnt
# cp -r /des /mnt
㈤ linux 查看能不能挂载cifs
Linux挂载共享文件就是把远程机器的文件挂载到本地进行使用,它可以分为windows共享挂载和linux共享挂载;1、windows共享挂载命令举例 mount -t cifs -o username=name,password=password //ip/remote_share_path /local_path
2、linux共享挂载nfs举例 mount -t nfs -o rw ip:/remote_path /localpath
上述nfs是共享文件类型,在linux下其包括samba,nfs,ftp三种。
㈥ Linux上挂载windows共享目录
笔者最近经常需要在windows和树莓派之前来回拷贝文件,最开始是使用U盘,然后使用VNC自带的文件传输工具,支持来回传输文件。也有一些SSH工具支持传递文件,但是频繁拷贝来说确实繁琐了些。windows的开发平台和工具用起来更加的和谐友好,比如写php文件,笔者一般在windows写好再上传到服务器,传递也很耗时间。最近闲逛才知道可以linux可以挂载windows共享目录,孤陋寡闻的认为只能挂载硬盘、U盘等。那我们开始吧。
1、在linux下要挂载windows的共享文件,需要安装cifs-utils软件包。
dpkg -l|grep cifs-utils可以查看是否安装了这个软件包,which mount.cifs可以查看这个软件包安装在哪里。sudo apt-get install cifs-utils可以安装软件包。
2、建立一个目录用来作挂载点。
笔者准备将共享目录挂载在mnt目录下,在mnt目录下建立share目录,sudo mkdir share 。
3、window共享share文件夹
文件夹上右键属性,设置共享属性。
4、挂载操作
sudo mount -t cifs -o username=Administrator,password=123456 //192.168.31.33/share /mnt/share。
192.168.31.33为windows的IP地址,Administrator为windows的用户名,123456为用户密码。在测试时,笔者不会不设置密码会出现告警,“mount error(13): Permission denied;Refer to the mount.cifs(8) manual page (e.g. man mount.cifs)“,设置windows的用户名密码后才能挂载成功。还有注意用户名Administrator第一个字母有可能是是大写的,所以一定要对应好用户名。
5、测试大功告成
在windows新建修改文件,在linux可以自由查看,修改就需要root权限了。
6、取消挂载
sudo umount /mnt/share 。当然,重启linux后挂载自动会取消。需要重新挂载。
7、脚本控制来挂载共享文件夹
为了方便起见,在开启linux后需要重新挂载共享文件夹,这一串命令可要让人头疼了,那么脚本来帮助!执行效果如下。如果挂载路径不一样,可要修改脚本用参数定位到新路径,那笔者就不尝试了。$? 执行上一个指令的返回值 ,显示最后命令的退出状态。0表示没有错误,其他任何值表明有错误。
欢迎取用:
㈦ 系统之家Linux中挂载windows共享文件的详细步骤怎么办
方法/步骤mount -t cifc "windows共享文件夹" "Linux /mnt路径"
i.e. mount -t cifs //16.187.190.60/test /mnt/
Linux 会要求输入访问Windows 共享文件夹上的密码。
注意:
Linux中提示:
Unable to find suitable address.
说明远程共享文件夹路径不存在。请仔细检查,并更正目录路径。
mount -t cifc "windows共享文件夹" "Linux /mnt路径"
i.e. mount -t cifs //16.187.190.50/test /mnt/
注意:
Linux中提示:
mount error(13): Permission denied
Refer to the mount.cifs(8) manual page (e.g. man mount.cifs)
解决方案:将访问Windows共享目录的用户名和密码直接加入到命令中。
mount -t cifs -o username=WindowsLogin,password="passwordinWindows"
//16.187.190.50/test /mnt/
注意:该命令中,username为windows上的用户;password为window用户对应的密码
步骤3的命令也可以使用以下方式实现:
mount.cifs -o username="Administrator",password="PasswordForWindows" //16.187.190.50/test /mnt/
通过步骤3和步骤4可以成功将windows共享文件夹挂载在/mnt目录下。不过由于mount命令只能由root权限用户使用。其挂载文件夹的默认owner和group都为root,并且不能通过chmod命令更改权限。
使用mount命令,给挂载共享文件夹指定owner和group.
mount.cifs -o username="Administrator",password="PasswordForWindows",uid=Mysa,gid=Mysa //16.187.190.50/test /mnt/
检查/mnt/中文件夹的owner和group。
更改文件夹权限。给mount共享文件夹所在组的写权限。