rabbitmq is terminating and closing connection

3,671 views
Skip to first unread message

si...@minddotss.com

unread,
Sep 8, 2016, 6:54:03 AM9/8/16
to rabbitmq-users
I placed rabbitmq in EC2 instance with ubuntu os. starting it is working after that i access rabbitmq through API's using php and put in cronjobs. Then After it is continuously terminating connection everyday.I changed rabbitmq server process in to 204000,and i enable handshake timeout in configuration.But it is not restarting.

Here is the logs:

Reason:Channel error on connection <0.21153.18> (172.31.19.214:52674 -> 172.31.19.214:5672, vhost: '/', user: 'test'), channel 1:
operation queue.declare caused a channel exception precondition_failed: "inequivalent arg 'durable' for queue 'GCMNewUserQueue' in vhost '/': received 'true' but current is 'false'"

=WARNING REPORT==== 8-Sep-2016::01:05:01 ===
closing AMQP connection <0.21153.18> (172.31.19.214:52674 -> 172.31.19.214:5672):
client unexpectedly closed TCP connection


2.=ERROR REPORT==== 8-Sep-2016::01:15:08 ===
** Generic server rabbit_disk_monitor terminating
** Last message in was update
** When Server state == {state,"/var/lib/rabbitmq/mnesia/rabbit@ip-172-31-19-214",
                               50000000,5437759488,100,10000,
                               #Ref<0.0.10.50232>,false,true}
** Reason for termination ==
** {unparseable,[]}

3.=ERROR REPORT==== 7-Sep-2016::09:03:16 ===
closing AMQP connection <0.583.1> (10.0.0.163:41652 -> 10.0.0.163:5672):
{handshake_timeout,frame_header}


4.=INFO REPORT==== 7-Sep-2016::09:00:10 ===
Disabling disk free space monitoring on unsupported platform:
{{'EXIT',{unparseable,[]}},1040715776}

5.**********************************************************
*** Publishers will be blocked until this alarm clears ***
**********************************************************

=INFO REPORT==== 7-Sep-2016::08:43:57 ===
vm_memory_high_watermark clear. Memory used:415940216 allowed:416286310

=WARNING REPORT==== 7-Sep-2016::08:43:57 ===
memory resource limit alarm cleared on node 'rabbit@ip-10-0-0-163'

=WARNING REPORT==== 7-Sep-2016::08:43:57 ===
memory resource limit alarm cleared across the cluster

=INFO REPORT==== 7-Sep-2016::08:44:01 ===
vm_memory_high_watermark set. Memory used:416457544 allowed:416286310

=WARNING REPORT==== 7-Sep-2016::08:44:01 ===
memory resource limit alarm set on node 'rabbit@ip-10-0-0-163'.

**********************************************************
*** Publishers will be blocked until this alarm clears ***
**********************************************************
6.=ERROR REPORT==== 7-Sep-2016::07:42:19 ===
Error in process <0.8195.2> on node 'rabbit@ip-10-0-0-163' with exit value: {badarg,[{erlang,port_command,[#Port<0.25569>,[40,"/bin/df -kP /var/lib/rabbitmq/mnesia/rabbit@ip-10-0-0-163",10,41,32,60,47,100,101,118,47,110,117,108,108,59,32,101,99,104,111,32,32,34,4,34,10]],[]},{os,'-unix_cmd/1-fun-0-',2,[{file,"os.erl"},{line,214}]}]}


7.=INFO REPORT==== 7-Sep-2016::07:18:02 ===
accepting AMQP connection <0.28500.1> (10.0.0.163:40524 -> 10.0.0.163:5672)

=WARNING REPORT==== 7-Sep-2016::07:18:02 ===
closing AMQP connection <0.28500.1> (10.0.0.163:40524 -> 10.0.0.163:5672):
client unexpectedly closed TCP connection

8.=WARNING REPORT==== 6-Sep-2016::12:26:21 ===
memory resource limit alarm cleared on node 'rabbit@ip-10-0-0-163'

=WARNING REPORT==== 6-Sep-2016::12:26:21 ===
memory resource limit alarm cleared across the cluster


Michael Klishin

unread,
Sep 8, 2016, 8:00:26 AM9/8/16
to rabbitm...@googlegroups.com
This is not RabbitMQ terminating but a particular node component, a disk space monitor.
In reasonably recent versions this means that RabbitMQ won't know how much disk space
there is available on the node, that's it.

According to the log your clients never perform AMQP 0-9-1 handshake. One common reason for that
is that you try to connect to a TLS port with a client not configured to use TLS or vice versa.

--
You received this message because you are subscribed to the Google Groups "rabbitmq-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rabbitmq-users+unsubscribe@googlegroups.com.
To post to this group, send email to rabbitmq-users@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--
MK

Staff Software Engineer, Pivotal/RabbitMQ

Siva Prasad

unread,
Sep 8, 2016, 8:33:58 AM9/8/16
to rabbitm...@googlegroups.com
Thanks Michael klishin for your quick response.

Actually In my project,we are using direct rabbitmq API's  to send data in to Queue.And in consumer side it is processing successfully After some time(night times)rabbitmq it is disconnecting.

And im using following API to send data.


with authentication and php Curl method is using to send json data.

And one more thing ,i changed memory set limit,file discriptor count,And also im trying to enable in conf file,at that rabbitmq is not restarting.

Last thing im running around 20 API's daily by using cronjob in ubuntu.

Michael Klishin

unread,
Sep 8, 2016, 8:48:44 AM9/8/16
to rabbitm...@googlegroups.com
Publishing over HTTP API is not commonly used and is available only as a last resort measure.
Consider using a "real" PHP client library [1].


--
You received this message because you are subscribed to the Google Groups "rabbitmq-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rabbitmq-users+unsubscribe@googlegroups.com.
To post to this group, send email to rabbitmq-users@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Siva Prasad

unread,
Sep 8, 2016, 9:02:06 AM9/8/16
to rabbitm...@googlegroups.com
ok,But in my project Andriod app will direct hit that API and send data to queue.And by using crontab im executing  consumer file ,inserting data in to database. 

On Thu, Sep 8, 2016 at 6:18 PM, Michael Klishin <mkli...@pivotal.io> wrote:
Publishing over HTTP API is not commonly used and is available only as a last resort measure.
Consider using a "real" PHP client library [1].

On Thu, Sep 8, 2016 at 3:33 PM, Siva Prasad <si...@minddotss.com> wrote:
Thanks Michael klishin for your quick response.

Actually In my project,we are using direct rabbitmq API's  to send data in to Queue.And in consumer side it is processing successfully After some time(night times)rabbitmq it is disconnecting.

And im using following API to send data.


with authentication and php Curl method is using to send json data.

And one more thing ,i changed memory set limit,file discriptor count,And also im trying to enable in conf file,at that rabbitmq is not restarting.

Last thing im running around 20 API's daily by using cronjob in ubuntu.

--
You received this message because you are subscribed to the Google Groups "rabbitmq-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rabbitmq-users+unsubscribe@googlegroups.com.
To post to this group, send email to rabbitm...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.



--
MK

Staff Software Engineer, Pivotal/RabbitMQ

--
You received this message because you are subscribed to a topic in the Google Groups "rabbitmq-users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/rabbitmq-users/OFwFNn185is/unsubscribe.
To unsubscribe from this group and all its topics, send an email to rabbitmq-users+unsubscribe@googlegroups.com.

Michael Klishin

unread,
Sep 8, 2016, 9:05:25 AM9/8/16
to rabbitm...@googlegroups.com
RabbitMQ Java client works on Android. Note that RabbitMQ client connections are supposed to be
long lived, which may or may not be easy or optimal for various mobile apps

Siva Prasad

unread,
Sep 8, 2016, 9:09:58 AM9/8/16
to rabbitm...@googlegroups.com
" One common reason for that is that you try to connect to a TLS port with a client not configured to use TLS or vice versa."

from ur response,these TLS port related issue will come when we hitting directly API.

And somewhere i got,cronjob will stop rabbitmq in the middle of the night(unix based time system).Is there Anything related


Michael Klishin

unread,
Sep 8, 2016, 9:15:10 AM9/8/16
to rabbitm...@googlegroups.com
Your node hits a resource alarm, which is quite visible in the logs.
See http://www.rabbitmq.com/alarms.html and solve that problem first.

Siva Prasad

unread,
Sep 8, 2016, 9:39:30 AM9/8/16
to rabbitm...@googlegroups.com
Hi micheal,

my system have these memory configuration,is it suitable for rabbitmq memory limit

root@ip-10-0-0-163://# free
             total       used       free     shared    buffers     cached
Mem:       1016324     946160      70164       3196       1636      32236
-/+ buffers/cache:     912288     104036
Swap:      1023996     926348      97648

Its Around 1GB. Let me know how much RAM is required for Rabbitmq.

Michael Klishin

unread,
Sep 9, 2016, 8:05:32 AM9/9/16
to rabbitm...@googlegroups.com

Siva Prasad

unread,
Sep 9, 2016, 8:31:33 AM9/9/16
to rabbitm...@googlegroups.com
Todays also i got same error in logs.And rabbitmq is disconnected.After that i restarted AWS server. Everyday night time its is shutdown.Present no work load.

My skype id :shivaa.prasad2,

these is my skype ,i will show my code logics and work loads and memory configs.please help me im totally unware about these problem
Reply all
Reply to author
Forward
0 new messages