forked from kamailio/kamailio
-
Notifications
You must be signed in to change notification settings - Fork 0
/
INSTALL
698 lines (544 loc) · 25.9 KB
/
INSTALL
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
==================================================
Kamailio SIP Server Installation Notes
http://www.kamailio.org
==================================================
Welcome! This is an amazingly flexible, robust and secure SIP server
built on years of experience in several Open Source projects. It's a merge
of the SIP Express Router (SER) and the Kamailio (OpenSER) products produced
by a joint development team.
This memo gives you hints on how to set up the Kamailio quickly.
You can find a similar tutorial and many more on project's web site:
- https://www.kamailio.org/w/documentation/
- https://www.kamailio.org/wiki/
Table of Contents
=================
1. Supported Architectures And Requirements
2. How-To Build Kamailio From The Source Code Distribution
2.1 Kamailio Fast Track Installation
2.2 Details Installing From Source Code
A) Build Commands
3. Quick-Start Installation Guide
A) Getting Help
B) Disclaimers
C) Quick Start
D) Kamailio With Persistent Data Storage
4. Troubleshooting
1. Supported Architectures And Requirements
-------------------------------------------
Supported operating systems:
- Linux (Debian, Ubuntu, Fedora, RedHat, CentOS, OpenSUSE, Gentoo, a.s.o.)
- FreeBSD, NetBSD, OpenBSD, Dragonfly BSD
- Solaris
- OS/X, Darwin
Note that some modules have dependencies on the Linux operating system.
This is clearly noted in the README files.
Partially supported
- Windows+Cygwin (core + static modules only, no IPv6, no
TCP, no dynamic modules)
Supported architectures
- i386, x86_64 (amd64), armv4l, sparc64, powerpc, powerpc64
Experimental architectures:
- mips1, mips2, sparc32, alpha
(for other architectures the Makefiles might need to be edited)
There are various configuration options defined in the Makefile.
Requirements:
- gcc or clang:
gcc >= 2.9x; 3.[12] recommended (it will work with older version
but it might require some options tweaking for best performance)
clang >= version 3.3
- bison or yacc (Berkley Yacc)
- flex
- GNU make (on Linux this is the standard "make", on *BSD and Solaris it is
called "gmake") version >= 3.80 (recommended 3.81).
- sed and tr (used in the makefiles)
- GNU tar ("gtar" on Solaris) and gzip if you want "make tar" to work
- GNU install, BSD install or Solaris install if you want "make
install", "make bin", "make sunpkg" to work
- libmysqlclient & libz (zlib) if you want MySQL support (the db_mysql module)
- libxml2 if you want to compile the cpl-c (CPL support) or pa (presence)
modules
- freeradius, radcli or libradiusclient-ng (> 5.0) if you need RADIUS support
(the auth_radius, acc_radius and misc_radius modules)
- libpq if you need PostgreSQL support (the db_postgres module)
- libexpat if you want the jabber gateway support (the jabber module) or the
XMPP gateway support
- libxml2 if you want to use the cpl-c (Call Processing Language) or
the presence modules (presence and pua*)
- libradius-ng -libs and devel headers- if you want to use functionalities
with radius support - authentication, accounting, group support, etc
- unixodbc - libs and devel headers - if you want UNIXODBC support as
DB underlayer
- libperl - libs and devel headers - if you want the perl connector to support
perl scripting from your config file (perl module)
- libsnmp9 - libs and devel headers - if you want SNMP client functionality
(SNMP AgentX subagent) for Kamailio
- libldap libs and devel headers v2.1 or greater - if you want LDAP support
- libpcre libs and devel headers - if you want to compile the lcr and dialplan
modules
- libsctp devel headers - if you want to compile the SCTP transport in the core
- libssl devel headers (openssl project) - if you want to compile the TLS module
- libunistring - for the WebSocket module
- python and devel headers for the Python module
- jdk and gcj for Java module
- the jansson library for the jansson module used for JSON document handling
Some modules have other requirements on third-party libraries. This is documented
in the README for the specific module.
OS Notes:
FreeBSD/OpenBSD/NetBSD: make sure gmake, bison or yacc & flex are installed.
FreeBSD 5.4:
------------
If you want to compile all the modules, you will need the following packages:
- mysql-client-* (any version, install one of the mysql*-client ports) for
libmysqlclient
- postgresql-libpqxx-2.4.2_1 (/usr/ports/databases/postgresql-libpqxx) for
libpq
- expat-1.95.8 (/usr/ports/textproc/expat2) for libexpat
- libxml2-2.6.18 (/usr/ports/textproc/libxml2) for libxml2
- radiusclient-0.4.7 (/usr/ports/net/radiusclient) for libradiusclient-ng
NOTE: you'll need to add radiusclient_ng=4 to the gmake command line if you
use the 0.4.* version.
Compile example (all the modules and SIP server core in a tar.gz):
gmake bin radiusclient_ng=4 include_modules="mysql jabber cpl-c auth_radius group_radius uri_radius postgres pa"
OpenBSD 3.7
-----------
- mysql-client-4.0.23 (/usr/ports/databases/mysql) for libmysqlclient
- expat-1.95.6 (/usr/ports/textproc/expat) for libexpat
- libxml-2.6.16p0 (/usr/ports/textproc/libxml) for libxml2
- radiusclient-ng-0.5.1 from
http://download.berlios.de/radiusclient-ng/radiusclient-ng-0.5.1.tar.gz
(you need to download and install it, since there is no "official"
openbsd port for it) for libradiusclient-ng
Compile example (all the modules and SIP server core in a tar.gz):
gmake bin include_modules="mysql jabber cpl-c auth_radius group_radius uri_radius pa"
NetBSD 2.0
----------
- mysql-client-4.1.12 (/usr/pkgsrc/databases/mysql4-client) for libmysqlclient
- expat-1.95.8nb2 (/usr/pkgsrc/textproc/expat) for libexpat
- libxml2-2.6.19 (/usr/pkgsrc/textproc/libxml2) for libxml2
- radiusclient-ng-0.5.1 (see OpenBSD)
Compile example (all the modules and SIP server in a tar.gz):
gmake bin include_modules="mysql jabber cpl-c auth_radius group_radius uri_radius pa"
Solaris 10
----------
As above; you can use Solaris's yacc instead of bison. You might also
need gtar and ginstall. If you don't have ginstall you can use Solaris
install, just make sure it's in the PATH (it's usually in /usr/sbin) and
add INSTALL=install either to the environment or to the make command line
(e.g.: gmake INSTALL=install all).
Compile example (all the modules and SIP server in a tar.gz):
gmake bin INSTALL=install include_modules="mysql jabber cpl-c auth_radius group_radius uri_radius postgres pa"
Linux
-----
Kamailio is part of the official Debian distribution. You can download binary modules
directly using normal packet management.
Needed packages for compiling all the modules:
* Debian:
- libmysqlclient-dev for libmysqlclient
- libpq-dev for libpq
- libexpat1-dev for libexpat
- libxml2-dev for libxml2
- libradiusclient-ng-dev for libradiusclient
- other libraries are needed for some other modules,
see README of the module you want to use
Kamailio have APT deb repositories that allow you to
install the binaries easily - see the web site for more details:
- http://kamailio.org
Cygwin (alpha state, partial support)
--------------------------------------
make sure make, bison, flex, minires and minires-devel (needed for the
resolver functions) are installed.
Only building Kamailio's core and some static modules is supported for now.
Stuff known not to work:
- IPv6 (cygwin doesn't support it yet)
- TCP (the tcp code heavily depends on file descriptor passing
between processes, which is not yet supported by cygwin)
- dynamic modules (non statically linked -- not supported because
backlinking doesn't work in windows by design)
Compile example (all the modules and Kamailio in a tar.gz):
make bin include_modules="mysql jabber cpl-c auth_radius group_radius uri_radius postgres pa"
2. Howto Build Kamailio From Source Code Distribution
-------------------------------------------------------
(NOTE: if make doesn't work try gmake instead)
2.1 Kamailio Fast Track Installation
....................................
If you are familiar with Unix/Linux build tools aready and you installed
the required dependencies, then you can just follow this section, otherwise
skip over it.
To get Kamailio installed, in the folder with source code run:
make cfg
make all
make install
If you want to install with additional modules, for example with mysql and
tls, run:
make include_modules="db_mysql tls" cfg
make all
make install
2.2 Details - Installing From Source Code
.........................................
Build Commands
Kamailio is split in four main parts: The core, the modules, the
utilities, and the various scripts/examples. When you build, you can decide to build
only the core, the modules, both, or all.
* Compile Kamailio core only:
make
Compile modules except some explicitly excepted (see below)
make modules - all modules in the modules/ directory
make modules-all or make every-module - all the modules
* Compile all:
make all
* Explicitly excepted modules:
By default make all will not build modules that require external libraries or
that are considered to be "experimental". For example, modules that have external
dependencies are: db_mysql, jabber, cpl-c, auth_radius, group_radius, uri_radius,
avp_radius, db_postgres, db_berkeley, carrierroute, ...
Including groups of modules:
Instead of compiling the default modules only, you can specify groups of
modules to include, according to their status:
- standard - Modules in this group are considered a standard part of Kamailio
(due to widespread usage) but they have no dependencies (note that some of
these interplay with external systems. However, they don't have compile
or link dependencies).
- db - Modules in this group use databases and need a database driver to run.
Included are drivers for the text mode db (dbtext) and for dumping
large amount of data to files (db_flatstore). See also the mysql or
postgres groups.
- standard_dep - Modules in this group are considered a standard part of Kamailio
(due to widespread usage) but they have dependencies that must be satisfied
for compilation.
NOTE! All presence modules (dialog, pa, presence_b2b, rls, xcap) have been
included in this group due to interdependencies
- stable - Modules in this group satisfy specific or niche applications,
and are considered stable for production use. They may or may not have dependencies
- experimental - Modules in this group are either not complete, untested, or
without enough reports of usage to allow the module into the stable group.
They may or may not have dependencies.
There is another set of groups mainly used by Kamailio, where modules
are grouped based on Debian packaging rules. For example:
- kstandard - Kamailio standard modules
- kpresence - Kamailio SIMPLE presence server modules
* To compile core with standard modules:
make group_include="standard" all
* To compile all modules (provided you have all the required libraries installed) use:
make group_include="standard standard-dep stable experimental" all
There are also in addition some "convenience" groups:
mysql - Include all the db modules dependent and the MySQL db driver
postgres - Include all the db modules and the PostgreSQL db driver
radius - Include all modules on radiusclient
presence - Include all the presence modules
Ex. to make a standard installation with MySQL, use:
make group_include="standard mysql" all
In addition to group_include (or instead), you can use
include_modules="modA modB"
to specify exactly the modules you want to include, ex.
make include_modules="mymodule" modules
You can also explicitly skip modules using skip_modules. Let's say you want all
the standard and standard-dep modules except domain:
make group_include="standard standard-dep" skip_modules="domain" all
NOTE!!! As this mechanism is very powerful, you may be uncertain which
modules that will be included. Just replace all (or modules) with print-modules
and you will see which modules will be included and excluded, ex:
make print-modules
will show which modules are excluded by default.
If you want to install or to build a binary package (a tar.gz with
Kamailio core and the modules), substitute "all" in the above command with
"install" or "bin".
* More compile examples:
- compile with profiling
make PROFILE=-pg all
- compile debug mode version
make mode=debug all
- compile debug version with profiling
make mode=debug PROFILE=-pg all
- compile only the print module
make modules=modules/print modules
- compile by default only the print module, in debuging mode and with
profiling:
make cfg modules=modules/print mode=debug PROFILE=-pg
make all
- change & save the modules list without rebuilding the whole config
(so that already compiled modules won't be re-compiled by
make all/make modules):
make modules-cfg include_modules="mysql postgress"
- change only the compile/build options, without changing the modules list:
make cfg-defs CPU=ultrasparc PROFILE=-pg
- compile by default all the usual modules + mysql and postgres, optimized
for pentium-m and for space (saves both the build options and the module
list)
make cfg include_modules="mysql postgres" CPU=pentium-m CC_EXTRA_OPTS=-Os
make all
- compile all the "default" modules except textops and vm
make skip_modules="textops vm" modules
- save the above option in the make config, so that all make commands
will use it by default:
make cfg skip_modules="textops vm"
- compile all default modules and include uri_radius (not compiled by default):
make include_modules="uri_radius" modules
- compile all the modules from the modules subdirectory (even the one excluded
by default):
make exclude_modules="" modules
- compile all the modules from the modules subdirectory excluding vm:
make exclude_modules=vm modules
or
make exclude_modules="" skip_modules=vm modules
- compile with the "tm" module statically linked and with profiling
make static_modules=tm PROFILE=-pg all
- compile with gcc-3.2 instead of gcc
make CC=gcc-3.2 all
or
CC=gcc-3.2 make all
Make targets:
=============
Make Local Build Config:
------------------------
* make cfg or make config - force config and module list regeneration
Example:
make cfg include_modules=mysql mode=debug
All future make invocations will include the mysql module and will build in debug mode
Note: If config.mak doesn't exist (e.g. initial checkout or after a make
proper) or if Makefile.defs was changed, the config will be re-generated
automatically by the first make command. For example:
make cfg include_modules=db_mysql; make all
is equivalent to
rm config.mak modules.lst; make include_modules=db_mysql.
* make cfg-defs (force config regeneration, but don't touch the module list)
Example:
make cfg-defs CPU=ultrasparc CC_EXTRA_OPTS=-Os PROFILE=-pg
make modules-cfg
or
make modules-list
saves the module list, without regenerating the build config
Example:
make modules-list include_modules="tls" skip_modules="print"
Clean:
------
* make clean - clean the base and modules too
* make proper - clean also the dependencies and the config, but not the module list
* make distclean - the same as proper
* make maintainer-clean - clean everything, including make's config, saved
module list, auto generated files, tags, *.dbg a.s.o
* make clean-all - clean all the modules in modules/*
* make proper-all - like make proper but for all the modules in modules/*
Config clean:
* make clean-cfg - cleans the compile config
* make clean-modules-cfg - cleans the modules list
Reduced clean:
* make local-clean - cleans only the core, no libs, utils or modules
* make clean-modules - like make clean, but cleans only the modules
* make clean-libs - like make clean, but cleans only the libs
* make clean-utils - like make clean, but cleans only the utils
Compile:
--------
* make proper
optional: make cfg <various cfg. options that should be saved>
* make proper-modules - like make proper, but only for modules
* make proper-libs - like make proper, but only for libs
* make proper-utils - like make proper, but only for utils
* make
or gmake on non-Linux systems
* make modules
or make modules exclude_modules="CVS print" etc.
Other Make Targets:
-------------------
Make tags:
make TAGS
Create a tar.gz with the sources (in ../):
make tar
Create a tar.gz with the binary distribution (in ../):
make bin
Create a gzipped solaris package (in ../):
make sunpkg
Create debian packages (in ../):
make deb
or
dpkg-buildpackage
Documentation:
--------------
Regenerate the README for all the "default" modules (include_modules,
skip_modules a.s.o can be used to alter the module list).
make README
Generates a manpage for all the modules that support it (.xml file in the
module directory).
make man
Generates README file for modules/foo.
make modules=modules/foo modules-readme
Install:
--------
make prefix=/usr/local install
Note: If you use prefix parameter in make install then you also need
to use this parameter in previous make commands, i.e. make, make modules,
or make all. If you fail to do this then Kamailio will look for the default
configuration file in a wrong directory, because the directory of the
default configuration file is hardcoded into Kamailio during compile time.
When you use a different prefix parameter when installing then the
directory hard coded in Kamailio and the directory in which the file will be
installed by make install will not match. (You can specify exact location
of the configuration file using -f parameter of Kamailio).
For example, if you do the following:
make all
make prefix=/ install
Then the installation will put the default configuration file into
/etc/kamailio/kamailio.cfg (because prefix is /),
but Kamailio will look for the file in /usr/local/etc/kamailio/kamailio.cfg
(because there was no prefix parameter make all and /usr/local is the default value of prefix).
The workaround is trivial, use the same parameters in all make commands:
make prefix=/ all
make prefix=/ install
or save the desired prefix in the make config (e.g.: make cfg prefix=/).
That applies to other make parameters as well (for example parameters
"modules" or "excluded_modules").
3. Quick-Start Installation Guide
---------------------------------
A) Getting Help
This guide gives you instructions on how to set up the Kamailio
on your box quickly. In case the default configuration does not fly, please
check the documentation at the Kamailio web site
http://www.kamailio.org to learn how to configure Kamailio for your site.
If the documentation does not resolve your problem you may try contacting
our user forum by E-mail at [email protected] -- that is the
mailing list of the Kamailio community. To participate in the mailing list,
please subscribe at the following web address:
https://lists.kamailio.org/cgi-bin/mailman/listinfo
B) Disclaimers
Note well the default "quick-start" configuration is very simple in order
to be easily installable. It provides minimum features. Particularly,
authentication is by default disabled, which means anyone can register using
any name with the server. (This is on purpose to avoid installation
dependencies on a database, which is needed for storing user credentials.)
C) Quick Start
The following step-by step guide gives you instructions how to install the
SQL-free distribution of Kamailio. If you need persistence and
authentication, then you have to install additional database support --
proceed to section D) after you are finished with C).
1) Download an RPM or Debian package from the links on the wiki
https://www.kamailio.org/wiki/
If you don't use an rpm or debian based distribution, try our tar.gz'ed
binaries
https://www.kamailio.org/pub/kamailio/latest/src/
If you use Solaris 8 you can try our solaris package.
If you use Gentoo Linux you do not have to download a package.
2) Install the package
RPM:
rpm -i <package_name>
debian:
dpkg -i <package_name>
Solaris:
gunzip <package_name>.gz ; pkgadd -d <package_name>
*BSD:
pkg_add package_name
3) Start the server
RPM:
/etc/init.d/kamailio start
debian:
Kamailio is started automatically after the install
(in case something fails you can start it with '/etc/init.d/kamailio start')
tar.gz:
Solaris:
the tar.gz does not include an init.d script, you'll have to create one of
your own or adapt one from the source distribution (pkg/debian/init.d,
pkg/kamailio/rpm/kamailio.init, pkg/kamailio/deb/debian/kamailio.init, a.s.o.)
You can start Kamailio directly with
/usr/local/sbin/kamailio.
4) Optionally, watch server's health using the kamctl utility
- to do so, first set the environment variable SIP_DOMAIN to your domain
name, e.g., in Bourne shell, call
export SIP_DOMAIN="myserver.foobar.com"
- if you are using other than 'localhost' mysql server for maintaining
subscriber database, change the variable 'SQL_HOST' to the proper
host name in the kamctl script
- run the kamctl utility
/usr/sbin/kamctl moni
or
/usr/local/sbin/kamctl moni (if you installed Kamailio from a
tar.gz or solaris package)
5) Connect SIP phones
Register with the server using your favorite SIP User Agent (phone).
In most cases, you need to set the following options:
Proxy server: host name of your server
Domain: the sip domain your server is configured to handle
User name: the account name for your device
Auth user: the ID used for authentication
Secret/Password: The configured authentication password
D) Kamailio With Persistent Data Storage
------------------------------------------
The default configuration is very simple and features many simplifications.
In particular, it does not authenticate users and loses User Location database
on reboot. To provide persistence, keep user credentials and remember users'
locations across reboots, Kamailio can be configured to use a database, like MySQL.
Before you proceed, you need to make sure MySQL is installed on your box. Your
MySQL server must be configured to deal with a large number of
connection. To increase it, set the following line in [mysqld] section
of your my.ini configuration file:
set-variable = max_connections=500
1) Download the package containing mysql support for Kamailio from the links
you find on:
https://www.kamailio.org/wiki/
(rpm and deb provided, most of the binary tar.gz distributions and the
solaris package include it; if it is not present you'll have to rebuild
from the source).
2) install the package
rpm -i <package_name>
or
dpkg -i <package_name>
or
emerge kamailio
(if do not want to put 'mysql' into your USE variable you can type:
USE="mysql" emerge kamailio)
3) create MySQL tables for Kamailio
- if you have a previously installed Kamailio on your system, use
/usr/local/sbin/kamdbctl reinstall
to convert your Kamailio database into new structures
- otherwise, if this is your very first installation, use
/usr/local/sbin/kamdbctl create
to create Kamailio database structures
(you will be prompted for password of MySql "root" user)
4) configure Kamailio to use SQL
uncomment all lines in configuration file kamailio.cfg which are related to authentication:
- loadmodule "db_mysql.so"
- loadmodule "auth.so"
- loadmodule "auth_db.so"
- modparam("usrloc", "db_mode", 2)
- modparam("auth", "calculate_ha1", yes)
- modparam("auth_db", "password_column", "password")
- if (!www_authorize("example.com", "subscriber")) {
www_challenge("example.com", "0");
break;
}
5) be sure to replace realm, the first parameter in www_* actions,
with name of your server; some broken UAC implementations don't
authenticate otherwise; the authentication command in your
configuration script should look then like this:
if (!www_authorize("myserver.foobar.com", "subscriber")) {
www_challenge("myserver.foobar.com", "0");
break;
}
6) restart the server
/etc/init.d/kamailio restart
7) you can now start managing the server using the kamctl utility;
you need to first set the environment variable SIP_DOMAIN to your
local SIP realm, e.g.,
export SIP_DOMAIN="myserver.example.com"
a) watch the server status using 'kamctl moni'
b) try to login with your SIP client as user 'admin' with password 'heslo'
c) try adding new users using
'kamctl add <username> <password>'
4. Troubleshooting
------------------
Q: SIP requests are replied by Kamailio with "483 Too Many Hops" or
"513 Message Too Large"
A: In both cases, the reason is probably an error in request routing script
which caused an infinite loop. You can easily verify whether this happens
by watching SIP traffic on loopback interface. A typical reason for
misrouting is a failure to match local domain correctly. If a server
fails to recognize a request for itself, it will try to forward it to
current URI in believe it would forward them to a foreign
domain. Alas, it forwards the request to itself again. This continues
to happen until value of max_forwards header field reaches zero or
the request grows too big. Solutions is easy: make sure that domain
matching is correctly configured. A quick way to achieve that is to
introduce a config option to ser.cfg or kamailio.cfg: alias=domainname,
where domainname shall be replaced with name of domain, which you wish to
server and which appears in request-URIs.
Q: Where to report issues?
A: Use bug tracker at: https://github.com/kamailio/kamailio/issues
Q: Any F.A.Q. that could be helpful to check before reporting an issue?
A: See: https://www.kamailio.org/wiki/tutorials/faq/main