4.23.0.0: restartVPC cleanup=true with public IPs on two VLANs fails with UnsupportedOperationException and leaves the VPC without a backup router
Maintainer thường phản hồi trong vòng 1 ngày
@bernardodemarco đang làm issue này rồi.
Từ ngày 28/10/2026.
Đánh giá
- Độ khó
- 2/5
- Thời gian dự kiến
- 1-3 giờ
- Mức phù hợp với người mới
- 78/100
- Loại issue
- Lỗi
- Độ rõ ràng
- Đặc tả rõ ràng
- Mức độ hoạt động
- Sôi nổi
- Công nghệ
- java
- Lĩnh vực
- infrastructure
Hướng nghiên cứu
Đọc NetworkHelperImpl.java quanh dòng 761, sau đó lần theo giá trị publicConfig đến VpcNetworkHelperImpl.reallocateRouterNetworks quanh dòng 165. Tái hiện cấu hình hai VLAN và restartVPC cleanup=true, hoặc thêm một bài kiểm thử hồi quy tập trung vào hành vi của danh sách có thể thay đổi. Công việc hoàn tất khi việc phân bổ lại mạng của router chấp nhận cả hai VLAN và quá trình khởi động lại luân phiên kết thúc với một router dự phòng.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
problem
NetworkHelperImpl.java line 761 (4.23.0.0 and main) is:
publicConfig.put(publicNetworks.get(0), List.of(defaultNic));
List.of returns an immutable list. VpcNetworkHelperImpl.reallocateRouterNetworks (line 165) then calls addAll on it and throws UnsupportedOperationException (ImmutableCollections.addAll), through NetworkHelperImpl.deployRouterWithTemplates (line 542) and VpcManagerImpl.rollingRestartVpc (line 4046). 4.22.0.0 used new ArrayList(Arrays.asList(defaultNic)).
The API answers "Internal Server Error". The rolling restart has already destroyed the backup router, and the new router stays Stopped.
Related: #12621 (fixed by #12622 in 4.22) has the same setup but a different error ("cidr is not formatted correctly"). This one is a separate bug.
versions
CloudStack 4.23.0.0 and main. 4.22.0.0 is not affected. KVM.
The steps to reproduce the bug
- A zone with public IP ranges on two VLANs.
- A redundant VPC with its source NAT IP on the first VLAN.
- Acquire a second public IP from the second VLAN and enable static NAT on it to a VM in the VPC. (A bare IP with no NAT or rule does not reach this code path; see VpcManagerImpl.isIpAllocatedToVpc.)
- restartVPC cleanup=true.
What to do about it?
Use a mutable list again, for example:
publicConfig.put(publicNetworks.get(0), new ArrayList<>(List.of(defaultNic)));
We carry this one-line change. With it, the new routers get NICs on both VLANs and the restart succeeds.
- Ngôn ngữ chính
- Java
- Star
- 3.1k
- Fork
- 1.4k
- Merge trung bình
- 9 ngày 12 giờ
- Pull request đã merge (30 ngày)
- 22
Chuẩn bị môi trường
- Không có Dockerfile hay tệp Docker Compose
- Có mẫu pull request
- Đọc hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của apache/cloudstack
-
Remote access VPN users are disconnected on every LB, ACL, port forward or firewall change (xl2tpd restarted on every iptables pass)Có thể đã có người làm Có pull request liên kết đang mở hoặc đã được merge. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
apache/cloudstack#14545 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
apache/cloudstack#14530 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
bug status:has-work-around
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
apache/cloudstack#14465 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 77/100
apache/cloudstack#14427 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
[UI] "canceled - Unable to reach the management server" notification when switching from project to default view on Instances page (4.20.3)Có thể đã có người làm @Damans227 đã nhận 22 ngày trước. Đang mởbug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
apache/cloudstack#14381 · 1 bình luận · 1 reaction · 1 người được giao ·
Maintainer thường phản hồi trong vòng 1 ngày
Tất cả issue của apache/cloudstack
Issue tương tự
-
maintenance
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 83/100
apache/maven-resources-plugin#569 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Data Sources visit drilldown returns an empty visitDurationByType for Achilles 1.7+ results (query still reads analysis 211)Có thể đã có người làm @DG47 đã nhận hôm nay. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 77/100
Maintainer thường phản hồi trong vòng 1 ngày
-
BUG
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 77/100
camel-tooling/camel-language-server#1482 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 82/100
Maintainer thường phản hồi trong vòng 3 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
micronaut-projects/micronaut-redis#844 ·
Maintainer thường phản hồi trong vòng 4 ngày