大网数据广告活动
服务器运维问答

samba share in /etc/fstab is ignored during mount -a but manual mount works

· 52CE 我爱测

It's one of these problems I'm running into every time that I set up a server :-( I have an Ubuntu server 16.04 and would like to auto-mount a samba share. In my /etc/fstab I have the entry: //10.10.2.2/share /media/share cifs de…

问题原文

原帖链接 · DerNils · CC BY-SA 3.0

It's one of these problems I'm running into every time that I set up a server :-(
I have an Ubuntu server 16.04 and would like to auto-mount a samba share.

In my /etc/fstab I have the entry:

//10.10.2.2/share    /media/share    cifs    defaults,_netdev,noauto,nofail,username=user,passwd=pass    0    0

When I execute

sudo mount -a 

I get no error message but the share is not mounted :-(

The most interesting part however is that if I do a

sudo mount /media/share

The share is mounted

I had various problems with samba before but this behavior is new for me. Does anybody have an idea how to address this issue?

已采纳解答

原帖链接 · Gerald Schneider · CC BY-SA 3.0

That's normal behaviour if you set noauto. From man mount:

noauto Can only be mounted explicitly (i.e., the -a option will not cause the filesystem to be mounted).

摘自公开归档,保留原文语言,版式经整理,外部媒体与邮箱地址已移除。

资料来源与适用范围

资料来源
Server Fault
适用范围
以原帖系统、软件版本与发布日期为准(2017-11-10)
内容语言
中文;命令、路径和错误标识保留技术原文
本地收录日期
2026-11-15
授权说明
CC BY-SA 3.0

正文与所需资源由本站本地存储。查看来源及更新记录 ↗

请按适用版本和实际日志确认原因;本站没有对每一种系统或设备逐项执行文中的操作。