kubectl Error from server (NotFound): the server could not find the requested resource ( pods/log

2,912 views
Skip to first unread message

co...@kaleosoftware.com

unread,
Dec 8, 2017, 9:21:24 PM12/8/17
to CoreOS User
I'm having an issue when trying to issue with logging. 

kubectl
-n staging get po


job
-ingestor-2118144467-82qqd             1/1       Running   0          1d
svc
-bot-1878717742-vnn6r                  1/1       Running   0          11m
svc
-key-phrase-detector-304701101-s3z9q   1/1       Running   0          1d
svc
-search-relevance-1480769826-6mg3w     1/1       Running   0          1d
svc
-settings-3026457329-mr34d             1/1       Running   0          1d
ui
-dashboard-3272795982-8j4zr             1/1       Running   0          1d



however if I: 

kubectl -n staging log svc-bot-1878717742-vnn6r -v6

I get the following result:

I1208 18:19:07.111172   43640 round_trippers.go:405] GET https://redacted:443/api/v1/namespaces/staging/pods/svc-bot-1878717742-vnn6r 200 OK in 380 milliseconds
I1208
18:19:07.208461   43640 round_trippers.go:405] GET https://redacted:443/api/v1/namespaces/staging/pods/svc-bot-1878717742-vnn6r/log 404 Not Found in 94 milliseconds
I1208
18:19:07.208760   43640 helpers.go:207] server response object: [{
 
"metadata": {},
 
"status": "Failure",
 
"message": "the server could not find the requested resource ( pods/log svc-bot-1878717742-vnn6r)",
 
"reason": "NotFound",
 
"details": {
   
"name": "svc-bot-1878717742-vnn6r",
   
"kind": "pods/log"
 
},
 
"code": 404
}]
F1208
18:19:07.208787   43640 helpers.go:120] Error from server (NotFound): the server could not find the requested resource ( pods/log svc-bot-1878717742-vnn6r)



Having a hard time figuring this out and googling has been of zero help to this point.

Any help would be greatly appreciated.

Rob Szumski

unread,
Dec 11, 2017, 12:32:00 PM12/11/17
to co...@kaleosoftware.com, CoreOS User
“log” vs “logs” was marked as deprecated in kubectl. Are you using a 1.9 kubectl that has already removed that? It’s strange that it is trying to request the kind of “pods/log”.

--
You received this message because you are subscribed to the Google Groups "CoreOS User" group.
To unsubscribe from this group and stop receiving emails from it, send an email to coreos-user...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

co...@kaleosoftware.com

unread,
Dec 13, 2017, 5:09:25 PM12/13/17
to CoreOS User
Making the request with logs gives the same result.

Thank you,

Cody

Rob Szumski

unread,
Dec 13, 2017, 7:23:02 PM12/13/17
to co...@kaleosoftware.com, CoreOS User
Hmm very strange. I’m not sure what’s going on because that syntax works for me in my cluster. Can you list logs from other pods?
Reply all
Reply to author
Forward
0 new messages