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
MGMT-14605: Gather more data for hypershift tests #5344
MGMT-14605: Gather more data for hypershift tests #5344
Conversation
@CrystalChun: This pull request references MGMT-14605 which is a valid jira issue. In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
Codecov Report
Additional details and impacted files@@ Coverage Diff @@
## master #5344 +/- ##
=========================================
Coverage ? 71.60%
=========================================
Files ? 238
Lines ? 41682
Branches ? 0
=========================================
Hits ? 29845
Misses ? 9563
Partials ? 2274 |
This is very useful 👍 I think that gather_hypershift_data function isn't collecting any logs, not specifically the code that you added to the function but what's already tehre. Also I don't get why it's trying to collect all these or these logs, assisted isn't running in this namespace, and all CRDs are already collected elsewhere |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Note that the hypershift CLI (the same CLI we use to deploy the hosoted cluster here) has a 'dump` option which collects all relevant information, similar to what must-gather is doing.
We used to have back when assisted-test-infra was running the CAPI tests
and this is how it's executed
deploy/operator/gather.sh
Outdated
@@ -157,6 +157,11 @@ function gather_hypershift_data() { | |||
hypershift_dir="${LOGS_DEST}/hypershift" | |||
mkdir -p "${hypershift_dir}" | |||
|
|||
oc get po -n hypershift -o yaml > ${hypershift_dir}/hypershift_pods.yaml | |||
oc get po -n hypershift -o custom-columns=:.metadata.name --no-headers | while read hypershift_pod_name ; do |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Already collected here
Consider collecting the yaml there or moving the log collection here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for pointing this out! Moved yaml collection there
deploy/operator/gather.sh
Outdated
oc get po -n hypershift -o custom-columns=:.metadata.name --no-headers | while read hypershift_pod_name ; do | ||
oc logs -n hypershift $hypershift_pod_name > ${hypershift_dir}/hypershift_pod_log_$hypershift_pod_name.log | ||
done | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we can delete line 165 to line 181
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also I don't get why it's trying to collect all these or these logs, assisted isn't running in this namespace, and all CRDs are already collected elsewhere
Oh so I think @danielerez added this for his AI on zero worker hypershift enhancement (PR link).
I think it could be relevant if we run tests that deploy AI on hypershift clusters, but maybe it's not as relevant for all hypershift tests.
Maybe these could be moved to a different function? What do you both think?
CRS=(agents infraenvs clusterdeployments agentclusterinstalls clusterimagesets) | ||
for cr in "${CRS[@]}"; do | ||
oc --kubeconfig ${SPOKE_KUBECONFIG} get "${cr}" -n "${SPOKE_NAMESPACE}" -o yaml > "${spoke_dir}/oc_get_${cr}.yaml" | ||
done | ||
|
||
oc --kubeconfig "${SPOKE_KUBECONFIG}" get nodes -o yaml > "${spoke_dir}/oc_get_nodes.yaml" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is great.
https://issues.redhat.com/browse/MGMT-14605 Collects more relevant data and logs for hypershift tests. Includes: 1. hostedcluster nodes 2. hostedcluster pods yamls and logs 3. hypershift pods' operator logs
74e0acd
to
3c202fb
Compare
Oh hmm it seems to have failed detecting the spoke kubeconfig so it didn't get the artifacts from the spoke cluster 🤔 |
@CrystalChun is this still relevant? |
@CrystalChun: The following tests failed, say
Full PR test history. Your PR dashboard. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here. |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: avishayt, CrystalChun The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
4f81467
into
openshift:master
https://issues.redhat.com/browse/MGMT-14605
Collects more relevant data and logs for hypershift tests. Includes:
List all the issues related to this PR
What environments does this code impact?
How was this code tested?
Checklist
docs
, README, etc)Reviewers Checklist
/cc @eranco74