abiosoft / abiosoft/colima

New Colima installations do never come up properly

Ouverte
#685 7 commentaires 2 réactions 0 personnes assignées Voir sur GitHub
Langage dominant
Go
Étoiles
30.8k
Forks
613
Métriques de merge des PR
Aucune PR mergée en 30 j

Description

### Description

We use Colima for quite a long time, but when we, our team, tried to setup Colima again, no one can get Colima working. As I can see and describe it, it seems so, that QEMU is not able to start properly.

### Version

Colima Version: 0.5.4
Lima Version: 0.15.0
Qemu Version: 7.2.0

### Operating System

- [ ] macOS Intel <= 12 (Monterrey)
- [ ] macOS Intel >= 13 (Ventura)
- [ ] macOS M1 <= 12 (Monterrey)
- [X] macOS M1 >= 13 (Ventura)
- [ ] Linux

### Output of `colima status`

The command does not return properly.

```
uid096801@nuewx0096801 ~ % colima status
FATA[0074] error retrieving current runtime: empty value
```

### Reproduction Steps

1. `colima start --cpu 2 --memory 8 --disk 80 --arch x86_64 --verbose`

### Expected behaviour

Normal startup of Colima as one year agon ;-)

### Additional context

Here is the output of `colima start --cpu 2 --memory 8 --disk 80 --arch x86_64 --verbose``

```
INFO[0000] starting colima
INFO[0000] runtime: docker
INFO[0000] preparing network ... context=vm
INFO[0000] starting ... context=vm
> Using the existing instance "colima"
> [hostagent] Starting QEMU (hint: to watch the boot progress, see "/Users/uid096801/.lima/colima/serial.log")
> SSH Local Port: 50999
> [hostagent] Waiting for the essential requirement 1 of 5: "ssh"
> [hostagent] Waiting for the essential requirement 1 of 5: "ssh"
> [hostagent] Waiting for the essential requirement 1 of 5: "ssh"
> [hostagent] Waiting for the essential requirement 1 of 5: "ssh"
> [hostagent] Waiting for the essential requirement 1 of 5: "ssh"
> [hostagent] Waiting for the essential requirement 1 of 5: "ssh"
> [hostagent] Waiting for the essential requirement 1 of 5: "ssh"
> [hostagent] Waiting for the essential requirement 1 of 5: "ssh"
> did not receive an event with the "running" status
FATA[0600] error starting vm: error at 'starting': exit status 1
uid096801@nuewx0096801 ~ %
````

Here is the to `~/.lima/colima/serial`:
```
uid096801@nuewx0096801 ~ % tail -f /Users/uid096801/.lima/colima/serial.log
BdsDxe: failed to load Boot0001 "UEFI QEMU QEMU CD-ROM " from PciRoot(0x0)/Pci(0x1,0x0)/Scsi(0x0,0x0): Not Found
BdsDxe: failed to load Boot0002 "UEFI Misc Device" from PciRoot(0x0)/Pci(0x9,0x0): Not Found

>>Start PXE over IPv4.
PXE-E16: No valid offer received.
BdsDxe: failed to load Boot0003 "UEFI PXEv4 (MAC:52555505EB74)" from PciRoot(0x0)/Pci(0x2,0x0)/MAC(52555505EB74,0x1)/IPv4(0.0.0.0,0x0,DHCP,0.0.0.0,0.0.0.0,0.0.0.0): Not Found

>>Start PXE over IPv6.
PXE-E16: No valid offer received.
BdsDxe: failed to load Boot0004 "UEFI PXEv6 (MAC:52555505EB74)" from PciRoot(0x0)/Pci(0x2,0x0)/MAC(52555505EB74,0x1)/IPv6(0000:0000:0000:0000:0000:0000:0000:0000,0x0,Static,0000:0000:0000:0000:0000:0000:0000:0000,0x40,0000:0000:0000:0000:0000:0000:0000:0000): Not Found

>>Start HTTP Boot over IPv4...
Error: Could not retrieve NBP file size from HTTP server.

Error: Server response timeout.
BdsDxe: failed to load Boot0005 "UEFI HTTPv4 (MAC:52555505EB74)" from PciRoot(0x0)/Pci(0x2,0x0)/MAC(52555505EB74,0x1)/IPv4(0.0.0.0,0x0,DHCP,0.0.0.0,0.0.0.0,0.0.0.0)/Uri(): Not Found

>>Start HTTP Boot over IPv6.
Error: Could not retrieve NBP file size from HTTP server.

Error: Unexpected network error.
BdsDxe: failed to load Boot0006 "UEFI HTTPv6 (MAC:52555505EB74)" from PciRoot(0x0)/Pci(0x2,0x0)/MAC(52555505EB74,0x1)/IPv6(0000:0000:0000:0000:0000:0000:0000:0000,0x0,Static,0000:0000:0000:0000:0000:0000:0000:0000,0x40,0000:0000:0000:0000:0000:0000:0000:0000)/Uri(): Not Found

>>Start PXE over IPv4.
PXE-E16: No valid offer received.
BdsDxe: failed to load Boot0007 "UEFI PXEv4 (MAC:5A94EFF12CEB)" from PciRoot(0x0)/Pci(0x8,0x0)/MAC(5A94EFF12CEB,0x1)/IPv4(0.0.0.0,0x0,DHCP,0.0.0.0,0.0.0.0,0.0.0.0): Not Found

>>Start PXE over IPv6.
PXE-E16: No valid offer received.
BdsDxe: failed to load Boot0008 "UEFI PXEv6 (MAC:5A94EFF12CEB)" from PciRoot(0x0)/Pci(0x8,0x0)/MAC(5A94EFF12CEB,0x1)/IPv6(0000:0000:0000:0000:0000:0000:0000:0000,0x0,Static,0000:0000:0000:0000:0000:0000:0000:0000,0x40,0000:0000:0000:0000:0000:0000:0000:0000): Not Found

>>Start HTTP Boot over IPv4...
Error: Could not retrieve NBP file size from HTTP server.

Error: Server response timeout.
BdsDxe: failed to load Boot0009 "UEFI HTTPv4 (MAC:5A94EFF12CEB)" from PciRoot(0x0)/Pci(0x8,0x0)/MAC(5A94EFF12CEB,0x1)/IPv4(0.0.0.0,0x0,DHCP,0.0.0.0,0.0.0.0,0.0.0.0)/Uri(): Not Found

>>Start HTTP Boot over IPv6.
...
```

Then the following appears in `serial.log`:

````
UEFI Interactive Shell v2.2
EDK II
UEFI v2.70 (EDK II, 0x00010000)
Mapping table
BLK0: Alias(s):
PciRoot(0x0)/Pci(0x1,0x0)/Scsi(0x0,0x0)
BLK1: Alias(s):
PciRoot(0x0)/Pci(0x9,0x0)
BLK2: Alias(s):
PciRoot(0x0)/Pci(0x9,0x0)/HD(2,MBR,0x5603A7B4,0x148,0xB40)
Press ESC in 1 seconds to skip startup.nsh or any other key to continue.
Shell>

```
Here is also our `lima.yaml`, taken from `~/.lima/colima`:

```
vmType: qemu
arch: x86_64
images:
- location: /Users/uid096801/Downloads/alpine-lima-clm-3.16.2-x86_64.iso
arch: x86_64
digest: sha512:7231f12b7f1bbb24976b6619af1948dead9835e951f84b92f01cd4f6b5eb4121dee2c683351fc3f4a7a6dea0f6f55a44368049099218eb2b94337d5de5f03c4f

cpus: 2
memory: 8GiB
disk: 80GiB
mounts:
- location: "~"
writable: true
- location: /tmp/colima
writable: true
mountType: reverse-sshfs
containerd:
system: false
user: false
dns:
- 192.168.107.1
firmware:
legacyBIOS: false
hostResolver:
enabled: false
hosts:
host.docker.internal: host.lima.internal
portForwards:
- guestPortRange:
- 0
- 0
guestSocket: /var/run/docker.sock
hostPortRange:
- 0
- 0
hostSocket: /Users/uid096801/.colima/default/docker.sock
proto: tcp
- guestPortRange:
- 0
- 0
guestSocket: /var/run/docker.sock
hostPortRange:
- 0
- 0
hostSocket: /Users/uid096801/.colima/docker.sock
proto: tcp
- guestIPMustBeZero: true
guestIP: 0.0.0.0
guestPortRange:
- 1
- 65535
hostIP: 0.0.0.0
hostPortRange:
- 1
- 65535
proto: tcp
- guestIP: 127.0.0.1
guestPortRange:
- 1
- 65535
hostIP: 127.0.0.1
hostPortRange:
- 1
- 65535
proto: tcp
provision:
- mode: system
script: sysctl -w fs.inotify.max_user_watches=1048576
- mode: user
script: sudo usermod -aG docker $USER
- mode: system
script: grep -q "^rc_env_allow" /etc/rc.conf || echo 'rc_env_allow="*"' >> /etc/rc.conf
- mode: system
script: |
#!/usr/bin/env sh

FILE=/etc/network/interfaces
BACKUP="$FILE.bak"

# this only happens one in the beginning
if [ ! -f "$BACKUP" ]; then
cp "$FILE" "$BACKUP"
fi

# reset the network file
cp "$BACKUP" "$FILE"

written() (
grep -q "^auto ${1}" "${FILE}"
)

vmnet() (
IFACE="col0"

if written $IFACE; then exit 0; fi

cat >>$FILE <>$FILE <

Guide de contribution

Aucun guide de contribution indexé pour ce dépôt

Piste de recherche

The issue is about Colima failing to start on macOS M1 with QEMU errors. Look at the lima.yaml configuration in ~/.lima/colima and the serial.log output showing UEFI boot failures. Start by examining the VM startup logic in the Colima codebase, particularly around QEMU initialization and disk image handling. Check if the Alpine ISO path is correct and if the firmware settings are compatible with M1. The fix likely involves adjusting the VM configuration or the boot process.

Rédigé par le modèle d'indexation à partir du texte de l'issue.

Évaluation

Stack technique
docker, go, macos
Domaine
cli, devops, infrastructure
Type d'issue
Bug
Difficulté
4/5
Temps estimé
3-5 jours
Activité
À l'abandon
Clarté
Plutôt claire
Accessibilité débutants
30/100

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.