openhab sendMail not working in 1.3.1

2,611 views
Skip to first unread message

kbd...@gmail.com

unread,
Sep 22, 2013, 2:45:08 PM9/22/13
to ope...@googlegroups.com
Hi,

i just upgraded to 1.3.1 and I am getting the following error for sendMail:

21:43:00.431 INFO  runtime.busevents[:46] - Amps_Max state updated to 33
21:43:00.566 INFO  runtime.busevents[:46] - Amps_Min state updated to 6
21:43:00.580 INFO  runtime.busevents[:46] - Power_GF_Frontdoor_snsr state updated to CLOSED
21:43:00.586 INFO  runtime.busevents[:46] - Power_GF_Frontdoor_AC state updated to CLOSED
21:43:00.591 INFO  runtime.busevents[:46] - Power_GF_Frontdoor_MT state updated to OPEN
21:43:00.598 INFO  runtime.busevents[:46] - Power_GF_Frontdoor state updated to OPEN
21:43:00.603 INFO  runtime.busevents[:46] - Light_GF_Corridor_Relay3 state updated to OFF
21:43:00.608 INFO  runtime.busevents[:46] - Light_GF_Corridor_Relay4 state updated to OFF
21:43:00.612 INFO  runtime.busevents[:46] - Heating_GF_Corridor2 state updated to OFF
21:43:00.616 INFO  runtime.busevents[:46] - Heating_GF_Corridor1 state updated to OFF
21:43:01.177 INFO  runtime.busevents[:46] - Amps state updated to 16
21:43:01.276 ERROR o.o.c.s.ScriptExecutionThread[:70] - Error during the execution of rule 'MainDoorClosed': The name 'sendMail(<XStringLiteralImpl>,<XStringLiteralImpl>,<XStringLiteralImpl>,<XStringLiteralImpl>)' cannot be resolved to an item or type.

the mail bundle in already in the addons directory.

appreciate your help




kbd...@gmail.com

unread,
Sep 23, 2013, 7:02:16 AM9/23/13
to ope...@googlegroups.com, kbd...@gmail.com
any idea? any hint from anyone!

kbd...@gmail.com

unread,
Sep 23, 2013, 11:53:47 AM9/23/13
to ope...@googlegroups.com, kbd...@gmail.com
Resolved

k...@openhab.org

unread,
Sep 23, 2013, 2:27:16 PM9/23/13
to ope...@googlegroups.com
How? What was the problem?

Zitat von kbd...@gmail.com:
>>> 21:43:01.276 ERROR o.o.c.s.ScriptExecutionThread[:70] -* Error during
>>> the execution of rule 'MainDoorClosed': The name
>>> 'sendMail(<XStringLiteralImpl>,<XStringLiteralImpl>,<XStringLiteralImpl>,<XStringLiteralImpl>)'
>>> cannot be resolved to an item or type.*
>>>
>>> *the mail bundle in already in the addons directory.*
>>>
>>> appreciate your help
>>>
>>>
>>>
>>>
>>>
>
> --
> You received this message because you are subscribed to the Google
> Groups "openhab" group.
> To unsubscribe from this group and stop receiving emails from it,
> send an email to openhab+u...@googlegroups.com.
> To post to this group, send email to ope...@googlegroups.com.
> Visit this group at http://groups.google.com/group/openhab.
> For more options, visit https://groups.google.com/groups/opt_out.



kbd...@gmail.com

unread,
Sep 23, 2013, 3:47:10 PM9/23/13
to ope...@googlegroups.com
in fact, it sent one email then stopped. this is my rules file. exact same fle is working under version 1.2

when move to 1.3.1 it does not work.

when i add import org.openhab.action.mail-1.3.1.*

The error (
sendMail(<XStringLiteralImpl>,<XStringLiteralImpl>,<XStringLiteralImpl>,<XStringLiteralImpl>)' >>> cannot be resolved to an item or type.*)
 
disappears but still sendMail does not send any emails and nothing appears in the log.




import org.openhab.core.library.types.*
import org.openhab.core.persistence.*
import org.openhab.action.mail-1.3.1.*
import org.openhab.model.script.actions.*


var Number counter = 1
var Timer timer = null

rule Startup
when
    System started
then
    say("Welcome at openHab!")
end

rule Goodbye
when
    System shuts down
then
    say("Good bye!")
end

 rule "Heater1ON"
    when
        Item Heating_GF_Corridor1 received command ON
    then
    Thread::sleep(250)
    // sendCommand('Light_GF_Corridor_Relay3', 'ON')
     sendMail('xx...@gmail.com', 'Relay hq on', 'Front door pic', 'http://192.168.0.146/Jpeg/CamImg.jpg')
end


 rule "MainDoorClosed"
    when
         Item Power_GF_Frontdoor_snsr received update CLOSED
    then
    //sendCommand('Light_GF_Corridor_Relay3', 'ON')
        
Thread::sleep(1500)
sendMail('xx...@gmail.com', 'Main Door closed', 'Front door movement', 'http://192.168.0.146/Jpeg/CamImg.jpg')
//http://192.168.0.146/Jpeg/CamImg.jpg
end


 rule "MainDoorOpen"
    when
         Item Power_GF_Frontdoor_snsr received update OPEN
    then
    //sendCommand('Light_GF_Corridor_Relay3', 'ON')
     
   
Thread::sleep(1500)
sendMail('xx...@gmail.com', 'Main Door Open', 'Front door movement', 'http://192.168.0.146/Jpeg/CamImg.jpg')
end


rule "Update max and min temperatures"
when
    Item Weather_Temperature changed or
    Time cron "0 0 0 * * ?" or
    System started
then   
    postUpdate(Weather_Temp_Max, Weather_Temperature.maximumSince(now.toDateMidnight).state)
    postUpdate(Weather_Temp_Min, Weather_Temperature.minimumSince(now.toDateMidnight).state)
end


rule "Update max and min Amps"
when
    Item Amps changed or
    Time cron "0 * * * * ?" or
    System started
then   
    postUpdate(Amps_Max, Amps.maximumSince(now.toDateMidnight).state)
    postUpdate(Amps_Min, Amps.minimumSince(now.toDateMidnight).state)
end

kbd...@gmail.com

unread,
Sep 25, 2013, 7:43:13 AM9/25/13
to ope...@googlegroups.com
Still unable to get it to work after 5days.

Is anyone else facing problems with sendMail?

The situation now is that it does not send the email and leaves no trace in any log file

Greg

unread,
Sep 25, 2013, 9:54:58 AM9/25/13
to ope...@googlegroups.com, kbd...@gmail.com
What platform are you using?

I can confirm on when I test it on windows 7, sendmail doesn't work, nor give any errors in the log file.  When I transfer it to linux, it works fine.

kbd...@gmail.com

unread,
Sep 25, 2013, 10:33:42 AM9/25/13
to ope...@googlegroups.com
Running as root on ubuntu
Regards

Greg

unread,
Sep 28, 2013, 5:20:52 PM9/28/13
to ope...@googlegroups.com, kbd...@gmail.com
Hmm.. now I'm getting this error:

java.lang.RuntimeException: The name 'sendMail(<XStringLiteralImpl>,<XStringLiteralImpl>,<XFeatureCallImplCustom>)' cannot be resolved to an item or type.
        at org.openhab.model.script.interpreter.ScriptInterpreter.internalFeatureCallDispatch(ScriptInterpreter.java:87)
        at org.eclipse.xtext.xbase.interpreter.impl.XbaseInterpreter._evaluateAbstractFeatureCall(XbaseInterpreter.java:658)
        at sun.reflect.GeneratedMethodAccessor38.invoke(Unknown Source)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:616)
        at org.eclipse.xtext.util.PolymorphicDispatcher.invoke(PolymorphicDispatcher.java:291)

kbd...@gmail.com

unread,
Sep 29, 2013, 4:04:01 AM9/29/13
to ope...@googlegroups.com, kbd...@gmail.com
Please let me know if you get to resolving it.
 
Thanks

kbd...@gmail.com

unread,
Oct 2, 2013, 1:41:56 PM10/2/13
to ope...@googlegroups.com, kbd...@gmail.com
has anyone managed to find a solution for this? still trying with no luck here

thx

kbd...@gmail.com

unread,
Oct 2, 2013, 2:22:49 PM10/2/13
to ope...@googlegroups.com, kbd...@gmail.com
Now I' ve updated to 1.4 snapshot

this rule:

 rule "MainDoorClosed"
    when
         Item Power_GF_Frontdoor_snsr received update CLOSED
    then
    //sendCommand('Light_GF_Corridor_Relay3', 'ON')
        
Thread::sleep(1500)
sendMail('x...@gmail.com', 'Main Door closed', 'Front door movement', 'http://192.168.0.146/Jpeg/CamImg.jpg')
//http://192.168.0.146/Jpeg/CamImg.jpg
end


now continuously sends emails - without stop!!!!

m.sch...@gmail.com

unread,
Oct 2, 2013, 3:21:33 PM10/2/13
to ope...@googlegroups.com, kbd...@gmail.com
I had the same issue

after changes at the rule file it failed with the same error message

 Error during the execution of rule 'OutPin0': The name 'sendMail(<XStringLiteralImpl>,<XStringLiteralImpl>,<XStringLiteralImpl>)' cannot be resolved to an item or type.

after restart of openhab it was fine again. For me it looks like a problem in the update procedure... but not sure just my two cents

markus

Martin Eskildsen

unread,
Oct 5, 2013, 9:43:15 AM10/5/13
to ope...@googlegroups.com, kbd...@gmail.com
Hi,

I have exact the same problem as mentioned in this thread.

I have a OpenHAB 1.2.0 running (sendMail works fine there). After I upgrade to 1.3.1 and use the configuration from 1.2.0 it stops sending mail.
I also tried to use 1.4.0_SNAPSHOT, because I saw some reports that it worked with that binding. In my case it just complained about  missing configuration in my cfg file. But the confiuguration is there, so still it didn't work for me.
I have tried both under Winows 7 x64 and Ubuntu 13.04, with same result both on Windows and Ubuntu. So I am pretty sure that the problem is somehow related to OpenHAB

Any Ideas?????

/Best regards
Martin

Martin Eskildsen

unread,
Oct 5, 2013, 1:03:36 PM10/5/13
to ope...@googlegroups.com, kbd...@gmail.com
Hi again,
I have some news - actually good news!
I can now confirm that it is working, it seems just like a matter of handling the strings. In 1.2.0 my call to sendMail looked liek this:

sendMail("mymail...@mailprovider.world", "My description", "My message");

If I keep that it doesn't work, it seems like it is the @ that is causing problems. At least if I instead write

sendMail('mymail...@mailprovider.world', "My description", "My message");

things is starting to work. I don't know why,(I don't have that knowledge regarding Java). My best guess is that it is the @ that is causing problems 
Can anybody give some clues here?

Best Regards
Martin

Martin Eskildsen

unread,
Oct 5, 2013, 2:04:58 PM10/5/13
to ope...@googlegroups.com, kbd...@gmail.com
Hi again,

I just realized that I have actually made another change to my setup. Actually the previous post isn't the root cause. 
It is the mail settings (smtp + port), that seems to cause the problems. In version 1.2.0 I have used:
port: 465

I have changed that to 
port: 587 (eg. default port 

For some reason the first smtp setting still work in version 1.2, but it doesn't work in 1.3.

By the way I am still calling sendMail by using "....

sendMail("mymailadress@mailprovider.world", "My description", "My message");

Next task is to get all the rest of my config up and running in 1.3.1 :)

Best regards
Martin
Den lørdag den 5. oktober 2013 19.03.36 UTC+2 skrev Martin Eskildsen:
Hi again,
I have some news - actually good news!
I can now confirm that it is working, it seems just like a matter of handling the strings. In 1.2.0 my call to sendMail looked liek this:

sendMail("mymailadress@mailprovider.world", "My description", "My message");

If I keep that it doesn't work, it seems like it is the @ that is causing problems. At least if I instead write

sendMail('mymailadress@mailprovider.world', "My description", "My message");

Chris Jackson

unread,
Jan 18, 2014, 7:15:59 AM1/18/14
to ope...@googlegroups.com, kbd...@gmail.com
I was just wondering if this problem was resolved or if people are still having problems with sendMail?

Chris

Kai Kreuzer

unread,
Jan 18, 2014, 11:46:11 AM1/18/14
to ope...@googlegroups.com, kbd...@gmail.com

I was just wondering if this problem was resolved or if people are still having problems with sendMail?


See https://github.com/openhab/openhab/issues/457 - it seems as if it is happening for a lot of people with all kinds of different actions.
I tried to reproduce it, but failed and right now I won’t have the chance to look at it any further. I hope Thomas can fix the problem before the release - or somebody else from the community. I consider it a rather critical bug.

Regards,
Kai

Khodor Bdeir

unread,
Jan 18, 2014, 11:47:23 AM1/18/14
to Kai Kreuzer, ope...@googlegroups.com

Still happening with me. 

Chris Jackson

unread,
Jan 18, 2014, 12:17:25 PM1/18/14
to ope...@googlegroups.com
Thanks for the link Kai,
I tried to look for this this morning, but also can’t reproduce it here :(

Cheers
Chris

(I hope you survived your flights ok!)

franz.di...@gmail.com

unread,
Apr 8, 2014, 7:42:58 AM4/8/14
to ope...@googlegroups.com
Error still occuring (1.5.0-SNAPSHOT, Raspberry Pi).

Dieter

Dave Hock

unread,
Apr 21, 2014, 2:31:12 PM4/21/14
to ope...@googlegroups.com, kbd...@gmail.com
I am seeing this for both mail and prowl notify......for both 1.4 and 1.5 snapshot...haven't had notifications working for a long time....

Thomas Eichstädt-Engelen

unread,
Apr 21, 2014, 3:00:10 PM4/21/14
to ope...@googlegroups.com
Dave, All, could you briefly describe your setup (Hardware, JDK, Bindings) in order to feet this issue reproduce able …

Best,

Thomas E.-E.


--
You received this message because you are subscribed to the Google Groups "openhab" group.
To unsubscribe from this group and stop receiving emails from it, send an email to openhab+u...@googlegroups.com.
To post to this group, send email to ope...@googlegroups.com.
Visit this group at http://groups.google.com/group/openhab.
For more options, visit https://groups.google.com/d/optout.

Kai Kreuzer

unread,
Apr 21, 2014, 3:11:14 PM4/21/14
to ope...@googlegroups.com, kbd...@gmail.com
This sounds very much like https://github.com/openhab/openhab/issues/457. But in this issue, the problem only occurs from time to time and restarting openHAB (a few times) usually helps. Can you confirm that it NEVER works for you?

For issue 457 we are still looking for a reproducible setup - I myself wasn’t able to set up my RasPi with openHAB 1.4 release and a few actions that would show this problem. So any hints how to reproduce are more than welcome!

Regards,
Kai


Dave Hock

unread,
Apr 21, 2014, 5:14:41 PM4/21/14
to ope...@googlegroups.com, kbd...@gmail.com


On Sunday, September 22, 2013 11:45:08 AM UTC-7, kbd...@gmail.com wrote:

Dave Hock

unread,
Apr 21, 2014, 5:15:27 PM4/21/14
to ope...@googlegroups.com
jdk1.7.0_55
Windows XP on an HPT5000 thin client, I had same issue on lbuntu 12.04 on another HPT5000 thin client....

I don't think its the german chars issue as not even sure how that could effect PROWL

I use very few 1.5 plugins (just took latest snapshot) mail, prowl, http, pioneeravr, zwave, habmin, db40, rrdrj

Kirk McCann

unread,
May 8, 2014, 11:42:35 PM5/8/14
to ope...@googlegroups.com, kbd...@gmail.com
I'm seeing the same error.  Has anyone found a resolution?

-Kirk
Message has been deleted

Kai Kreuzer

unread,
May 9, 2014, 3:45:18 PM5/9/14
to ope...@googlegroups.com, kbd...@gmail.com
This sounds like https://github.com/openhab/openhab/issues/457
There was still nobody able to provide a set of configurations files, with which this problem can be reproduced.
It it fully reproducible in your case? This could help for the analysis of the issue.

Regards,
Kai

Kbdeir

unread,
May 10, 2014, 11:54:23 AM5/10/14
to Kai Kreuzer, ope...@googlegroups.com
This has been consistently happening since version 1.3 on 3 different installations on 3 different Linux boxes

Regards

Sent from my iPhone

Kirk McCann

unread,
May 10, 2014, 5:12:09 PM5/10/14
to ope...@googlegroups.com
Kai, 

I have an image of my system running on a raspberry pi.  If you could use it to figure out the issue.  I could supply it.  Or if you have some ideas of things to look at I can troubleshoot it.

Kirk

Sent from my iPad
You received this message because you are subscribed to a topic in the Google Groups "openhab" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/openhab/5VA2iWGuQ5Y/unsubscribe.
To unsubscribe from this group and all its topics, send an email to openhab+u...@googlegroups.com.

Kai Kreuzer

unread,
May 18, 2014, 4:07:48 PM5/18/14
to ope...@googlegroups.com
Kirk,

If you could send me your configuration folder (or at least a subset with which you can still reproduce the problem, it would be great) - I will then try to reproduce the problem with it on my end.

Cheers,
Kai

ich...@gmail.com

unread,
May 20, 2014, 5:08:52 PM5/20/14
to ope...@googlegroups.com
don't know if it's related or if if can help but I have exactly the same problem with actions declared by squeezebox or xpl bundles.

I did the following tests just by adding or removing pluggins (I always used the same configuration files)

First tests :
1 - I first detected the problem on an Asus eee Box (Atom D510) with Windows 7 64 bits.
2 - The problem was always reproduced : if I restart openhab or the action.squeezebox pluggin I always had the same error (The name 'squeezeboxPlayUrl(<XStringLiteralImpl>,<XStringLiteralImpl>)' cannot be resolved to an item or type.).
3 - I removed pluggins (by getting them away from addons directory then restarting openhab) and the problem suddently completly disapeared when I just had the following pluggins : binding.http, binding.tcp and the 3 squeezebox pluggins. (I did some restart and the squeezebox command was correctly parsed).
4 - If I put back other pluggins (eg persistence.logging) the problem reappered and was constant.

Second tests :
5 - I then copied and tried the full openhab directory (distrib+full config) on 4 computers and the results were :
- Eee Box Atom D510 Windows 7 64b : never works (except with minimal config described above).
- Aleutia Atom N2800 Windows 7 32b : never works (except with minimal config described above).
- Celeron B830 Windows 8 64b : always works
- i7 2600K Windows 64b : always works

I have the following feelings :
The problem seems to appears on less power computers.
The config or the pluggins are not in fault
It could be a synchronization problem in the parser of the action commands.

...
hope it helps.



Ben Jones

unread,
May 20, 2014, 5:23:09 PM5/20/14
to ope...@googlegroups.com, ich...@gmail.com
I think this is something to do with the other startup issues being reported around the place. Have you got any 'System started' triggers in your rules? Once I removed all of these I saw a big improvement in startup reliability and stability. There are issues with the order openHAB starts up various modules, and the fact some parts of the system are single threaded, causing concurrency issues. I am no expert but there are chaps with much more expertise looking into this (Davy etc).

ich...@gmail.com

unread,
May 20, 2014, 5:43:20 PM5/20/14
to ope...@googlegroups.com, ich...@gmail.com
yep i have nothing in my startup rules.

ich...@gmail.com

unread,
May 20, 2014, 5:53:45 PM5/20/14
to ope...@googlegroups.com, ich...@gmail.com
just to be clear.
the rules and items used for the above tests were minimalist.
The full item file was :
//squeezebox
Number sq_test_play_select "Demo" (Squeeze)

The full rule sile was :
rule "Select Radio Station"
    when
        Item sq_test_play_select received command
    then
        switch(receivedCommand) {
            case 0 : playStream(null)
            case 1 : squeezeboxSpeak("squeezeplay","Welcome to openHab!", 100)
            case 2 : squeezeboxPlayUrl("squeezeplay", "http://crock.streamakaci.com:80")
            case 3 : squeezeboxPlayUrl("squeezeplay", "http://wdr-mp3-m-wdr2-duesseldorf.akacast.akamaistream.net/7/371/119456/v1/gnl.akacast.akamaistream.net/wdr-mp3-m-wdr2-duesseldorf")
      case 4 : squeezeboxPlayUrl("squeezeplay", "http://relay3.181.fm:14126/")
                  
        }
end

and the full sitemap :
sitemap demo label="Main Menu"
{
    Frame label="Groupes" {
        Text label="Squeezebox"  icon="video" {   
            Selection item=sq_test_play_select mappings=[0=stop, 1=SPEAK, 2=CROCK, 3=WDR2, 4=BUZZ]
        }
    }
}

lozano....@gmail.com

unread,
May 21, 2014, 8:48:01 AM5/21/14
to ope...@googlegroups.com, ich...@gmail.com
sendMail is broken out-of-the-box. I'm on 1.5 and I get the error sendMail(<XStringLiteralImpl>,<XStringLiteralImpl>,<XStringLiteralImpl>,<XStringLiteralImpl>) every time my rule executes. Rule executes as expected without problems but this call always fails. Mail action is on the addons folder and SMTP configuration set in the cfg file.

Please advise. Thanks

Pablo Slavkin

unread,
May 21, 2014, 7:59:55 PM5/21/14
to ope...@googlegroups.com, ich...@gmail.com, lozano....@gmail.com
Hi, I'd the same problem and partially solve that becouse is related to action bug. the case is that if you run an action (for example sendComand, postComand, or something like that )BEFORE the jar was loaded CRUNCH! and never resume, even after the jar was loaded .
read that issue: https://github.com/openhab/openhab/issues/457
And the jar loading order is not costumized.. so my workaround was to do NOTHING on the startup action role and so, and voala!
BUT... the second part not solved yet is after that , the senMail works, but fail connecting the server with an error like the final text attached.. 
so if you solve the second part, let me know.. i'm wasting a hole day to send a misserably mail without succes.. 
luck!

------------------------------------------------------------------
0:46:33.525 ERROR o.o.action.mail.internal.Mail[:122] - Could not send e-mail to 'xx‘.
org.apache.commons.mail.EmailException: Sending the email to the following server failed : mail.xx:587
at org.apache.commons.mail.Email.sendMimeMessage(Email.java:1242)
Caused by: javax.mail.SendFailedException: Send failure (javax.mail.MessagingException: Failure sending HELO command to SMTP server)
at javax.mail.Transport.send(Transport.java:163)
Caused by: javax.mail.MessagingException: Failure sending HELO command to SMTP server
at org.apache.geronimo.javamail.transport.smtp.SMTPTransport.sendHelo(SMTPTransport.java:1914)
20:46:33.534 ERROR o.o.c.s.ScriptExecutionThread[:50] - Error during the execut
------------------------------------------------------------------------

so, the problem 

lozano....@gmail.com

unread,
May 22, 2014, 1:45:54 PM5/22/14
to ope...@googlegroups.com, ich...@gmail.com, lozano....@gmail.com
I think the implementation is simply broken. I don't experience issues with start-up rules. The rule I have executes when my devices send an update of its status. I put some logging and I see the logs in the files and the console but when the sendEmail cmd comes to execute it brakes. So, I decided to go with the pushOver command. I wanted to avoid paying 5 bucks for the app.. just because I'm pro-I-want-everything-for-free, but my rule alerts me when my alarm is on and one of my motion detectors fires up.. so.. I mean.. yeah, pushOver better than emails in this case.

Thanks

Kai Kreuzer

unread,
May 22, 2014, 3:00:43 PM5/22/14
to ope...@googlegroups.com, ich...@gmail.com, lozano....@gmail.com
Hi Lozano,

No, the mail action is not broken. I am using it successful and also in Pablos case it is called, but then has problems on the SMTP communication.
Whenever you get an exception with <XStringLiteralImpl>, it means that your action is not even recognized, so it does not even get the chance to work correctly.

Regards,
Kai


Kai Kreuzer

unread,
May 22, 2014, 3:03:45 PM5/22/14
to ope...@googlegroups.com, ich...@gmail.com, lozano....@gmail.com
the senMail works, but fail connecting the server with an error like the final text attached.. 

Could not send e-mail to ‚xx‘
Sending the email to the following server failed : mail.xx:587

Is mail.xx really the hostname of your SMTP server? And then „xx“ is not a valid e-mail address. If you correct this, I would assume that the mail action works for you.

Regards,
Kai


Kai Kreuzer

unread,
May 22, 2014, 3:08:08 PM5/22/14
to ope...@googlegroups.com
Thanks for your analysis.
I so far would have assumed that it has something to do with executing a rule once before an action is loaded.
But looking at your rule, it seems as if nothing is executed until everything should be fully started up and still it happens.
So do I get you right that merely adding the persistence logging bundle (did you have any configuration for it set up?) made the problem appear?
This would be a lead to further analyse and reproduce the problem.

Cheers,
Kai


lozano....@gmail.com

unread,
May 22, 2014, 5:18:41 PM5/22/14
to ope...@googlegroups.com
Kai, not sure if you are replying to my post or somebody else, but in my case, I just drooped the logging bundle into the addons folder which is.. mmm.. I think it's the default one. Any how, I didn't add any additional configuration. In fact, I added the logInfo call when I thought the rule wasn't executing. I'm sure that having logging or not the sendEmail cmd will brake. And again, this is 1.5 running on a MacMini with Java 1.6.x. 
I decided to used pushOver instead of insisting on send an email on the event.

Thanks

ich...@gmail.com

unread,
May 22, 2014, 6:29:39 PM5/22/14
to ope...@googlegroups.com
Kai,
Yes it's that.
The problem can appear even if all bundles are well loaded before the action is sent.
About the addon persistence, I did some test with other ones and I got the same result (the persistence was just an example). What is important is that, just by adding a bundle in the addons directory, it is possible to create the problem.

I have a config and addons files triggering the problem. How can I send it? (don't forget that the problem is machine dependant... and the same setup works perfeclty on other pc...).

Kai Kreuzer

unread,
May 25, 2014, 5:07:40 PM5/25/14
to ope...@googlegroups.com
Hi,

Thanks - I just spent (again) a few hours trying to reproduce the effect on my Raspberry Pi (which should be slow enough…) and I think I finally saw the effect (although it does not happen often and once I touch anything, it works again).

The odd thing is that it has nothing to do with the bundle loading order - what the issue title (https://github.com/openhab/openhab/issues/457) actually suggested.
If I add the action bundle after the system has started, everything works fine. After investigating for a while, I think we have an effect of a race condition here; in certain situations, the system simply does not notice that a new action has been started as it is just busy processing a different one.

I have just submitted a fix, which I could not yet test myself (as it needs a new build): https://github.com/openhab/openhab/commit/40f23783dcb3a8a9e16487113bc7c45cf10a7a40
In this fix, I have also added some logging, which could help further analysing the problem (if it still remains).

I would like to ask you to try out the latest build #638 from Jenkins (https://openhab.ci.cloudbees.com/job/openHAB/) and let me know, if it solves the problem for you.
It it does NOT solve it, please start your system with start_debug.sh and send me your logfile (from a startup which resulted in the problem).

Let’s touch wood!

Best regards,
Kai

ich...@gmail.com

unread,
May 26, 2014, 12:57:15 PM5/26/14
to ope...@googlegroups.com
Hello,
Sorry for the delay but I had lack of time those days.
I did my tests again and I have to correct what I said last time : I had a bad commented and bad writen startup rule in my config.
rule "Update max and min temperatures"
when
    System started
then   
    postUpdate(dummy,
end

If I correct the syntax error ( eg : postUpdate(dummy,ON) ) the problem disappears.

Except that, I confirm that I can reproduce the bug just by adding an addon and if I remove the addon the problem dissapears.
I join the config wich is the minimal one that create the problem.
In addons I just have the 3 squeezebox plugins, binding.http, binding.tcp and action.xpl.
If I remove action.xpl or if I correct the syntax error in the startup rule, the problem disappears.

If also join the debug logs with 3 starts and restarts of openhab without action.xpl (3 success in a row) and 3 others with the action.xpl (3 fail in a row).

I'll try your new build and tell you if it's better.
OpenHAB-1.5.zip
openhab-fail with xpl action.log
openhab-success without xpl action.log

ich...@gmail.com

unread,
May 26, 2014, 3:23:21 PM5/26/14
to ope...@googlegroups.com
Kai,
I tried the new build and still have the problem.
Here is the log.
openhab.log

Kai Kreuzer

unread,
May 26, 2014, 4:40:16 PM5/26/14
to ope...@googlegroups.com
s%#t….
Well, thanks, I’ll have a look at the logs.

Regards,
Kai

<openhab.log>

Kai Kreuzer

unread,
May 28, 2014, 4:19:01 PM5/28/14
to ope...@googlegroups.com
Hi,

Ok, again a few more hours with the debugger and I think I have finally found the problem and fixed it with this commit:

The build #641 (https://openhab.ci.cloudbees.com/job/openHAB/641/, currently running) should contain this fix - I am looking forward to your feedback and very, very much hope that it is now solved!

Best regards,
Kai

ich...@gmail.com

unread,
May 29, 2014, 6:19:47 AM5/29/14
to ope...@googlegroups.com
Hi,
It seems that you got it :)
I tried full configs on my to atom machines with the new build and every is working perfectly. No more action not recognized (xpl, squeezebox and sendmail - I was able to reproduce the sendmail action error too).
Congratulations!!
I hope other people will confirm that.

Kai Kreuzer

unread,
May 29, 2014, 6:20:48 AM5/29/14
to ope...@googlegroups.com
Thanks for the quick feedback, this is indeed very good news!!!

Cheers,
Kai

Kirk D Mccann

unread,
May 29, 2014, 2:27:18 PM5/29/14
to ope...@googlegroups.com
 When I moved the jar file out of the directory and back it reset.

-Kirk

Thanks and Have a Good Day,
Kirk McCann


--
You received this message because you are subscribed to a topic in the Google Groups "openhab" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/openhab/5VA2iWGuQ5Y/unsubscribe.
To unsubscribe from this group and all its topics, send an email to openhab+u...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages