You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@apisix.apache.org by "Fabriceli (via GitHub)" <gi...@apache.org> on 2023/02/07 01:56:59 UTC

[GitHub] [apisix-ingress-controller] Fabriceli opened a new issue, #1654: bug: ApisixUpstream invalid memory address or nil pointer dereference

Fabriceli opened a new issue, #1654:
URL: https://github.com/apache/apisix-ingress-controller/issues/1654

   ### Current Behavior
   
   ```sh
   2023-02-07T09:48:08+08:00       warn    apisix/upstream.go:69   upstream not found      {"name": "kube-system_kps-kube-prometheus-stack-kube-controller-manager_10257", "url": "http://apisix-admin.apisix.svc.cluster.local:9180/apisix/admin/upstreams/f210c125", "cluster": "default"}
   2023-02-07T09:48:08+08:00       warn    types/types.go:212      upstream is not referenced      {"cluster": "name=default; base_url=http://apisix-admin.apisix.svc.cluster.local:9180/apisix/admin", "upstream": "kube-system_kps-kube-prometheus-stack-kube-controller-manager_10257"}
   panic: runtime error: invalid memory address or nil pointer dereference
   [signal SIGSEGV: segmentation violation code=0x1 addr=0x8 pc=0x1782ecc]
   
   goroutine 484 [running]:
   github.com/apache/apisix-ingress-controller/pkg/providers/apisix.(*apisixUpstreamController).syncRelationship(0xc000113e00, 0xc000940600, {0xc000303170, 0x29}, {0x1f428a0, 0xc0000e9f00})
           /build/controller/pkg/providers/apisix/apisix_upstream.go:484 +0x24c
   github.com/apache/apisix-ingress-controller/pkg/providers/apisix.(*apisixUpstreamController).sync(0xc000113e00, {0x1f424b0, 0xc0000521c0}, 0xc000940600)
           /build/controller/pkg/providers/apisix/apisix_upstream.go:178 +0x36f
   github.com/apache/apisix-ingress-controller/pkg/providers/apisix.(*apisixUpstreamController).runWorker(0xc000113e00, {0x1f424b0, 0xc0000521c0})
           /build/controller/pkg/providers/apisix/apisix_upstream.go:107 +0x4a
   created by github.com/apache/apisix-ingress-controller/pkg/providers/apisix.(*apisixUpstreamController).run
           /build/controller/pkg/providers/apisix/apisix_upstream.go:94 +0x20d
   ```
   
   ### Expected Behavior
   
   No error
   
   
   ### Error Logs
   
   ```sh
   panic: runtime error: invalid memory address or nil pointer dereference
   [signal SIGSEGV: segmentation violation code=0x1 addr=0x8 pc=0x1782ecc]
   
   goroutine 482 [running]:
   github.com/apache/apisix-ingress-controller/pkg/providers/apisix.(*apisixUpstreamController).syncRelationship(0xc0002d2600, 0xc000a2a980, {0xc00084e9c0, 0x29}, {0x1f428a0, 0xc00042fb40})
           /build/controller/pkg/providers/apisix/apisix_upstream.go:484 +0x24c
   github.com/apache/apisix-ingress-controller/pkg/providers/apisix.(*apisixUpstreamController).sync(0xc0002d2600, {0x1f424b0, 0xc00074e380}, 0xc000a2a980)
           /build/controller/pkg/providers/apisix/apisix_upstream.go:178 +0x36f
   github.com/apache/apisix-ingress-controller/pkg/providers/apisix.(*apisixUpstreamController).runWorker(0xc0002d2600, {0x1f424b0, 0xc00074e380})
           /build/controller/pkg/providers/apisix/apisix_upstream.go:107 +0x4a
   created by github.com/apache/apisix-ingress-controller/pkg/providers/apisix.(*apisixUpstreamController).run
           /build/controller/pkg/providers/apisix/apisix_upstream.go:94 +0x20d
   
   ```
   
   ### Steps to Reproduce
   
   1. `kubectl apply -f svc.yaml`:
   ```yaml
   apiVersion: apisix.apache.org/v2
   kind: ApisixUpstream
   metadata:
     name: name-of-svc
     namespace: app-admin
   spec:
   ```
   2. Got the `nil pointer` error
   
   ### Environment
   
   - APISIX Ingress controller version (run `apisix-ingress-controller version --long`)
     1.6.0
   - Kubernetes cluster version (run `kubectl version`)
   ```sh
   Client Version: version.Info{Major:"1", Minor:"24", GitVersion:"v1.24.8", GitCommit:"fdc77503e954d1ee641c0e350481f7528e8d068b", GitTreeState:"clean", BuildDate:"2022-11-09T13:38:19Z", GoVersion:"go1.18.8", Compiler:"gc", Platform:"linux/amd64"}
   Kustomize Version: v4.5.4
   Server Version: version.Info{Major:"1", Minor:"24", GitVersion:"v1.24.9", GitCommit:"9710807c82740b9799453677c977758becf0acbb", GitTreeState:"clean", BuildDate:"2022-12-08T10:08:06Z", GoVersion:"go1.18.9", Compiler:"gc", Platform:"linux/amd64"}
   
   ```
   - OS version if running APISIX Ingress controller in a bare-metal environment (run `uname -a`)
   ```sh
   Linux metal-master1-sit 5.4.0-131-generic #147-Ubuntu SMP Fri Oct 14 17:07:22 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux
   ```
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [apisix-ingress-controller] Fabriceli commented on issue #1654: bug: ApisixUpstream invalid memory address or nil pointer dereference

Posted by "Fabriceli (via GitHub)" <gi...@apache.org>.
Fabriceli commented on issue #1654:
URL: https://github.com/apache/apisix-ingress-controller/issues/1654#issuecomment-1423676456

   > Have you enabled the admission component? Also, obviously, the ApisixUpstream configuration you submitted is wrong.
   > 
   > Using the wrong configuration will inevitably get wrong results
   Besides kubernetes no shown any error for this yaml, donc, i think apisix-ingress-controller should handle this error also.
   ![image](https://user-images.githubusercontent.com/13508022/217730428-7c954ca0-48ae-45d8-9087-ff6e1cba7fcc.png)
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [apisix-ingress-controller] tao12345666333 commented on issue #1654: bug: ApisixUpstream invalid memory address or nil pointer dereference

Posted by "tao12345666333 (via GitHub)" <gi...@apache.org>.
tao12345666333 commented on issue #1654:
URL: https://github.com/apache/apisix-ingress-controller/issues/1654#issuecomment-1423580129

   Have you enabled the admission component?
   Also, obviously, the ApisixUpstream configuration you submitted is wrong.
   
   Using the wrong configuration will inevitably get wrong results
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [apisix-ingress-controller] github-actions[bot] commented on issue #1654: bug: ApisixUpstream invalid memory address or nil pointer dereference

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on issue #1654:
URL: https://github.com/apache/apisix-ingress-controller/issues/1654#issuecomment-1543044421

   This issue has been marked as stale due to 90 days of inactivity. It will be closed in 30 days if no further activity occurs. If this issue is still relevant, please simply write any comment. Even if closed, you can still revive the issue at any time or discuss it on the dev@apisix.apache.org list. Thank you for your contributions.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [apisix-ingress-controller] github-actions[bot] commented on issue #1654: bug: ApisixUpstream invalid memory address or nil pointer dereference

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on issue #1654:
URL: https://github.com/apache/apisix-ingress-controller/issues/1654#issuecomment-1585407674

   This issue has been closed due to lack of activity. If you think that is incorrect, or the issue requires additional review, you can revive the issue at any time.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [apisix-ingress-controller] github-actions[bot] closed issue #1654: bug: ApisixUpstream invalid memory address or nil pointer dereference

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] closed issue #1654: bug: ApisixUpstream invalid memory address or nil pointer dereference
URL: https://github.com/apache/apisix-ingress-controller/issues/1654


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [apisix-ingress-controller] Fabriceli commented on issue #1654: bug: ApisixUpstream invalid memory address or nil pointer dereference

Posted by "Fabriceli (via GitHub)" <gi...@apache.org>.
Fabriceli commented on issue #1654:
URL: https://github.com/apache/apisix-ingress-controller/issues/1654#issuecomment-1423670308

   > Have you enabled the admission component? Also, obviously, the ApisixUpstream configuration you submitted is wrong.
   > 
   > Using the wrong configuration will inevitably get wrong results
   
   I know this wrong configuration, but this can not lead to CRASH the apisix-ingress-controller, non?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org