Closed jianzhangbjz closed 6 months ago
/assign @gmeghnag
This omc
binary was build with the latest code.
jiazha-mac:omc jiazha$ git log
commit 4dcebdc397740a11030cc6458d9ef33aa4127d37 (HEAD -> main, origin/main, origin/HEAD)
Author: gmeghnag <gmeghnag@redhat.com>
Date: Mon May 6 22:20:13 2024 +0200
fix #156
...
jiazha-mac:omc jiazha$ go install
jiazha-mac:omc jiazha$ ls -l /Users/jiazha/golang/go1.21/bin/omc
-rwxr-xr-x 1 jiazha staff 101573666 5 9 11:01 /Users/jiazha/golang/go1.21/bin/omc
Hi @jianzhangbjz when you run omc get namespaces
it only return the namespaces where the <namespace>.yaml
file is present so you can do omc get ns <namespace> -o yaml
.
If you want to check all the projects present in the must-gather you can execute:
omc projects
But you will see that executing omc get <namespace> -o yaml
for all of them (except the ones listed as namespace) will fail because the namespace resource yaml file is not present for them.
I am wondering whether we could add a warning message to the user that the actual collected namespace number is larger than the ones that contain \<namespace>.yaml? This might reduce any unnecessary confusion or back and forth MG collection request to the customer.
Something like:
$ omc get ns
Warning: the actual project number is 431, which is larger than the following listed. Check must-gather.local.7235806614755410709/quay-XXXXXX/namespaces instead!
NAME STATUS AGE
default Active 1y
kube-system Active 1y
openshift Active 1y
openshift-cluster-version Active 1y
openshift-etcd Active 1y
@cchen666 I don't want the output of omc get ns
to be different from that of oc get ns
(mostly because of automation that can be done using omc
), so we won't implement any warning messages at the moment.
When checking the must-gather from https://access.redhat.com/support/cases/#/case/03798085, the
omc
only gets 5 projects.However, the
omg
can get 431 projects, as follows,