net-kourier: The test sample HelloWorld go failed

HI!

After the kourier is deployed, it is verified that the verification does not get the results I want. By checking the log, it is found that the service is missing, but there are some in the resource, What’s the matter?

[root@k8s-master ~]# kubectl logs service.serving.knative.dev/helloworld-go
error: no kind "Service" is registered for version "serving.knative.dev/v1" in scheme "k8s.io/kubectl/pkg/scheme/scheme.go:28"
[root@k8s-master ~]# kubectl api-resources | grep knative
metrics                                           autoscaling.internal.knative.dev/v1alpha1   true         Metric
podautoscalers                    kpa,pa          autoscaling.internal.knative.dev/v1alpha1   true         PodAutoscaler
images                            img             caching.internal.knative.dev/v1alpha1       true         Image
certificates                      kcert           networking.internal.knative.dev/v1alpha1    true         Certificate
ingresses                         kingress,king   networking.internal.knative.dev/v1alpha1    true         Ingress
serverlessservices                sks             networking.internal.knative.dev/v1alpha1    true         ServerlessService
knativeeventings                                  operator.knative.dev/v1alpha1               true         KnativeEventing
knativeservings                                   operator.knative.dev/v1alpha1               true         KnativeServing
configurations                    config,cfg      serving.knative.dev/v1                      true         Configuration
revisions                         rev             serving.knative.dev/v1                      true         Revision
routes                            rt              serving.knative.dev/v1                      true         Route
services                          kservice,ksvc   serving.knative.dev/v1                      true         Service

Response results:

[root@k8s-master ~]# curl -v -H "Host: helloworld-go.default.127.0.0.1.nip.io" http://localhost:8080
* Rebuilt URL to: http://localhost:8080/
*   Trying ::1...
* TCP_NODELAY set
* Connected to localhost (::1) port 8080 (#0)
> GET / HTTP/1.1
> Host: helloworld-go.default.127.0.0.1.nip.io
> User-Agent: curl/7.61.0
> Accept: */*
>
< HTTP/1.1 404 Not Found
< date: Thu, 18 Nov 2021 10:23:37 GMT
< server: envoy
< content-length: 0
<
* Connection #0 to host localhost left intact

kubernetes environment:

[root@k8s-master ~]# kubectl version
Client Version: version.Info{Major:"1", Minor:"21", GitVersion:"v1.21.2", GitCommit:"092fbfbf53427de67cac1e9fa54aaa09a28371d7", GitTreeState:"clean", BuildDate:"2021-06-16T12:59:11Z", GoVersion:"go1.16.5", Compiler:"gc", Platform:"linux/amd64"}
Server Version: version.Info{Major:"1", Minor:"21", GitVersion:"v1.21.2", GitCommit:"092fbfbf53427de67cac1e9fa54aaa09a28371d7", GitTreeState:"clean", BuildDate:"2021-06-16T12:53:14Z", GoVersion:"go1.16.5", Compiler:"gc", Platform:"linux/amd64"}

knative environment: v0.17.4

kourier environment: v0.17.2

knative

About this issue

  • Original URL
  • State: closed
  • Created 3 years ago
  • Comments: 18 (8 by maintainers)

Most upvoted comments

Thank you. So, it seems your cluster deployed Istio and enabled auto-injection. Istio configuration (especially Istio sidecar auto injection) caused the issue which should not be related to Knative.

Your namespace has a istio-injection=enabled label?

@nak3 OK, thanks. I’ll install it again with reference to the version dependency.

You mean that their version relation ship, correct? I think you can refer to https://github.com/knative/community/blob/main/mechanics/RELEASE-SCHEDULE.md

In short,

  • Kourier and Knative version should be correspondent. - e.g. Knative 1.0.x then you should use Kourier 1.0.x.
  • Knative which is not EOL should be used. - e.g. 0.24 or later is supported now.
  • Knative should be deployed on the Kubernetes which is minimum k8s version or later.