Need Help w/ Samba Please!!! (XP to see Linux)

Dragnov

Diamond Member
Apr 24, 2001
6,878
0
0
Okay, I've been messing around with this thing for several days now and I can't get this working! Arrrgh! I'm a complete newb to the Linux world so if you so if you give instructions, please be detailed... :p

So here goes...

XP Machine - 192.168.2.33
Linux Machine - 192.168.2.24

I'm running Mandrake 8.2
I donwloaded Samba and have it installed.
I believe I properly configured the smb.conf file

I'm trying to get my main Windows XP machine to be able to browse through the Linux Machine which is essentially a file server. I can see the Linux machine in my network neighborhodd now (workgroup: Irvine). My XP machine name is "Alex", while the Linux machine is just "localhost". The problem is I can't get in though... I get this error...

\\Localhost is not accessible. You might not have permission to use this network resource. Contact the administrator of this server to find out if you have access permissions.

You were not connected because a duplicate name exists on the network. Go to System in Control Panel to change the computer name and try again.


in my smbpasswd file I added a user "alex" along with a password. ("alex" is a valid linux user also). ONCE I was able to get in after I don't know what I really did, but after a restart it wouldn't work anymore. Any ideas? I'm guessing its dealing with permissions and stuff?

Heres a shortend my smb.conf file...

[global]
workgroup = Irvine
server string = Mandrake Linux
hosts allow = 192.168.2. 127.

encrypt passwords = yes
smb passwd file = /etc/smbpasswd

interfaces = 192.168.2.24 127.0.0.1


[homes]
comment = Home Directories
browseable = no
writeable = yes

[videos]
comment = Linux Box Videos
path = /mnt/windows/alex/vids
read only = no
public = yes
valid user = alex


 

Dragnov

Diamond Member
Apr 24, 2001
6,878
0
0
Okay I figured the problem out but I need the resolution to it. :p

The problem was the name of "localhost" of the Linux machine. If I just type in the IP address, I'm able to get in just fine now. So how do I change the Linux Machine computer name? Thanks in advance.
 

TheOmegaCode

Platinum Member
Aug 7, 2001
2,954
1
0
In FreeBSD I just edit /etc/rc.conf, or just do it in /stand/sysinstall...

Taken from The great AT Linux/BSD/*NIX FAQ project!
Q: How do I set domainname and get it to survive a reboot?
A: You have to initialize the domainname on boot. The network services reset at every reboot. Thus, in order to set the domainname during boot, do the following:

In etc/sysconfig/network add in the following lines:
NISDOMAIN='xxxxxx.xxx'

In /etc/rc.sysinit add in the following lines:

# Set the NIS domain name
if [ -n "$NISDOMAIN" ]; then
action "Setting NIS domain name $NISDOMAIN" domainname $NISDOMAIN
else
domainname ""
fi

right after the lines:

# Set the hostname.
action $"Setting hostname ${HOSTNAME}: " hostname ${HOSTNAME}
 

rabidpenguin

Junior Member
Jul 2, 2002
11
0
0
My first question is why did you go through the trouble to download Samba when it comes on the Mandrake install CD?. Second, you can change the localhost name in the network properties. And third, you can make your life eeasier by doing you Samba config using Swat. It should have loaded when you installed Samba. To check this open up a web browser and go to http://localhost:901 .
 

manly

Lifer
Jan 25, 2000
12,863
3,632
136
You can change the Samba server NetBIOS name independently of the machine's hostname.

man smb.conf