It looks like you have enabled SMPP. You need to disable it.
Please let me know how to disable SMPP.
In your config fragment you don't have it, so I guess you omitted the most relevant part of the configuration. Just revert any other changes that you did.
@Anton I am sorry for asking, is there a line of code I need to add to turn off SMPP? because at the moment I can't find it and i added nothing else apart from what is posted above which came from the official source
Upload somewhere your configs, so we can check.
My Traccar.cml files looks like this
<?xml version='1.0' encoding='UTF-8'?>
<!DOCTYPE properties SYSTEM 'http://java.sun.com/dtd/properties.dtd'>
<properties>
<entry key='config.default'>./conf/default.xml</entry>
<!--
This is the main configuration file. All your configuration parameters should be placed in this file.
Default configuration parameters are located in the "default.xml" file. You should not modify it to avoid issues
with upgrading to a new version. Parameters in the main config file override values in the default file. Do not
remove "config.default" parameter from this file unless you know what you are doing.
For list of available parameters see following page: https://www.traccar.org/configuration-file/
-->
<entry key='database.driver'>org.h2.Driver</entry>
<entry key='database.url'>jdbc:h2:./data/database</entry>
<entry key='database.user'>sa</entry>
<entry key='database.password'></entry>
<!-- Working with SMS for Twilio, Added 16th Jan 2018 at 9:27AM -->
<entry key='notificator.types'>web,mail,sms</entry>
<entry key='notificator.sms.manager.class'>org.traccar.sms.HttpSmsClient</entry>
<entry key='sms.http.url'>https://api.twilio.com/2010-04-01/Accounts/A**************************/Messages.json</entry>
<entry key='sms.http.user'>A***************************</entry>
<entry key='sms.http.password'>c*********************************</entry>
<entry key='sms.http.template'>
From=%2B17135615254&To={phone}&Body={message}
</entry>
<!-- Added These Lines on January 12 2019 Because of connection issues to DB
<entry key='database.url'>jdbc:h2:/home/user/Documents/yourDataBaseName/target/database</entry>-->
</properties>
That is what I have, I have replaced the some Twilio credentials with asterisks (******)
What about default xml? Please upload it somewhere instead of posting directly into the forum comment.
Thanks @Anton, Here are the pasted details:
Traccar.xml: https://pastebin.com/PYNah6Wh
Default.cml: https://pastebin.com/gBhXcvAB
Thanks
Where did you get following line?
<entry key='sms.enable'>true</entry>
It's not part of the default configuration and you said you haven't changed anything other than what you showed originally, so how did it get there?
Hello, @Anton Like I said at the time of posting, I did nothing else, But as you know I was reading other official posts and this was recommended too. So I did add that line of code and also the ones at traccar.xml which I have shared. Please let me know how to turn off SMPP. Please!!
I would recommend you to re-install everything clean and do only what official documentation says.
From your original error message I know that the line was there when you first asked, so please don't lie.
@Anton why would I lie? I added this based on the official recommendations, will taking it off solve the issue? because I actually had to pay someone to upgrade from 4.0 to 4.2 as myself did it once as lost everything.
@Anton, I think I did everything correctly, I just restarted Traccar server and now the SMS works. Thanks for your support. Will be sending you a cup of coffee. Thank you so much. Will let you know when I make my donations
Thanks Guys, I get this error in my Logs :
WARN: SMS sending error - com.cloudhopper.smpp.type.SmppChannelException: SMPP session is not connected - MessageException (SmppClient:254 < *:264 < ...)
I have followed the tutorials here: https://www.traccar.org/http-sms-api/ and used the code below"
<entry key='notificator.types'>web,mail,sms</entry> <entry key='notificator.sms.manager.class'>org.traccar.sms.HttpSmsClient</entry> <entry key='sms.http.url'>https://api.twilio.com/2010-04-01/Accounts/[YOUR ACCOUNT SID]/Messages.json</entry> <entry key='sms.http.user'>[YOUR ACCOUNT SID]</entry> <entry key='sms.http.password'>[YOUR AUTH TOKEN]</entry> <entry key='sms.http.template'> From=[YOUR PHONE NUMBER]&To={phone}&Body={message} </entry>
NB: I encoded the + sign with %2B as required (I Hope)