jookies / jasmin

Jasmin - Open source SMS gateway
http://jasminsms.com
Other
1.04k stars 558 forks source link

Jasmin crash after a time #986

Open marceloNascimentoDev opened 3 years ago

marceloNascimentoDev commented 3 years ago

Good afternoon, recently I started using Jasmin as SMS gateway and initially it worked properly, but after a while I can no longer manipulate the connectors by jcli and send MT messages, being necessary to restart the containers to return to process correctly. When I try to send an MT message via HTTP I get the following error message: Endpoint: http://127.0.0.1:1401/send?username=user&password=user4&to=5541991169812&content=test&from=JasminDev

HTTP Response: Success "[Failure instance: Traceback: <class 'txamqp.client.ChannelClosed'>: Method(name=close, id=40) (406, 'PRECONDITION_FAILED - consumer ack timed out on channel 1', 0, 0) content = None /usr/local/lib/python3.9/site-packages/jasmin/queues/factory.py:230:publish

:3:basic_publish /usr/local/lib/python3.9/site-packages/twisted/internet/defer.py:1613:unwindGenerator /usr/local/lib/python3.9/site-packages/twisted/internet/defer.py:1529:_cancellableInlineCallbacks --- --- /usr/local/lib/python3.9/site-packages/jasmin/managers/clients.py:590:perspective_submit_sm /usr/local/lib/python3.9/site-packages/twisted/internet/defer.py:1418:_inlineCallbacks /usr/local/lib/python3.9/site-packages/txamqp/protocol.py:72:invoke /usr/local/lib/python3.9/site-packages/txamqp/protocol.py:123:_raise_closed ]" Log Default-.log: 2021-05-12 20:36:04 ERROR 1 Bind failed [[Failure instance: Traceback (failure with no frames): : Request timed out after 30 secs: PDU [command: CommandId.bind_transceiver, sequence_number: 1, command_status: CommandStatus.ESME_ROK system_id: b'secret' password: b'secret' system_type: b'' interface_version: 52 addr_ton: b'INTERNATIONAL' addr_npi: b'ISDN' address_range: None ] ]]. Disconnecting... 2021-05-12 20:36:04 WARNING 1 Disconnecting... 2021-05-12 20:36:04 WARNING 1 Shutdown requested...disconnecting 2021-05-12 20:36:04 WARNING 1 Disconnecting... 2021-05-12 20:36:06 INFO 1 Connecting to IPv4Address(type='TCP', host='89.**.***.***', port=5091) ... 2021-05-12 20:36:06 WARNING 1 SMPP connection established from 89.**.***.*** to port 39892 2021-05-12 20:36:06 INFO 1 Connection made to 89.**.***.***:5091 2021-05-12 20:36:06 WARNING 1 Requesting bind as transceiver 2021-05-12 20:36:06 WARNING 1 SMPP 89.**.***.*** disconnected from port 39892: [Failure instance: Traceback (failure with no frames): : Connection was closed cleanly. ] 2021-05-12 20:36:06 ERROR 1 Connection lost. Reason: [Failure instance: Traceback (failure with no frames): : Connection was closed cleanly. ] 2021-05-12 20:36:06 INFO 1 Reconnecting after 10 seconds ... Jasmin version:0.10.9 Docker-compose: version: "3" services: redis: image: redis:alpine rabbit-mq: image: rabbitmq:alpine ports: - 5672:5672 - 15672:15672 jasmin: build: context: ./ dockerfile: ./docker/Dockerfile.dev container_name: jasmin volumes: - ./jasmin:/usr/jasmin/jasmin ports: - 2775:2775 - 8990:8990 - 1401:1401 depends_on: - redis - mysql - rabbit-mq environment: REDIS_CLIENT_HOST: redis AMQP_BROKER_HOST: rabbit-mq mysql: image: mysql:5.7 container_name: mysql expose: - "3306" volumes: - ./dbdata:/var/lib/mysql environment: MYSQL_DATABASE: jasmin MYSQL_ROOT_PASSWORD: passwd
osquem commented 3 years ago

Hi @marceloNascimentoDev I have the same issue since yesterday. Did you find a fix or the cause of the problem?

kissonde commented 3 years ago

I also have the same problem. @marceloNascimentoDev and @osquem any developments?

xiaoyiios commented 2 years ago

I also have the same problem. @marceloNascimentoDev and @osquem any developments? +1

Please kindly refer to the details of logs.I already double confirmed the username and password is correct.

2021-11-16 02:39:52 INFO 1 Establishing TCP connection to 172.16.10.229:1401 2021-11-16 02:39:52 INFO 1 Connecting to IPv4Address(type='TCP', host='172.16.10.229', port=1401) ... 2021-11-16 02:39:52 WARNING 1 SMPP connection established from 172.16.10.229 to port 42640 2021-11-16 02:39:52 INFO 1 Connection made to 172.16.10.229:1401 2021-11-16 02:39:52 WARNING 1 Requesting bind as transceiver 2021-11-16 02:40:22 ERROR 1 Request timed out after 30 secs: PDU [command: CommandId.bind_transceiver, sequence_number: 1, command_status: CommandStatus.ESME_ROK system_id: b'csd' password: b'csd@123' system_type: b'' interface_version: 52 addr_ton: <AddrTon.UNKNOWN: 1> addr_npi: <AddrNpi.UNKNOWN: 1> address_range: None ] 2021-11-16 02:40:22 ERROR 1 Bind failed [[Failure instance: Traceback (failure with no frames): <class 'smpp.pdu.error.SMPPRequestTimoutError'>: Request timed out after 30 secs: PDU [command: CommandId.bind_K system_id: b'csd' password: b'csd@123' system_type: b'' interface_version: 52 addr_ton: <AddrTon.UNKNOWN: 1> addr_npi: <AddrNpi.UNKNOWN: 1> address_range: None ] ]]. Disconnecting... 2021-11-16 02:40:22 WARNING 1 Disconnecting... 2021-11-16 02:40:22 INFO 1 Ordering a disconnect with no further reconnections. 2021-11-16 02:40:22 INFO 1 Stopped automatic connection retrying. 2021-11-16 02:40:22 INFO 1 Disconnecting SMPP client 2021-11-16 02:40:22 WARNING 1 Disconnecting... 2021-11-16 02:40:22 WARNING 1 Shutdown requested...disconnecting 2021-11-16 02:40:22 WARNING 1 Disconnecting... 2021-11-16 02:40:22 WARNING 1 SMPP 172.16.10.229 disconnected from port 42640: [Failure instance: Traceback (failure with no frames): <class 'twisted.internet.error.ConnectionDone'>: Connection was closed clea. ] 2021-11-16 02:40:22 ERROR 1 Connection lost. Reason: [Failure instance: Traceback (failure with no frames): <class 'twisted.internet.error.ConnectionDone'>: Connection was closed cleanly. ] 2021-11-16 02:40:22 INFO 1 Exiting.

farirat commented 2 years ago

Is this issue up to date ? What jasmin release was it ?

jaur-jaur commented 2 years ago

I have the same. I'm using v0.10.9

farirat commented 2 years ago

how much traffic is going through jasmin ? what interfaces are used (smpp/http) ? and are you running interceptors ? sms loggers ? do you have ram/cpu monitoring sheets ?

tonylemeunier commented 1 year ago

Hi everyone,

I have the same issue. Do we have an update about this ?

Regards,

marcinkowalczyk commented 1 year ago

I'm testing 0.10.2 with latest docker image and seems it's affected by this problem too. rabbit & gateway on one box. Looks that best option is to add another container with smppsim, creating new bind,submit_sm new message and check if uuid was generated - if no restart container

    healthcheck:
      test: curl -s 'http://127.0.0.1:1401/send?to=1234&from=1234loop1234&content=Hello&dlr=no&tags=LOOPBACK&username=XXX&password=YYY' |  grep -E '[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}'