Skip to content
This repository has been archived by the owner on Nov 16, 2020. It is now read-only.

UI allows deletion of an active trace file leading to an EACCES exception on Windows #31

Closed
witling opened this issue Oct 9, 2019 · 2 comments · Fixed by #32
Closed
Assignees
Milestone

Comments

@witling
Copy link

witling commented Oct 9, 2019

The management UI allows the deletion of a trace file that is actively worked on making any further actions regarding tracing impossible due to ubiquitous error message. The Delete event should at least assert that no tracing currently relies on that log.

Steps to reproduce

  • Create a new trace inside Admin -> Tracing view
  • Delete the newly created log file
    2019-10-09 14_00_26-Window
  • Window with erlang error will be prompted which does not disappear after reloading the page
    2019-10-09 14_00_46-Window

Fixes

After restarting the RabbitMQ server, the UI is working again.

Environment

  • RabbitMQ version: 3.7.18
  • Erlang version: 21.3
  • Browser: IE11
  • Management UI: Admin -> Tracing
  • Operating system: Windows Server 2016, v10.0.14393
  • Errors reported in the js console: -
  • RabbitMQ plugin information via rabbitmq-plugins list
    [ * ] rabbitmq_event_exchange 3.7.18
    [e * ] rabbitmq_management 3.7.18
    [e * ] rabbitmq_management_agent 3.7.18
    [E * ] rabbitmq_tracing 3.7.18
    [e * ] rabbitmq_web_dispatch 3.7.18

Logs

2019-10-09 13:39:27.418 [info] <0.676.0> Enabling tracing for vhost '/'
2019-10-09 13:39:27.433 [info] <0.726.0> Tracer opened log file "/var/tmp/rabbitmq-tracing/all.log" with format json
2019-10-09 13:59:15.059 [warning] <0.2825.0> Node rabbit@---------- could not be contacted: {badrpc,
                                                {'EXIT',
                                                 {{badmatch,{error,eacces}},
                                                  [{rabbit_tracing_files,
                                                    file_info,1,
                                                    [{file,
                                                      "src/rabbit_tracing_files.erl"},
                                                     {line,49}]},
                                                   {rabbit_tracing_files,
                                                    '-list/0-lc$^0/1-0-',1,
                                                    [{file,
                                                      "src/rabbit_tracing_files.erl"},
                                                     {line,29}]},
                                                   {rpc,local_call,3,
                                                    [{file,"rpc.erl"},
                                                     {line,321}]},
                                                   {rabbit_tracing_util,
                                                    apply_on_node,5,
                                                    [{file,
                                                      "src/rabbit_tracing_util.erl"},
                                                     {line,16}]},
                                                   {rabbit_tracing_wm_files,
                                                    to_json,2,
                                                    [{file,
                                                      "src/rabbit_tracing_wm_files.erl"},
                                                     {line,32}]},
                                                   {cowboy_rest,call,3,
                                                    [{file,
                                                      "src/cowboy_rest.erl"},
                                                     {line,1576}]},
                                                   {cowboy_rest,
                                                    set_resp_body,2,
                                                    [{file,
                                                      "src/cowboy_rest.erl"},
                                                     {line,1466}]},
                                                   {cowboy_rest,upgrade,4,
                                                    [{file,
                                                      "src/cowboy_rest.erl"},
                                                     {line,288}]}]}}}
@witling
Copy link
Author

witling commented Oct 9, 2019

move issue to rabbitmq-tracing?

@michaelklishin michaelklishin changed the title UI allows deleting active trace leading to dysfunction UI allows deleting active trace leading to an EACCES exception Oct 9, 2019
@michaelklishin michaelklishin transferred this issue from rabbitmq/rabbitmq-management Oct 9, 2019
@michaelklishin michaelklishin changed the title UI allows deleting active trace leading to an EACCES exception UI allows deletion of an active trace file leading to an EACCES exceptions Oct 9, 2019
@lukebakken
Copy link
Contributor

Can't reproduce on Linux. Guaranteed this is a win32-only problem (eacces).

@lukebakken lukebakken self-assigned this Oct 16, 2019
lukebakken added a commit that referenced this issue Oct 17, 2019
On win32 systems, deleting a trace file from out under RabbitMQ will lead to subsequent `{error, eacces}` errors.

Fixes #31
@michaelklishin michaelklishin added this to the 3.7.20 milestone Oct 17, 2019
@michaelklishin michaelklishin changed the title UI allows deletion of an active trace file leading to an EACCES exceptions UI allows deletion of an active trace file leading to an EACCES exception on Windows Oct 17, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants