Undeploying Eventing function is not working

I am noticing that the “Undeploy” button for Eventing function does not always work. Is the NQ1L command that I can stop any processes in Eventing function and undeploy it? So far I would leave Eventing function “be” for 20-30 min, and then would be able to undeploy function with the button, but for the last 2 days I complete was unable to undeploy the eventing function.

Thank you

Hi @evgeniya.bell There is no n1ql command to stop eventing function undeploy. Ideally, it should not take long to undeploy a function. Could you please share below details to help root cause the problem?

  1. Couchbase server version
  2. cb_collect logs
  3. Node configuration (CPUs, RAM, OS)

Thanks.

@jeelan.poola Here is screen cast of the function being in “undeploying state” for over 2 weeks. When I try to delete it, it persists after page refresh.

  1. Couchbase server v: Enterprise Edition 6.0.0 build 1693 ‧ IPv4
  2. I am not sure where to find cbcollect_info.log. I only were able to locate script at C:\Program Files\Couchbase\Server\bin
  3. Setup images. Buckets that I am using for eventing are highlighted in yellow

nodes buckets

Overall I think when I have error in eventing function, that is when this undeploying gets “frozen”.

Hi Evgeniya,

Unfortunately, we’ll need logs to figure out what the problem may be. You can find more details about uploading log files here: https://docs.couchbase.com/server/6.0/cli/cbcollect-info-tool.html

I can help further after looking at the logs. Alternatively, we can share a tool that resets all eventing definitions if you’d like to start over. If you need this tool, please let us know.

Thank you,
Siri

@Siri, a tool that resets all eventing would be very appreciated! Thank you!

@Siri, is it possible to share the tool you mentioned to clear of eventing definitions? Thank you.

Sure will share the build and tool. Thanks.

@Siri
We are facing the same issue is there a resolution for removing the Events which are not getting “Undeployed”

@PrashantSingh - if you’re using Couchbase 6.0.x or 6.5.x - the tool “cbevent” comes with the installed product as “/opt/couchbase/bin/cbevent”. You can run “cbevent -flush” to remove all handlers and reset (note that handlers will be lost if flushed). Please let me know if it helps. If you’re on an older version which doesn’t come with this tool, please let me know your OS and Couchbase Version and I can share a backport of the tool.

If flushing the handlers is not an option, please let me know and I can dig in to see why it’s not undeploying and how we can remove whatever is blocking the undeploy.

Thanks,
Siri

1 Like

@Siri Thank you for the Suggestion . We were able to clean up the events using the command . :slight_smile: