[SOLVED] Items not exposed even on a personal instance of openHAB cloud (is it like myopenHAB.org?)

Hi all!
having the intention to use IFTTT with openHAB again, I decided to configure a personal openHAB cloud server, and I succeeded by following the excellent instructions contained here step by step:

https://community.openhab.org/t/openhab-cloud-setup-guide-for-azure-and-ifttt/83208

I did not use Azure but another cloud service and I used Ubunto 20.04 LTS instead of 18.04. Everything seems to work (access to the cloud server, remote access to my openHAB server, etc.), except for a not insignificant detail for those like me who still want to use IFTTT: I don’t see any exposed items, although I have correctly configured openhabcloud.cfg and although I tried to send ON/OFF commands via Karaf to the exposed object . I also tried:

  • to clear the openHAB cache
  • to regenerate UUID and secret
  • to remove and reinstall the openHAB cloud connector
  • to delete the user with which I had initially registered on my personal openHAB cloud server and register again with the new UUID and secret
  • to restart the Raspberry Pi on which I have installed my openHAB server (with openhabian)

Needless to say, I verified the openHAB log and found no significant error messages. I have openHAB 2.5.10 Release Build, and I am getting a suspicion: by chance now it is not possible to expose items also on personal instances of openHAB cloud, as happened last year with myopenHAB.org? Or did I make some stupid mistake that is stupid enough to make me not be able to realize it? :slight_smile:

Any suggestions are appreciated. Thanks!

Marco

Have you checked the cloud’s log file if there is anything that may help ?

Dear Wolfgang,
I was able to get a log only after stopping openhabcloudservice and restarting with sudo node app.js. I do not why… Anyway, logging produced this:

2020-11-30 19:55:29:2929 info: openHAB-cloud: Backend service is starting up...
2020-11-30 19:55:29:2929 info: openHAB-cloud: Backend logging initialized...
2020-11-30 19:55:30:3030 info: openHAB-cloud: Initializing XMPP connection to GCM
2020-11-30 19:55:30:3030 info: openHAB-cloud: Connecting to Redis at 127.0.0.1:6379
2020-11-30 19:55:31:3131 info: openHAB-cloud: Mailer will emulate sending in development environment
2020-11-30 19:55:32:3232 info: opneHAB-cloud: Trying to connect to mongodb at: mongodb://127.0.0.1/openhab?poolSize=50
2020-11-30 19:55:32:3232 info: openHAB-cloud: Scheduling a statistics job (every 5 min)
2020-11-30 19:55:32:3232 info: openHAB-cloud: IFTTT is configured, app handling IFTTT capabilities...
2020-11-30 19:55:32:3232 info: openHAB-cloud: express server listening on port 3000
2020-11-30 19:55:32:3232 info: openHAB-cloud: Redis connect response: OK
2020-11-30 19:55:32:3232 info: openHAB-cloud: Redis is ready
2020-11-30 19:55:32:3232 info: openHAB-cloud: Successfully connected to mongodb
2020-11-30 19:55:32:3232 warn: openHAB-cloud: GCM XMPP error: XMPP authentication failure
2020-11-30 19:55:36:3636 info: openHAB-cloud: Authorizing incoming openHAB connection
2020-11-30 19:55:36:3636 info: openHAB-cloud: Incoming openHAB connection for uuid 54ba59bd-04e6-4d6e-9ac6-c1e3fab4d4a9
2020-11-30 19:55:36:3636 info: openHAB-cloud: Connected openHAB with 54ba59bd-04e6-4d6e-9ac6-c1e3fab4d4a9 successfully
2020-11-30 19:55:36:3636 info: openHAB-cloud: uuid 54ba59bd-04e6-4d6e-9ac6-c1e3fab4d4a9 server address undefined:undefined my address undefined:undefined
2020-11-30 19:56:32:3232 debug: openHAB-cloud: Checking for offline openHABs (0)
2020-11-30 19:56:32:3232 debug: openHAB-cloud: Checking orphaned rest requests (2)
2020-11-30 19:56:32:3232 debug: openHAB-cloud: expiring orphaned response
2020-11-30 19:57:32:3232 debug: openHAB-cloud: Checking for offline openHABs (0)
2020-11-30 19:57:32:3232 debug: openHAB-cloud: Checking orphaned rest requests (1)
2020-11-30 19:58:32:3232 debug: openHAB-cloud: Checking for offline openHABs (0)
2020-11-30 19:58:32:3232 debug: openHAB-cloud: Checking orphaned rest requests (1)
2020-11-30 19:59:32:3232 debug: openHAB-cloud: Checking for offline openHABs (0)
2020-11-30 19:59:32:3232 debug: openHAB-cloud: Checking orphaned rest requests (1)
2020-11-30 20:00:00:000 info: openHAB-cloud: every5min statistics collection job started
2020-11-30 20:00:00:000 info: openHAB-cloud: every5min statistics collection job finished
2020-11-30 20:00:32:3232 debug: openHAB-cloud: Checking for offline openHABs (0)
2020-11-30 20:00:32:3232 debug: openHAB-cloud: Checking orphaned rest requests (1)
2020-11-30 20:01:32:3232 debug: openHAB-cloud: Checking for offline openHABs (0)
2020-11-30 20:01:32:3232 debug: openHAB-cloud: Checking orphaned rest requests (1)
2020-11-30 20:02:32:3232 debug: openHAB-cloud: Checking for offline openHABs (0)
2020-11-30 20:02:32:3232 debug: openHAB-cloud: Checking orphaned rest requests (1)
2020-11-30 20:03:11:1111 info: openHAB-cloud frontend is shutting down from SIGINT

The only “suspicious” row is 2020-11-30 19:55:32:3232 warn: openHAB-cloud: GCM XMPP error: XMPP authentication failure, but I am unable to better understand. On the openHAB server side (a Raspberry Pi) I just tried to understand some more details after setting the log level at DEBUG, and the only significant issue that I found so far is:

2020-11-30 21:37:41.704 [DEBUG] [org.osgi.framework.ServiceEvent ] - ServiceEvent REGISTERED - {org.eclipse.smarthome.core.events.EventSubscriber, org.eclipse.smarthome.model.script.engine.action.ActionService}={service.id=508, mode=remote, service.bundleid=294, service.scope=bundle, expose=lampada_soggiorno_1_int, component.name=org.openhab.io.openhabcloud.internal.CloudService, service.config.label=openHAB Cloud, component.id=324, baseURL=https://xxxxxxx.ddns.net, service.config.category=io, service.config.description.uri=io:openhabcloud, service.pid=[org.openhab.openhabcloud, org.openhab.openhabcloud]}

lampada_soggiorno_1_int is the name of the item that should be exposed and that I still do not see on https:///xxxxxxx.ddns.net/items. I really do not know how to proceed further. Any help is appreciated!

MP

I think the problem is the row with:

2020-11-30 19:55:36:3636 info: openHAB-cloud: uuid 54ba59bd-04e6-4d6e-9ac6-c1e3fab4d4a9 server address undefined:undefined my address undefined:undefined

the related code line is

logger.info('openHAB-cloud: uuid ' + socket.handshake.uuid + ' server address ' + openhab.serverAddress + " my address " + internalAddress);

so I would expect to see the servers addresses.

Thank you for your kind reply.
But at this point I feel helpless. What should I do to assign the right values to openhab.serverAddress and to internalAddress?

All the best, Marco

How does your config file look like ?

Do you mean my config.json file? Here it is:

{
    "system": {
        "host": "xxxxxxx.ddns.net",
        "port": "443",
        "protocol": "https",
        "logger" : {
            "dir": "./logs",
            "maxFiles" : "7d",
            "level" : "debug",
            "morganOption" : "dev"
          }
    },
    "express":{
      "key" : "some express key"
    },
    "mongodb": {
        "hosts": ["127.0.0.1"],
        "db": "openhab"
    },
    "redis": {
        "host": "127.0.0.1",
        "port": "6379",
        "password": "secret"
    },
    "mailer": {
        "host" : "somehost",
        "port": 465,
        "secureConnection": true,
        "user": "someuser",
        "password": "somepass",
        "from": "<your-mail>"
    },
    "gcm" : {
      "jid": "something@gcm.googleapis.com",
      "password": "password"
    },
    "ifttt" : {
      "iftttChannelKey" : "xxxxxxxxxxxxxxxxxx",
      "iftttTestToken" : "yyyyyyyyyyyyyyyyyy"

    },
    "legal": {
    	"terms" : "",
        "policy": ""
    }

}

Please, note that I inserted dummy values for “iftttChannelKey” and for “iftttTestToken”. Please, forgive me if I am saying something nonsense, but is it not by chance that my problem can be generated by a permissions problem, as often happens in unix systems?

Thank you, Marco

I have worked with UNIX systems for years. The only permissions issues I have never encountered any unexplainable permissions issues. I assume Linux, being a UNIX-like system, is similar/

It looks like you used the config-development.json file as a template for your configuration. I am using the config-productin.json file as a template in my installation. There is at least one difference ( morganOption ). I do ot know what this is being used for.
In case it would be a permission option I would expect to see an error message.

Hi Wolfgang,
there is also another difference inside the “mongodb” section:

"mongodb": {
    "hosts": ["127.0.0.1"],
    "db": "openhab",
    "user": "",
    "password": ""
},

My config.json does not have the lines with “user” and “password” at all:

"mongodb": {
    "hosts": ["127.0.0.1"],
    "db": "openhab"
},

Trying to setup my config.json exactly as it is inside the config-productin.json template (two empty fields) does not work: the openHAB cloud web page becomes inaccessible. Actually, I do not use any user and password to access mongodb. Did you set a specific user/password for mongodb instead?

Thank you and kind regards, Marco

I am using user and password for mongodb. As far as I remember an user with related privileges is not the default. It should work without a user.

I spent some more times during the weekend on this issue, but I have not come to the end of anything. I also set up a parallel installation of openHAB on docker on a Synology NAS at my disposal, for the sake of using openHAB 2.4.0 instead of the latest 2.5.0: nothing to do, the result is the same.
I think the problem is in the cloud server setup. When I have time I will make another attempt: I want to install a trial version of openhabcloud within my network and not on the cloud server, just to see if the problem recurs. If the problem doesn’t recur in my home environment, then it might be worth looking for a new provider for the cloud service. Thanks again to Wolfgang for his help, I keep you informed!

I have the same issue. Private OH Cloud instance with no items showing up.

Your openHAB is online. Click here to access your openHAB's dashboard

Unfortunately at the moment I have no time for further tests. As soon as I will have time to spend I will try that “dummy installation” on a server inside my home network. Knowing I’m not alone is partial consolation …

You probably just need to reverse this pull

2 Likes

You got it!!!
I modified app.js by commenting line 746 in this way:

socket.on('itemupdate', function (data) {
    //disabling item updates for now
    //return;

and now exposed objects are visible again. I still do not know if IFTTT is working, I had no time. During the weekend I will try and probably I will put SOLVED on this topic.

Thank you!

Glad it’s working for you. Mine isn’t working though as I’m using OH3 and I can’t find where they killed the feature in the OH3 code base.

I confirm that IFTTT is working also!! Thank you. Well, for the moment I will stay with Openhab2, then let’s see…

This topic was automatically closed 41 days after the last reply. New replies are no longer allowed.