• V20: 3CX Re-engineered. Get V20 for increased security, better call management, a new admin console and Windows softphone. Learn More.

Solved Debian Management Console Service Won't Start

Status
Not open for further replies.

Robert Juric

Joined
Jan 14, 2017
Messages
11
Reaction score
0
Hello, I'm running 3CX on Debian, installed from the ISO. I had everything up and running last week, went out of town for a week and when I returned I'm unable to login.

When I got the web admin I get an nginx 502 - Bad Gateway error. When I log in to the server the Management Console service is not running. I've tried to restart the service, but it times out and enters the failed state. Any ideas or additional log info I could dig into?

Mar 06 11:20:20 jennifer systemd[1]: Starting 3CX PhoneSystem 01 Management Console...
-- Subject: Unit 3CXPhoneSystemMC01.service has begun with start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit 3CXPhoneSystemMC01.service has begun starting up.
Mar 06 11:22:20 jennifer systemd[1]: 3CXPhoneSystemMC01.service start operation timed out. Terminating.
Mar 06 11:22:20 jennifer systemd[1]: Failed to start 3CX PhoneSystem 01 Management Console.
-- Subject: Unit 3CXPhoneSystemMC01.service has failed
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit 3CXPhoneSystemMC01.service has failed.
--
-- The result is failed.
Mar 06 11:22:20 jennifer systemd[1]: Unit 3CXPhoneSystemMC01.service entered failed state.
 
Hey,

same problem on debian distro here. As for me this problem appears after an update from 15.0.60903.0 to 15.0.62928.5 on Saturday.
The system seems working but Management Console is "out of order" with the same message - nginx 502 bad gateway and a server error after a login attempt


root@xxxx:~# systemctl start 3CXPhoneSystemMC01.service
Job for 3CXPhoneSystemMC01.service failed. See 'systemctl status 3CXPhoneSystemMC01.service' and 'journalctl -xn' for details.


root@xxxx:~# systemctl status 3CXPhoneSystemMC01.service
● 3CXPhoneSystemMC01.service - 3CX PhoneSystem 01 Management Console
Loaded: loaded (/lib/systemd/system/3CXPhoneSystemMC01.service; enabled)
Active: failed (Result: timeout) since Mon 2017-03-06 18:25:58 CET; 19min ago
Process: 12946 ExecStart=/usr/lib/3cxpbx/ManagementConsoleJS --pid /var/run/phonesystem/3CXPhoneSystemMC01.pid -p /var/lib/3cxpbx/Instance1/Data/Http/webroot (code=killed, signal=INT)
Main PID: 12946 (code=killed, signal=INT)

Mar 06 18:25:58 xxxx systemd[1]: 3CXPhoneSystemMC01.service start operation timed out. Terminating.
Mar 06 18:25:58 xxxx systemd[1]: Failed to start 3CX PhoneSystem 01 Management Console.
Mar 06 18:25:58 xxxx systemd[1]: Unit 3CXPhoneSystemMC01.service entered failed state.

Restarting the server isn't solving the problem in my case


 
Hi, could you please run this command, systemctl start 3CXPhoneSystemMC01
Let us know.
 
Yea, I've tried this a few times:


Job for 3CXPhoneSystemMC01.service failed. See 'systemctl status 3CXPhoneSystemMC01.service' and 'journalctl -xn' for details.

root@servername:~# systemctl status 3CXPhoneSystemMC01 -l
● 3CXPhoneSystemMC01.service - 3CX PhoneSystem 01 Management Console
Loaded: loaded (/lib/systemd/system/3CXPhoneSystemMC01.service; enabled)
Active: failed (Result: timeout) since Mon 2017-03-06 13:03:29 CST; 1min 11s ago
Process: 2656 ExecStart=/usr/lib/3cxpbx/ManagementConsoleJS --pid /var/run/phonesystem/3CXPhoneSystemMC01.pid -p /var/lib/3cxpbx/Instance1/Data/Http/webroot (code=killed, signal=INT)
Main PID: 2656 (code=killed, signal=INT)

Mar 06 13:01:29 servername systemd[1]: Starting 3CX PhoneSystem 01 Management Console...
Mar 06 13:01:34 servername sudo[2702]: phonesystem : TTY=unknown ; PWD=/var/lib/3cxpbx ; USER=root ; COMMAND=/usr/bin/apt-get update -o Dir::Etc::sourcelist=sources.list.d/3cxpbx.list -o Dir::Etc::sourceparts=- -o APT::Get::List-Cleanup=0
Mar 06 13:01:34 servername sudo[2702]: pam_unix(sudo:session): session opened for user root by (uid=0)
Mar 06 13:03:29 servername systemd[1]: 3CXPhoneSystemMC01.service start operation timed out. Terminating.
Mar 06 13:03:29 servername systemd[1]: Failed to start 3CX PhoneSystem 01 Management Console.
Mar 06 13:03:29 servername systemd[1]: Unit 3CXPhoneSystemMC01.service entered failed state.
 
Hello there,

Please try again today as the issue is caused because the PBX tries to connect to a mail server that cannot connect to. For example if you left our mail server that was there as an example then you may face this issue. Please try restarting again and see if ti works now. Let us know how it goes.
 
Yep, all is good now. This 3CX server was a new build so we hadn't input the SMTP server info yet.

Thanks for the response 3CX!
 
Hello,

Sounds the problem still active today.
How can the management service crash because of a mail server not available ?

How can I pass this SMTP connection problem and get back my management console ?

Regards
 
Hello @Stéphane DAGUET

Have you tried the command systemctl start 3CXPhoneSystemMC01?
Are the rest of the services running?
 
Hello,

Yes, for sure. I finally started with strace (strace -f -o trace.log /usr/lib/3cxpbx/ManagementConsoleJS --pid /var/run/phonesystem/3CXPhoneSystemMC01.pid -p /var/lib/3cxpbx/Instance1/Data/Http/webroot); wait a moment, and understand the problem was also related to the mail server. After a long moment, the service finally started - I modified the systemctl TimeoutStartSec which was 120s to 600s, then started the service.

However, I would recommend 3cx to no block service starting in case of mail server misconfiguration and/or timeout to connect to it.

Best regards
 
Glad to hear the issue is resolved and thank you for sharing your solution.
Please note that this issue has been addressed for the next update and you should not encounter this issue again.
 
Hello,

I ve the same problem.

i have increased the timeout in systemd and two services didn't start. I try to reboot the server but nothing ... Below the result of the command when I try to start 3CXPhoneSystemMC01

May 28 14:19:51 sl0001 systemd[1]: Starting 3CX PhoneSystem Configuration Service...
-- Subject: Unit 3CXCfgServ01.service has begun with start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit 3CXCfgServ01.service has begun starting up.
May 28 14:20:16 sl0001 systemd[1]: Started 3CX PhoneSystem Configuration Service.
-- Subject: Unit 3CXCfgServ01.service has finished start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit 3CXCfgServ01.service has finished starting up.
--
-- The start-up result is done.
May 28 14:20:16 sl0001 systemd[1]: Starting 3CX PhoneSystem 01 Management Console...
-- Subject: Unit 3CXPhoneSystemMC01.service has begun with start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit 3CXPhoneSystemMC01.service has begun starting up.
May 28 14:22:16 sl0001 systemd[1]: 3CXPhoneSystemMC01.service start operation timed out. Terminating.
May 28 14:22:16 sl0001 systemd[1]: Failed to start 3CX PhoneSystem 01 Management Console.
-- Subject: Unit 3CXPhoneSystemMC01.service has failed
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit 3CXPhoneSystemMC01.service has failed.
--
-- The result is failed.
May 28 14:22:16 sl0001 systemd[1]: Unit 3CXPhoneSystemMC01.service entered failed state.


When I launch the command with straw (see above) the response is continuously :

Connecting to the PBX... Check config.json!

Can you help me ?

Best regards,

Olivier
 
If you want to modify the service timeout, head to:
/lib/systemd/system/3CX<servicename>.service

e.g.
vi /lib/systemd/system/3CXPhoneSystemMC01.service

and edit the line:
TimeoutStartSec=120

change to something that might actually work for you... (300 seconds seemed to be OK for me) then:

systemctl start 3CXPhoneSystemMC01.service

Note that if you query the properties of the service it'll return a different name:
e.g.
systemctl show 3CXQueueManager01.service -p TimeoutStartSec #returns nothing...

but this will work:
root@pbx01:/var/log# systemctl show 3CXQueueManager01.service -p TimeoutStartUSec
TimeoutStartUSec=5min

I'll let others discuss the value of inconsistent naming.

systemctl show 3CXQueueManager01.service -a # this will show all properties defined for the service
 
Status
Not open for further replies.

Getting Started - Admin

Latest Posts

Forum statistics

Threads
141,629
Messages
748,929
Members
144,741
Latest member
Boykins_54
Get 3CX - Absolutely Free!

Link up your team and customers Phone System Live Chat Video Conferencing

Hosted or Self-managed. Up to 10 users free forever. No credit card. Try risk free.

3CX
A 3CX Account with that email already exists. You will be redirected to the Customer Portal to sign in or reset your password if you've forgotten it.