Problem with setting up Zooz USB Z-Wave Plus S2 Stick ZST10

Hi @stefan.oh and @robmac

Thanks for sticking with me! Sorry I was away for a day – other stuff intervened.

One thing I did accomplish yesterday (in relation to HomeAutomation here at my Mom’s house) was to have a conversation with Agnes at Zooz yesterday morning. There is no doubt that the Zooz stick is operational, so that is good! Using “PC Controller” I was unable to exclude the old Z-Wave switches, so I bought a handful more which will arrive later this afternoon. [ I don’t have a laptop here, so I can’t get the Zooz USB stick close enough (to exclude older, cheap Z-Wave switches). I’ll work on them when I get back to my own home and have a significantly better setup. ]

Meanwhile . . .

I reread the udev rule only after I posted my prior comments and saw the difference. I agree that this rule does not seem to affect the Zooz controller. Still, the fact there is no udev rule on my system at all when you (everyone?) have it is puzzling!

I just did a reinstall, a few moments ago. This time I installed the recommended " Azul Zulu Build of OpenJDK"

My new install reports the same!

Well, I am at a different openjdk version as I have installed as recommended for a new OH 3.2 installation (and am NOT on an RPI ):

openjdk version "11.0.14.1" 2022-02-08 LTS
OpenJDK Runtime Environment Zulu11.54+25-CA (build 11.0.14.1+1-LTS)
OpenJDK 64-Bit Server VM Zulu11.54+25-CA (build 11.0.14.1+1-LTS, mixed mode)

As this is the official OH 3.2 reccommendation, this difference is not likely germane.

This is very good to know. Alas, still no joy.

I installed through the OH webpage at localhost:8080 This is pretty much the first thing it suggests after inputting a new UID, PW and location

Man – this seemed sooo promising! I was very excited when I read this as I know the original OH installation on this host did not have this binding installed.

I installed that binding. Unfortunately, the controller is still offline.

Did you ever try the LCK file permissions either from my post or the second solution in the thread @robmac posted? Or run OH as root as @mhilbush suggested?

Here’s a short story. I create a modified zwave binding for a variety of reasons (unimportant here). I recently tried a shortcut and controller would not start :frowning_face: I restarted OH and everything came back :smiley: Interesting in relation to this thread is this;

note the removal of the LCK file

Also info level logging for this same restart showed this ;

Note the time of the stale lock removal and the first INFO (controller is null).

Lastly I found an earlier Debug log level start-up

The debug you posted above is identical but doesn’t connect to the serial port. Since all the other permissions seem in place, it seems like the LCK file or something specific to the serial port. Maybe that will narrow down your search.

On the serial binding there is an obvious error message (unfortunately I run across this when I get sloppy). I found a recent post showing the message and solution.


I do not think that is an issue here because you would have noticed.

Bob

Hi All:

This was a nonstarter. As I thought about it (if I thought it through correctly . . .), I would have needed to emulate RPI hardware.

I did quickly install OH on a LinuxMint 20.3 machine about a half hour ago.

[EDIT: the idea being it might work differently on an Ubuntu/Debian-based distro than a Fedora/RedHat-based distro ]

Same (not working Zooz stick) result.

Hi Bob @apella12

)*^#$@%!!

Sorry, I missed coming back to that, which I was going to do a couple nights ago.

OK:

hostname.redacted@redacted: ~$ sudo systemctl status openhab.service

● openhab.service - openHAB - empowering the smart home
Loaded: loaded (/usr/lib/systemd/system/openhab.service; disabled; vendor preset: disabled)
Active: active (running) since Fri 2022-04-01 14:15:41 PDT; 1h 37min ago
Docs: Introduction | openHAB
https://community.openhab.org
Main PID: 7254 (java)
Tasks: 118 (limit: 18738)
Memory: 1001.8M
CPU: 1min 40.123s
CGroup: /system.slice/openhab.service
└─7254 /usr/bin/java -XX:-UsePerfData -Dopenhab.home=/usr/share/openhab -Dopenhab.conf=/etc/openhab -Dopenhab.runtime=/usr/share/openhab/runtime -Dopenhab.userdata=/var/lib/openhab -Dopenhab.logdir=>

Apr 01 15:52:22 hostname.redacted karaf[7254]: check_group_uucp(): error testing lock file creation Error details:Permission deniedcheck_lock_status: No permission to create lock file.
Apr 01 15:52:22 hostname.redacted karaf[7254]: FAILED TO OPEN: No such file or directory

Indeed, there is no relevant file at /run/lock

please stand by a few moments while I figure out how to start openHAB manually

I believe it is linked via /var/lock. Try that.

That message in karat seems to point that way. Edit: I mean this

Bob

1 Like

Hi @apella12 @mhilbush @robmac @rpwong @stefan.oh and anyone else I may have overlooked

OK, the easiest way I could see to do this (i.e. run openhab as root) quickly (since there are a bunch of startup parameters I do not yet know or understand) was to edit the openhab.service and set the user and group arguments to “root”

OK, now we are getting somewhere.

sudo systemctl status openhab.service reports no error!

Lock file appears:

Zooz Z-Wave USB stick available and online!


Please understand I know this is not safe(!) way of operating and I have already stopped the service running as root!


I am quite embarrassed to have overlooked my note to follow up on this “test” instruction the other night. Sorry to have wasted more time for everyone on on this!

That said . . . The question now is how to best address this (both for me and the larger community)?

At the macro level: This looks like a pretty major oversight in the openHAB codebase and from what I can see has been biting people in the rear for at least 1.5 years (i.e. since the Nov. 2020 forum post) While persons running OpenHabian are seemingly not affected, it seems to affect persons running both inside Docker containers or on “bare metal” on a “high powered” host like me.

I am sorry to infer that this type of (100% blocking) problem may well be why I had so many automation “experts” steer me away from openHAB.

HomeAssistant has been eating it up and as a fairly linux-skilled automation “newbie” this particular experience does validate their success quite a bit. As I mentioned the other day, I had HA running with this same Zooz stick in a VM [ i.e. conceptually (and in implementation!) much more complex than “sudo dnf install openhab” ] in just a few minutes (granted, I have gotten fairly good at VMs lately, but virtual machine first-timers would be completely lost and just that would likely take them hours – hence RPI installations).

I understand software can suffer regressions, but there have been ~2 point releases since this was surfaced.

So . . . How does this get fixed? [ I will post an issue on Github in a few moments as a starter. ] Do the developers listen here?


At the personal level: with regards specifically to my install for my mom . . .

She has waved off openHAB: “if a guy with as much computer experience as you can not get this running in a couple evenings (when she saw how fast HA and Domotics had been tested a year or so ago), I don’t want it.”

She asked me to evaluate Hubitat in between struggles here and has decided to test-implement that. We’ll start tomorrow.

At my own house where I have the twin of this server I will attempt another openHAB installation (I also have the exact same Zooz USB Z-Wave stick) maybe in May or so.

Maybe by then this permissions issue will be fixed in OH 3.3.x Otherwise I will need to figure out the best way to allow OH access to the folder in question.

The “solution” discussed here by Stephen @gatekeeper6838 seems risky and impermanent. Others further down in the thread also point to the negative security implications.

Most are also referring to group “uucp” while my installation(s) don’t even have such a group and indeed suggest the OH group in question (for the serial device) would be “dialout”.

Anyway, groupings may have changed between 3.0.x and 3.2.x, but it seems worth mentioning as another potential blocker.

Hi Bob @apella12

That is correct. You wrote as I was penning a “novel” right below you.

Giving /var/lock different permissions will likely not persist across reboot.

Lots of challenges here! . . . but I’ll give it some more tries. :crazy_face:

Hi Everyone:

I have posted an issue to openhab-addons at Github

Hopefully this will get some quick attention from the developers.

Extensive (deeper) reading today in other threads shows that it has even affected some new installs on RPi (openHABian)

When a home automation hub blocks installation of a critical communication device, new users will likely flee. This is really a problem . . . I think I am fairly rare in not giving up easily!

1 Like

I’m glad you have it working.

I almost didn’t post again out of respect that everyone has their problem-solving process, but as you are new, decided to try to refocus a bit on what I was pretty convinced was the issue.

As to the “novel” you wrote that is above my pay grade.

Again congrats.

Bob

Hi Bob @apella12

Well, not really! A non-persistent workaround and/or loosening security is unacceptable.

I will further test this in my home lab, but as I implied in my “novel,” at the current moment in my opinion this absolutely blocks the use of openHAB in a production environment.

Thanks for prodding me again. My usual process is to hunt down every lead.

The “wall” of text in the lengthy post to which you had referred me made me attempt some other stuff first . . . and then I missed it on my checklist when I came back around. That’s actually embarrassing to me!

So…I agree with your mother. But you weren’t asking my opinion on that, so I didn’t offer it.

I don’t recommend openHAB to family/friends or set it up for others to run. I don’t want to be in a position where they’re dependent on a system that only I can update, change, or fix when something goes wrong. So, I always talk about home automation and openHAB as a hobby that I enjoy, not as a robust, consumer-ready solution that I think people should use. It’s too complex for that.

MainUI in OH 3 is a major step forward in usability, but even then it’s still a lot. That’s no one’s fault, it’s just what happens when a system has tons of capabilities. It’s always funny to me when anyone promises tons of features with a simple interface. You end up with a single button that does ten different things, depending on how you press it.

Well, no. openHABian with Z-Wave works. openHAB without Z-Wave works. You’ve run into a specific problem on a specific OS. That’s why I suggested trying it on a different platform.

As to why this issue persists, that other thread pretty much explains it. As far as I can tell, none of the people who were impacted reported an issue in GitHub. They may not have realized that it’s something that should be reported, or maybe they just didn’t care enough to prevent it from happening to anyone else. Whatever the case, I’m grateful to you for determining the root cause and opening an issue to alert developers. That’s how openHAB gets better.

Sorry that this hasn’t been a smooth experience for you, but it’s probably for the best that you aren’t setting OH up for your mom and walking away. I hope you’ll stick around as this is a good community.

Oh my,

should have read

My apoligies for this misleading advice. The serial BINDING has (as far as I know) nothing to to with the communication between the ZWave binding and the port the controller is represented by on OS level.

This is just one of many differences between the various Linux distributions. In this case between my RasPi OS and your Fedora. Obviosly they handle some security aspects in a different way.

Now I see, you found out what blocked your success. Good to see that and I try to remember that as a possiblee obstacle for non openhabian users.

@FBachofner Glad you got to root (no pun intended) cause. :wink:

But, wow, that nrjavaserial issue referred to by @wborn in the GitHub issue is really nasty. Six years and still not solved. :sob: Not sure what the path forward will be from here.

I guess it also explains why Ubuntu works fine (for now), but I fear it just might be a matter of time before Ubuntu breaks, too.

Can I ask a question? Did this issue get resolved? Was it a problem with nrjavaserial and the file lock bug?

Well worked out and thanks for digging.

Sorry could not help enough to keep you engaged.

Hope Hubitat works out. I like the little things. Nice low power and great for a small home or if you put a few in they can work together to cover a large area.

Hi Russ @rpwong:

If I had a nickel for every time I heard that . . . :crazy_face: :rofl:

The (setup) complexity should not really end up hampering the end consumer if the system is put together reasonably.

What I am more worried about is breaking changes on system updates. If I plan a visit for 3 or 4 days and update the system and it breaks, then I may have to extend my visit and miss other opportunities back at home. I could mitigate the risk by testing on a virtually identical system at home (except for the variety of switches and sensors (since those tend to be location specific), but there is still fairly significant risk. [ Especially when I find out there are longstanding known bugs. ]

These improvements are a major reason I decided to take another look at openHAB.

I just installed a Zooz scene controller with 5 buttons, each of which can perform up to 7 functions (if I understand it fully – have not yet played with it exhaustively).

My Mom will get ONE function per button so she does not get confused! [ My Dad was an engineer and would likely have enjoyed the complex functionality, but alas, he passed away a decade ago. ]

  • As I mentioned, I did try it on a different platform – Linux Mint (Ubuntu-based) vs. the Fedora system on which I intended to run the “production” system
  • After an exhaustive review, I found there were at least two reports (that I distinctly remember) of new openHABian installs on which Z-Wave did not work. It seems that this does not affect openHABian users who upgraded from 1.x or 2.x as you may have.

[ I know you have been with the platform that long, but don’t know whether you performed in-place upgrades or may have installed new. Anyway, openHABian does not seem to be a guarantee of Z-Wave working “out of the box.” ]

.

Well, about as “smooth” as with many not fully “baked” IT endeavors, so I am actually used to this! :money_mouth_face:

Mom is used to (especially) IT things not always working smoothly (especially in early iterations) – but seems to understand that she often contributes a LOT of user error into the mix: forgetting instructions, not understanding why and/or how things work (and is therefore not able to work things out on her own)

I absolutely intend to keep experimenting with openHAB! This very helpful community is one major reason for that.

Thanks again for your helpful input!

Hi Stefan @stefan.oh:

Thanks again for your assistance and for the update!

While we all collaboratively figured out the “blocker,” the “solution” is actually a bit less obvious.

I obviously don’t want to run openHAB as root, and some of the “fixes” seem non-durable across reboots.

I could write init scripts to work around this, but that implies new problems too:

  1. This may cause problems on OS or openHAB upgrades
  2. It makes the resulting system much less “standard” and harder to grok as a result ( home automation is already “non-standard” enough! )

As mentioned above, I’m not a Linux expert, but with my limited knowledge, the workaround here would survive reboots. Obviously, it is not ideal. also based on comments the OH developers consider this a bug in an external helper application and as you noted has been around awhile.

Bob

Hi Mark @mhilbush:

LA Times has an interesting article today about feral pigs. There are too many. Pigs root, right? Perhaps openHAB could hire the excess pigs to root out bugs and help deal with the surplus?! :rofl: :boar: :pig:

Yep, this is critical to address!

Z-Wave is one of two protocols which make local (and low energy) control possible. It is widespread in home automation. Not supporting this with easy to implement solutions could be a death knell for openHAB.

I find it particularly interesting that the rapid rise of Home Assistant occurred during the last four or five years, right during the six year existence of this bug!

One of the things I kept reading about openHAB is that “longstanding bugs” are not addressed. I am going to guess that this one (Z-Wave serial controller problems) is likely “exhibit A.” People who reach to open solutions like this are far more likely to want to avoid Google, Amazon, Wi-Fi devices (which can “report home”), etc.

Another issue that openHAB is not addressing is adding support for version 700 Z-Wave devices. [ Come to think of it, I wonder if this signifies a long-term desire to drop support for Z-Wave by openHAB?! 700 will take over. 500 (and earlier?) devices do not work without workarounds . . . and will likely soon be unavailable in the marketplace. ]

Anyway, if Z-Wave does not work out of the box . . . !!

Fortunately, from a quick read the first post in the bug thread seems to imply a solution:

I’m emphasizing on this because the problem has arisen by nrjavaserial’s claim to be the out-of-box solution instead of sticking to the well working principal that package maintainers are responsible for the native libraries

I have not yet fully parsed the thread, but this seems like a clear opportunity for openHAB developers to lead the way on the solution! Let’s hope they rise to the challenge.

[ Please note, I understand this may be easier said than done (I don’t develop anything beyond scripts and some minor PHP stuff – Java is largely a mystery to me – but if openHAB is to succeed, the developers at least have to acknowledge the issue CLEARLY and UPFRONT . I think it’s likely a bunch of potential users install and then immediately hit this blocker only to get extremely frustrated. ]

NOT SO! Please look at my post #49. Mint is an Ubuntu derivative. Same exact problem!

Hi Rob @robmac

As you can see from my posts, I am still engaged! [ My partner with whom I have three children would not be surprised . . . as both she and I don’t think we really ever want to get married! But I do stick to my interests and commitments! (20 years in her case!) :smiling_face_with_three_hearts: ]

In my Mom’s case, there are only 6 switches and some AV and HVAC stuff to (hopefully) control. The longer term plan calls for about 20 switches and a handful of sensors. Hubitat should handle that just fine.

It will be interesting to see whether I can integrate a home security (and camera) system with it later this year. IMO, she pays too much to ADT / Protection One and I have identified a number of far lower-cost monitoring services for DIY systems . . .