| 1 |
IMS Usrloc SCSCF Module |
| 2 |
|
| 3 |
Jason Penton |
| 4 |
|
| 5 |
Smile Communications |
| 6 |
|
| 7 |
Edited by |
| 8 |
|
| 9 |
Richard Good |
| 10 |
|
| 11 |
Smile Communications |
| 12 |
|
| 13 |
Yasin Caner |
| 14 |
|
| 15 |
Copyright © 2012 Smile Communications |
| 16 |
__________________________________________________________________ |
| 17 |
|
| 18 |
Table of Contents |
| 19 |
|
| 20 |
1. Admin Guide |
| 21 |
|
| 22 |
1. Overview |
| 23 |
2. Dependencies |
| 24 |
|
| 25 |
2.1. Kamailio Modules |
| 26 |
|
| 27 |
3. Parameters |
| 28 |
|
| 29 |
3.1. db_url (string) |
| 30 |
3.2. db_mode (string) |
| 31 |
3.3. maxcontact (int) |
| 32 |
3.4. maxcontact_3gpp (int) |
| 33 |
3.5. maxcontact_behaviour (int) |
| 34 |
3.6. max_subscribes(int) |
| 35 |
3.7. sub_dialog_hash_size(int) |
| 36 |
3.8. timer_procs(int) |
| 37 |
3.9. timer_interval (int) |
| 38 |
3.10. desc_time_order (int) |
| 39 |
3.11. matching_mode (int) |
| 40 |
3.12. cseq_delay (int) |
| 41 |
3.13. fetch_rows(int) |
| 42 |
3.14. hash_size (int) |
| 43 |
3.15. subs_hash_size (int) |
| 44 |
3.16. contacts_hash_size (integer) |
| 45 |
3.17. nat_bflag (integer) |
| 46 |
3.18. contact_delete_delay (int) |
| 47 |
3.19. support_wildcardPSI (int) |
| 48 |
3.20. unreg_validity (int) |
| 49 |
3.21. user_data_xsd (string) |
| 50 |
3.22. realm (string) |
| 51 |
3.23. skip_realm (int) |
| 52 |
|
| 53 |
4. RPC Commands |
| 54 |
|
| 55 |
4.1. ulscscf.status |
| 56 |
4.2. ulscscf.showimpu |
| 57 |
4.3. ulscscf.snapshot |
| 58 |
|
| 59 |
2. Frequently Asked Questions |
| 60 |
|
| 61 |
List of Examples |
| 62 |
|
| 63 |
1.1. Set db_url parameter |
| 64 |
1.2. Set db_mode parameter |
| 65 |
1.3. Set maxcontact parameter |
| 66 |
1.4. Set maxcontact_3gpp parameter |
| 67 |
1.5. Set maxcontact_behaviour parameter |
| 68 |
1.6. Set max_subscribes parameter |
| 69 |
1.7. Set sub_dialog_hash_size parameter |
| 70 |
1.8. Set timer_procs parameter |
| 71 |
1.9. Set timer_interval parameter |
| 72 |
1.10. Set desc_time_order parameter |
| 73 |
1.11. Set matching_mode parameter |
| 74 |
1.12. Set cseq_delay parameter |
| 75 |
1.13. Set fetch_rows parameter |
| 76 |
1.14. Set hash_size parameter |
| 77 |
1.15. Set subs_hash_size parameter |
| 78 |
1.16. Set contacts_hash_size parameter |
| 79 |
1.17. Set nat_bflag parameter |
| 80 |
1.18. Set contact_delete_delayparameter |
| 81 |
1.19. Set support_wildcardPSI parameter |
| 82 |
1.20. Set unreg_validity parameter |
| 83 |
1.21. Set unreg_validity parameter |
| 84 |
1.22. Set realm parameter |
| 85 |
1.23. Set skip_realm parameter |
| 86 |
|
| 87 |
Chapter 1. Admin Guide |
| 88 |
|
| 89 |
Table of Contents |
| 90 |
|
| 91 |
1. Overview |
| 92 |
2. Dependencies |
| 93 |
|
| 94 |
2.1. Kamailio Modules |
| 95 |
|
| 96 |
3. Parameters |
| 97 |
|
| 98 |
3.1. db_url (string) |
| 99 |
3.2. db_mode (string) |
| 100 |
3.3. maxcontact (int) |
| 101 |
3.4. maxcontact_3gpp (int) |
| 102 |
3.5. maxcontact_behaviour (int) |
| 103 |
3.6. max_subscribes(int) |
| 104 |
3.7. sub_dialog_hash_size(int) |
| 105 |
3.8. timer_procs(int) |
| 106 |
3.9. timer_interval (int) |
| 107 |
3.10. desc_time_order (int) |
| 108 |
3.11. matching_mode (int) |
| 109 |
3.12. cseq_delay (int) |
| 110 |
3.13. fetch_rows(int) |
| 111 |
3.14. hash_size (int) |
| 112 |
3.15. subs_hash_size (int) |
| 113 |
3.16. contacts_hash_size (integer) |
| 114 |
3.17. nat_bflag (integer) |
| 115 |
3.18. contact_delete_delay (int) |
| 116 |
3.19. support_wildcardPSI (int) |
| 117 |
3.20. unreg_validity (int) |
| 118 |
3.21. user_data_xsd (string) |
| 119 |
3.22. realm (string) |
| 120 |
3.23. skip_realm (int) |
| 121 |
|
| 122 |
4. RPC Commands |
| 123 |
|
| 124 |
4.1. ulscscf.status |
| 125 |
4.2. ulscscf.showimpu |
| 126 |
4.3. ulscscf.snapshot |
| 127 |
|
| 128 |
1. Overview |
| 129 |
|
| 130 |
This module serves as a storage engine for SCSCF contacts, much like |
| 131 |
the standard Kamailio module that is usrloc, is a storage engine for |
| 132 |
standard SIP contacts. |
| 133 |
|
| 134 |
2. Dependencies |
| 135 |
|
| 136 |
2.1. Kamailio Modules |
| 137 |
|
| 138 |
2.1. Kamailio Modules |
| 139 |
|
| 140 |
The following modules must be loaded before this module: |
| 141 |
* TM |
| 142 |
* Presence |
| 143 |
* IMS dialog |
| 144 |
|
| 145 |
3. Parameters |
| 146 |
|
| 147 |
3.1. db_url (string) |
| 148 |
3.2. db_mode (string) |
| 149 |
3.3. maxcontact (int) |
| 150 |
3.4. maxcontact_3gpp (int) |
| 151 |
3.5. maxcontact_behaviour (int) |
| 152 |
3.6. max_subscribes(int) |
| 153 |
3.7. sub_dialog_hash_size(int) |
| 154 |
3.8. timer_procs(int) |
| 155 |
3.9. timer_interval (int) |
| 156 |
3.10. desc_time_order (int) |
| 157 |
3.11. matching_mode (int) |
| 158 |
3.12. cseq_delay (int) |
| 159 |
3.13. fetch_rows(int) |
| 160 |
3.14. hash_size (int) |
| 161 |
3.15. subs_hash_size (int) |
| 162 |
3.16. contacts_hash_size (integer) |
| 163 |
3.17. nat_bflag (integer) |
| 164 |
3.18. contact_delete_delay (int) |
| 165 |
3.19. support_wildcardPSI (int) |
| 166 |
3.20. unreg_validity (int) |
| 167 |
3.21. user_data_xsd (string) |
| 168 |
3.22. realm (string) |
| 169 |
3.23. skip_realm (int) |
| 170 |
|
| 171 |
3.1. db_url (string) |
| 172 |
|
| 173 |
database URL for storing impu/contacts records |
| 174 |
|
| 175 |
Example 1.1. Set db_url parameter |
| 176 |
... |
| 177 |
modparam("ims_usrloc_scscf", "db_url", "mysql//username:password@localho |
| 178 |
st/scscf") |
| 179 |
... |
| 180 |
|
| 181 |
3.2. db_mode (string) |
| 182 |
|
| 183 |
This is the database mode to be used for the SCSCF usrloc data |
| 184 |
persistent storage. Currently this module supports the Write-Back |
| 185 |
scheme only. |
| 186 |
* 0 - This disables database completely. Only memory will be used. |
| 187 |
Contacts will not survive restart. |
| 188 |
* 1 - Write-Backend scheme. All changes are made to memory and |
| 189 |
database synchronization is done in the timer |
| 190 |
|
| 191 |
Default value is 0. |
| 192 |
|
| 193 |
Example 1.2. Set db_mode parameter |
| 194 |
... |
| 195 |
modparam("ims_usrloc_scscf", "db_mode", 1) |
| 196 |
... |
| 197 |
|
| 198 |
3.3. maxcontact (int) |
| 199 |
|
| 200 |
The parameter can be used to limit the number of contact for each impu |
| 201 |
|
| 202 |
Default value is 0(max) |
| 203 |
|
| 204 |
Example 1.3. Set maxcontact parameter |
| 205 |
... |
| 206 |
modparam("ims_usrloc_scscf", "maxcontact", 10) |
| 207 |
... |
| 208 |
|
| 209 |
3.4. maxcontact_3gpp (int) |
| 210 |
|
| 211 |
The parameter can be used to limit the number of 3GPP contact for each |
| 212 |
impu |
| 213 |
|
| 214 |
Default value is 0.(max) |
| 215 |
|
| 216 |
Example 1.4. Set maxcontact_3gpp parameter |
| 217 |
... |
| 218 |
modparam("ims_usrloc_scscf", "maxcontact_3gpp", 0) |
| 219 |
... |
| 220 |
|
| 221 |
3.5. maxcontact_behaviour (int) |
| 222 |
|
| 223 |
Behaviour of usrloc , after impu reach max contacts limit. |
| 224 |
* 0 - Disabled |
| 225 |
* 1 - Reject after reaching limit. |
| 226 |
* 2 - Overwrite |
| 227 |
|
| 228 |
Default value is 0. |
| 229 |
|
| 230 |
Example 1.5. Set maxcontact_behaviour parameter |
| 231 |
... |
| 232 |
modparam("ims_usrloc_scscf", "maxcontact_behaviour", 2) |
| 233 |
... |
| 234 |
|
| 235 |
3.6. max_subscribes(int) |
| 236 |
|
| 237 |
Max number of subscribes allowed per watcher for each IMPU |
| 238 |
|
| 239 |
Default value is 0. |
| 240 |
|
| 241 |
Example 1.6. Set max_subscribes parameter |
| 242 |
... |
| 243 |
modparam("ims_usrloc_scscf", "max_subscribes", 2) |
| 244 |
... |
| 245 |
|
| 246 |
3.7. sub_dialog_hash_size(int) |
| 247 |
|
| 248 |
Subscriber dialog hash table size |
| 249 |
|
| 250 |
Default value is 10. |
| 251 |
|
| 252 |
Example 1.7. Set sub_dialog_hash_size parameter |
| 253 |
... |
| 254 |
modparam("ims_usrloc_scscf", "sub_dialog_hash_size", 512) |
| 255 |
... |
| 256 |
|
| 257 |
3.8. timer_procs(int) |
| 258 |
|
| 259 |
process number of handling registeration |
| 260 |
|
| 261 |
Default value is 0 |
| 262 |
|
| 263 |
Example 1.8. Set timer_procs parameter |
| 264 |
... |
| 265 |
modparam("ims_usrloc_scscf", "timer_procs", 5) |
| 266 |
... |
| 267 |
|
| 268 |
3.9. timer_interval (int) |
| 269 |
|
| 270 |
Number of seconds between two timer runs. The module uses a timer to |
| 271 |
delete expired contacts, synchronize with database and other tasks, |
| 272 |
that need to be run periodically |
| 273 |
|
| 274 |
Default value is 90 |
| 275 |
|
| 276 |
Example 1.9. Set timer_interval parameter |
| 277 |
... |
| 278 |
modparam("ims_usrloc_scscf", "timer_interval", 120) |
| 279 |
... |
| 280 |
|
| 281 |
3.10. desc_time_order (int) |
| 282 |
|
| 283 |
If the user's contacts should be kept timestamp ordered; otherwise the |
| 284 |
contact will be ordered based on q value. Non 0 value means true. |
| 285 |
|
| 286 |
Default value is timestamp ordering not enabled |
| 287 |
|
| 288 |
Example 1.10. Set desc_time_order parameter |
| 289 |
... |
| 290 |
modparam("ims_usrloc_scscf", "desc_time_order", 1) |
| 291 |
... |
| 292 |
|
| 293 |
3.11. matching_mode (int) |
| 294 |
|
| 295 |
What contact matching algorithm to be used. |
| 296 |
* 0 - Contact Only matching |
| 297 |
* 1 - Contact and Callid Matching |
| 298 |
* 2 - Contact and Path header matching |
| 299 |
* 3 - Only contact IP and Port Matching |
| 300 |
|
| 301 |
Default value is 0. |
| 302 |
|
| 303 |
Example 1.11. Set matching_mode parameter |
| 304 |
... |
| 305 |
modparam("ims_usrloc_scscf", "matching_mode", 0) |
| 306 |
... |
| 307 |
|
| 308 |
3.12. cseq_delay (int) |
| 309 |
|
| 310 |
Delay (in seconds) for accepting as retransmissions register requests |
| 311 |
with same Call-ID and Cseq. |
| 312 |
|
| 313 |
Default value is 20. |
| 314 |
|
| 315 |
Example 1.12. Set cseq_delay parameter |
| 316 |
... |
| 317 |
modparam("ims_usrloc_scscf", "cseq_delay", 20) |
| 318 |
... |
| 319 |
|
| 320 |
3.13. fetch_rows(int) |
| 321 |
|
| 322 |
The number of the rows to be fetched at once from database when loading |
| 323 |
the location records. |
| 324 |
|
| 325 |
Default value is 2000. |
| 326 |
|
| 327 |
Example 1.13. Set fetch_rows parameter |
| 328 |
... |
| 329 |
modparam("ims_usrloc_scscf", "fetch_rows", 3000) |
| 330 |
... |
| 331 |
|
| 332 |
3.14. hash_size (int) |
| 333 |
|
| 334 |
The number of entries of the hash table used by usrloc |
| 335 |
|
| 336 |
Default value 512 |
| 337 |
|
| 338 |
Example 1.14. Set hash_size parameter |
| 339 |
... |
| 340 |
modparam("ims_usrloc_scscf", "hash_size", 512) |
| 341 |
... |
| 342 |
|
| 343 |
3.15. subs_hash_size (int) |
| 344 |
|
| 345 |
The number of entries of the hash table used by usrloc to store the ims |
| 346 |
subscribe records |
| 347 |
|
| 348 |
Default value 512 |
| 349 |
|
| 350 |
Example 1.15. Set subs_hash_size parameter |
| 351 |
... |
| 352 |
modparam("ims_usrloc_scscf", "subs_hash_size", 512) |
| 353 |
... |
| 354 |
|
| 355 |
3.16. contacts_hash_size (integer) |
| 356 |
|
| 357 |
The number of entries of the hash table used by usrloc to store the |
| 358 |
contact records |
| 359 |
|
| 360 |
Default value is 512 |
| 361 |
|
| 362 |
Example 1.16. Set contacts_hash_size parameter |
| 363 |
... |
| 364 |
modparam("ims_usrloc_scscf", "contacts_hash_size", 512) |
| 365 |
... |
| 366 |
|
| 367 |
3.17. nat_bflag (integer) |
| 368 |
|
| 369 |
NAT marker to handle natted registration |
| 370 |
|
| 371 |
Default value is 0 |
| 372 |
|
| 373 |
Example 1.17. Set nat_bflag parameter |
| 374 |
... |
| 375 |
modparam("ims_usrloc_scscf", "nat_bflag", 3) |
| 376 |
... |
| 377 |
|
| 378 |
3.18. contact_delete_delay (int) |
| 379 |
|
| 380 |
If contact is put into delay delete state, this is how long we delay |
| 381 |
before deleting |
| 382 |
|
| 383 |
Default value is 30 |
| 384 |
|
| 385 |
Example 1.18. Set contact_delete_delayparameter |
| 386 |
... |
| 387 |
modparam("ims_usrloc_scscf", "contact_delete_delay", 32) |
| 388 |
... |
| 389 |
|
| 390 |
3.19. support_wildcardPSI (int) |
| 391 |
|
| 392 |
Wildcard Public-Service-Identity (RFC5002). it will be actived by |
| 393 |
setting 1 |
| 394 |
|
| 395 |
Default value is 0.(disabled) |
| 396 |
|
| 397 |
Example 1.19. Set support_wildcardPSI parameter |
| 398 |
modparam("ims_usrloc_scscf", "support_wildcardPSI", 0) |
| 399 |
|
| 400 |
3.20. unreg_validity (int) |
| 401 |
|
| 402 |
Default validity time in seconds for unregister assignment to SCSCF |
| 403 |
|
| 404 |
Default value is 1800 |
| 405 |
|
| 406 |
Example 1.20. Set unreg_validity parameter |
| 407 |
... |
| 408 |
modparam("ims_usrloc_scscf", "unreg_validity", 0) |
| 409 |
... |
| 410 |
|
| 411 |
3.21. user_data_xsd (string) |
| 412 |
|
| 413 |
Default value is 1800 |
| 414 |
|
| 415 |
Example 1.21. Set unreg_validity parameter |
| 416 |
... |
| 417 |
modparam("ims_usrloc_scscf", "user_data_xsd", "/usr/local/etc/kamailio/C |
| 418 |
xDataType_Rel6.xsd") |
| 419 |
... |
| 420 |
|
| 421 |
3.22. realm (string) |
| 422 |
|
| 423 |
Default value is NULL |
| 424 |
|
| 425 |
Example 1.22. Set realm parameter |
| 426 |
... |
| 427 |
modparam("ims_usrloc_scscf", "realm", "kamailio-ims.org") |
| 428 |
... |
| 429 |
|
| 430 |
3.23. skip_realm (int) |
| 431 |
|
| 432 |
Skipping defined network name in the realm for NOTIFY's Message body |
| 433 |
reginfo tag. |
| 434 |
|
| 435 |
Default value is 0 |
| 436 |
|
| 437 |
Example 1.23. Set skip_realm parameter |
| 438 |
... |
| 439 |
modparam("ims_usrloc_scscf", "skip_realm", 1) |
| 440 |
... |
| 441 |
|
| 442 |
4. RPC Commands |
| 443 |
|
| 444 |
4.1. ulscscf.status |
| 445 |
4.2. ulscscf.showimpu |
| 446 |
4.3. ulscscf.snapshot |
| 447 |
|
| 448 |
Exported RPC commands. |
| 449 |
|
| 450 |
4.1. ulscscf.status |
| 451 |
|
| 452 |
4.2. ulscscf.showimpu |
| 453 |
|
| 454 |
4.3. ulscscf.snapshot |
| 455 |
|
| 456 |
Chapter 2. Frequently Asked Questions |
| 457 |
|
| 458 |
2.1. Where can I find more about Kamailio? |
| 459 |
2.2. Where can I post a question about this module? |
| 460 |
2.3. How can I report a bug? |
| 461 |
|
| 462 |
2.1. |
| 463 |
|
| 464 |
Where can I find more about Kamailio? |
| 465 |
|
| 466 |
Take a look at https://www.kamailio.org/. |
| 467 |
|
| 468 |
2.2. |
| 469 |
|
| 470 |
Where can I post a question about this module? |
| 471 |
|
| 472 |
First at all check if your question was already answered on one of our |
| 473 |
mailing lists: |
| 474 |
* User Mailing List - |
| 475 |
https://lists.kamailio.org/mailman3/postorius/lists/sr-users.lists. |
| 476 |
kamailio.org/ |
| 477 |
* Developer Mailing List - |
| 478 |
https://lists.kamailio.org/mailman3/postorius/lists/sr-dev.lists.ka |
| 479 |
mailio.org/ |
| 480 |
|
| 481 |
E-mails regarding any stable Kamailio release should be sent to |
| 482 |
<[email protected]> and e-mails regarding development |
| 483 |
versions should be sent to <[email protected]>. |
| 484 |
|
| 485 |
2.3. |
| 486 |
|
| 487 |
How can I report a bug? |
| 488 |
|
| 489 |
Please follow the guidelines provided at: |
| 490 |
https://github.com/kamailio/kamailio/issues. |