question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

RABBITMQ: FRAME_ERROR. [RE-OPEN]

See original GitHub issue

Hello everyone,

I have a problem with pika and rabbitmq, the user is connected to a channel, called “/profile/username”

When I send a 30MB file through a django form and ajax, I get the following error (I do not use channel or rabbitmq in the action of sending the form, (Django http request to a view)):

[2017/09/01 02:16:33] WebSocket CONNECT /profile/username/stream/ [127.0.0.1:45582]
WARNING:pika.adapters.base_connection:Socket closed when connection was open
WARNING:pika.connection:Disconnected from RabbitMQ at localhost:5672 (501): FRAME_ERROR - type 3, first 16 octets = <<42,171,223,145,112,216,92,19,214,170,218,214,186,
64,138,171>>: {invalid_frame_end_marker,39}
2017-09-01 02:16:39,792 - ERROR - server - Error trying to receive messages:
ERROR:daphne.server:Error trying to receive messages:
Exception in thread Thread-5:
Traceback (most recent call last):
File "/usr/lib/python3.5/threading.py", line 914, in _bootstrap_inner
self.run()
File "/home/adrian/project/venv/lib/python3.5/site-packages/channels/management/commands/runserver.py", line 175, in run
worker.run()
File "/home/adrian/project/venv/lib/python3.5/site-packages/channels/worker.py", line 87, in run
channel, content = self.channel_layer.receive_many(channels, block=True)
File "/home/adrian/project/venv/lib/python3.5/site-packages/asgiref/base_layer.py", line 43, in receive_many
return self.receive(channels, block)
File "/home/adrian/project/venv/lib/python3.5/site-packages/asgi_rabbitmq/core.py", line 822, in receive
return future.result()
File "/usr/lib/python3.5/concurrent/futures/_base.py", line 405, in result
return self.__get_result()
File "/usr/lib/python3.5/concurrent/futures/_base.py", line 357, in __get_result
raise self._exception
pika.exceptions.ConnectionClosed
Exception in thread Thread-3:
Traceback (most recent call last):
File "/usr/lib/python3.5/threading.py", line 914, in _bootstrap_inner
self.run()
File "/home/adrian/project/venv/lib/python3.5/site-packages/channels/management/commands/runserver.py", line 175, in run
worker.run()
File "/home/adrian/project/venv/lib/python3.5/site-packages/channels/worker.py", line 87, in run
channel, content = self.channel_layer.receive_many(channels, block=True)
File "/home/adrian/project/venv/lib/python3.5/site-packages/asgiref/base_layer.py", line 43, in receive_many
return self.receive(channels, block)
File "/home/adrian/project/venv/lib/python3.5/site-packages/asgi_rabbitmq/core.py", line 822, in receive
return future.result()
File "/usr/lib/python3.5/concurrent/futures/_base.py", line 405, in result
return self.__get_result()
File "/usr/lib/python3.5/concurrent/futures/_base.py", line 357, in __get_result
raise self._exception
pika.exceptions.ConnectionClosed

Exception in thread Thread-6:
Traceback (most recent call last):
File "/usr/lib/python3.5/threading.py", line 914, in _bootstrap_inner
self.run()
File "/home/adrian/project/venv/lib/python3.5/site-packages/channels/management/commands/runserver.py", line 175, in run
worker.run()
File "/home/adrian/project/venv/lib/python3.5/site-packages/channels/worker.py", line 87, in run
channel, content = self.channel_layer.receive_many(channels, block=True)
File "/home/adrian/project/venv/lib/python3.5/site-packages/asgiref/base_layer.py", line 43, in receive_many
return self.receive(channels, block)
File "/home/adrian/project/venv/lib/python3.5/site-packages/asgi_rabbitmq/core.py", line 822, in receive
return future.result()
File "/usr/lib/python3.5/concurrent/futures/_base.py", line 405, in result
return self.__get_result()
File "/usr/lib/python3.5/concurrent/futures/_base.py", line 357, in __get_result
raise self._exception
pika.exceptions.ConnectionClosed
INFO:neo4j.bolt:~~ [CLOSE]

Exception in thread Thread-4:
Traceback (most recent call last):
File "/usr/lib/python3.5/threading.py", line 914, in _bootstrap_inner
self.run()
File "/home/adrian/project/venv/lib/python3.5/site-packages/channels/management/commands/runserver.py", line 175, in run
worker.run()
File "/home/adrian/project/venv/lib/python3.5/site-packages/channels/worker.py", line 87, in run
channel, content = self.channel_layer.receive_many(channels, block=True)
File "/home/adrian/project/venv/lib/python3.5/site-packages/asgiref/base_layer.py", line 43, in receive_many
return self.receive(channels, block)
File "/home/adrian/project/venv/lib/python3.5/site-packages/asgi_rabbitmq/core.py", line 822, in receive
return future.result()
File "/usr/lib/python3.5/concurrent/futures/_base.py", line 405, in result
return self.__get_result()
File "/usr/lib/python3.5/concurrent/futures/_base.py", line 357, in __get_result
raise self._exception
pika.exceptions.ConnectionClosed

Software used:

  • Pika 0.10.0
  • Django 1.11.4
  • Python3.5
  • asgi_rabbitmq==0.5.3
  • channels (last version)

I have created a project with the configuration of the project:

https://github.com/adriancarayol/issue-871

Steps:

install requeriments.txt makemigrations + migrate runserver enter the URL: 127.0.0.1:8000/example Upload a file larger than 30 MB in the rabbitmq log file I also found this:

=ERROR REPORT==== 6-Sep-2017::00:34:55 ===
Error on AMQP connection <0.2183.0> (127.0.0.1:36466 -> 127.0.0.1:5672, vhost: '/', user: 'guest', state: running), channel 2:
operation none caused a connection exception frame_error: "type 3, first 16 octets = «132,2,158,13,120,86,89,177,63,47,150,109,77,252,\n                            102,160»: {invalid_frame_end_marker,83}"

=ERROR REPORT==== 6-Sep-2017::00:34:58 ===
closing AMQP connection <0.2183.0> (127.0.0.1:36466 -> 127.0.0.1:5672):
fatal_frame_error

Wireshark captures: http://imgur.com/fxoKunol.png http://imgur.com/dyjfivll.png http://imgur.com/R3QYOS8l.png

Thanks.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:17 (8 by maintainers)

github_iconTop GitHub Comments

2reactions
proofit404commented, Oct 11, 2017

Hi, guys.

I’m asgi_rabbitmq developer. I will try to upgrade my library to recent pika and check it against given project.

Hope I will have time to do it soon.

1reaction
adriancarayolcommented, Oct 11, 2017

@lukebakken yes, frame error has been solved, we are waiting for profit404 to do the pull request.

Read more comments on GitHub >

github_iconTop Results From Across the Web

RabbitMQ: Why don't channels reopen after a reconnection?
1, Spring AMQP disables it unless you explicitly create your own RabbitMQ connection factory and provide it to the CachingConnectionFactory.
Read more >
AMQP Specification (XML-derived) - RabbitMQ
AMQP Specification (XMLderived). Page 1 of 63 ... frameerror. 501 connection ... Test scenario: Client opens a channel and then reopens the same...
Read more >
Error Handling and Recovery - Bunny
When connecting to RabbitMQ 3.2 or later, Bunny will raise Bunny::AuthenticationFailureError when it receives a proper authentication failure notification.
Read more >
Keeping RabbitMQ connections alive in PHP | by Leo - Mollie
The refactor from Beanstalk to RabbitMQ started out without major problems. ... if we do not care for it, only to reopen it...
Read more >
opmanager_standard_userguide.pdf - ManageEngine
Port Frame Error Rate ... VMware vFabric RabbitMQ ... Ticket Reopen Settings : If an alert re-occurs, this setting will allow you re-open...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found