crc: [BUG]"crc start" can't add CRC section to hosts file and deletes existing section

General information

  • OS: Windows 11 Professional
  • Hypervisor: Hyper-V
  • Did you run crc setup before starting it (Yes/No)? -> Yes
  • Running CRC on: Laptop / Baremetal-Server / VM -> Laptop

CRC version

CRC version: 2.37.1+36d451
OpenShift version: 4.15.14

CRC status

DEBU CRC version: 2.37.1+36d451
DEBU OpenShift version: 4.15.14
DEBU Running 'crc status'
CRC VM:          Running
OpenShift:       Unreachable (v4.15.14)
RAM Usage:       716MB of 20.98GB
Disk Usage:      21.35GB of 32.68GB (Inside the CRC VM)
Cache Usage:     71.53GB
Cache Directory: C:\Users\megas\.crc\cache

CRC config

- consent-telemetry                     : no
- memory                                : 20480

Host Operating System

ホスト名:               DESKTOP5
OS 名:                  Microsoft Windows 11 Pro
OS バージョン:          10.0.22631 N/A ビルド 22631
OS 製造元:              Microsoft Corporation
OS 構成:                スタンドアロン ワークステーション
OS ビルドの種類:        Multiprocessor Free
登録されている所有者:   megascus@msn.com
登録されている組織:     N/A
プロダクト ID:          00355-60723-44496-AAOEM
最初のインストール日付: 2022/09/22(木), 8:13:38
システム起動時間:       2024/06/14(金), 8:52:09
システム製造元:         Thirdwave Corporation
システム モデル:        XF
システムの種類:         x64-based PC
プロセッサ:             1 プロセッサインストール済みです。
                        [01]: Intel64 Family 6 Model 151 Stepping 2 GenuineIntel ~2100 Mhz
BIOS バージョン:        American Megatrends Inc. 1402A, 2022/04/01(金)
Windows ディレクトリ:   C:\WINDOWS
システム ディレクトリ:  C:\WINDOWS\system32
起動デバイス:           \Device\HarddiskVolume1
システム ロケール:      ja;日本語
入力ロケール:           ja;日本語
タイム ゾーン:          (UTC+09:00) 大阪、札幌、東京
物理メモリの合計:       130,813 MB
利用できる物理メモリ:   90,704 MB
仮想メモリ: 最大サイズ: 150,269 MB
仮想メモリ: 利用可能:   107,140 MB
仮想メモリ: 使用中:     43,129 MB
ページ ファイルの場所:  C:\pagefile.sys
ドメイン:               WORKGROUP
ログオン サーバー:      \\DESKTOP5
ホットフィックス:       6 ホットフィックスがインストールされています。
                        [01]: KB5037591
                        [02]: KB5012170
                        [03]: KB5027397
                        [04]: KB5039212
                        [05]: KB5037663
                        [06]: KB5037959
ネットワーク カード:    3 NIC(s) インストール済みです。
                        [01]: Wintun Userspace Tunnel
                              接続名:           OpenVPN Wintun
                              状態:          メディアは接続されていません
                        [02]: TAP-Windows Adapter V9
                              接続名:           ローカル エリア接続
                              状態:          メディアは接続されていません
                        [03]: Realtek Gaming 2.5GbE Family Controller
                              接続名:           イーサネット
                              DHCP が有効:      はい
                              DHCP サーバー:    192.168.11.1
                              IP アドレス
                              [01]: 192.168.11.20
                              [02]: fe80::a56e:bd94:56e:633a
                              [03]: 2408:211:32d:6500:3938:30b5:6061:ae22
                              [04]: 2408:211:32d:6500:ebbf:c4e1:af0f:f484
Hyper-V の要件:         ハイパーバイザーが検出されました。Hyper-V に必要な機能は表示されません。

Steps to reproduce

  1. crc setup
  2. crc start

Expected

OpenShift Local could start.

Actual

OpenShift Local could not start. And, “crc start” deleted existing section, like “127.0.0.1 localhost” Error message: Error running post start: can’t add CRC section, check hosts file

Logs

INFO Using bundle path C:\Users\megas\.crc\cache\crc_hyperv_4.15.14_amd64.crcbundle
INFO Checking minimum RAM requirements
INFO Check if Podman binary exists in: C:\Users\megas\.crc\bin\oc
INFO Checking if running in a shell with administrator rights
INFO Checking Windows release
INFO Checking Windows edition
INFO Checking if Hyper-V is installed and operational
INFO Checking if Hyper-V service is enabled
INFO Checking if crc-users group exists
INFO Checking if current user is in crc-users and Hyper-V admins group
INFO Checking if vsock is correctly configured
INFO Checking if the win32 background launcher is installed
INFO Checking if the daemon task is installed
INFO Checking if the daemon task is running
INFO Checking admin helper service is running
INFO Checking SSH port availability
INFO Loading bundle: crc_hyperv_4.15.14_amd64...
INFO Starting CRC VM for openshift 4.15.14...
INFO CRC instance is running with IP 127.0.0.1
INFO CRC VM is running
Error running post start: can't add CRC section, check hosts file

Before gather the logs try following if that fix your issue

$ crc delete -f
$ crc cleanup
$ crc setup
$ crc start --log-level debug

Please consider posting the output of crc start --log-level debug on http://gist.github.com/ and post the link in the issue. https://gist.github.com/megascus/b0caac285a5b0854a0118ed62a94e82e

hosts: https://gist.github.com/megascus/9916cf196a61638a89a321fe42632aaa

About this issue

  • Original URL
  • State: closed
  • Created 2 years ago
  • Comments: 15 (9 by maintainers)

Most upvoted comments

I am satisfied because my immediate problem has been solved. Please close this ticket if necessary.

We’re closing this issue as requested.

Feel free to open a new issue if you need any more help or run into any other issues. Thanks again for your support!