IP camera binding not working anymore after upgrade to OH 2.5.9

I used OH2.4.x with an early version of a v2.5 IP camera binding. Configuration was donme using test files:
‘’’ Thing ipcamera:DAHUA:001 [ IPADDRESS=“”, PASSWORD=“secret”, USERNAME=“admin”, ONVIF_PORT=80 ]’’’

in combination with: Image CamImage { channel=“ipcamera:DAHUA:001:image” }

This worked, but now after switching to OH 2.5.9 this does not work anymore. I expected the config syntax is changed, so removed the ‘things’ file restarted OH uninstalled the IP camera binding and installed the IP camera binding again.

Expected to see some ‘thing’ in the inbox, but nothing happens.
When checking the log: Extension ‘binding-ipcamera’ has been installed and no errors.

Am I overlooking something here ? How to setup the binding ?
Before removing the ‘things’ file, there was also no error in the log.

There are breaking changes, you need to adapt your config:

The serverPort is required now in your things file.
Also clean the cache as there could be pieces of old binding left in the cache.

1 Like

I think I am facing something else, it looks like the binding is not used.

  • I emptied the cache and tmp directories
  • I changed the log level for the ipcamera binding to trace
  • When I restart openhab, and do ‘grep -ri camera’ in the log directory th result is:
    openhab.log:2020-09-28 20:27:49.923 [INFO ] [el.core.internal.ModelRepositoryImpl] - Loading model ‘ipcamera.items’
    openhab.log:2020-09-28 20:27:50.725 [INFO ] [el.core.internal.ModelRepositoryImpl] - Loading model ‘ipcamera.things’

Nothing from the binding, when checking paper UI the binding is installed.

Console output:
235 │ Active │ 80 │ 2.5.9 │ openHAB Add-ons :: Bundles :: IpCamera Binding

stopped and started the binding a few times via the console. No errors, nothing in the log.

Any idea what is happening here, or where to look ?

Read post 2 of this thread and then post your thingnfile after u edit it.

I tried 2 options, since I wanted to start with a setup with ffmpeg:

  1. As I used with OH2.4.x but now added SERVER_PORT=-1
    Thing ipcamera:DAHUA:001 [ IPADDRESS=“”, PASSWORD=“secret”, USERNAME=“admin”, SERVER_PORT=-1, ONVIF_PORT=80 ]

  2. Copy from the post you referring to
    Thing ipcamera:DAHUA:001 [IPADDRESS=“”, PASSWORD=“prutser”, USERNAME=“admin”, POLL_CAMERA_MS=2000, SERVER_PORT=54321, IP_WHITELIST="(", IMAGE_UPDATE_EVENTS=0]

For 2: There is no ffmpeg running, so IP addresses do make not much sense. but in both cases there is not a single log message related to the ipcamera binding.
grep -ri camera does only return: Loading model ‘ipcamera.things’
If this things file is incorrect, I would expect at least an error in the log, or am I wrong ?

During OH startup I have an exception related to uPnp , because it cannot setup a multicast group. Might this affect the binding ? Other things like MQTT / Weather binding work as expected.

You have all caps. See here

1 Like

Yes, it is. The post I linked to talks about breaking changes, so I assumed you would read further on: go to the readme of the binding and change all your uppercase configs to camelcase.

@matt1 and @sihui

Thank you both for your help :smiley:

Sometimes there are a lot of documentation/examples to find which are outdated and applicable to other versions. (no offence, I am a software engineer myself (unfortunately not Java) and making documentation is usually the not the nicest part :grinning:)

I was more or less fooled by the fact that there was not a single log message related to: Binding init, binding misconfiguration, binding load error, invalid binding name, invalid parameter name…or something like that. For that reason I even did not bother to start looking into the details.
Probably an additional sanity check with an error message would help. I assume it was due to the ‘dahua’ being in uppercase which caused the binding to silently continue.

An additional note in bold in the documentation above the table with binding properties stating “case sensitive” might also be a good idea. It might at least save your valuable time from nagging people like me.

To make a long store short, the cam is now recognized, I get log message from the binding and I was able to get an image in the browser. Still some work to do related to the new binding options, but that should be ok now.

1 Like

IMHO the official docs should be the only place to look and they should contain everything you need. In this case there are full examples in the official docs so this should be covered. Everyone can edit and PR changes to the docs.

Yes the dauha in uppercase was the issue and I agree. It is 1 single line of code to add a WARN to your logs. Can you open a github issue? I am still in the middle of changing things over to V3 build enviroment and getting a test server up and going so its best an issue is raised.

I doubt that would get approved as it is standard practice to not use uppercase so adding that to the docs would make it longer and it is already very long.

If you notice any other things that can be improved, then by all means please make a suggestion as it is easy to not test for things like this as in my head I know it is ‘wrong’ so I don’t try and see what it is like for a user that has not written the code.