在 ubuntu 上运行 openshift crc,crc 启动处于“等待用户的 pull secret 写入实例磁盘”状态

在 ubuntu 上运行 openshift crc,crc 启动处于“等待用户的 pull secret 写入实例磁盘”状态

我正在笔记本电脑上设置 crc 环境(本地 Redhat Openshift),用于自学。启动 crc 时遇到问题。

crc 启动命令停止于:INFO 等待用户的拉取机密写入实例磁盘......

这是最新的重新设置结果:(在进行设置/重新开始之前我已经进行了 crc 删除/crc 清理)

主机操作系统:Ubuntu 24.04 LTS(无虚拟层,直接在笔记本电脑上进行设置)Bios 虚拟化:已激活。

配置.json:

{
    "ConfigVersion": 3,
    "Driver": {
        "IPAddress": "192.168.130.11",
        "MachineName": "crc",
        "StorePath": "/home/elmokh/.crc",
        "BundleName": "crc_libvirt_4.15.3_amd64",
        "ImageSourcePath": "/home/elmokh/.crc/cache/crc_libvirt_4.15.3_amd64/crc.qcow2",
        "ImageFormat": "qcow2",
        "Memory": 10752,
        "CPU": 4,
        "DiskCapacity": 33285996544,
        "SharedDirs": [
            {
                "ReadOnly": false,
                "Source": "/home/elmokh",
                "Tag": "dir0",
                "Target": "/home/elmokh",
                "Type": "virtiofs",
                "Username": ""
            }
        ],
        "Network": "crc",
        "CacheMode": "default",
        "IOMode": "threads",
        "VSock": false,
        "StoragePool": "crc"
    },
    "DriverName": "libvirt",
    "DriverPath": "/home/elmokh/.crc/bin",
    "Name": "crc"
}
crc version
CRC version: 2.34.1+b470b5
OpenShift version: 4.15.3
Podman version: 4.4.4

crc status
crc does not seem to be setup correctly, have you run 'crc setup'?

crc setup
INFO Using bundle path /home/elmokh/.crc/cache/crc_libvirt_4.15.3_amd64.crcbundle 
INFO Checking if running as non-root              
INFO Checking if running inside WSL2              
INFO Checking if crc-admin-helper executable is cached 
INFO Checking if running on a supported CPU architecture 
INFO Checking if crc executable symlink exists    
INFO Creating symlink for crc executable          
INFO Checking minimum RAM requirements            
INFO Check if Podman binary exists in: /home/elmokh/.crc/bin/oc 
INFO Checking if Virtualization is enabled        
INFO Checking if KVM is enabled                   
INFO Checking if libvirt is installed             
INFO Checking if user is part of libvirt group    
INFO Checking if active user/process is currently part of the libvirt group 
INFO Checking if libvirt daemon is running        
INFO Checking if a supported libvirt version is installed 
INFO Checking if crc-driver-libvirt is installed  
INFO Checking crc daemon systemd service          
INFO Setting up crc daemon systemd service        
INFO Checking crc daemon systemd socket units     
INFO Setting up crc daemon systemd socket units   
INFO Checking if AppArmor is configured           
INFO Updating AppArmor configuration              
INFO Using root access: Updating AppArmor configuration 
INFO Using root access: Changing permissions for /etc/apparmor.d/libvirt/TEMPLATE.qemu to 644  
INFO Checking if systemd-networkd is running      
INFO Checking if NetworkManager is installed      
INFO Checking if NetworkManager service is running 
INFO Checking if dnsmasq configurations file exist for NetworkManager 
INFO Checking if the systemd-resolved service is running 
INFO Checking if /etc/NetworkManager/dispatcher.d/99-crc.sh exists 
INFO Writing NetworkManager dispatcher file for crc 
INFO Using root access: Writing NetworkManager configuration to /etc/NetworkManager/dispatcher.d/99-crc.sh 
INFO Using root access: Changing permissions for /etc/NetworkManager/dispatcher.d/99-crc.sh to 755  
INFO Using root access: Executing systemctl daemon-reload command 
INFO Using root access: Executing systemctl reload NetworkManager 
INFO Checking if libvirt 'crc' network is available 
INFO Setting up libvirt 'crc' network             
INFO Checking if libvirt 'crc' network is active  
INFO Starting libvirt 'crc' network               
INFO Checking if CRC bundle is extracted in '$HOME/.crc' 
INFO Checking if /home/elmokh/.crc/cache/crc_libvirt_4.15.3_amd64.crcbundle exists 
Your system is correctly setup for using CRC. Use 'crc start' to start the instance

crc start --pull-secret-file ./pull-secret.json 
INFO Using bundle path /home/elmokh/.crc/cache/crc_libvirt_4.15.3_amd64.crcbundle 
INFO Checking if running as non-root              
INFO Checking if running inside WSL2              
INFO Checking if crc-admin-helper executable is cached 
INFO Checking if running on a supported CPU architecture 
INFO Checking if crc executable symlink exists    
INFO Checking minimum RAM requirements            
INFO Check if Podman binary exists in: /home/elmokh/.crc/bin/oc 
INFO Checking if Virtualization is enabled        
INFO Checking if KVM is enabled                   
INFO Checking if libvirt is installed             
INFO Checking if user is part of libvirt group    
INFO Checking if active user/process is currently part of the libvirt group 
INFO Checking if libvirt daemon is running        
INFO Checking if a supported libvirt version is installed 
INFO Checking if crc-driver-libvirt is installed  
INFO Checking crc daemon systemd socket units     
INFO Checking if AppArmor is configured           
INFO Checking if systemd-networkd is running      
INFO Checking if NetworkManager is installed      
INFO Checking if NetworkManager service is running 
INFO Checking if dnsmasq configurations file exist for NetworkManager 
INFO Checking if the systemd-resolved service is running 
INFO Checking if /etc/NetworkManager/dispatcher.d/99-crc.sh exists 
INFO Checking if libvirt 'crc' network is available 
INFO Checking if libvirt 'crc' network is active  
INFO Loading bundle: crc_libvirt_4.15.3_amd64...  
INFO Creating CRC VM for OpenShift 4.15.3...      
INFO Generating new SSH key pair...               
INFO Generating new password for the kubeadmin user 
INFO Starting CRC VM for openshift 4.15.3...      
INFO CRC instance is running with IP 192.168.130.11 
INFO CRC VM is running                            
INFO Updating authorized keys...                  
INFO Configuring shared directories               
INFO Check internal and public DNS query...       
INFO Check DNS query from host...                 
WARN Wildcard DNS resolution for apps-crc.testing does not appear to be working 
INFO Verifying validity of the kubelet certificates... 
INFO Starting kubelet service                     
INFO Waiting for kube-apiserver availability... [takes around 2min] 
INFO Adding user's pull secret to the cluster...  
INFO Updating SSH key to machine config resource... 
INFO Waiting until the user's pull secret is written to the instance disk ...

我尝试了调试模式,这个步骤一直循环:

DEBU retry loop: attempt 171                      
DEBU Running SSH command: <hidden>                
DEBU SSH command succeeded                        
DEBU error: Temporary error: pull secret not updated to disk - sleeping 2s

同时以下命令表明我可以访问 crc 机器:


crc status
CRC VM:          Running
OpenShift:       Unreachable (v4.15.3)
RAM Usage:       1.977GB of 10.96GB
Disk Usage:      19.05GB of 32.68GB (Inside the CRC VM)
Cache Usage:     26.27GB
Cache Directory: /home/elmokh/.crc/cache


ssh -i ~/.crc/machines/crc/id_ecdsa -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null  [email protected]
Warning: Permanently added '192.168.130.11' (ED25519) to the list of known hosts.
Red Hat Enterprise Linux CoreOS 415.92.202403080220-0
  Part of OpenShift 4.15, RHCOS is a Kubernetes native operating system
  managed by the Machine Config Operator (`clusteroperator/machine-config`).

WARNING: Direct SSH access to machines is not recommended; instead,
make configuration changes via `machineconfig` objects:
  https://docs.openshift.com/container-platform/4.15/architecture/architecture-rhcos.html

---
[systemd]
Failed Units: 1
  qemu-guest-agent.service


我将等待任何进一步的命令来帮助分析该问题。

相关内容