forked from Mirrors/freeswitch
2184af8ea6
In the systemd unit for FS/debian, if the WorkingDirectory is not set then it defaults to '/'. This is fine for FS, and is a common and expected chdir choice for daemons. We had previously set this to /run/freeswitch. Due to Debian having systemd-coredump(8) disabled, this was causing core files to be written to /run/freeswitch, which is a bad place for them as it's mounted on tmpfs. So in commitcd68e0f
we changed this to the log directory /var/log/freeswitch. That choice is a bit usual as well on Debian. It's better to leave FS as running on '/'. This will prevent core files from being written unless the user adjusts `sysctl kernel.core_pattern`, which is a reasonable thing to expect if the user wants these files. Core files can be huge, and even having them go to /var/log unexpectedly can be a problem. When Debian adds the systemd-coredumps support this will all work nicely and automatically. ref: http://www.freedesktop.org/software/systemd/man/coredump.conf.html ref: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=744964 References-commit:cd68e0fe1b
FS-7909
33 lines
631 B
Desktop File
33 lines
631 B
Desktop File
;;;;; Author: Travis Cross <tc@traviscross.com>
|
|
|
|
[Unit]
|
|
Description=freeswitch
|
|
After=syslog.target network.target local-fs.target
|
|
|
|
[Service]
|
|
; service
|
|
Type=forking
|
|
PIDFile=/run/freeswitch/freeswitch.pid
|
|
ExecStart=/usr/bin/freeswitch -ncwait -nonat
|
|
TimeoutSec=45s
|
|
Restart=always
|
|
; exec
|
|
RuntimeDirectory=freeswitch
|
|
RuntimeDirectoryMode=0755
|
|
User=freeswitch
|
|
Group=freeswitch
|
|
LimitCORE=infinity
|
|
LimitNOFILE=100000
|
|
LimitNPROC=60000
|
|
;LimitSTACK=240
|
|
LimitRTPRIO=infinity
|
|
LimitRTTIME=7000000
|
|
IOSchedulingClass=realtime
|
|
IOSchedulingPriority=2
|
|
CPUSchedulingPolicy=rr
|
|
CPUSchedulingPriority=89
|
|
UMask=0007
|
|
|
|
[Install]
|
|
WantedBy=multi-user.target
|