I just tried out openhab for the first time today, and am trying to setup a milight bridge. Now I’ve searched long and far in this forum, but somehow nothing has fixed my problem.
Whenever I try to send a signal to my bridge, I get the debug message
2016-03-24 22:57:51.143 [DEBUG] [.io.net.http.SecureHttpContext] - security is disabled - processing aborted!
2016-03-24 22:57:51.157 [DEBUG] [.o.b.m.internal.MilightBinding] - milight: item is of type brightness
2016-03-24 22:57:51.164 [DEBUG] [.o.b.m.internal.MilightBinding] - milight: sendOn
2016-03-24 22:57:51.166 [DEBUG] [.o.b.m.internal.MilightBinding] - milight: messageBytes to transform: '42:00:55’
2016-03-24 22:57:51.173 [DEBUG] [.o.b.m.internal.MilightBinding] - Sent packet ‘42:00:55’ to bridge ‘bridge’ (null:50000)
2016-03-24 22:57:51.285 [DEBUG] [.io.net.http.SecureHttpContext] - security is disabled - processing aborted!
2016-03-24 22:57:51.291 [DEBUG] [.o.u.w.i.servlet.WebAppServlet] - Servlet request received!
2016-03-24 22:57:51.294 [DEBUG] [.o.u.w.i.servlet.WebAppServlet] - reading sitemap home
Now I’ve read that the (null:50000) thing means that it can neither find a valid IP address, nor a port. However, I’ve quadruple checked my openhab.cfg file and it says
Milight Binding
Host of the first Milight bridge to control
milight:bridge.host=192.168.178.123
Port of the bridge to control (optional, defaults to 50000)
milight:bridge.port=8899
Host of the second Milight bridge to control
milight:.host=
Port of the bridge to control (optional, defaults to 50000)
milight:.port=
For formatting reasons, I’ve left out the #'s but they are before every line except milight:bridge.host=192.168.178.123
and
milight:bridge.port=8899
Am I overlooking something? I’m really stuck here and can’t go to sleep before I turn off the lights once with my computer
How would I go about finding that out? I have not changed anything myself, everything is as it came with the latest raspbian jessie I downloaded today from their website.
All that’s changed is the bridge1 part, right? That’s what I had initially, but since I only have one bridge I just renamed it (for now). But I changed it to bridge1 now and am getting the same logs:
2016-03-24 23:34:52.234 [DEBUG] [.io.net.http.SecureHttpContext] - security is disabled - processing aborted!
2016-03-24 23:34:52.246 [DEBUG] [.o.b.m.internal.MilightBinding] - milight: item is of type brightness
2016-03-24 23:34:52.258 [DEBUG] [.o.b.m.internal.MilightBinding] - milight: sendOn
2016-03-24 23:34:52.266 [DEBUG] [.o.b.m.internal.MilightBinding] - milight: messageBytes to transform: '42:00:55’
2016-03-24 23:34:52.271 [DEBUG] [.o.b.m.internal.MilightBinding] - Sent packet ‘42:00:55’ to bridge ‘bridge1’ (null:50000)
And do you mean the <> brackets? In that case yes.
OK, it is definitely a problem within your openhab.cfg file, preventing the binding to read your bridge config.
Did you copy the openhab_default.cfg to openhab.cfg and made your changes there.
No typo in the name, as your topic for this thread has a typo (it is not openhub.cfg) ?
By copy it is just meant to duplicate and rename it right? Because that’s what I did, and yes I named it correctly though I frequently mess that up All the changes are in a file called openhab.cfg that’s sitting in the configurations folder.
Now I am running out of ideas.
Could you please check if your user running openhab has sufficient rights to access the openhab.cfg file.
If you duplicated and changed it as a different user, this could be a problem.
How would I go about checking that? The guide I used said to write
sudo chown -hR openhab:openhab /usr/share/openhab
and from what I got that deals with the rights? this is the guide that I followed, I realize now that I maybe shouldn’t have done it through a 3rd party website. I followed it line for line up until when it began dealing with the Hue
As I understand, openhab is running under user openhab.
So you could login as user openhab and try to edit openhab.cfg. If you get a permission denied error on saving, then you have an issue with the rights.
What I’ve been doing is access my Pi via my network, using my MacBook. So I type commands through a Terminal Remote Connection and can access and update files through the finder, as shown in the tutorial. I can access and change the file using both ways, so I assume I have all the rights, right?
For a try, you could ssh into your raspi, navigate to your configurations folder and type ls -lia openhab.cfg.
You will then see the permissions and the owner.
Please post the output.
It just worked! I have absolutely no idea why as I didn’t change anything, maybe it was because I shut down my Pi overnight, though I’m pretty sure I’ve restarted it before. Anyway, I’m really glad it works now, thanks for your support! Now off to create all kinds of rules!