Skip to content
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

Fixes #31307 - Improve compute network error messages #8520

Merged
merged 1 commit into from
May 12, 2021

Conversation

sbernhard
Copy link
Contributor

@sbernhard sbernhard commented May 11, 2021

Previously, if the connection to the compute resource fails, the
following error message was shown.
Failed to find compute attributes, please check if VM 'xyz' was deleted.

Users are completely confused. With the following change nice error
messages are shown:

Reject:
Receiving vm data for host 'xyz.local' from used compute resource 'VMware' failed: 'Connection to compute resource refused'.

Unreachable:
Receiving vm data for host 'xyz.local' from used compute resource 'VMware' failed: 'Compute resource destination unreachable'.

Timeout:
Receiving vm data for host 'xyz.local' from used compute resource 'VMware' failed: 'Connection to compute resource timed out'.

@theforeman-bot
Copy link
Member

Issues: #31307

@sbernhard
Copy link
Contributor Author

sbernhard commented May 11, 2021

For testing:

# iptables --append OUTPUT --protocol tcp -d 192.168.10.1 --jump  REJECT
# hammer host update --id 9 --parameters t3=t6
Could not update the host:
  Receiving vm data for host 'xyz.local' from used compute resource 'VMware' failed: 'Connection to compute resource refused'.

# iptables --append OUTPUT --protocol tcp -d 192.168.10.1 --jump  REJECT --reject-with icmp-host-unreachable
# hammer host update --id 9 --parameters t3=t6
Could not update the host:
  Receiving vm data for host 'xyz.local' from used compute resource 'VMware' failed: 'Compute resource destination unreachable'.

# iptables --append OUTPUT --protocol tcp -d 192.168.10.1 --jump DROP
# hammer host update --id 9 --parameters t3=t6
Could not update the host:
  Receiving vm data for host 'xyz.local' from used compute resource 'VMware' failed: 'Connection to compute resource timed out'.

@ekohl ekohl changed the title Fixes #31307 - Improve error message Fixes #31307 - Improve compute network error messages May 11, 2021
@sbernhard
Copy link
Contributor Author

sbernhard commented May 11, 2021

I don't think that the foreman test issue in 2.7 is related to this change.

lzap
lzap previously approved these changes May 12, 2021
Copy link
Member

@lzap lzap left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am good, @timogoebel ?

timogoebel
timogoebel previously approved these changes May 12, 2021
Copy link
Member

@timogoebel timogoebel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@sbernhard: I'm good as well, please make sure the checks are green or else we can't merge.

timogoebel
timogoebel previously approved these changes May 12, 2021
@ekohl
Copy link
Member

ekohl commented May 12, 2021

On merge we should fix up the commit message to match what I did to the title of this PR. It's just a bit more descriptive.

Previously, if the connection to the compute resource fails, the
following error message was shown.
  Failed to find compute attributes, please check if VM 'xyz' was deleted.

Users are completely confused. With the following change nice error
messages are shown:

Reject:
  Receiving vm data for host 'xyz.local' from used compute resource 'VMware' failed: 'Connection to compute resource refused'.

Unreachable:
  Receiving vm data for host 'xyz.local' from used compute resource 'VMware' failed: 'Compute resource destination unreachable'.

Timeout:
  Receiving vm data for host 'xyz.local' from used compute resource 'VMware' failed: 'Connection to compute resource timed out'.
@sbernhard
Copy link
Contributor Author

On merge we should fix up the commit message to match what I did to the title of this PR. It's just a bit more descriptive.

done. Thanks @ekohl

@timogoebel
Copy link
Member

[test upgrade]

@ezr-ondrej ezr-ondrej self-assigned this May 12, 2021
@timogoebel
Copy link
Member

@ezr-ondrej: Are you good as well?

Copy link
Member

@ezr-ondrej ezr-ondrej left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ezr-ondrej: Are you good as well?

Yeah, I just didn't see you've already reviewed :)

@timogoebel timogoebel merged commit 1278e53 into theforeman:develop May 12, 2021
@timogoebel
Copy link
Member

Thanks, everyone! :)

Yeah, I just didn't see you've already reviewed :)

I need to gain some karma points today. :)

@tbrisker
Copy link
Member

Cherry pick in GH-8616

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants