Find the answer to your Linux question:
Results 1 to 3 of 3
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1

    Samba: interfaces and host allow.

    I know this is likely an obvious question to a lot of you but I haven't been able to find an explanation for this:

    I'm making a home file server with CentOS 6.2 running 'basic server' with desktop and x-window installed (all of which is currently kicking my butt). In the smb.conf file I have the following which came automatically with Samba:

         interfaces = lo eth0
         hosts allow = 127. 192.168.12. 192.168.13.
    1) I want to configure this correctly for security reasons but I've struggled to find what these mean. As far as I can find on google interfaces the ways it will talk to clients, but how it that different than 'hosts allow'?

    2) What do 'lo' and 'eth0' mean?

    3) My network is 192.168.1. and none of the listed networks are that. Is this because the ones Samba came up with are wrong or does Samba know something I don't?

    Thank you so much for your help,

  2. #2
    Trusted Penguin Irithori's Avatar
    Join Date
    May 2009
    A network daemon listens on (at least) one port and (at least) one IP, so that it can be reached by its clients.
    IPs are bound to physical or virtual network devices. These are calles lo for loopback, eth0 for the first ethernet, eth1 for the second, etc

    By default, samba will listen on all available devices.
    The interfaces keyword can limit that.

    "hosts allow" is more focused on the IPs of the clients. Say, I want only a few hosts of a network allow access, then "hosts allow" can be used

    About the and
    No idea. Maybe this is a left over from previous config changes.

    Btw, the default smb.conf is actually a good source of documentation.
    As comments, it lists every keyword and gives an explanation.
    You must always face the curtain with a bow.

  3. #3
    Thank you that helps everything make a lot more sense! And the commenting in smb.conf has helped a lot, just couldn't figure out a few things.

  4. $spacer_open

Posting Permissions

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