On 01/10/15 15:43, Olle E. Johansson wrote:
On 14 Sep
2015, at 23:26, Daniel-Constantin Mierla <miconda(a)gmail.com> wrote:
The situation is quite annoying sometimes even for me, I was thinking of
ways to make it more convenient when installing sources and starting
with a command line or running from source tree as I do most of the time.
The /var/run/kamailio is not created by debian installation process,
because /var/run is temporary and content deleted on each restart. It
was like that but changed when discovered, because even installed from
deb, after the restart of the system, kamailio won't start. Same happens
if done with 'make install', it will work up to next system restart.
Right now the /var/run/kamailio is created by the init.d script
/etc/init.d/kamailio, which seems to be the common across other linux
daemons.
On debian, the init.d script can be deployed and /var/run/kamailio/
created by running:
make install-initd-debian
There is an alternative for centos:
make install-initd-centos
Just noticed it doesn't create the folder, patch will follow (although
it might be created by user add command).
I will add a dedicated Makefile target to create the folder, but a
complete procedure will require adding the user and changing the owner
of the folder, if kamailio is started under that specific user.
Among ideas I played with:
- create the folder from kamailio source at startup, if it doesn't
exist and enough privileges -- this will require to start kamailio
initially as root
If we depend on it we should definitely create it unless already
created.
A patch was pushed this week already and backported to 4.3.
Cheers,
Daniel
--
Daniel-Constantin Mierla