abiosoft / abiosoft/colima

eth0 default route metric (200) overrides col0 (300) after DHCP lease

Đang mở
#1,551 3 bình luận 0 reaction 0 người được giao Xem trên GitHub
Ngôn ngữ chính
Go
Star
30.8k
Fork
613
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Mô tả

### Description

I am not able to pull images due to the routing conflict. I always have to restart the colima instance to pull the images.

**Details:**
I am seeing a routing conflict where the **eth0** interface is assigned a default route with a lower metric than **col0**. This causes the VM to lose internet connectivity (or route through the wrong interface).

**Reproduction Steps:**

1. `Start Colima with --network-address.`
2. Wait for a DHCP lease or network change.
3. Run ip route inside the VM.

**Actual Behavior:**
Two default routes exist, but **eth0** has a metric of 200, making it the preferred path over **col0** (metric 300).

**Routing Table (After Issue):**

```
default via 192.168.5.2 dev eth0 proto dhcp src 192.168.5.1 metric 200
default via 192.168.0.1 dev col0 proto dhcp src 192.168.0.78 metric 300
```

**Suggested Fix:**
Ensure that the **col0** interface is always assigned a lower metric (e.g., 50 or 100) or ensure **eth0** is configured with **ipv4.never-default** or a significantly higher metric.

### Version

colima version 0.10.1
git commit: ed905203afdbc6fd4eae6cc301918099ff31e86e

runtime: docker
arch: aarch64
client: v29.3.1
server: v29.2.1
limactl version 2.1.1
zsh: command not found: qemu-img

### Operating System

- [ ] macOS Intel <= 13 (Ventura)
- [ ] macOS Intel >= 14 (Sonoma)
- [ ] Apple Silicon <= 13 (Ventura)
- [x] Apple Silicon >= 14 (Sonoma)
- [ ] Linux

### Output of `colima status`

colima status
INFO[0000] colima is running using macOS Virtualization.Framework
INFO[0000] arch: aarch64
INFO[0000] runtime: docker
INFO[0000] mountType: virtiofs
INFO[0000] address: 192.168.0.78
INFO[0000] docker socket: unix:///Users//.colima/default/docker.sock
INFO[0000] containerd socket: unix:///Users//.colima/default/containerd.sock

### Reproduction Steps

1. `Start Colima with --network-address.`
2. Wait for a DHCP lease or network change.
3. Run ip route inside the VM.

### Expected behaviour

**col0** should be the preferred route always.

### Additional context

_No response_

Hướng dẫn đóng góp

Chưa lập chỉ mục được hướng dẫn đóng góp cho kho mã nguồn này

Đánh giá

Issue này chưa được đánh giá.

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.