I have a problem with OpenHAB2 with getting rules to import/execute.
When I define rules in PaperUI, I can see them in the web interface and also in Karaf under the scheduler:
openhab> smarthome:automation listRules
----------------------------------------------------------------------------------------------------
ID UID NAME STATUS
----------------------------------------------------------------------------------------------------
1 0df4c68f-1634-4858-a10a-c6ec784ee31d PNUT Night Lite OFF IDLE
2 1d75bf81-a51f-422c-b2ab-41ed4e9c8c7e PNUT Night Light ON IDLE
3 46df60c6-3343-40f5-a78e-97094f877f65 PNUT ROOM LIGHT OFF (SCHOOL DAYS) IDLE
4 695d0f0c-d7c9-491b-8dfa-143632af2891 X-MAS Lights ON Outside IDLE
5 73ab5aa5-ee41-43e5-857f-945f61bdaadc LVRM LAMP OFF (SLEEP) IDLE
6 74aa25ef-03ea-495c-8247-8a7c0b5fe8c7 PNUT ROOM LIGHT ON (SCHOOL DAYS) IDLE
7 acdf5eec-ebb8-4e2a-a901-6ae2c17e9342 X-MAS Lights OFF Outside IDLE
8 d2bed2bf-57e5-4489-8295-3f8cf3949882 MBRM Night Lights ON IDLE
9 f6c8b229-28e0-4780-88e1-441049208c14 MBRM Night Lights OFF IDLE
10 ffa4238e-b4ef-4526-bdb1-fbb589ece9bb LVRM LAMP ON (DAY/EVENING) IDLE
----------------------------------------------------------------------------------------------------
However, when I try to use HABmin rules designer, the rules are written to disk but won’t work. They are being written under /etc/openhab2/rules.
ls /etc/openhab2/rules
(1)_office_fan.rules readme.txt
I tried to use karaf to import the office_fan.rules file and it blows up apparently doesn’t like the formatting. (yes, I do understand that I have to escape the parenthesis, etc. I am not a linux/unix novice.)
Can someone help me to understand just how RULES execute or get imported into OpenHAB2. I have poured through a ton of docs and it seems a lot are geared towards older versions. Perhaps I made a mistake of going with Openhab2 vs the older platform. There are no errors in the openhab.log file related to rules or syntax errors. I suspect the HABmin rules are just not being seen at all.
The PaperUI rules are very simplistic and won’t do what I would like accomplish.
* Platform information:
* OS: Ubuntu 4.4.0-116-generic
* Java Runtime Environment: openjdk version "1.8.0_151"
OpenJDK Runtime Environment (build 1.8.0_151-8u151-b12-0ubuntu0.16.04.2-b12)
OpenJDK 64-Bit Server VM (build 25.151-b12, mixed mode)
* openHAB version:
Active 0.10.0.201802191927 Eclipse SmartHome *
Active 2.12.0.v20170518-0757 Xtend Runtime Library
Active 2.12.0.v20170518-0757 Xtend Macro Interfaces
Active 2.12.0.v20170518-0959 Xtext
Active 2.12.0.v20170519-0752 Xtext Common Types
Active 2.12.0.v20171017-1700 Xtext IDE Core
Active 2.12.0.v20170518-0959 Xtext Utility
Active 2.12.0.v20170519-0752 Xbase Model
Active 2.12.0.v20170519-0752 Xbase Generic IDE Services
Active 2.12.0.v20170518-0757 Xbase Runtime Library
Active 2.3.0 JUPnP Library
Active 2.3.0.201803071159 openHAB Core
Active 2.3.0.201803071159 openHAB Karaf Integration
Resolved 2.3.0.201803071159 openHAB Sound Support, Hosts: 116
Active 2.3.0.201803071159 openHAB Dashboard UI
Active 2.3.0.201803071159 openHAB 1.x Compatibility Layer
Active 1.1.1.201605111122 Swagger Provider
Active 2.4.5 Jackson-annotations
Active 2.4.5 Jackson-core
Active 2.4.5 jackson-databind
Active 2.4.5 Jackson-dataformat-YAML
Active 0.10.0.201802191927 Eclipse SmartHome Automation API
Active 0.10.0.201802191927 Eclipse SmartHome Automation commands
Active 0.10.0.201802191927 Eclipse SmartHome Automation Core
Active 0.10.0.201802191927 Eclipse SmartHome Automation Module Core
Active 0.10.0.201802191927 Eclipse SmartHome Automation Media Modules
Active 0.10.0.201802191927 Eclipse SmartHome Automation Module Script
Active 0.10.0.201802191927 Eclipse SmartHome Automation Script Globals
Active 0.10.0.201802191927 Eclipse SmartHome Automation Script RuleSupport
Active 0.10.0.201802191927 Eclipse SmartHome Automation Module Timer
Active 0.10.0.201802191927 Eclipse SmartHome Automation GSON Parser
Active 0.10.0.201802191927 Eclipse SmartHome Automation Providers
Active 0.10.0.201802191927 Eclipse SmartHome Automation REST API
Active 0.10.0.201712081218 Eclipse SmartHome Exec Transformation Service
Active 0.10.0.201712081218 Eclipse SmartHome JavaScript Transformation Service
Active 0.10.0.201712081218 Eclipse SmartHome JSonPath Transformation Service
Active 0.10.0.201712081218 Eclipse SmartHome Map Transformation Service
Active 0.10.0.201712081218 Eclipse SmartHome RegEx Transformation Service
Active 0.10.0.201712081218 Eclipse SmartHome Scale Transformation Service
Active 0.10.0.201712081218 Eclipse SmartHome XPath Transformation Service
Active 0.10.0.201712081218 Eclipse SmartHome Xslt Transformation Service
Active 0.10.0.201712081218 Eclipse SmartHome Basic UI, Fragments: 234
Active 0.10.0.201712081218 Eclipse SmartHome WebApp UI, Fragments: 235
Active 0.10.0.201712081218 Eclipse SmartHome Paper UI, Fragments: 238
Active 1.3.5.0 MariaDB JDBC Client
Active 2.3.0.201801141430 Network Binding
Active 2.3.0.201801141430 ZWave Binding
Active 2.3.0.201801141430 openHAB REST Documentation
Active 1.12.0.201801160209 openHAB JDBC SQL Persistence bundle
Resolved 2.3.0.201801141430 openHAB Basic UI Fragment, Hosts: 226
Resolved 2.3.0.201801141430 openHAB Classic UI Fragment, Hosts: 227
Active 2.3.0.201801141430 HABmin User Interface
Active 2.3.0.201801141430 HABPanel User Interface
Resolved 2.3.0.201801141430 openHAB Paper UI Theme Fragment, Hosts: 228
Active 0.9.10.v20160429-1435 reflections (wrap)
Active 1.5.8.v20160511-1038 swagger-jersey2-jaxrs (wrap)
Active 1.12.0.201801160209 openHAB Mqtt Action
Active 1.12.0.201801160209 openHAB MQTT Transport Bundle