Severe : Could not contact the Allmon3 Manager

I too have a little issue with Configuring my Nodes as when I do load the URL is says.

Severe : Could not contact the Allmon3 Manager.

I think its because I dont have a /etc/allmon3/user folder but Its work in Progress which I am working on…

I’m using the Allstar 2.0 on a x64 Server…

Thanks

Rob…

I didn’t have a users file upon installing 0.10 either. Just touch /etc/allmon3/users and then create a user per the README. That will fix the user issue.

I also didn’t have a menu.ini. I thought maybe I did something wrong because the package manager said those files got installed.

If you don’t have a menu.ini.example grab Allmon3/menu.ini.example at develop · AllStarLink/Allmon3 · GitHub rename it to menu.ini and configure it per the comments.

Yeah tried to simply add a user using the allmon2-passwd command and I get the Following

When I create a users folder

Traceback (most recent call last):
File “/usr/bin/allmon3-passwd”, line 46, in
with open(user_filename, newline=“”) as user_file:
IsADirectoryError: [Errno 21] Is a directory: ‘/etc/allmon3/users’

When I remove the folder

Traceback (most recent call last):
File “/usr/bin/allmon3-passwd”, line 46, in
with open(user_filename, newline=“”) as user_file:
FileNotFoundError: [Errno 2] No such file or directory: ‘/etc/allmon3/users’

I’m guessing the issue is me…

lol

Rob…

Users is a file not a folder. You have to create the file with the touch command…
However, if there’s a users directory you have to remove it:

cd /etc/allmon3
sudo rm users

Create the user file:
sudo touch /etc/allmon3/users

Then add your admin (and/or other) user:
sudo allmon3-passwd admin

Well who says you cant teach Grandpa how to suck eggs ?..

Thanks for the Re-Education…

Told ya it was Prob me…

Now just need to fix the following and hopefully I am Golden…

SEVERE: Could not contact the allmon3 manager. Check the allmon3 service, webserver config, and reload the window.

Thanks

Rob…

You didn’t need to worry about users yet, but that’s ok. It’s fixed now. :slight_smile:

First thing to work on is getting the Allmon3 service to login to the Asterisk Manager.

  • Edit the /etc/allmon3/allmon3.ini file and set the user ID and password to match the user ID and password in /etc/asterisk/manager.ini
  • Restart the service. As root to sudo: systemctl restart allmon3.service
  • Check that the service is running w/o errors. As root to sudo: systemctl status allmon3.service

Added an issue:

systemctl status allmon3 gives me the Following even though aiohttp is satisfied

allmon3.service - Allmon3 daemon
Loaded: loaded (/lib/systemd/system/allmon3.service; enabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Fri 2023-05-26 11:23:57 CDT; 1min 57s ago
Process: 291 ExecStart=/usr/bin/allmon3 (code=exited, status=1/FAILURE)
Main PID: 291 (code=exited, status=1/FAILURE)

May 26 11:23:56 1200Node systemd[1]: Starting Allmon3 daemon…
May 26 11:23:56 1200Node systemd[1]: Started Allmon3 daemon.
May 26 11:23:57 1200Node allmon3[291]: Traceback (most recent call last):
May 26 11:23:57 1200Node allmon3[291]: File “/usr/bin/allmon3”, line 18, in
May 26 11:23:57 1200Node allmon3[291]: from asl_allmon import allmon3_server, allmon3_ws_status, allmon3_ws_cmd, allmon3_ws_voter
May 26 11:23:57 1200Node allmon3[291]: File “/usr/lib/python3/dist-packages/asl_allmon/allmon3_server/init.py”, line 8, in <modu
May 26 11:23:57 1200Node allmon3[291]: from aiohttp import web
May 26 11:23:57 1200Node allmon3[291]: ModuleNotFoundError: No module named ‘aiohttp’
May 26 11:23:57 1200Node systemd[1]: allmon3.service: Main process exited, code=exited, status=1/FAILURE
May 26 11:23:57 1200Node systemd[1]: allmon3.service: Failed with result ‘exit-code’.

repeater@1200Node:~$ pip3 show aiohttp
Name: aiohttp
Version: 3.8.4
Summary: Async http client/server framework (asyncio)
Home-page: GitHub - aio-libs/aiohttp: Asynchronous HTTP client/server framework for asyncio and Python
Author: None
Author-email: None
License: Apache 2
Location: /home/repeater/.local/lib/python3.7/site-packages
Requires: yarl, asynctest, attrs, frozenlist, charset-normalizer, multidict, typing-extensions, aiosignal, async-timeout
Required-by:

Installing the pip modules to a .local directory isn’t likely to work for another user. The daemon runs as the user allmon3. Can you install the pip modules as root into the system-wide dist-packages or site-packages locations?

As root do something like this:

$ python3
Python 3.9.2 (default, Feb 28 2021, 17:03:44)
[GCC 10.2.1 20210110] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import sys
>>> print(sys.path)
['', '/usr/lib/python39.zip', '/usr/lib/python3.9', '/usr/lib/python3.9/lib-dynload', '/usr/local/lib/python3.9/dist-packages', '/usr/lib/python3/dist-packages']
>>>

For system daemons, the python package dependencies must be in the default import paths.

But you have to do it as the root user. From the “$” prompt, it tells me you’re using a non-root account.

repeater@1200Node:~$ su
Password:
root@1200Node:/home/repeater# python3
Python 3.7.3 (default, Oct 31 2022, 14:04:00)
[GCC 8.3.0] on linux
Type “help”, “copyright”, “credits” or “license” for more information.

import sys
print (sys.path)
[‘’, ‘/usr/lib/python37.zip’, ‘/usr/lib/python3.7’, ‘/usr/lib/python3.7/lib-dynload’, ‘/usr/local/lib/python3.7/dist-packages’, ‘/usr/lib/python3/dist-packages’]

I removed the earlier post

Right. So notice that your pip3 library path of /home/repeater/.local/lib is not longer available. You need to install the python dependencies as root so they and up in the correct site-packages location globally. That’s why allmon3 won’t start.

Ok well might give this up for a while…
allmon3.service - Allmon3 daemon
Loaded: loaded (/lib/systemd/system/allmon3.service; enabled; vendor preset: en
Active: failed (Result: exit-code) since Fri 2023-05-26 17:47:59 CDT; 34s ago
Process: 9071 ExecStart=/usr/bin/allmon3 (code=exited, status=1/FAILURE)
Main PID: 9071 (code=exited, status=1/FAILURE)

May 26 17:47:59 1200Node systemd[1]: Starting Allmon3 daemon…
May 26 17:47:59 1200Node systemd[1]: Started Allmon3 daemon.
May 26 17:47:59 1200Node allmon3[9071]: Traceback (most recent call last):
May 26 17:47:59 1200Node allmon3[9071]: File “/usr/bin/allmon3”, line 18, in <mo
May 26 17:47:59 1200Node allmon3[9071]: from asl_allmon import allmon3_server,
May 26 17:47:59 1200Node allmon3[9071]: File "/usr/lib/python3/dist-packages/asl
May 26 17:47:59 1200Node allmon3[9071]: from aiohttp_session import get_sessio
May 26 17:47:59 1200Node allmon3[9071]: ModuleNotFoundError: No module named 'aioh
May 26 17:47:59 1200Node systemd[1]: allmon3.service: Main process exited, code=ex
May 26 17:47:59 1200Node systemd[1]: allmon3.service: Failed with result 'exit-cod

root@1200Node:/home/repeater# nano /etc/allmon3/web.iniroot@1200Node:/home/repeater# python3
Python 3.7.3 (default, Oct 31 2022, 14:04:00)
[GCC 8.3.0] on linux
Type “help”, “copyright”, “credits” or “license” for more information.

import sys
print (sys.path)
[‘’, ‘/usr/lib/python37.zip’, ‘/usr/lib/python3.7’, ‘/usr/lib/python3.7/lib-dynload’, ‘/usr/local/lib/python3.7/dist-packages’, ‘/usr/lib/python3/dist-packages’]

Used root and the issue still wont go away…

As root, what is the output of pip3 show aiohttp and pip3 show aiohttp_session? You should see something like:

# pip3 show aiohttp
Name: aiohttp
Version: 3.8.4
Summary: Async http client/server framework (asyncio)
Home-page: https://github.com/aio-libs/aiohttp
Author: None
Author-email: None
License: Apache 2
Location: /usr/local/lib/python3.7/dist-packages
Requires: asynctest, multidict, attrs, frozenlist, typing-extensions, charset-normalizer, yarl, aiosignal, async-timeout
Required-by: aiohttp-session

# pip3 show aiohttp_session
Name: aiohttp-session
Version: 2.12.0
Summary: sessions for aiohttp.web
Home-page: https://github.com/aio-libs/aiohttp_session/
Author: Andrew Svetlov
Author-email: andrew.svetlov@gmail.com
License: Apache 2
Location: /usr/local/lib/python3.7/dist-packages
Requires: aiohttp, typing-extensions
Required-by:

pip3 show aiohttp does show the same but does not have an entry on Required-by …

pip3 show aiohttp_session shows nothing…

Then you didn’t install aiohttp_session. If you install that with pip3, it should start.

Maybe I missed that Instruction on the Install or maybe its because Im using the PC based version on Allstarlink
allmon3.service - Allmon3 daemon
Loaded: loaded (/lib/systemd/system/allmon3.service; enabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Sat 2023-05-27 13:20:18 CDT; 1s ago
Process: 29105 ExecStart=/usr/bin/allmon3 (code=exited, status=1/FAILURE)
Main PID: 29105 (code=exited, status=1/FAILURE)

May 27 13:20:17 1200Node allmon3[29105]: asyncio.run(start_tasks())
May 27 13:20:17 1200Node allmon3[29105]: File “/usr/lib/python3.7/asyncio/runners.py”, line 43, in run
May 27 13:20:17 1200Node allmon3[29105]: return loop.run_until_complete(main)
May 27 13:20:17 1200Node allmon3[29105]: File “/usr/lib/python3.7/asyncio/base_events.py”, line 584, in run_until_complete
May 27 13:20:17 1200Node allmon3[29105]: return future.result()
May 27 13:20:17 1200Node allmon3[29105]: File “/usr/bin/allmon3”, line 97, in start_tasks
May 27 13:20:17 1200Node allmon3[29105]: except asyncio.exceptions.CancelledError as e:
May 27 13:20:17 1200Node allmon3[29105]: AttributeError: module ‘asyncio’ has no attribute ‘exceptions’
May 27 13:20:18 1200Node systemd[1]: allmon3.service: Main process exited, code=exited, status=1/FAILURE
May 27 13:20:18 1200Node systemd[1]: allmon3.service: Failed with result ‘exit-code’.

ok pip3 Install aiohttp_session

now status gives me…

What does your /etc/allmon3/allmon3.ini look like?
What does you /etc/asterisk/manager.ini look like?

Be sure not to post any passwords.