jookies / jasmin

Jasmin - Open source SMS gateway
http://jasminsms.com
Other
991 stars 540 forks source link

Failed to load smppcc configuration #1133

Open mrsanvicente opened 10 months ago

mrsanvicente commented 10 months ago

Hello everyone,

My jasmin stop working 2 times, one with load of sms and the other no load.

the smppcc configuration can not be loaded, with the folowing error:

Sep 07 18:02:53 sms jasmind[5839]: yield self.pb['smppcm'].amqpBroker.channelReady Sep 07 18:02:53 sms jasmind[5839]: builtins.AttributeError: 'NoneType' object has no attribute 'channelReady'

I was looking at the celery service and it looks ok.

Sep 07 17:21:15 sms jasmin-celery[5851]: [2023-09-07 17:21:15,765: INFO/MainProcess] Connected to amqp://guest:**@127.0.0.1:5672// Sep 07 17:21:15 sms jasmin-celery[5851]: [2023-09-07 17:21:15,781: INFO/MainProcess] mingle: searching for neighbors Sep 07 17:21:16 sms jasmin-celery[5851]: [2023-09-07 17:21:16,805: INFO/MainProcess] mingle: all alone Sep 07 17:21:16 sms jasmin-celery[5851]: [2023-09-07 17:21:16,823: INFO/MainProcess] celery@sms ready.

While looking at the channel, ican 2 channel instead 6 when it was working

rabbitmqctl list_connections name channels -q

Before the failure

name channels 127.0.0.1:60608 -> 127.0.0.1:5672 1 127.0.0.1:60610 -> 127.0.0.1:5672 1 127.0.0.1:60622 -> 127.0.0.1:5672 1 127.0.0.1:60638 -> 127.0.0.1:5672 3 127.0.0.1:60654 -> 127.0.0.1:5672 1

After the failure:

name channels 127.0.0.1:51454 -> 127.0.0.1:5672 3 127.0.0.1:51466 -> 127.0.0.1:5672 1

Not sure now to solve this issue, the load command on cli fails. The only way is to go back to a previus snapshot.

Any hints on this problem?

Thanks

farirat commented 10 months ago

is this a new install ? please specify your env (os, python, rabbitmq, ...)

mrsanvicente commented 10 months ago

Hello,
It is a four months install.

Ubuntu 20.04.5 LTS redis-cli 5.0.7 RabbitMQ logo 3.8.2Erlang 22.2.7 Python 3.8.10

anything more?

mrsanvicente commented 10 months ago

Hello using restapi request "dlr": "no",

dlr:RegisteredDeliveryReceipt.NO_SMSC_DELIVERY_RECEIPT_REQUESTED

And by the way, the smpp bind are transmitter, no way to receive dlr.

bind transmitter dlr_expiry 86400 dlr_msgid 0

Regards

On Fri, Sep 8, 2023 at 7:22 AM The Z @.***> wrote:

and dlr-level=3 ?

— Reply to this email directly, view it on GitHub https://github.com/jookies/jasmin/issues/1133#issuecomment-1711664709, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABM4J2ZQMJLEC4AKMEF37CTXZMLXXANCNFSM6AAAAAA4PTQR7Y . You are receiving this because you authored the thread.Message ID: @.***>

-- Mario San Vicente Cheers!

farirat commented 10 months ago

did jasmin get upgraded and so it's data as well ? please be precise on jasmin versions.

mrsanvicente commented 10 months ago

Hello,

Ubuntu 20.04 It is /usr/local/bin/jasmind.py --version Twisted version: 22.1.0

I just installed pre requisites and 2 curl -s https://setup.jasminsms.com/deb | sudo bash 3 sudo apt install jasmin-sms-gateway

Thanks

On Sat, Sep 9, 2023 at 5:13 AM The Z @.***> wrote:

did jasmin get upgraded and so it's data as well ? please be precise on jasmin versions.

— Reply to this email directly, view it on GitHub https://github.com/jookies/jasmin/issues/1133#issuecomment-1712486589, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABM4J22674AX64NJZK6BHFDXZRFPDANCNFSM6AAAAAA4PTQR7Y . You are receiving this because you authored the thread.Message ID: @.***>

-- Mario San Vicente Cheers!

farirat commented 10 months ago

You get jasmin version when you connect to telnet console (telnet 127.0.0.1 8990). What about the upgrade question ?

mrsanvicente commented 10 months ago

Hi there!

Welcome to Jasmin 0.10.12 console.

I ran apt-get update, before installing rabbit, redis and jasmin.

Hope that the details needed.

Thanks

On Mon, Sep 11, 2023 at 5:28 AM The Z @.***> wrote:

You get jasmin version when you connect to telnet console (telnet 127.0.0.1 8990). What about the upgrade question ?

— Reply to this email directly, view it on GitHub https://github.com/jookies/jasmin/issues/1133#issuecomment-1713692328, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABM4J26UQEB6FKPNQYZQVNDXZ3YW5ANCNFSM6AAAAAA4PTQR7Y . You are receiving this because you authored the thread.Message ID: @.***>

-- Mario San Vicente Cheers!

farirat commented 10 months ago

To eliminate a potential data migration issue, stop jasmin, backup/delete everything under /etc/jasmin/store/*, start jasmin Test and confirm issue reproduction.

mrsanvicente commented 10 months ago

Hello,

OK i stop and erased data. Try to load an got error cause there is no data.

Then try to add ah smppcc and got error message:

==> /var/log/jasmin/smppclient-manager.log <== 2023-09-12 01:38:07 ERROR 15256 AMQP Broker is not added

Cheers Mario

On Mon, Sep 11, 2023 at 5:21 PM The Z @.***> wrote:

To eliminate a potential data migration issue, stop jasmin, backup/delete everything under /etc/jasmin/store/*, start jasmin Test and confirm issue reproduction.

— Reply to this email directly, view it on GitHub https://github.com/jookies/jasmin/issues/1133#issuecomment-1714730719, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABM4J274KJ5UMKZP76KWPNDXZ6MFZANCNFSM6AAAAAA4PTQR7Y . You are receiving this because you authored the thread.Message ID: @.***>

-- Mario San Vicente Cheers!

farirat commented 10 months ago

Did jasmin connect to rabbitmq already ? check /var/log/jasmin/amqp-client.log

mrsanvicente commented 10 months ago

Hello The Z,

Sorry for the late reply.

The log for amqp-client.log is empty.

The rabbit service is broken.

systemctl status rabbitmq-server

Process: 43641 ExecStart=/usr/sbin/rabbitmq-server (code=exited, status=1/FAILURE)

journalctl -xe

-- The job identifier is 10058. Sep 13 13:11:02 sms systemd[1]: rabbitmq-server.service: Main process exited, code=exited, status=1/FAILURE -- Subject: Unit process exited -- Defined-By: systemd -- Support: http://www.ubuntu.com/support

-- An ExecStart= process belonging to unit rabbitmq-server.service has exited.

-- The process' exit code is 'exited' and its exit status is 1. Sep 13 13:11:02 sms systemd[1]: rabbitmq-server.service: Failed with result 'exit-code'. -- Subject: Unit failed -- Defined-By: systemd -- Support: http://www.ubuntu.com/support

-- The unit rabbitmq-server.service has entered the 'failed' state with result 'exit-code'. Sep 13 13:11:02 sms systemd[1]: Failed to start RabbitMQ Messaging Server. -- Subject: A start job for unit rabbitmq-server.service has failed -- Defined-By: systemd -- Support: http://www.ubuntu.com/support

-- A start job for unit rabbitmq-server.service has finished with a failure.

-- The job identifier is 10058 and the job result is failed. Sep 13 13:11:02 sms jasmin-celery[793]: [2023-09-13 13:11:02,207: ERROR/MainProcess] consumer: Cannot connect to amqp://guest:**@ 127.0.0.1:5672//: [Errno 111]> Sep 13 13:11:02 sms jasmin-celery[793]: Trying again in 32.00 seconds...

Thank you

On Tue, Sep 12, 2023 at 3:09 AM The Z @.***> wrote:

Did jasmin connect to rabbitmq already ? check /var/log/jasmin/amqp-client.log

— Reply to this email directly, view it on GitHub https://github.com/jookies/jasmin/issues/1133#issuecomment-1715320936, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABM4J22SOPKIC4JHLZADZM3X2ARDFANCNFSM6AAAAAA4PTQR7Y . You are receiving this because you authored the thread.Message ID: @.***>

-- Mario San Vicente Cheers!

mrsanvicente commented 10 months ago

Adding more info /usr/sbin/rabbitmqctl stop /usr/sbin/rabbitmq-server

BOOT FAILED

Error description: init:do_boot/3 init:start_em/1 rabbit:start_it/1 line 474 rabbit:broker_start/1 line 350 rabbit:start_loaded_apps/2 line 600 app_utils:manage_applications/6 line 126 lists:foldl/3 line 1263 rabbit:'-handle_app_error/1-fun-0-'/3 line 723 throw:{could_not_start,ra, {ra, {{shutdown, {failed_to_start_child,ra_system_sup, {shutdown, {failed_to_start_child,ra_log_sup, {shutdown, {failed_to_start_child,ra_log_wal_sup, {shutdown, {failed_to_start_child,ra_log_wal, {{case_clause,{error,eacces}}, [{ra_log_wal,open_existing,1, [{file,"src/ra_log_wal.erl"},{line,646}]}, {ra_log_wal,'-recover_wal/2-lc$^0/1-0-',1, [{file,"src/ra_log_wal.erl"},{line,265}]}, {ra_log_wal,recover_wal,2, [{file,"src/ra_log_wal.erl"},{line,268}]}, {ra_log_wal,init,1, [{file,"src/ra_log_wal.erl"},{line,214}]}, {gen_batch_server,init_it,6, [{file,"src/gen_batch_server.erl"},{line,133}]}, {proc_lib,init_p_do_apply,3, [{file,"proc_lib.erl"},{line,249}]}]}}}}}}}}}, {ra_app,start,[normal,[]]}}}} Log file(s) (may contain more information): @. @._upgrade.log

{"init terminating in do_boot",{could_not_start,ra,{ra,{{shutdown,{failed_to_start_child,ra_system_sup,{shutdown,{failed_to_start_child,ra_log_sup,{shutdown,{failed_to_start_child,ra_log_wal_sup,{shutdown,{failed_to_start_child,ra_log_wal,{{case_clause,{error,eacces}},[{ra_log_wal,open_existing,1,[{file,"src/ra_log_wal.erl"},{line,646}]},{ra_log_wal,'-recover_wal/2-lc$^0/1-0-',1,[{file,"src/ra_log_wal.erl"},{line,265}]},{ra_log_wal,recover_wal,2,[{file,"src/ra_log_wal.erl"},{line,268}]},{ra_log_wal,init,1,[{file,"src/ra_log_wal.erl"},{line,214}]},{gen_batch_server,init_it,6,[{file,"src/gen_batch_server.erl"},{line,133}]},{proc_lib,init_p_do_apply,3,[{file,"proc_lib.erl"},{line,249}]}]}}}}}}}}},{ra_app,start,[normal,[]]}}}}} init terminating in do_boot ({could_notstart,ra,{ra,{{shutdown,{}},{raapp,start,[]}}}})

Crash dump is being written to: /var/log/rabbitmq/erl_crash.dump...done

will try to reinstall and keep you posted.

Thanks

On Wed, Sep 13, 2023 at 1:13 PM Mario San Vicente @.***> wrote:

Hello The Z,

Sorry for the late reply.

The log for amqp-client.log is empty.

The rabbit service is broken.

systemctl status rabbitmq-server

Process: 43641 ExecStart=/usr/sbin/rabbitmq-server (code=exited, status=1/FAILURE)

journalctl -xe

-- The job identifier is 10058. Sep 13 13:11:02 sms systemd[1]: rabbitmq-server.service: Main process exited, code=exited, status=1/FAILURE -- Subject: Unit process exited -- Defined-By: systemd -- Support: http://www.ubuntu.com/support

-- An ExecStart= process belonging to unit rabbitmq-server.service has exited.

-- The process' exit code is 'exited' and its exit status is 1. Sep 13 13:11:02 sms systemd[1]: rabbitmq-server.service: Failed with result 'exit-code'. -- Subject: Unit failed -- Defined-By: systemd -- Support: http://www.ubuntu.com/support

-- The unit rabbitmq-server.service has entered the 'failed' state with result 'exit-code'. Sep 13 13:11:02 sms systemd[1]: Failed to start RabbitMQ Messaging Server. -- Subject: A start job for unit rabbitmq-server.service has failed -- Defined-By: systemd -- Support: http://www.ubuntu.com/support

-- A start job for unit rabbitmq-server.service has finished with a failure.

-- The job identifier is 10058 and the job result is failed. Sep 13 13:11:02 sms jasmin-celery[793]: [2023-09-13 13:11:02,207: ERROR/MainProcess] consumer: Cannot connect to amqp://guest:**@ 127.0.0.1:5672//: [Errno 111]> Sep 13 13:11:02 sms jasmin-celery[793]: Trying again in 32.00 seconds...

Thank you

On Tue, Sep 12, 2023 at 3:09 AM The Z @.***> wrote:

Did jasmin connect to rabbitmq already ? check /var/log/jasmin/amqp-client.log

— Reply to this email directly, view it on GitHub https://github.com/jookies/jasmin/issues/1133#issuecomment-1715320936, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABM4J22SOPKIC4JHLZADZM3X2ARDFANCNFSM6AAAAAA4PTQR7Y . You are receiving this because you authored the thread.Message ID: @.***>

-- Mario San Vicente Cheers!

-- Mario San Vicente Cheers!

farirat commented 10 months ago

Okay so that's a rabbit issue, you can simply uninstall/install it, no impact on jasmin.

mrsanvicente commented 10 months ago

Hello,

I uninstall, cleaned , and reinstalled and still not working.

sudo apt-get remove --auto-remove rabbitmq-server sudo apt-get purge --auto-remove rabbitmq-server

sudo apt-get install rabbitmq-server

Logs:

2023-09-15 00:08:30 ERROR 2743544 AMQP Broker is not added ==> /var/log/jasmin/restapi.log <== 2023-09-15 00:23:30 ERROR 2743548 [404] @.*** GET /

Sep 15 00:07:31 sms jasmind[2743544]: File "/usr/local/bin/jasmind.py", line 429, in start Sep 15 00:07:31 sms jasmind[2743544]: yield self.startdeliverSmThrowerService() Sep 15 00:07:31 sms jasmind[2743544]: File "/usr/local/bin/jasmind.py", line 255, in startdeliverSmThrowerService Sep 15 00:07:31 sms jasmind[2743544]: return self.components['deliversm-thrower'].addAmqpBroker(self.components['amqp-broker-factory']) Sep 15 00:07:31 sms jasmind[2743544]: KeyError: 'amqp-broker-factory'

Regards Mario

On Thu, Sep 14, 2023 at 10:12 AM The Z @.***> wrote:

Okay so that's a rabbit issue, you can simply uninstall/install it, no impact on jasmin.

— Reply to this email directly, view it on GitHub https://github.com/jookies/jasmin/issues/1133#issuecomment-1719750280, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABM4J23HA4HFVXYURE4CL2DX2MUHRANCNFSM6AAAAAA4PTQR7Y . You are receiving this because you authored the thread.Message ID: @.***>

-- Mario San Vicente Cheers!