匿名使用者
匿名使用者 發問時間: 電腦與網際網路其他:電腦 · 1 0 年前

為何windows存取Linux一直說名稱在網路上重復呢??

我的smb.conf檔設這樣

[global]

# workgroup = NT-Domain-Name or Workgroup-Name

workgroup = workgroup

# server string is the equivalent of the NT Description field

server string = Linux

# This option is important for security. It allows you to restrict

# connections to machines which are on your local network. The

# following example restricts access to two C class networks and

# the "loopback" interface. For more examples of the syntax see

# the smb.conf man page

hosts allow = 192.168.50.5 192.168.50.6 127.

# if you want to automatically load your printer list rather

# than setting them up individually then you'll need this

printcap name = /etc/printcap

load printers = yes

# Put a capping on the size of the log files (in Kb).

max log size = 50

# Security mode. Most people will want user level security. See

# security_level.txt for details.

security = share

# Use password server option only with security = share

; password server = <NT-Server-Name>

[homes]

comment = Home Directories

browseable = no

writeable = yes

# Un-comment the following and create the netlogon directory for Domain Logons

; [netlogon]

# Un-comment the following to provide a specific roving profile share

# the default is to use the user's home directory

;[Profiles]

# NOTE: If you have a BSD-style print system there is no need to

# specifically define each individual printer

[printers]

comment = All Printers

path = /var/spool/samba

browseable = no

# Set public = yes to allow user 'guest account' to print

printable = yes

# This one is useful for people to share files

[tmp]

comment = Temporary file space

path = /tmp

writeable = yes

guest ok = yes

;[public]

;[fredsprn]

;[fredsdir]

;[pchome]

;[public]

/etc/smb/lmhosts沒有設定

/etc/hosts也沒設定

但是我可以從Linux連到WIN2000和WINXP分享的資料夾,卻不能從windows連到Linux.

請麻煩大家幫我解答

就算不確定的答案也回答,因為我想試成功

已更新項目:

不過只有一張網路卡而已捏..

2 個已更新項目:

在網路上的芳鄰多出來一台電腦Linuxsmb,我的Localhost也還在,但是Linuxsmb點擊之後說:找不到網路路徑,而Lcalhost點擊之後說:網路上名稱重複

3 個已更新項目:

我/etc/hosts設定內容

原本是127.0.0.1 localhost.localdomain localhost

後來改127.0.0.1 king.localdomain

結果win2000 有顯示king的電腦,但是他說找不到路徑

在改192.168.50.3(Linux的電腦IP) localhost.localdomain localhost

win2000顯示Localhost也是說名稱重複

請問前面IP代表什麼意思

而localdomain前面的localhost好像是代表主機名稱

但localdomain後面的localhost 我就不知道了

1 個解答

評分
  • 1 0 年前
    最佳解答

    請先檢查一下您的 Linux 中是否設定兩張網卡並且接在同一個 HUB 或實體網路區段中, 是的話, 會出現名稱已被使用是正常的,要嘛就停掉一張網卡,要嘛就分開接在不同的 HUB 或實體網路區段中就可以了.其它的設定方面,請參考鳥哥網站 SAMBA 那一篇. (太久沒設定了,已經忘得差不多囉!)http://linux.vbird.org/linux_server/0370samba.php

    2006-12-04 01:37:48 補充:

    原則上您的設定應該沒什麼大問題,不過...請在 [global] 節區中再加一行:netbios name = linuxsmb這個是設定在網芳上看到的主機名稱.

    2006-12-05 02:52:05 補充:

    給您的建議設定:【/etc/hosts 內容】127.0.0.1 king.localdomain localhostwww.xxx.yyy.zzz king.abc.com.tw註:www.xxx.yyy.zzz : 您的 IPabc.com.tw : 您的 Domain

    2006-12-05 02:54:33 補充:

    【/etc/samba/smb.conf 內容】[global]smb passwd file = /etc/samba/smbpasswddomain master = noencrypt passwords = yeswins support = nomax log size = 50preferred master = nosecurity = sharelocal master = no

    2006-12-05 02:55:06 補充:

    server string = Linuxworkgroup = workgroupclient code page = 950valid chars = 0xb9log file = /var/log/samba/log.%mnetbios name = kingload printers = noos level = 20socket options = TCP_NODELAY SO_RCVBUF=8192 SO_SNDBUF=8192

    2006-12-05 02:55:47 補充:

    [homes]comment = Home Directoriesbrowseable = nowritable = yes[tmp]comment = Temporary file spacepath = /tmppublic = yeswriteable = yesguest ok = yes

    參考資料: 經驗 + 網路
還有問題?馬上發問,尋求解答。