Manpages

NAME

smbmount - 裝 載 一 個 smbfs 文 件 系 統

總 覽 SYNOPSIS

smbmount {service} {mount-point} [-o options]

描 述 DESCRIPTION

smbmount 可 以 裝 載 一 個 Linux SMB文 件 系 統 。 它 通 常 在 帶 "-t smbfs" 選 項 執 行 mount(8) 命 令 時 被 作 爲 mount.smbfs執 行 。 當 然 內 核 必 須 支 持 smbfs文 件 系 統 。

smbmount使 用 的 選 項 是 用 逗 號 分 隔 的 一 串 key=value字 串 對 的 列 表 。 It is possible to send options other than those listed here, assuming that smbfs supports them. If you get mount failures, check your kernel log for errors on unknown options.

smbmount is a daemon. After mounting it keeps running until the mounted smbfs is umounted. It will log things that happen when in daemon mode using the "machine name" smbmount, so typically this output will end up in log.smbmount. The smbmount process may also be called mount.smbfs. 注 意

smbmount 調 用 smbmnt(8)來 完 成 實 際 的 裝 載 任 務 。 你 必 須 確 保 smbmnt 位 於 可 以 找 到 的 路 徑 中 。

選 項 OPTIONS

username=<arg> 指 定 聯 接 時 的 用 戶 名 。 如 果 不 指 定 , 程 序 會 用 USER這 個 環 境 變 量 。 這 個 選 項 也 接 受 "user%password", "user/workgroup"或 "user/workgroup%password"形 式 的 參 數 , 允 許 密 碼 和 工 作 組 作 爲 用 戶 名 的 一 部 分 同 時 被 指 定 。
password=<arg> 指 定 SMB口 令 。 如 果 不 指 定 , 將 使 用 環 境 變 量 PASSWD. 如 果 沒 有 指 定 , 也 沒 有 環 境 變 量 , smbmount會 提 示 輸 入 口 令 , 除 非 使 用 了 guest選 項 。

Note that passwords which contain the argument delimiter character (i.e. a comma ’,’) will failed to be parsed correctly on the command line. However, the same password defined in the PASSWD environment variable or a credentials file (see below) will be read correctly.

credentials=<filename>

specifies a file that contains a username and/or password. The format of the file is:

username = <value>
password = <value>

This is preferred over having passwords in plaintext in a shared file, such as /etc/fstab. Be sure to protect any credentials file properly.

krb

Use kerberos (Active Directory).

netbiosname=<arg> 設 定 源 NetBIOS主 機 名 。 默 認 是 本 機 名 。
uid=<arg> 設 定 裝 載 的 文 件 系 統 的 用 戶 標 識 符 。 可 以 用 用 戶 名 或 者 UID數 字 兩 種 辦 法 來 指 定 。
gid=<arg> 設 定 裝 載 的 文 件 系 統 的 組 標 識 符 。 可 以 用 組 名 或 者 GID數 字 兩 種 方 法 來 指 定 。
port=<arg> 設 定 遠 程 SMB系 統 的 端 口 號 。 默 認 是 139。
fmask=<arg> 設 定 文 件 掩 碼 。 這 決 定 了 本 地 文 件 系 統 中 遠 程 文 件 的 權 限 。 它 不 是 掩 碼 而 是 實 際 的 文 件 權 限 。 默 認 值 是 根 據 當 前 的 umask算 出 來 的 。
dmask=<arg> 設 定 目 錄 掩 碼 。 這 決 定 了 本 地 文 件 系 統 中 遠 程 目 錄 的 權 限 。 它 不 是 掩 碼 而 是 實 際 的 目 錄 權 限 。 默 認 值 是 根 據 當 前 的 umask算 出 來 的 。
debug=<arg> 設 定 調 試 等 級 。 對 於 跟 蹤 SMB的 聯 接 問 題 非 常 有 用 。 建 議 的 值 是 4. 如 果 設 置 得 過 高 , 會 產 生 大 量 輸 出 , 可 能 會 掩 蓋 有 用 的 輸 出 。
ip=<arg> 設 定 目 標 主 機 或 IP地 址 。
workgroup=<arg> 設 定 目 的 工 作 組 。
sockopt=<arg> 設 定 TCP套 接 字 的 一 些 選 項 。 參 見 smb.conf(5)配 置 文 件 中 的 socket options選 項 。
scope=<arg> 設 定 NetBIOS範 圍 。

guest 不 提 示 口 令

ro 以 只 讀 方 式 裝 載 。

rw 以 讀 寫 方 式 裝 載 。

iocharset=<arg>

sets the charset used by the Linux side for codepage to charset translations (NLS). Argument should be the name of a charset, like iso8859-1. (Note: only kernel 2.4.0 or later)

codepage=<arg>

sets the codepage the server uses. See the iocharset option. Example value cp850. (Note: only kernel 2.4.0 or later)

ttl=<arg>

sets how long a directory listing is cached in milliseconds (also affects visibility of file size and date changes). A higher value means that changes on the server take longer to be noticed but it can give better performance on large directories, especially over long distances. Default is 1000ms but something like 10000ms (10 seconds) is probably more reasonable in many cases. (Note: only kernel 2.4.2 or later)

ENVIRONMENT VARIABLES

The variable USER may contain the username of the person using the client. This information is used only if the protocol level is high enough to support session-level passwords. The variable can be used to set both username and password by using the format username%password.

The variable PASSWD may contain the password of the person using the client. This information is used only if the protocol level is high enough to support session-level passwords.

The variable PASSWD_FILE may contain the pathname of a file to read the password from. A single line of input is read and used as the password.

BUGS

Passwords and other options containing , can not be handled. For passwords an alternative way of passing them is in a credentials file or in the PASSWD environment.

The credentials file does not handle usernames or passwords with leading space.

One smbfs bug is important enough to mention here, even if it is a bit misplaced:

Mounts sometimes stop working. This is usually caused by smbmount terminating. Since smbfs needs smbmount to reconnect when the server disconnects, the mount will eventually go dead. An umount/mount normally fixes this. At least 2 ways to trigger this bug are known.

Note that the typical response to a bug report is suggestion to try the latest version first. So please try doing that first, and always include which versions you use of relevant software when reporting bugs (minimum: samba, kernel, distribution)

SEE ALSO

Documentation/filesystems/smbfs.txt in the linux kernel source tree may contain additional options and information.

FreeBSD also has a smbfs, but it is not related to smbmount

For Solaris, HP-UX and others you may want to look at smbsh(1) or at other solutions, such as Sharity or perhaps replacing the SMB server with a NFS server.

作 者 AUTHOR

samba軟 件 和 相 關 工 具 最 初 由 Andrew Tridgell創 建 。 samba現 在 由 Samba Team 作 爲 開 源 軟 件 來 發 展 , 類 似 linux內 核 的 開 發 方 式 。 最 初 的 samba手 冊 頁 是 Karl Auer寫 的 。 手 冊 頁 源 碼 已 經 轉 換 爲 YODL格 式 (另 一 種 很 好 的 開 源 軟 件 , 可 以 在 ftp://ftp.ice.rug.nl/pub/unix找; 到 ), 由 Jeremy Sllison 更 新 到 Samba2.0 版 本 。 Gerald Carter 在 Samba2.2中 將 它 轉 化 爲 DocBook 格 式 。 Alexander Bokovoy 在 Samba 3.0中 實 現 了 DocBook XML4.2 格 式 的 轉 換 。

[中 文 版 維 護 人 ]

meaculpa <meaculpa [AT] 21cn.com>

[中 文 版 最 新 更 新 ]

2000/12/08

《 中 國 linux論 壇 man手 冊 頁 翻 譯 計 劃 》 :

http://cmpp.linuxforum.net 本 頁 面 中 文 版 由 中 文 man 手 冊 頁 計 劃 提 供 。 中 文 man 手 冊 頁 計 劃 : https://github.com/man-pages-zh/manpages-zh