Relatively new to openHAB… had great help from this forum…
Initially installed OH 1.8.3 with the manual install on Raspberry Pi with Jessie; had it eventually all going…
Later found out that the
apt-get method would have been better in order to have a consistent basis for support purposes.
OK, we managed to get this going once, why not a second time?!
Saved my config files, and re-imaged the rPi with the base image prior to OH, MQTT, and samba installs.
What I noticed during this install:
a) OH file ownership in
root:root; changed it to
sudo chown -hR openhab:openhab /etc/openhab sudo chown -hR openhab:openhab /usr/share/openhab
b) since I log into the rPi as maxg, I added me to the group openhab
Once OH and MQTT was installed, they both were tested and deemed working.
Now here comes the twist: samba is giving me grief.
sudo apt-get install samba samba-common-bin
changed samba config:
sudo nano /etc/samba/smb.conf
by making these changes:
workgroup = WORKGROUP
160611 MaxG changed from no to yes
wins support = yes
160611 MaxG changed from no to yes
read only = yes
160611 MaxG added:
[OpenHAB Home] comment = OpenHAB Home path = /usr/share/openhab browseable = yes writeable = yes only guest = no create mask = 0777 directory mask = 0777 public = no
[OpenHAB Config] comment= OpenHAB Site Config path = /etc/openhab browseable = yes writeable = yes only guest = no create mask = 0777 directory mask = 0777 public = no
added myself to samba
sudo smbpasswd -a maxg
checkedif service is up
sudo /etc/init.d/smbd status
… all good.
On Windows 10, I simply reused my previously working designer; pointed to new directory all good; as in it can see the config files.
However, and here starts the frustration (and it might be more a Linux question than one for openhab):
I can read/write to the
configurations directory, but the the directories underneath; and have no clue why this is so.
The directories look like this:
[10:51:25] maxg@rpiautomation /etc/openhab $ ls -la total 32 drwxrwxrwx 4 openhab openhab 4096 Jun 11 10:50 . drwxr-xr-x 114 root root 4096 Jun 10 21:42 .. drwxr-xr-x 8 openhab openhab 4096 Jun 10 21:39 configurations drwxrwxrwx 4 openhab openhab 4096 Jun 10 20:29 jetty -rwxrwxrwx 1 openhab openhab 2583 May 23 05:44 logback_debug.xml -rwxrwxrwx 1 openhab openhab 2311 May 23 05:44 logback.xml -rwxrwxrwx 1 openhab openhab 145 May 23 05:44 login.conf -rwxrw-rw- 1 maxg maxg 0 Jun 11 10:50 New Text Document.txt -rwxrwxrwx 1 openhab openhab 302 May 23 05:44 quartz.properties [10:51:39] maxg@rpiautomation /etc/openhab $ ls -la configurations/ total 228 drwxr-xr-x 8 openhab openhab 4096 Jun 10 21:39 . drwxrwxrwx 4 openhab openhab 4096 Jun 11 10:50 .. drwxr-xr-x 2 openhab openhab 4096 Jun 10 21:45 items -rw-r--r-- 1 openhab openhab 22423 Jun 10 21:43 openhab.cfg -rw-r--r-- 1 openhab openhab 84565 Jun 10 21:43 openhab.cfg.orig -rw-r--r-- 1 openhab openhab 84565 May 23 05:44 openhab_default.cfg drwxr-xr-x 2 openhab openhab 4096 Jun 10 21:45 persistence drwxr-xr-x 2 openhab openhab 4096 Jun 10 21:45 rules drwxr-xr-x 2 openhab openhab 4096 Jun 10 21:45 scripts drwxr-xr-x 2 openhab openhab 4096 Jun 10 21:45 sitemaps drwxr-xr-x 2 openhab openhab 4096 Jun 10 20:31 transform -r--r----- 1 openhab openhab 24 May 23 05:44 users.cfg
Maybe the questions should be:
Are my file permission correct? If not, what should they be?
Is it OK to log in as maxg as member of the group openhab? Or will this interfere with openhab (seeing a file owned by maxg when modified)?