OP25 OP25 crashes mid conversation

Status
Not open for further replies.

MTL_Emergencies

Member++
Database Admin
Joined
Sep 6, 2019
Messages
147
Location
Quebec, Canada
I am having an issue with OP25 (Boatbod) that it crashes mid conversation at random times.
Sometimes it runs for 3hrs without any issues and sometimes it crashes after 10 mins.

I added below a copy of my stderr.4 file (I had to cut some parts because the message was too long)

Code:
Using Python /usr/bin/python2
Configuring audio instance #0 [audio0]
using ALSA sound system
audio device: default
Listening on 127.0.0.1:23466
10/04/22 11:22:35.575346 [SERAM] Initializing P25 system
10/04/22 11:22:35.575607 [SERAM] reading system tgid_tags_file: montreal.tsv
10/04/22 11:22:35.649910 [SERAM] setting tgid(50001), prio(4), tag(Regroupement 1)
10/04/22 11:22:35.650325 [SERAM] setting tgid(50002), prio(4), tag(Regroupement 2)
10/04/22 11:22:35.650657 [SERAM] setting tgid(50003), prio(4), tag(Regroupement 3)
10/04/22 11:22:35.650986 [SERAM] setting tgid(50004), prio(4), tag(Regroupement 4)
10/04/22 11:22:35.652325 [SERAM] setting tgid(60041), prio(2), tag(Repartition)
10/04/22 11:22:35.652501 [SERAM] setting tgid(60042), prio(2), tag(Premier Repondants A)
10/04/22 11:22:35.652668 [SERAM] setting tgid(60043), prio(2), tag(Premier Repondants B)
10/04/22 11:22:35.652822 [SERAM] setting tgid(60051), prio(2), tag(COMMANDEMENT 3)
10/04/22 11:22:35.652963 [SERAM] setting tgid(60052), prio(2), tag(COMMANDEMENT 4)
10/04/22 11:22:35.653097 [SERAM] setting tgid(60053), prio(2), tag(COMMANDEMENT 5)
10/04/22 11:22:35.653235 [SERAM] setting tgid(60054), prio(2), tag(COMMANDEMENT 6)
10/04/22 11:22:35.653380 [SERAM] setting tgid(60055), prio(2), tag(COMMANDEMENT 7)
10/04/22 11:22:35.653518 [SERAM] setting tgid(60056), prio(2), tag(COMMANDEMENT 8)
10/04/22 11:22:35.653661 [SERAM] setting tgid(60057), prio(2), tag(COMMANDEMENT 14)
10/04/22 11:22:35.653815 [SERAM] setting tgid(60058), prio(4), tag(Poste de Commandement A)
10/04/22 11:22:35.653953 [SERAM] setting tgid(60059), prio(2), tag(COMMANDEMENT 11)

10/04/22 11:22:35.686933 [SERAM] reading system rid_tags_file: mtl-rid.tsv
10/04/22 11:22:35.775888 [SERAM] setting rid(25099), tag(Quebec 511)
10/04/22 11:22:35.776052 [SERAM] reading system whitelist file: seram.wlist
10/04/22 11:22:35.781740 [SERAM] added talkgroup 60051 from seram.wlist
10/04/22 11:22:35.782084 [SERAM] added talkgroup 60052 from seram.wlist
10/04/22 11:22:35.782250 [SERAM] added talkgroup 60053 from seram.wlist
10/04/22 11:22:35.782364 [SERAM] added talkgroup 60054 from seram.wlist
10/04/22 11:22:35.782463 [SERAM] added talkgroup 60055 from seram.wlist
10/04/22 11:22:35.782560 [SERAM] added talkgroup 60056 from seram.wlist
10/04/22 11:22:35.782653 [SERAM] added talkgroup 60057 from seram.wlist
10/04/22 11:22:35.782741 [SERAM] added talkgroup 60059 from seram.wlist
10/04/22 11:22:35.782828 [SERAM] added talkgroup 60091 from seram.wlist
10/04/22 11:22:35.782915 [SERAM] added talkgroup 60092 from seram.wlist
10/04/22 11:22:35.783174 [SERAM] added talkgroup 60041 from seram.wlist
10/04/22 11:22:35.783262 [SERAM] added talkgroup 60042 from seram.wlist
10/04/22 11:22:35.783347 [SERAM] added talkgroup 60043 from seram.wlist
10/04/22 11:22:35.783432 [SERAM] added talkgroup 50001 from seram.wlist
10/04/22 11:22:35.783519 [SERAM] added talkgroup 50002 from seram.wlist
10/04/22 11:22:35.783605 [SERAM] added talkgroup 50003 from seram.wlist
10/04/22 11:22:35.783692 [SERAM] added talkgroup 50004 from seram.wlist
Enabled trunking module: tk_p25.py
device: {u'args': u'rtl=0', u'gain_mode': False, u'gains': u'LNA:248', u'usable_bw_pct': 0.85, u'ppm': 0.0, u'rate': 2400000, u'tunable': True, u'offset': 0, u'name': u'sdr0'}
Device name: "sdr0", osmosdr args: "rtl=0"
gr-osmosdr 0.1.4 (0.1.4) gnuradio 3.7.13.4
built-in source types: file osmosdr fcd rtl rtl_tcp uhd miri hackrf bladerf rfspace airspy airspyhf soapy redpitaya freesrp
Using device #0 Realtek RTL2838UHIDIR SN: 00000001
Found Rafael Micro R820T tuner
[R82XX] PLL not locked!
gr-osmosdr driver gain_mode: False
[R82XX] PLL not locked!
channel (dev sdr0): {u'plot': u'', u'cqpsk_tracking': True, u'name': u'SERAM Public Safety', u'demod_type': u'cqpsk', u'tracking_feedback': 0.85, u'destination': u'udp://127.0.0.1:23466', u'excess_bw': 0.2, u'trunking_sysname': u'SERAM', u'filter_type': u'rc', u'blacklist': u'', u'device': u'sdr0', u'symbol_rate': 4800, u'frequency': 770506250, u'tracking_threshold': 30, u'meta_stream_name': u'metastream_0', u'if_rate': 24000, u'whitelist': u'seram.wlist', u'enable_analog': u'off'}
Using two-stage decimator for speed=2400000, decim=25/4 if1=96000 if2=24000
op25_audio::open_socket(): enabled udp host(127.0.0.1), wireshark(23466), audio(23466)
10/04/22 11:22:37.402687 [0] Unable to initialize demod to freq: 770506250, using device freq: 800000000
10/04/22 11:22:37.405937 [0] Initializing P25 receiver: SERAM Public Safety
10/04/22 11:22:37.407023 [0] metadata updates not enabled
10/04/22 11:22:37.408521 [0] reading channel whitelist file: seram.wlist
10/04/22 11:22:37.411924 [0] added talkgroup 60051 from seram.wlist
10/04/22 11:22:37.412998 [0] added talkgroup 60052 from seram.wlist
10/04/22 11:22:37.415223 [0] added talkgroup 60053 from seram.wlist
10/04/22 11:22:37.415607 [0] added talkgroup 60054 from seram.wlist
10/04/22 11:22:37.416345 [0] added talkgroup 60055 from seram.wlist
10/04/22 11:22:37.416612 [0] added talkgroup 60056 from seram.wlist
10/04/22 11:22:37.416828 [0] added talkgroup 60057 from seram.wlist
10/04/22 11:22:37.417010 [0] added talkgroup 60059 from seram.wlist
10/04/22 11:22:37.417182 [0] added talkgroup 60091 from seram.wlist
10/04/22 11:22:37.417354 [0] added talkgroup 60092 from seram.wlist
10/04/22 11:22:37.417822 [0] added talkgroup 60041 from seram.wlist
10/04/22 11:22:37.417968 [0] added talkgroup 60042 from seram.wlist
10/04/22 11:22:37.418112 [0] added talkgroup 60043 from seram.wlist
10/04/22 11:22:37.418257 [0] added talkgroup 50001 from seram.wlist
10/04/22 11:22:37.418403 [0] added talkgroup 50002 from seram.wlist
10/04/22 11:22:37.418558 [0] added talkgroup 50003 from seram.wlist
10/04/22 11:22:37.418705 [0] added talkgroup 50004 from seram.wlist
python version detected: 2.7.16 (default, Oct 10 2019, 22:02:15)
[GCC 8.3.0]
Allocating 15 zero-copy buffers
10/05/22 16:03:59.836855 [0] control channel timeout, freq(770.756250)
10/05/22 16:04:00.874020 [0] control channel timeout, freq(770.756250)
10/05/22 16:04:01.911698 [0] control channel timeout, freq(770.756250)
10/05/22 16:04:41.022242 [0] voice update:  tg(60041), rid(700119), freq(772.006250), slot(-), prio(2)
10/05/22 16:04:41.245820 [0] releasing:  tg(60041), freq(772.006250), slot(-), reason(duid15)
10/05/22 16:04:42.059528 [0] voice update:  tg(60041), rid(0), freq(772.006250), slot(-), prio(2)
//
10/05/22 16:14:01.183540 PCM underrun
//
10/05/22 16:27:36.635655 [0] voice update:  tg(50001), rid(700120), freq(770.506250), slot(1), prio(4)
10/05/22 16:27:45.476716 [0] releasing:  tg(50001), freq(770.506250), slot(1), reason(duid15)
10/05/22 16:28:16.873395 [0] voice update:  tg(60091), rid(702099), freq(770.506250), slot(1), prio(2)
//
10/05/22 16:29:40.844627 PCM underrun
//
10/05/22 16:42:55.620050 [0] voice update:  tg(60041), rid(700360), freq(770.756250), slot(1), prio(2)
10/05/22 16:43:00.216617 [0] releasing:  tg(60041), freq(770.756250), slot(1), reason(duid15)
10/05/22 16:43:02.448930 [0] voice update:  tg(60041), rid(702099), freq(770.756250), slot(1), prio(2)
10/05/22 16:43:05.832378 PCM underrun
10/05/22 16:43:14.517018 [0] releasing:  tg(60041), freq(770.756250), slot(1), reason(duid15)
10/05/22 16:43:21.408529 [0] voice update:  tg(60041), rid(0), freq(770.506250), slot(0), prio(2)
10/05/22 16:43:38.978856 [0] releasing:  tg(60041), freq(770.506250), slot(0), reason(duid15)
//
10/05/22 16:58:34.822618 [0] voice update:  tg(60041), rid(701843), freq(770.756250), slot(0), prio(2)
10/05/22 16:58:56.733375 [0] releasing:  tg(60041), freq(770.756250), slot(0), reason(duid15)
10/05/22 16:59:04.531200 [0] voice update:  tg(60041), rid(702099), freq(770.506250), slot(1), prio(2)
//
10/05/22 17:00:09.242840 PCM underrun
10/05/22 17:00:12.417277 [0] releasing:  tg(60041), freq(770.756250), slot(0), reason(duid15)
10/05/22 17:00:17.495353 [0] voice update:  tg(60041), rid(701843), freq(772.256250), slot(0), prio(2)
10/05/22 17:00:31.367393 [0] releasing:  tg(60041), freq(772.256250), slot(0), reason(duid15)
//
10/05/22 17:04:55.806285 PCM underrun
10/05/22 17:05:06.562213 [0] releasing:  tg(60041), freq(770.756250), slot(0), reason(duid15)
10/05/22 17:05:08.703687 [0] voice update:  tg(50002), rid(0), freq(770.756250), slot(0), prio(4)
10/05/22 17:05:15.193836 [0] releasing:  tg(50002), freq(770.756250), slot(0), reason(duid15)
//
10/05/22 17:20:08.907622 PCM underrun
//
10/05/22 17:25:56.523303 [0] voice update:  tg(60059), rid(0), freq(770.506250), slot(0), prio(2)
10/05/22 17:26:00.452924 [0] releasing:  tg(60059), freq(770.506250), slot(0), reason(duid15)
 

boatbod

Member
Joined
Mar 3, 2007
Messages
3,411
Location
Talbot Co, MD
Unfortunately the log you posted only contains PCM underrun which is just an ALSA warning, not a fatal error.
Can you be more specific about the symptoms of the crash. Specifically, are there any "Traceback" error reports in the log or is it core dumping?
 

MTL_Emergencies

Member++
Database Admin
Joined
Sep 6, 2019
Messages
147
Location
Quebec, Canada
OP25 is automatically started with LXDE-pi:
Code:
@lxterminal -e /home/pi/op25/op25/gr-op25_repeater/apps/SERAM-SITE1.sh
I'm also running chromium full screen with:
Code:
@chromium-browser --kiosk --app=http://127.0.0.1:8080
When it crashes, the terminal disappears (as if it was closed). It always crashes mid-conversation so I'm thinking it may be a CPU overload but it's running at 30-40% when decoding a transmission.
I'm not sure what what you mean by "core dumping". My verbosity level was at 3 (when I posted the log above) and I raised it to 5 (hoping to get any more info about crashes).

This is the kind of info I'm getting now:
Code:
10/06/22 10:49:10.362695 [0] voice update:  tg(60051), rid(701487), freq(770.506250), slot(1), prio(2)
10/06/22 10:49:10.362855 [0] releasing control channel
10/06/22 10:49:10.363785 [SERAM] has no idle receivers for control channel monitoring
10/06/22 10:49:32.928042 [0] releasing:  tg(60051), freq(770.506250), slot(1), reason(duid15)
10/06/22 10:49:32.930280 [0] idling receiver
10/06/22 10:49:32.931857 [0] set control channel=770.756250
//
10/06/22 10:52:10.096423 [SERAM] has no idle receivers for control channel monitoring
10/06/22 10:52:11.417604 [SERAM] set tgid=60151, srcaddr=0
10/06/22 10:52:11.418276 [SERAM] has no idle receivers for control channel monitoring
10/06/22 10:52:11.788785 [SERAM] set tgid=60151, srcaddr=0
10/06/22 10:52:11.789499 [SERAM] has no idle receivers for control channel monitoring
10/06/22 10:52:12.506858 [SERAM] set tgid=60151, srcaddr=0
Note that I'm not monitoring talkgroup 60151 (which is encrypted) so I'm wondering why it isn't receiving the CC.
 

boatbod

Member
Joined
Mar 3, 2007
Messages
3,411
Location
Talbot Co, MD
If the last thing in your stderr.2 log are the lines you posted above, the only way the terminal window could suddenly disappear would be if core dumped. (See attached screen shot of a forced SIGSEGV) because a normal shutdown is logged with the appearance of a "flowgraph complete" message.

You might want to try running the startup script from an interactive terminal to see what the terminal exit message is immediately after it crashes. You're not getting to see this now because the shell script is a child of the lxterminal process
 

Attachments

  • Screenshot from 2022-10-07 06-56-58.png
    Screenshot from 2022-10-07 06-56-58.png
    183.8 KB · Views: 10

MTL_Emergencies

Member++
Database Admin
Joined
Sep 6, 2019
Messages
147
Location
Quebec, Canada
I tried to change the terminal type from web interface to terminal but now I'm getting this error:
Code:
10/07/22 09:10:06.681407 [0] idling receiver
10/07/22 09:10:06.681629 [0] set control channel=770.506250
terminal: exception occurred (66, 18)
python version detected: 2.7.16 (default, Oct 10 2019, 22:02:15)
[GCC 8.3.0]
terminal: exception:
Traceback (most recent call last):
  File "/home/pi/op25/op25/gr-op25_repeater/apps/terminal.py", line 486, in run
    self.setup_curses()
  File "/home/pi/op25/op25/gr-op25_repeater/apps/terminal.py", line 116, in setup_curses
    self.title_help()
  File "/home/pi/op25/op25/gr-op25_repeater/apps/terminal.py", line 152, in title_help
    self.help_bar.addstr(0, 0, help_str.center(self.maxx-1, " "), curses.A_REVERSE)
error: addstr() returned ERR

Allocating 15 zero-copy buffers
Flowgraph complete. Exiting
I didn't modify terminal.py

My json file looks like this:
Code:
{
    "channels": [
        {
            "name": "SERAM Public Safety",
            "device": "sdr0",
            "trunking_sysname": "SERAM",
            "meta_stream_name": "metastream_0",
            "demod_type": "cqpsk",
            "cqpsk_tracking": true,
            "tracking_threshold": 30,
            "tracking_feedback": 0.85,
            "destination": "udp://127.0.0.1:23466",
            "excess_bw": 0.2,
            "filter_type": "rc",
            "frequency": 770506250,
            "if_rate": 24000,
            "plot": "",
            "symbol_rate": 4800,
            "enable_analog": "off",
            "blacklist": "",
            "whitelist": "seram.wlist"
        }
    ],
    "devices": [
        {
            "args": "rtl=0",
            "gains": "LNA:248",
            "gain_mode": false,
            "name": "sdr0",
            "offset": 0,
            "ppm": 0.0,
            "rate": 2400000,
            "usable_bw_pct": 0.85,
            "tunable": true
        }
    ],
    "trunking": {
        "module": "tk_p25.py",
        "chans": [
            {
                "nac": "0xcf1",
                "sysname": "SERAM",
                "control_channel_list": "770.50625, 772.00625, 770.95625, 770.75625, 770.70625, 770.45625, 770.20625",
                "whitelist": "seram.wlist",
                "blacklist": "",
                "tgid_tags_file": "montreal.tsv",
                "rid_tags_file": "mtl-rid.tsv",
                "tdma_cc": false,
                "crypt_behavior": 1
            }
        ]
    },
    "audio": {
        "module": "sockaudio.py",
        "instances": [
            {
                "instance_name": "audio0",
                "device_name": "default",
                "udp_port": 23466,
                "audio_gain": 1.0,
                "number_channels": 1
            }
        ]
    },
    "terminal": {
        "module": "terminal.py",
        "terminal_type": "curses",
        "#terminal_type": "http:127.0.0.1:8080",
        "curses_plot_interval": 0.1,
        "http_plot_interval": 0.2,
        "http_plot_directory": "../www/images",
        "tuning_step_large": 1200,
        "tuning_step_small": 100
    }
}

Basically OP25 works correctly with the web interface but doesn't want to start on terminal.
 

MTL_Emergencies

Member++
Database Admin
Joined
Sep 6, 2019
Messages
147
Location
Quebec, Canada
After doing some further testing, I could start OP25 using the .sh file and it opens an Xterm sessions but I couldn't run the command directly from the terminal.
 

boatbod

Member
Joined
Mar 3, 2007
Messages
3,411
Location
Talbot Co, MD
I tried to change the terminal type from web interface to terminal but now I'm getting this error:
Code:
10/07/22 09:10:06.681407 [0] idling receiver
10/07/22 09:10:06.681629 [0] set control channel=770.506250
terminal: exception occurred (66, 18)
python version detected: 2.7.16 (default, Oct 10 2019, 22:02:15)
[GCC 8.3.0]
terminal: exception:
Traceback (most recent call last):
  File "/home/pi/op25/op25/gr-op25_repeater/apps/terminal.py", line 486, in run
    self.setup_curses()
  File "/home/pi/op25/op25/gr-op25_repeater/apps/terminal.py", line 116, in setup_curses
    self.title_help()
  File "/home/pi/op25/op25/gr-op25_repeater/apps/terminal.py", line 152, in title_help
    self.help_bar.addstr(0, 0, help_str.center(self.maxx-1, " "), curses.A_REVERSE)
error: addstr() returned ERR

Allocating 15 zero-copy buffers
Flowgraph complete. Exiting
I didn't modify terminal.py
This error relates to Curses addstr() routine not liking your terminal for some reason.
It actually doesn't matter if you run with the curses terminal or the http terminal, but the key thing is that the window in which you start the op25 shell script needs to be interactive (i.e. opened by you manually) and not dissapear once the shell script exits.
 

MTL_Emergencies

Member++
Database Admin
Joined
Sep 6, 2019
Messages
147
Location
Quebec, Canada
I have reasons to think the crashes may be caused by the way OP25 starts (with LXDE)
I instead created a service (with systemd) to make it start automatically (without terminal).

For now everything works fine. I'll keep you updated if any crashes do occur.
Thanks
 
Status
Not open for further replies.
Top