SAMBA Issue

  • Platform information:
    • Hardware: Rapsperry Pi 2 model B
    • OS: Raspbian latest
    • Java Runtime Environment: Java™ SE Runtime Environment (build 1.8.0_201-b09)
    • openHAB version: Openhab 2.4.0
  • Issue of the topic: I can’t see Samba in my Windows 10 PC. I set it up everything based on the documents

enable win support

my smb.conf file

[OpenHAB]
comment = OpenHAB
path = /usr/share/openhab2
create mask = 0777
directory mask = 0777
read only = No

[openHAB2-userdata]
comment = openHAB2 userdata
path = /var/lib/openhab2
create mask = 0777
directory mask = 0777
read only = No

[openHAB2-conf]
comment = openHAB2 site configuration
path = /etc/openhab2
create mask = 0777
directory mask = 0777
read only = No

No idea why it’s not showing up and how can i trouble shoot this

I’m using an RPI also and here’s a pic of my working samba config located at /etc/samba/smb.conf

Screenshot%20at%202019-01-25%2009-56-24

I love that veto of .DS_Store files. I need to add that to my config!

Just trying to keep it clean.:wink: Glad you like it.:+1:

Won’t allow me to connect.

image

Sorry I’m new to linux

What name are you using to access the samba share? The default name is openhabian and password is openhabian.

I use my custom account and the default one. Still not working, funny thing is it’s not even showing in my network

It should show up here right?

image

At the moment I’m using linux mint and this is what it looks like.

Screenshot%20at%202019-01-25%2010-24-22

Did you install OH using the openhabian image or do a manual install?

I install it based on the package repo, I flash my sdcard with raspbian latest full and install the OH2 via putty using package repo then openhabian config tool. Also whe I hit the manual setup in openhabian tool and choose samba, nothing happens.

Have you changed the samba smb.conf to add browseable=Yes and writeable=Yes like in the pic I posted?

Per the doc’s your file should have this at minimal:

[openHAB2-userdata]
  comment=openHAB2 userdata
  path=/var/lib/openhab2
  browseable=Yes
  writeable=Yes
  only guest=no
  public=no
  create mask=0777
  directory mask=0777

[openHAB2-conf]
  comment=openHAB2 site configuration
  path=/etc/openhab2
  browseable=Yes
  writeable=Yes
  only guest=no
  public=no
  create mask=0777
  directory mask=0777

Yes I edit my smb.conf to this

but when i do testparm it shows like this:

I only see openhab-userdata and openhab-conf are you missing the openhab-share and could that be the problem?

Under Custom Share Definitions add like below.

Screenshot%20at%202019-01-25%2010-49-10

I only have share definitions not the custom share definitions. As instructed in the docs I should put it in the end of the file right?

Yes, that should work as Custom Definitions are at the end of the file.

Still same issue. can’t see it on windows network

After making changes did you try restarting samba? If not use sudo systemctl restart smbd.service

Also try with user name openhab instead of openhabian and see if that makes a difference.

Still no signs of Samba in my windows network.

I have no idea how your network and PC is setup so I’m not sure what else to try.:thinking: If you think it’s a problem with OH and not Windows then maybe try installing OH via the openhabian image.
https://bintray.com/openhab/bin/download_file?file_path=openhabianpi-raspbian-201804031720-gitdba76f6-crc9e93c3eb.img.xz

Installing this way samba should work out of the box without having to change or add anything on the OH/linux side.

1 Like

You can also search the forum to see if there’s others with the same issue. Here is one topic I found but there are many more.

Hope it helps.

Security over everything :slight_smile:

If you’re on Windows 10 this should help:

Change Registry Value
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters\AllowInsecureGuestAuth
From 0 to 1

source:
https://support.microsoft.com/de-ch/help/4046019/guest-access-in-smb2-disabled-by-default-in-windows-10-and-windows-ser

1 Like