other languages
NMBD(8) | NMBD(8) |
NAME¶
nmbd - 向客戶端提供構造在IP之上的NetBIOS名字服務的NetBIOS名字伺服器總覽 SYNOPSIS¶
nmbd [-D] [-F] [-S] [-a] [-i] [-o] [-h] [-V][-d <debug level>] [-H <lmhosts file>] [-l <log directory>][-n <primary netbios name>] [-p <port number>] [-s <configuration file>]描述 DESCRIPTION¶
此程式是 Samba(7) 套件的一部分。 nmbd 是一個回應構造於IP之上的NetBIOS名字服務請求的伺服器,這些請求由SMBD/CIFS 客戶(如Windows 95/98、NT和LanManager客戶)產生。當然它也參與構造Windows的"網 絡鄰居」查看的瀏覽協議。 當SMB/CIFS客戶機啟動時,會試圖查找一個SMB/CIFS伺服器。說得更精確些就是它們要知道 正在使用的主機對應的IP地址。 在其它的服務中, nmbd 將監聽這樣的請求,如果客戶自身的NetBIOS名字已被指定的話就用正 在運行的主機IP地址回復它。這個「自身的NetBIOS名字」在預設情況下將是正在運行的主機在 DNS中的名字,但可以用 -n 參數(查看後面關於OPTIONS的描述)越過它。從而 nmbd 將用它自已的名字來回應廣播查詢。要讓 nmbd 回應額外名字的話可以在 smb.conf(5)配置檔案中通過參數來設定。 nmbd 也可用作一個WINS(Windows網際網路名稱服務)伺服器。它作為WINS數據庫伺服器運作時,用名字注冊請求來建立一個數據庫以接收和回應客戶對這些名字的查詢。 另外, nmbd 也可以作WINS代理,轉發使用者不能直接以WINS協議和WINS伺服器交談的廣播查詢。選項 OPTIONS¶
- -D
- 如果指定這個參數的話,將使 nmbd 作為一個背景守護程式運行。這樣,它分配本身的進程在背景運行,並監視適當的端口請求。在預設情況下, nmbd 通常以命令行方式啟動,背景運行。 nmbd 也能通過inetd 這個超級守護程式來啟動,但不推薦這樣做。
- -F
- If specified, this parameter causes the main nmbd process to not daemonize, i.e. double-fork and disassociate with the terminal. Child processes are still created as normal to service each connection request, but the main process does not exit. This operation mode is suitable for running nmbd under process supervisors such as supervise and svscan from Daniel J. Bernstein's daemontools package, or the AIX process monitor.
- -S
- If specified, this parameter causes nmbd to log to standard output rather than a file.
- -i
- If this parameter is specified it causes the server to run "interactively", not as a daemon, even if the server is executed on the command line of a shell. Setting this parameter negates the implicit daemon mode when run from the command line. nmbd also logs to standard output, as if the -S parameter had been given.
- -h|--help
- Print a summary of command line options.
- -H <filename>
- 指定NetBIOS的lmhosts檔案。
NetBIOS的lmhosts檔案是一份NetBIOS名字到IP地址對應關系的列表,
nmbd伺服器將會通過在
smb.conf (5)檔案中 name resolve
order描述的名字解析機制來裝入和使用這個檔案,以便讓伺服器解析可能的NetBIOS名字查詢。注意到nmbd並
不用這個檔案的內容來回答可能的名字查詢。在這個檔案中添加內容只會影響本電腦的NetBIOS名字解析。
這個檔案的預設存放路徑已被作為編譯處理的一部分加入到samba中了。通常預設路徑是
/usr/local/samba/lib/lmhosts, /usr/samba/lib/lmhosts 或是 /etc/samba/lmhosts。 在lmhosts (5)手冊頁中查找描述此檔案的詳細內容。
- -V
- 列印出nmbd的版本信息。
- -s <configuration file>
- The file specified contains the configuration details required by the server. The information in this file includes server-specific information such as what printcap file to use, as well as descriptions of all the services that the server is to provide. See smb.conf for more information. The default configuration file name is determined at compile time.
- -d|--debug=debuglevel
- debuglevel 是一個從0到10的整數。如果沒有指定此參數則預設的值是0。 如果這個值越高,越多關於伺服器的詳細活動信息將被記錄到檔案中。在0調試級時,只記錄緊急錯誤 和嚴重警告。對於日以即日地運行服務,1調試級是個合理的等級,它只產生一定數量的關於執行操作 的信息。 1以上的調試級將產生相當多的記錄數據,並且只在研究問題時才有用。3以上的調試級只被設計為讓開 發者使用並會產生極大數量的記錄數據,而且其中很多部分非常難以理解。 注意在此使用這個參數將越過在 smb.conf 檔案中的log level 參數。
- -l|--logfile=logbasename
- 用參數-l可以指定一個帶路徑的檔名作為記錄檔案,並會在你給出的名稱後自動加上 ".client"的擴展名。The log file is never removed by the client.
- -p <UDP port number>
- UDP端口號是一個正整數。 這個選項來改變 nmbd響應查詢的預設UDP端口號(通常它是 137) 。除非你是位這方面的專家,否則請不要用這個選項改變它。
檔案 FILES¶
- /etc/inetd.conf
- 如果你用 inetd 這個超級守護程式來運行nmbd伺服器,那麼必須在這個檔案中包含適當的啟動參數和信息。
- /etc/rc
- (也可以是你的系統所用的其它初始化稿本) 如果將nmbd當作服務,在啟動時運行,這個檔案必須包含合適的服務啟動順序。
- /etc/services
- If running the server via the meta-daemon inetd, this file must contain a mapping of service name (e.g., netbios-ssn) to service port (e.g., 139) and protocol type (e.g., tcp).
- /usr/local/samba/lib/smb.conf
- 這是伺服器配置檔案 smb.conf(5) 預設的存放位置。 系統安裝配置檔案通常的一些其它位置也可能是 /usr/samba/lib/smb.conf 和 /etc/samba/smb.conf。 當nmbd被用作WINS伺服器時(參見 smb.conf(5) 手冊頁中對 wins support 參數的描述), nmbd 將會把WINS數據庫檔案 wins.dat寫到 var/locks 目錄下。 如果 nmbd 作為 主瀏覽器 (參見 smb.conf (5)手冊頁中對 local master參數的描述), nmbd將會把瀏覽數據庫 browse.dat 寫到var/locks目錄下。