This is why all the process was so complicated and here I describe the installation. Maybe your SMSC requires that setting too. My SMSC provider (virgin mobile) requires messaging mode «default» (esm-class = 0) instead of kannel’s default messaging mode «store and forward» (esm-class = 1). New version doesn’t either (lol), but we can change the source code, compile and install that «customized» version. Old version doesn’t let configure «esm-class = 0» in the nfig file With this configuration, when we specify the smsc in the HTTP request the sms will be routed to the smsc with that id, but when we don't, Kannel will fall back to a round-robin between smsc1 and smsc2.First, using «apt-get install kannel» is not recommended, because it will install an old version. default-smsc string If no SMSC ID is given with the HTTP request, use this one as default route for all push messages.Īnother option would be to use the denied-smsc-id variable: group = smsc.We can avoid this by setting a default SMSC to be used by all outgoing message with the following sendsms-user group variable: In this example, if we don't specify any smsc in the GET request, the sms will not match any of the rules for smsc1 or smsc2 and will not be sent. Where SMSC_ID can be one of smsc1 or smsc2. Now, we can specify what smsc to send through in the request to kannel sendsms interface: GET /kannel/sendsms?smsc=SMSC_ID&to=TO&text=TEXT In our kannel config file we add the following lines: group = smsc Suppose we have 2 SMSC, smsc1 and smsc2 and we want to route sms messages to one of those 2 SMSC. Juggling with these variables allows you to create from very simple to very complex routing scenarios. Multiple entries are separated with semicolons (' ') Preferred-smsc-id SMS messages with SMSC ID from this list are sent to this SMSC instead than to SMSC without that ID as preferred. Multiple entries are separated with semicolons (' ')Īllowed-smsc-id This list is opposite to previous: only SMS messages with SMSC ID in this list are ever routed to this SMSC. There are three SMSC parameters which control the routing to a specific SMSC:ĭenied-smsc-id SMS messages with SMSC ID equal to any of the IDs in this list are never routed to this SMSC. By default, Kannel will route the message in a round-robin way between all connected SMSCs.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |