Skip to content

VR: fix dnmasq misconfiguration if there are multiple IP ranges in a shared network - #8741

Merged
weizhouapache merged 1 commit into
apache:4.18from
weizhouapache:4.18-fix-dnsmasq-multiple-ip-range
Apr 24, 2024
Merged

weizhouapache merged 1 commit into
apache:4.18from
weizhouapache:4.18-fix-dnsmasq-multiple-ip-range

Conversation

@weizhouapache

Copy link
Copy Markdown
Member

Description

This PR fixes #8158

This PR also allows specifying IP in non-default IP range of shared networks when deploy a VM.

Types of changes

  • Breaking change (fix or feature that would cause existing functionality to change)
  • New feature (non-breaking change which adds functionality)
  • Bug fix (non-breaking change which fixes an issue)
  • Enhancement (improves an existing feature and functionality)
  • Cleanup (Code refactoring and cleanup, that may add test cases)
  • build/CI

Feature/Enhancement Scale or Bug Severity

Feature/Enhancement Scale

  • Major
  • Minor

Bug Severity

  • BLOCKER
  • Critical
  • Major
  • Minor
  • Trivial

Screenshots (if appropriate):

How Has This Been Tested?

How did you try to break this feature and the system with this change?

@weizhouapache weizhouapache added this to the 4.18.2.0 milestone Mar 4, 2024
@weizhouapache weizhouapache linked an issue Mar 4, 2024 that may be closed by this pull request
@codecov

codecov Bot commented Mar 4, 2024

Copy link
Copy Markdown

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 13.17%. Comparing base (10f72a1) to head (3dd5d4c).
Report is 1 commits behind head on 4.18.

Additional details and impacted files
@@            Coverage Diff            @@
##               4.18    #8741   +/-   ##
=========================================
  Coverage     13.17%   13.17%           
  Complexity     9204     9204           
=========================================
  Files          2724     2724           
  Lines        258137   258137           
  Branches      40235    40235           
=========================================
  Hits          33998    33998           
  Misses       219830   219830           
  Partials       4309     4309           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@sureshanaparti

Copy link
Copy Markdown
Contributor

@blueorangutan package

@sureshanaparti sureshanaparti left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

clgtm

Comment thread systemvm/debian/opt/cloud/bin/cs/CsHelper.py
@sureshanaparti

Copy link
Copy Markdown
Contributor

@blueorangutan package

@blueorangutan

Copy link
Copy Markdown

@sureshanaparti a [SL] Jenkins job has been kicked to build packages. It will be bundled with KVM, XenServer and VMware SystemVM templates. I'll keep you posted as I make progress.

@blueorangutan

Copy link
Copy Markdown

Packaging result [SF]: ✔️ el7 ✔️ el8 ✔️ el9 ✔️ debian ✔️ suse15. SL-JID 8863

@yadvr

yadvr commented Mar 8, 2024

Copy link
Copy Markdown
Member

@blueorangutan test

@blueorangutan

Copy link
Copy Markdown

@rohityadavcloud a [SL] Trillian-Jenkins test job (centos7 mgmt + kvm-centos7) has been kicked to run smoke tests

@blueorangutan

Copy link
Copy Markdown

[SF] Trillian test result (tid-9428)
Environment: kvm-centos7 (x2), Advanced Networking with Mgmt server 7
Total time taken: 42273 seconds
Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr8741-t9428-kvm-centos7.zip
Smoke tests completed. 109 look OK, 1 have errors, 0 did not run
Only failed and skipped tests results shown below:

Test Result Time (s) Test File
test_08_migrate_vm Error 43.84 test_vm_life_cycle.py

@JoaoJandre JoaoJandre modified the milestones: 4.18.2.0, 4.18.3 Mar 21, 2024
@weizhouapache

Copy link
Copy Markdown
Member Author

@blueorangutan package

@weizhouapache

Copy link
Copy Markdown
Member Author

@ccycv
can you test it ?

@DaanHoogland

Copy link
Copy Markdown
Contributor

@blueorangutan package

@blueorangutan

Copy link
Copy Markdown

@DaanHoogland a [SL] Jenkins job has been kicked to build packages. It will be bundled with KVM, XenServer and VMware SystemVM templates. I'll keep you posted as I make progress.

@blueorangutan

Copy link
Copy Markdown

Packaging result [SF]: ✔️ el7 ✔️ el8 ✔️ el9 ✔️ debian ✔️ suse15. SL-JID 9393

@DaanHoogland

Copy link
Copy Markdown
Contributor

@blueorangutan test

@blueorangutan

Copy link
Copy Markdown

@DaanHoogland a [SL] Trillian-Jenkins test job (centos7 mgmt + kvm-centos7) has been kicked to run smoke tests

@ccycv

ccycv commented Apr 24, 2024

Copy link
Copy Markdown

@ccycv can you test it ?

Just tested in 2 different environments, CloudStack 4.18.1 and 4.19, looks fine. I only think the MTU should be at the end of the config file; right now, it is after the first guest network.

This is how looks a cloud.conf with 5 guest ranges:

listen-address=127.0.0.1,149.xxx.xxx.53,91.xxx.xxx.137,51.xxx.xxx.66,217.xxx.xxx.51,217.xxx.xxx.182
dhcp-range=set:interface-eth0-0,149.xxx.xxx.53,static
dhcp-option=tag:interface-eth0-0,15,cs1cloud.internal
dhcp-option=tag:interface-eth0-0,6,149.xxx.xxx.53,8.8.4.4,8.8.8.8
dhcp-option=tag:interface-eth0-0,3,149.xxx.xxx.62
dhcp-option=eth0,26,1500
dhcp-option=tag:interface-eth0-0,1,255.255.255.240
dhcp-range=set:interface-eth0-1,91.xxx.xxx.137,static
dhcp-option=tag:interface-eth0-1,15,cs1cloud.internal
dhcp-option=tag:interface-eth0-1,6,91.xxx.xxx.137,8.8.4.4,8.8.8.8
dhcp-option=tag:interface-eth0-1,3,91.xxx.xxx.142
dhcp-option=tag:interface-eth0-1,1,255.255.255.240
dhcp-range=set:interface-eth0-2,51.xxx.xxx.66,static
dhcp-option=tag:interface-eth0-2,15,cs1cloud.internal
dhcp-option=tag:interface-eth0-2,6,51.xxx.xxx.66,8.8.4.4,8.8.8.8
dhcp-option=tag:interface-eth0-2,3,51.xxx.xxx.126
dhcp-option=tag:interface-eth0-2,1,255.255.255.192
dhcp-range=set:interface-eth0-3,217.xxx.xxx.51,static
dhcp-option=tag:interface-eth0-3,15,cs1cloud.internal
dhcp-option=tag:interface-eth0-3,6,217.xxx.xxx.51,8.8.4.4,8.8.8.8
dhcp-option=tag:interface-eth0-3,3,217.xxx.xxx.62
dhcp-option=tag:interface-eth0-3,1,255.255.255.224
dhcp-range=set:interface-eth0-4,217.xxx.xxx.182,static
dhcp-option=tag:interface-eth0-4,15,cs1cloud.internal
dhcp-option=tag:interface-eth0-4,6,217.xxx.xxx.182,8.8.4.4,8.8.8.8
dhcp-option=tag:interface-eth0-4,3,217.xxx.xxx.190
dhcp-option=tag:interface-eth0-4,1,255.255.255.224

@weizhouapache

Copy link
Copy Markdown
Member Author

dhcp-option=eth0,26,1500

@ccycv
You tested with the changes in this PR, right ? just to confirm

@ccycv

ccycv commented Apr 24, 2024

Copy link
Copy Markdown

dhcp-option=eth0,26,1500

@ccycv You tested with the changes in this PR, right ? just to confirm

Yes, with this PR

@weizhouapache

Copy link
Copy Markdown
Member Author

dhcp-option=eth0,26,1500

@ccycv You tested with the changes in this PR, right ? just to confirm

Yes, with this PR

great, thanks @ccycv
let's merge this pr

we can address the mtu issue in a separated pr if it causes mtu misconfiguration inside the vms

@weizhouapache
weizhouapache merged commit 3b0e6ac into apache:4.18 Apr 24, 2024
@DaanHoogland
DaanHoogland deleted the 4.18-fix-dnsmasq-multiple-ip-range branch April 24, 2024 13:08
@ccycv

ccycv commented Apr 24, 2024 •

Copy link
Copy Markdown

dhcp-option=eth0,26,1500

@ccycv You tested with the changes in this PR, right ? just to confirm

Yes, with this PR

great, thanks @ccycv let's merge this pr

we can address the mtu issue in a separated pr if it causes mtu misconfiguration inside the vms

Just detected an issue, i see this in health check :

Failed to fetch results with details: bash: line 1: /opt/cloud/bin/filesystem_writable_check.py: Permission denied

Update: after making the file /opt/cloud/bin/filesystem_writable_check.py executable, the health check works fine.

@weizhouapache

Copy link
Copy Markdown
Member Author

Failed to fetch results with details: bash: line 1: /opt/cloud/bin/filesystem_writable_check.py: Permission denied

Update: after making the file /opt/cloud/bin/filesystem_writable_check.py executable, the health check works fine.

@ccycv
did you replace the files in /opt/cloud/bin when you tested this PR ?
some files (including filesystem_writable_check.py) are not executable in source code, you can mark them all as executable

chmod +x /opt/cloud/bin/*

@ccycv

ccycv commented Apr 24, 2024

Copy link
Copy Markdown

Failed to fetch results with details: bash: line 1: /opt/cloud/bin/filesystem_writable_check.py: Permission denied
Update: after making the file /opt/cloud/bin/filesystem_writable_check.py executable, the health check works fine.

@ccycv did you replace the files in /opt/cloud/bin when you tested this PR ? some files (including filesystem_writable_check.py) are not executable in source code, you can mark them all as executable

chmod +x /opt/cloud/bin/*

I have only replaced the cloud-scripts.tgz on the management server and did the router rebuild.

@weizhouapache

Copy link
Copy Markdown
Member Author

cloud-scripts.tgz

@ccycv
if you use maven to rebuild the tarball, the scripts in the tarball should be executable

mvn -P developer,systemvm clean install -pl systemvm/

@blueorangutan

Copy link
Copy Markdown

[SF] Trillian test result (tid-9982)
Environment: kvm-centos7 (x2), Advanced Networking with Mgmt server 7
Total time taken: 42891 seconds
Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr8741-t9982-kvm-centos7.zip
Smoke tests completed. 109 look OK, 1 have errors, 0 did not run
Only failed and skipped tests results shown below:

Test Result Time (s) Test File
test_08_migrate_vm Error 0.08 test_vm_life_cycle.py

@yadvr yadvr modified the milestones: 4.18.3, 4.19.1.0 Apr 30, 2024
dhslove pushed a commit to ablecloud-team/ablestack-cloud that referenced this pull request May 3, 2024
weizhouapache added a commit to weizhouapache/cloudstack that referenced this pull request Dec 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

No open projects
Status: Done

Development

Successfully merging this pull request may close these issues.

dnsmasq-dhcp - ignored

7 participants