I finally find out where the problem was.
the modpath parameter in config file was missing:
modparam("perl", "modpath", "/usr/lib/kamailio/perl")
I thought that when I installed module from repository i won't be
necessary to set up path to perl modules because i will be in default
directory :/ ...
thanks anyway
good you found it and thanks for writing back the solution, perhaps
should be documented in the readme for the future.
Was it the same case for python? Some module parameter that has to be set?
Cheers,
Daniel
On 2 May 2012 08:46, Daniel-Constantin Mierla <miconda(a)gmail.com
<mailto:miconda@gmail.com>> wrote:
Hello,
On 5/2/12 12:50 AM, Ladislav Jurák wrote:
I tried with this script:
sub donothing{
$a = 1000;
return 1;
}
... still the same error
not a perl/python user myself (using instead
app_lua when needed),
so I cannot test for the moment. But I know other peoples are
using perl or python and haven't reported such issue -- maybe one
of them will be able to answer faster.
Cheers,
Daniel
Thank you for fast reply.
LJ.
On 2 May 2012 00:22, Daniel-Constantin Mierla <miconda(a)gmail.com
<mailto:miconda@gmail.com>> wrote:
Hello,
On 5/2/12 12:07 AM, Ladislav Jurák wrote:
Hello,
I have problem with loading perl module on Kamailio v3.2
installed from repository on Debian sqeeze amd64. Perl
modules was also installed from repository package
kamailio-perl-modules. I have also installed all perl
dependences listed in perl module documentary.
Into Kamailio config file I added:
loadmodule "perl.so"
and
modparam("perl", "filename", "/etc/kamailio/skript.pl
<http://skript.pl>")
Now when I'm trying to start Kamailio I'll get following:
May 1 23:13:46 server kamailio: DEBUG: <core> [cfg.y:1712]:
loading module perl.so
May 1 23:13:46 server kamailio: DEBUG: <core>
[sr_module.c:557]: load_module: trying to load
</usr/lib64/kamailio/modules_k/perl.so>
May 1 23:13:46 server kamailio: WARNING: <core>
[sr_module.c:620]: /usr/lib64/kamailio/modules_k/perl.so:
exports dlflags interface is deprecated and it will not be
supported in newer versions; consider using mod_register()
instead
May 1 23:13:46 server kamailio: DEBUG: <core>
[modparam.c:96]: set_mod_param_regex: 'perl' matches module
'perl'
May 1 23:13:46 server kamailio: DEBUG: <core>
[sr_module.c:763]: find_param_export: found <filename> in
module perl [/usr/lib64/kamailio/modules_k/perl.so]
May 1 23:13:46 server kamailio: DEBUG: <core>
[modparam.c:113]: set_mod_param_regex: found <filename> in
module perl [/usr/lib64/kamailio/modules_k/perl.so]
May 1 23:13:46 server /usr/sbin/kamailio[31192]: DEBUG:
<core> [sr_module.c:928]: DEBUG: init_mod: perl
May 1 23:13:46 server /usr/sbin/kamailio[31192]: ERROR:
perl [perl.c:238]: failed to load perl file
"/etc/kamailio/skript.pl <http://skript.pl>".
May 1 23:13:46 server /usr/sbin/kamailio[31192]: ERROR:
<core> [sr_module.c:932]: init_mod(): Error while
initializing module perl (/usr/lib64/kamailio/modules_k/perl.so)
I am confused about the WARNIG too, can it have some
influence to the errors?
File skript.pl <http://skript.pl> is in the specified
directory. I also changed permissions to 777. It's content
is from sample "branches.pl <http://branches.pl>".
I have similar problem with module app_python.so.
Can you please give me some advice? It's important for me to
get this module working.
the warning is harmless, it is just for developers, should be
made info or notice, rather than being a warning.
The error itself is because of perl_parse() function, which
could not understand the script. Can you try with a very
basic perl script, like just printing a message or doing a
simple operation to see if it starts?
Cheers,
Daniel
--
Daniel-Constantin Mierla -http://www.asipto.com
http://twitter.com/#!/miconda <http://twitter.com/#%21/miconda>
-http://www.linkedin.com/in/miconda
--
S pozdravom LJ
--
Daniel-Constantin Mierla -http://www.asipto.com
http://twitter.com/#!/miconda <http://twitter.com/#%21/miconda>
-http://www.linkedin.com/in/miconda
--
S pozdravom LJ
_______________________________________________
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users(a)lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users