Skip to content

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to delete the scaled object deployed in Azure AKS and Namespace in terminating state #5090

Closed
nidiculageorge opened this issue Oct 17, 2023 · 10 comments
Labels
bug Something isn't working

Comments

@nidiculageorge
Copy link

Report

Unable to delete the scaled object deployed in Azure AKS and Namespace in terminating state

image

Expected Behavior

As we tried deleting the namespace its in terminating state because of the above scaled object in that namespace

Actual Behavior

Namesapce should be deleted after the scaled object is deleted

Steps to Reproduce the Problem

Logs from KEDA operator

example

KEDA Version

2.11.1

Kubernetes Version

1.25

Platform

Microsoft Azure

Scaler Details

No response

Anything else?

No response

@nidiculageorge nidiculageorge added the bug Something isn't working label Oct 17, 2023
@nidiculageorge
Copy link
Author

I tried removing the finalizer but still I am unable to remove the Scaled object the finalizer is not getting removed from the scaled object

image

@SpiritZhou
Copy link
Contributor

Could you provide the events of scaledobject or logs of keda-operator?

@zroubalik
Copy link
Member

Do you have KEDA operator up and running?

@nidiculageorge
Copy link
Author

nidiculageorge commented Oct 18, 2023

@zroubalik we have keda operator running running in the cluster.But other applications are also using this same Keda

image

@zroubalik
Copy link
Member

So try to remove these scaledobjects first, then namespace

@nidiculageorge
Copy link
Author

nidiculageorge commented Oct 18, 2023

@zroubalik this is keda namespace .Could you please clarify.

Or do we need to delete this

image

@zroubalik
Copy link
Member

just delete all scaledobjects in the namespace you are about to remote:

k delete scaledobject --all -n YOUR_NAMESPACE

And also check keda-operator pod logs to see if there are any errors or anything

@nidiculageorge
Copy link
Author

@zroubalik I tried deleting the same and is stuck like this

image

@nidiculageorge
Copy link
Author

nidiculageorge commented Oct 19, 2023

@zroubalik I could see some errors in the keda operator log related to this namespace which we are trying to delete

2023-10-19T03:28:51Z ERROR scale_handler error getting metric for scaler {"scaledObject.Namespace": "autozoning-live-ibr-34", "scaledObject.Name": "recognitionicr-autoscaler", "scaler": "azureServiceBusScaler", "error": "scaler with id 2 not found, len = 0, cache has been probably already invalidated"}
github.com/kedacore/keda/v2/pkg/scaling.(*scaleHandler).GetScaledObjectMetrics
/workspace/pkg/scaling/scale_handler.go:485
github.com/kedacore/keda/v2/pkg/metricsservice.(*GrpcServer).GetMetrics
/workspace/pkg/metricsservice/server.go:48
github.com/kedacore/keda/v2/pkg/metricsservice/api._MetricsService_GetMetrics_Handler
/workspace/pkg/metricsservice/api/metrics_grpc.pb.go:98
google.golang.org/grpc.(*Server).processUnaryRPC
/workspace/vendor/google.golang.org/grpc/server.go:1336
google.golang.org/grpc.(*Server).handleStream
/workspace/vendor/google.golang.org/grpc/server.go:1704
google.golang.org/grpc.(*Server).serveStreams.func1.2
/workspace/vendor/google.golang.org/grpc/server.go:965
2023-10-19T03:28:51Z ERROR scale_handler error getting metric spec for the scaler {"scaledObject.Namespace": "autozoning-live-ibr-34", "scaledObject.Name": "recognitionicr-autoscaler", "scaler": "azureServiceBusScaler", "error": "scaler with id 3 not found. Len = 0"}
github.com/kedacore/keda/v2/pkg/scaling.(*scaleHandler).GetScaledObjectMetrics
/workspace/pkg/scaling/scale_handler.go:446
github.com/kedacore/keda/v2/pkg/metricsservice.(*GrpcServer).GetMetrics
/workspace/pkg/metricsservice/server.go:48
github.com/kedacore/keda/v2/pkg/metricsservice/api._MetricsService_GetMetrics_Handler
/workspace/pkg/metricsservice/api/metrics_grpc.pb.go:98
google.golang.org/grpc.(*Server).processUnaryRPC
/workspace/vendor/google.golang.org/grpc/server.go:1336
google.golang.org/grpc.(*Server).handleStream
/workspace/vendor/google.golang.org/grpc/server.go:1704
google.golang.org/grpc.(*Server).serveStreams.func1.2
/workspace/vendor/google.golang.org/grpc/server.go:965

@nidiculageorge
Copy link
Author

@zroubalik any update

@kedacore kedacore locked and limited conversation to collaborators Oct 26, 2023
@tomkerkhove tomkerkhove converted this issue into discussion #5131 Oct 26, 2023

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

Labels
bug Something isn't working
Projects
Archived in project
Development

No branches or pull requests

3 participants