Ok, so I finally started my migration. I followed the instructions to bring all my legacy stuff over. So far… almost nothing is working.
Small things like the http binding are working. The xbmc is as well. Anything to control lights… not so much.
So here is what I have. Ubuntu 14. Fresh install of openhab2 as of last night. zulu for java. Working with just the flat files (expert mode) for fault tolerance reasons.
2018-05-28 10:30:15.753 [hingStatusInfoChangedEvent] - 'hue:0210:1:bulb1' changed from OFFLINE: Hue bridge reports light as not reachable. to ONLINE
2018-05-28 10:30:56.797 [hingStatusInfoChangedEvent] - 'hue:0210:1:bulb1' changed from ONLINE to OFFLINE: Hue bridge reports light as not reachable.
2018-05-28 10:31:06.919 [hingStatusInfoChangedEvent] - 'hue:0210:1:bulb1' changed from OFFLINE: Hue bridge reports light as not reachable. to ONLINE
2018-05-28 10:36:20.916 [hingStatusInfoChangedEvent] - 'hue:0210:1:bulb1' changed from ONLINE to OFFLINE: Hue bridge reports light as not reachable.
2018-05-28 10:36:31.040 [hingStatusInfoChangedEvent] - 'hue:0210:1:bulb1' changed from OFFLINE: Hue bridge reports light as not reachable. to ONLINE
When I try to flip the light on or off. I see the state change. But the light doesn’t do anything.
But I also get this.
2018-05-28 11:00:24.282 [WARN ] [org.openhab.binding.upb ] - FrameworkEvent WARNING - org.openhab.binding.upb
org.osgi.framework.ServiceException: org.apache.felix.scr.impl.manager.SingleComponentManager.getService() returned a null service object
at org.eclipse.osgi.internal.serviceregistry.ServiceFactoryUse.factoryGetService(ServiceFactoryUse.java:232) [?:?]
at org.eclipse.osgi.internal.serviceregistry.ServiceFactoryUse.getService(ServiceFactoryUse.java:111) [?:?]
at org.eclipse.osgi.internal.serviceregistry.ServiceConsumer$2.getService(ServiceConsumer.java:45) [?:?]
at org.eclipse.osgi.internal.serviceregistry.ServiceRegistrationImpl.getService(ServiceRegistrationImpl.java:496) [?:?]
at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.getService(ServiceRegistry.java:461) [?:?]
at org.eclipse.osgi.internal.framework.BundleContextImpl.getService(BundleContextImpl.java:619) [?:?]
at org.apache.felix.eventadmin.impl.handler.EventHandlerProxy.obtain(EventHandlerProxy.java:286) [3:org.apache.karaf.services.eventadmin:4.1.3]
at org.apache.felix.eventadmin.impl.handler.EventHandlerProxy.sendEvent(EventHandlerProxy.java:407) [3:org.apache.karaf.services.eventadmin:4.1.3]
at org.apache.felix.eventadmin.impl.tasks.HandlerTask.runWithoutBlacklistTiming(HandlerTask.java:82) [3:org.apache.karaf.services.eventadmin:4.1.3]
at org.apache.felix.eventadmin.impl.tasks.SyncDeliverTasks.execute(SyncDeliverTasks.java:104) [3:org.apache.karaf.services.eventadmin:4.1.3]
at org.apache.felix.eventadmin.impl.tasks.AsyncDeliverTasks$TaskExecuter.run(AsyncDeliverTasks.java:166) [3:org.apache.karaf.services.eventadmin:4.1.3]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:?]
at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:?]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:?]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:?]
at java.lang.Thread.run(Thread.java:748) [?:?]
Not sure why. But it’s pretty consistent.
Anyone run in to this? I am sure this is a long day ahead of me trying to get over to 2. But I have coffee and snacks. Im ready.
I strongly recommend to use autodetection, works flawlessly for all 2.x bindings and especially for the hue binding … You still can use your items files to link the channels to the hue thing.
I tinkered around with things file for hue a lot and finally when using autodiscovering it worked right out of the box.
I also started with text files (coming from openHAB1), but quickly realized that it is a lot easier to use autodetection …
i have seen that. but i am not a fan of all the stuff from the UI going in to a single DB instead of the files. Harder to tinker with for me and could cause issues with my fault tolerance plans
You can set everything you like as internal bridge-name in the *.things file - so even “1” should be fine.
But theres a small typing error in your *.items file:
Get everything working with the legacy bindings first. Then one by one move to the 2.x version bindings, if you want to. Don’t try to move everything over to the 2.x version of the bindings you are using all at once. It is too much to deal with.
Let me say this again because it always seems to come up. JSONDB is just a text file. You can open it with VIM and everything. You can manually edit it. You can check it into source control. You can write it by hand.
There is nothing you can do with .things files that you cannot do with the JSONDB file.
One important note is unless you are using the development branch of the zwave binding, you cannot define Things manually and much use autodetection (unless I missed that getting merged in 2.3).
The location of the files is /var/lib/openhab2/jsondb.
One important caveat I forgot to mention though is jsondb should probably only be manually edited when OH is not running. There have been reports of corruptions and such when editing it by hand with OH running.
so I just did an apt-get update on my machine. Installed some openhab update. and now i am FLOODING my log at startup with this.
2018-05-29 16:41:20.116 [ERROR] [pse.smarthome.core.items.GenericItem] - Tried to set invalid state ON (StringType) on item WorkBenchOutlet1 of type SwitchItem, ignoring it
2018-05-29 16:41:20.119 [ERROR] [pse.smarthome.core.items.GenericItem] - Tried to set invalid state OFF (StringType) on item WorkBenchSafetyOutlet of type SwitchItem, ignoring it
2018-05-29 16:41:20.122 [ERROR] [pse.smarthome.core.items.GenericItem] - Tried to set invalid state -1 (StringType) on item MasterBedRoomLightLevel of type NumberItem, ignoring it
2018-05-29 16:41:20.125 [ERROR] [pse.smarthome.core.items.GenericItem] - Tried to set invalid state OFF (StringType) on item MasterBedroom_MotionSensorOverride of type SwitchItem, ignoring it
2018-05-29 16:41:20.132 [ERROR] [pse.smarthome.core.items.GenericItem] - Tried to set invalid state OFF (StringType) on item BedroomMotionSensor of type SwitchItem, ignoring it
seems like all my persistence recovery is messed up.
ok, odd but it worked. I tried to force a downgrade back to 2.2. That REALLY broke stuff. I ran the apt-get upgrade again and it started up…
So I am happy to say, i am officially up and running with 2.3.
my HUE and zwave is running on standard and not legacy. So I just have to migrate the rest off the legacy plugins. I have started getting in the ui and will be looking at the JSONDB and start working on my fault tolerance setup again.