asterisk failed to start under systemd

Bug #1477105 reported by god
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
asterisk (Ubuntu)
Invalid
Undecided
Unassigned

Bug Description

Installed asterisk from repo on 15.04 x86_64: Version: 1:13.1.0~dfsg-1ubuntu2
When started automatically on boot it's failing - no binding to ports 5060 for unknown reason.

Curiously when started manually (as root of course) asterisk is working just fine. So I guess it's hairy and ugly /etc/init.d/asterisk mess to blame and an ultimate fix would be to finally ship asterisk.service instead.

But in a meantime I'm looking for workaround to make this work.

systemctl status is 'degraded' after boot.
systemctl status asterisk
● asterisk.service - Asterisk PBX
   Loaded: loaded (/lib/systemd/system/asterisk.service; enabled; vendor preset: enabled)
   Active: active (running) since Wed 2015-07-22 11:47:11 UTC; 1min 10s ago
     Docs: man:asterisk(8)
 Main PID: 1102 (asterisk)
   CGroup: /lxc/asterisk/system.slice/asterisk.service
           └─1102 /usr/sbin/asterisk -g -f -U asterisk

Jul 22 11:47:11 asterisk systemd[1]: Started Asterisk PBX.
Jul 22 11:47:11 asterisk systemd[1]: Starting Asterisk PBX...

does not report anything suspicious.

journalctl -a -u asterisk
-- Logs begin at Wed 2015-07-22 11:45:04 UTC, end at Wed 2015-07-22 11:47:12 UTC. --
Jul 22 11:47:11 asterisk systemd[1]: Started Asterisk PBX.
Jul 22 11:47:11 asterisk systemd[1]: Starting Asterisk PBX...

as well as journalctl.

Yet, no port binding:
"ss -tapn | grep 5060" - gives nothing.

ps aux|grep asterisk
asterisk 1102 0.0 0.3 1496976 29660 ? Ssl 11:47 0:01 /usr/sbin/asterisk -g -f -U asterisk

Although asterisk is running.

Tags: systemd-boot
Revision history for this message
god (humper) wrote :
Revision history for this message
god (humper) wrote :
Revision history for this message
god (humper) wrote :

Attached are the only 2 modified configuration files.

Robie Basak (racb)
tags: added: systemd-boot
Revision history for this message
god (humper) wrote :

My bad - turned out to be permission issue which prevented asterisk from reading it's config files. Nevertheless - having native .service file instead of legacy shell script would make this a bit easier to troubleshoot.

Changed in asterisk (Ubuntu):
status: New → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.