OH2 - Rules not triggered

I upgraded my HA system (fresh SD card) to OH2. I can control my lights through paper UI just fine.

However, I copied my rules file from OH1 and none of my rules trigger. I removed every rule with the exception of below and it still won’t turn on the light. Any suggestions on what might be missing?

I am using Eclipse SmartHome designer to make sure my syntax is correct.

 rule "Lights on"
when
	Time cron "0 41 10 ? * SUN-THU *"
then
 	sendCommand(Desk, ON)
end

I wasn’t sure where the log file moved, so I don’t know the tail command to view it anymore.

It might be related to issues with the OH2 cron implementation: Scheduler not working reliable for Cron Expressions · Issue #3132 · eclipse-archived/smarthome · GitHub.

Thanks!

I changed my cron to below and the light still doesn’t turn on:

rule "Lights on"
when
	Time cron "0 09 11 * * ?"
then
 	sendCommand(Desk, ON)	
end

I added a pushover command and can now get an alert, but I still can’t get the switch to turn on. Do I need to change how items are defined in my items file? Do I need to remove them from the items file since they are defined in Paper UI?

 rule "Lights on"
when
	Time cron "0 11 15 * * ?"
then
 	pushover("Time test")
 	sendCommand(Karen_Office, ON)
 	sendCommand(Desk, ON)
end

Below is an excerpt of my .items file:

	Color Desk "Desk" <hue> (Office, Lights) {hue="34"}
	Dimmer Office_Karen "Office Karen" <hue> (Office, Lights) {hue="17;brightness;20"} 

Yes. Do not try to define the same Item in both places.

Are you seeing errors in your logs?

I removed the items definition from the .items file and I’m still not getting the light to turn on. I’ve tried multiple different lights.

I was using the command below to view the logs on OH1, but it doesn’t work in OH2:

tail -f /var/log/openhab/openhab.log

I think it is /var/log/openhab2/openhab.log for OH 2.

Thanks Rich!

I checked the logs and I’m getting this error:

2017-03-19 15:28:00.588 [INFO ] [smarthome.model.script.Light tripped] - Karen's office Tripped
2017-03-19 15:28:00.591 [ERROR] [ntime.internal.engine.ExecuteRuleJob] - Error during the execution of rule Lights on: An error occured during the script execution: The name 'Desk' cannot be resolved to an item or type.

I checked Paper UI and the Hue light is named “Desk”. I removed it from the items file, so it is only defined in Paper UI.