No subject


Mon Feb 21 11:07:19 GMT 2011


ubuntu at rabbit2:~$ sudo rabbitmqctl list_queues name messages durable
Listing queues ...
jiggleflop    1       false
...done.
ubuntu at rabbit2:~$ irb -rubygems -rbunny
irb(main):001:0> (b=Bunny.new).start
=> :connected
irb(main):002:0> b.queue('jiggleflop').pop[:payload]
=> "hello"
irb(main):003:0> exit

So far so good.  Now, I stop rabbit back on the node where I created the queue:

ubuntu at rabbit1:~$ sudo rabbitmqctl stop_app
Stopping node rabbit at rabbit1 ...
...done.

And look again from the other side:

ubuntu at rabbit2:~$ sudo rabbitmqctl list_queues
Listing queues ...
...done.
ubuntu at rabbit2:~$

OK, the queue's gone. It wasn't durable, so  I should have the
all-clear to declare and recreate it?

ubuntu at rabbit2:~$ irb -rubygems -rbunny
irb(main):001:0> (b=Bunny.new).start
=> :connected
irb(main):002:0> b.queue('jiggleflop')
Bunny::ForcedConnectionCloseError: Error Reply Code: 541
Error Reply Text: INTERNAL_ERROR

Not only can I not declare the queue, but even trying to do so has
hosed my connection to Rabbit:

irb(main):003:0> b.queue('flappydoodle')
Bunny::ConnectionError: Not connected to server

If I reconnect, I can declare a different queue:

irb(main):004:0> (b=Bunny.new).start
=> :connected
irb(main):005:0> b.queue('flappydoodle').publish("booya!")
nil

But still not the one that used to exist on the downed node:

irb(main):006:0> b.queue('jiggleflop')
Bunny::ForcedConnectionCloseError: Error Reply Code: 541
Error Reply Text: INTERNAL_ERROR

Below is the contents of rabbit at rabbit2.log corresponding to the above message.

=ERROR REPORT==== 3-Mar-2011::16:30:43 ===
** Generic server <0.31140.23> terminating
** Last message in was {init,false}
** When Server state == {q,{amqqueue,{resource,<<"/">>,queue,<<"jiggleflop">>},
                                     false,false,none,[],<0.31140.23>},
                           none,false,rabbit_variable_queue,undefined,
                           {[],[]},
                           {[],[]},
                           undefined,undefined,undefined,undefined,
                           {state,fine,undefined},
                           {dict,0,16,16,8,80,48,
                                 {[],[],[],[],[],[],[],[],[],[],[],[],[],[],
                                  [],[]},
                                 {{[],[],[],[],[],[],[],[],[],[],[],[],[],[],
                                   [],[]}}},
                           undefined,undefined}
** Reason for termination ==
** {bad_return_value,
       {error,
           {badarg,
               [{erlang,is_process_alive,[<3039.17457.20>]},
                {rabbit_amqqueue,'-internal_declare/2-fun-3-',2},
                {rabbit_misc,'-execute_mnesia_tx_with_tail/1-fun-0-',1},
                {mnesia_tm,apply_fun,3},
                {mnesia_tm,execute_transaction,5},
                {worker_pool_worker,handle_call,3},
                {gen_server2,handle_msg,2},
                {proc_lib,wake_up,3}]}}}

=ERROR REPORT==== 3-Mar-2011::16:30:43 ===
** Generic server <0.31098.23> terminating
** Last message in was {'$gen_cast',
                           {method,
                               {'queue.declare',1,<<"jiggleflop">>,false,
                                   false,false,false,false,[]},
                               none}}
** When Server state == {ch,running,1,<0.31095.23>,<0.31097.23>,undefined,
                            #Fun<rabbit_channel_sup.0.123274458>,none,
                            {set,0,16,16,8,80,48,
                                {[],[],[],[],[],[],[],[],[],[],[],[],[],[],[],
                                 []},
                                {{[],[],[],[],[],[],[],[],[],[],[],[],[],[],
                                  [],[]}}},
                            1,
                            {[],[]},
                            {[],[]},
                            {user,<<"guest">>,true,
                                rabbit_auth_backend_internal,
                                {internal_user,<<"guest">>,
                                    <<167,104,147,29,51,174,238,60,197,220,53,
                                      95,33,74,109,229,87,242,107,47>>,
                                    true}},
                            <<"/">>,<<>>,
                            {dict,0,16,16,8,80,48,
                                {[],[],[],[],[],[],[],[],[],[],[],[],[],[],[],
                                 []},
                                {{[],[],[],[],[],[],[],[],[],[],[],[],[],[],
                                  [],[]}}},
                            {dict,0,16,16,8,80,48,
                                {[],[],[],[],[],[],[],[],[],[],[],[],[],[],[],
                                 []},
                                {{[],[],[],[],[],[],[],[],[],[],[],[],[],[],
                                  [],[]}}},
                            <0.31093.23>,
                            {state,fine,undefined},
                            false,1,
                            {0,nil},
                            []}
** Reason for termination ==
** {{{bad_return_value,
         {error,
             {badarg,
                 [{erlang,is_process_alive,[<3039.17457.20>]},
                  {rabbit_amqqueue,'-internal_declare/2-fun-3-',2},
                  {rabbit_misc,'-execute_mnesia_tx_with_tail/1-fun-0-',1},
                  {mnesia_tm,apply_fun,3},
                  {mnesia_tm,execute_transaction,5},
                  {worker_pool_worker,handle_call,3},
                  {gen_server2,handle_msg,2},
                  {proc_lib,wake_up,3}]}}},
     {gen_server2,call,[<0.31140.23>,{init,false}]}},
    [{gen_server2,call,2},
     {rabbit_amqqueue,declare,5},
     {rabbit_channel,handle_method,3},
     {rabbit_channel,handle_cast,2},
     {gen_server2,handle_msg,2},
     {proc_lib,wake_up,3}]}

=ERROR REPORT==== 3-Mar-2011::16:30:43 ===
connection <0.31095.23> (running), channel 1 - error:
{{{bad_return_value,
      {error,
          {badarg,
              [{erlang,is_process_alive,[<3039.17457.20>]},
               {rabbit_amqqueue,'-internal_declare/2-fun-3-',2},
               {rabbit_misc,'-execute_mnesia_tx_with_tail/1-fun-0-',1},
               {mnesia_tm,apply_fun,3},
               {mnesia_tm,execute_transaction,5},
               {worker_pool_worker,handle_call,3},
               {gen_server2,handle_msg,2},
               {proc_lib,wake_up,3}]}}},
  {gen_server2,call,[<0.31140.23>,{init,false}]}},
 [{gen_server2,call,2},
  {rabbit_amqqueue,declare,5},
  {rabbit_channel,handle_method,3},
  {rabbit_channel,handle_cast,2},
  {gen_server2,handle_msg,2},
  {proc_lib,wake_up,3}]}

=WARNING REPORT==== 3-Mar-2011::16:30:43 ===
Non-AMQP exit reason '{{{bad_return_value,
                         {error,
                          {badarg,
                           [{erlang,is_process_alive,[<3039.17457.20>]},
                            {rabbit_amqqueue,'-internal_declare/2-fun-3-',2},
                            {rabbit_misc,
                             '-execute_mnesia_tx_with_tail/1-fun-0-',1},
                            {mnesia_tm,apply_fun,3},
                            {mnesia_tm,execute_transaction,5},
                            {worker_pool_worker,handle_call,3},
                            {gen_server2,handle_msg,2},
                            {proc_lib,wake_up,3}]}}},
                        {gen_server2,call,[<0.31140.23>,{init,false}]}},
                       [{gen_server2,call,2},
                        {rabbit_amqqueue,declare,5},
                        {rabbit_channel,handle_method,3},
                        {rabbit_channel,handle_cast,2},
                        {gen_server2,handle_msg,2},
                        {proc_lib,wake_up,3}]}'

=INFO REPORT==== 3-Mar-2011::16:30:43 ===
closing TCP connection <0.31095.23> from 127.0.0.1:39949


More information about the rabbitmq-discuss mailing list