Find the answer to your Linux question:
Page 1 of 2 1 2 LastLast
Results 1 to 10 of 11
I am trying to get Samba to work. I am running RH 9.0 and my other systems are win2k boxes. I've been following some how-to's step by step. One of ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Mar 2003
    Posts
    57

    Trying to get SAMBA to work...netbios name =?


    I am trying to get Samba to work. I am running RH 9.0 and my other systems are win2k boxes. I've been following some how-to's step by step. One of the lines I added to my smb.conf file is:
    netbios name = example-server

    or something like that. Well it actually worked when I ran
    smbd -D
    nmbd -D

    it has some issues still but atleast now I can see the exmple-server from my windows machine. But my question is this, on my windows machine I see the computer name as "example-server"

    But my hostname as set by the command hostname is RH9. So why isn't the computer seen as RH9...

    Also becuase I am running KDE, when I go to my "network configuration" option, there area number of tabs that I can mess with. Does that hostname command control the same thing that I see in this "network configuration" screen"? And also why does the newbios name = line in the smb.conf override everything?

  2. #2
    Linux Guru
    Join Date
    Oct 2001
    Location
    Täby, Sweden
    Posts
    7,578
    The NetBIOS name that samba uses doesn't really have anything to do with the hostname of the system, it's just that if you don't specify the NetBIOS name, samba will use the system hostname as the default.
    The names that Windows boxes see are always the NetBIOS names, though. If you want this the correct way, just remove the netbios name setting from you smb.conf.

  3. #3
    Just Joined!
    Join Date
    Mar 2003
    Posts
    57
    Thanks Dolda, if you don't mind I still have a lot of confusion about Samba. Even though right now things are working. When I click on the linux machine from my win2k machine I see the folders and the one file I put in them. The only problem is that I don't remember when I set all those different folders. There are like 3. So I would like to get clear the steps that need to be done to make this work:

    1.) Config your smb.conf file...however I am not sure exactly what all the parameters do. I mean I can figure out some...but I think also every [ ] element is like a new directory or something. Except for the [global] which I am assuming is some global parameters that need to be set. Also within each [ ] section, I guess it sets the parameters for that section. I am guessing the path = part is setting the actually directory that is being used.

    2.) Then do I need to mount something? Well I followed some other guide, and it told me to make a directory and then mount it. But I'm not sure what that does, and I'm not even sure if it works. I would like to find a way to figure out whether that folder was even "mounted" appropriately. But does this mounting this even effect anything? I have no idea.

    3.) now I also have to set the smbpasswd. Again I am not really clear about this, but do I need to do this. Basically I need to create a user and password for any computer user that will be trying to connect to the linux computer. Perhaps that is why I was seeing the folders before but not allowed access in them. Anyway, I would love to see a list of users that I've specified within the smbpasswd directory, so I can either know what I need to add, or double check what is in there already.

    4.) finally I need to run /usr/sbin/nmbd -D and /usr/sbin/smbd -D Which I understand can be setup to run automatically at boot up every single time, but I don't know how. I'd like to know that as well.

    I've been trying to read the man for smb.conf, and I still am, but that thing is long, and having no idea what it is all about, makes understanding even a little difficult.

    So as you can see there are many steps in setting all this up (not to mention, making sure windows 2000 has the Netbios protocol, which I didn't originally), and quite frankly I don't know which settings are doing which. Or at least not sure.

  4. #4
    Linux Guru
    Join Date
    Oct 2001
    Location
    Täby, Sweden
    Posts
    7,578
    I\d be surprised if Samba didn't confuse me. It's a rather big thing.
    Anyway...

    1. Yes, every [] section (except [global]) does specify a share, and everything therein are parameters for that share.

    2. Mount? What does mounting have with this to do? Mount anything if you feel like it, but it's not specifically related to samba.

    3. The reason for smbpasswd is quite simple. You see, the way passwords are stored is in encrypted form. Both UNIX and Windows does this, and to make sure that noone can get the passwords, you use a one-way encryption, meaning that once you encrypt something, you can't decrypt it, but every time you encrypt something you always get the same result. That way, when a user logs in with his password, the login process encrypts it, and compares the encrypted string with the one stored in the password database, and if they match, the user in authenticated. The thing is, however, that UNIX and Windows use two different encryption algorithms. So when a Windows computer requests to log in, it sends the password encrypted with the Windows algorithm. That means that Samba can't reencrypt it to match it against your UNIX password database. So therefore you need the smbpasswd database, where passwords are encrypted with Windows' algorithm.

    4. Don't run nmbd -D and smbd -D, run "service smb start" instead. To make it start automatically at system startup, create a link in /etc/rc.d/rc3.d or /etc/rc.d/rc5.d (depending on which one is your default runlevel), named S65smb and pointing to /etc/rc.d/init.d/smb.

    The Windows computers do not have to have the NetBEUI protocol installed, you just enable it over IP.

  5. #5
    Just Joined!
    Join Date
    Mar 2003
    Posts
    57
    Ok, I'll try to get rid of NetBEUI and see if it works. Hmm then what is the mounting for. Is the mounting for the linux machine to see the windows share then? One of the main reasons I am trying to get Samba up and running is so that I can print to my printer attached to the windows machine--which I believe you have helped me on already (though I didn't understand much when you posted your remarks originally).

    I have another issue now. I have a bunch of shares...granted that's fine becuase I was going hog wild to tested it with a bunch of different folders. And I've also learned that the smb.conf file is also just the settings that are changed by the "Samba Server Setting" option in KDE (GUI version of it, I believe smb.conf is more powerful though). But one weird thing is that when I go to my windows machine I see a bunch of shares, and one share I don't see where I initialized it.

    There is one share folder that is basically a link to my home folder as in /home/username, but I don't remember ever sharing that folder, and I can't find anywhere that says that folder is shared. Does anybody have any idea why this is happening?

  6. #6
    Linux Enthusiast
    Join Date
    Jun 2002
    Location
    San Antonio
    Posts
    621
    yeah, that is most probably in [homes] . That is one kind of weird share, like [printers] in that it gets processed differently. It shares your /home/$username directory so you can get all your "personal belongings" from a different computer.
    I respectfully decline the invitation to join your delusion.

  7. #7
    Just Joined!
    Join Date
    Mar 2003
    Posts
    57
    Can I get rid of that [homes] share? Or is it low-level and always expected to be there. My guess is yes, by just deleting it...but will that screw things up?

    You know one thing I'm still just getting use to right now is that Linux started from the ground up as mainly a text based OS (as did all), and it migrated to haveing a GUI X-windows on top of it. But then a lot of editing and configuring of the system is still suggested to be done in the text based configuration files. But there is also this GUI configuration option. So what happens to me, as a newbie, is that I starte messing with the config file, and then I start snooping around for the GUI configuration tools, and then I edit both, and then I'm not sure if the GUI configuration tool basically just alters the text file behind the scenes or what. I wish there was a more obvious link with what each tool does in correspondence to which config file.

  8. #8
    Linux Guru
    Join Date
    Oct 2001
    Location
    Täby, Sweden
    Posts
    7,578
    Quote Originally Posted by deadseasquirrels
    I wish there was a more obvious link with what each tool does in correspondence to which config file.
    Don't we all? Of course, I don't use configuration tools; a text editor is more than enough, but when I still did, I wished that. But really, isn't that kind of the purpose with GUI tools: to hide the actual "low-level" stuff from the end user? There are those who are scared by the kernel's dmesgs at boot time, and imagine what they would think of such tools.

    By the way, you might not know it, but a GNU/Linux system is basically a UNIX system, and since UNIX has been around since 1969, it is truly text based. More text based than most systems.

  9. #9
    Linux User
    Join Date
    Jan 2003
    Location
    Cardiff, Wales
    Posts
    478

    samba help

    If you want to get into samba in a big way then i would recommend buying SAMS Teachyourself SAMBA in 24hours. 24 hours my arse but it is an excellent book all the same. can get it on amazon.

    also i got my company to buy me a subscription to www.computerbooksonline

    we negotiated and got a years access for £400. thousands of full content it books in html format and fully searchable. absolute bargain coz i didn't pay.
    No trees were harmed during the creation of this message. Its made from a blend of elephant tusk and dolphin meat.

  10. #10
    Linux Newbie
    Join Date
    Apr 2003
    Location
    UK, Manchester
    Posts
    147
    I read the Oreilly's Using Samba and it is a good book as are most Oreilly titles.

Page 1 of 2 1 2 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •