Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

virtualbox: Error dialing TCP: dial tcp 127.0.0.1:x: connect: connection refused #7674

Closed
jyobeer opened this issue Apr 15, 2020 · 17 comments
Closed
Labels
kind/support Categorizes issue or PR as a support question. needs-solution-message Issues where where offering a solution for an error would be helpful triage/needs-information Indicates an issue needs more information in order to work on it.

Comments

@jyobeer
Copy link

jyobeer commented Apr 15, 2020

Steps to reproduce the issue:

  1. minikube start

Full output of failed command:

Full output of minikube start command used, if not already included:
πŸ˜„ minikube v1.9.2 on Ubuntu 16.04
✨ Using the virtualbox driver based on existing profile
πŸ‘ Starting control plane node m01 in cluster minikube
πŸ”„ Restarting existing virtualbox VM for "minikube" ...
🀦 StartHost failed, but will try again: driver start: Maximum number of retries (5) exceeded
πŸ”„ Restarting existing virtualbox VM for "minikube" ...

πŸ’£ Failed to start virtualbox VM. "minikube start" may fix it.: driver start: Maximum number of retries (5) exceeded

Optional: Full output of minikube logs command:

The control plane node must be running for this command
@jyobeer
Copy link
Author

jyobeer commented Apr 15, 2020

πŸ˜„ minikube v1.9.2 on Ubuntu 16.04
✨ Using the virtualbox driver based on existing profile
πŸ‘ Starting control plane node m01 in cluster minikube
πŸ”₯ Creating virtualbox VM (CPUs=2, Memory=975MB, Disk=20000MB) ...
🀦 StartHost failed, but will try again: creating host: create host timed out in 120.000000 seconds
πŸ”₯ Deleting "minikube" in virtualbox ...
πŸ”₯ Creating virtualbox VM (CPUs=2, Memory=975MB, Disk=20000MB) ...

❌ [CREATE_TIMEOUT] Failed to start virtualbox VM. "minikube start" may fix it. creating host: create host timed out in 120.000000 seconds
πŸ’‘ Suggestion: Try 'minikube delete', and disable any conflicting VPN or firewall software
⁉️ Related issue: #7072

@jyobeer
Copy link
Author

jyobeer commented Apr 15, 2020

Output of minikube start --alsologtostderr -v=8 is as below

W0415 09:07:46.247751    6690 root.go:248] Error reading config file at /home/dmadmin/.minikube/config/config.json: open /home/dmadmin/.minikube/config/config.json: no such file or directory
I0415 09:07:46.252892    6690 notify.go:125] Checking for updates...
I0415 09:07:48.833634    6690 start.go:262] hostinfo: {"hostname":"ubuntu","uptime":4103,"bootTime":1586962765,"procs":307,"os":"linux","platform":"ubuntu","platformFamily":"debian","platformVersion":"16.04","kernelVersion":"4.4.0-31-generic","virtualizationSystem":"kvm","virtualizationRole":"host","hostid":"8c5750d2-ff05-4ad5-96fa-a936adcaced9"}
I0415 09:07:48.852278    6690 start.go:272] virtualization: kvm host
πŸ˜„  minikube v1.9.2 on Ubuntu 16.04
I0415 09:07:48.889498    6690 driver.go:245] Setting default libvirt URI to qemu:///system
✨  Using the virtualbox driver based on existing profile
I0415 09:07:50.217372    6690 start.go:310] selected driver: virtualbox
I0415 09:07:50.217790    6690 start.go:656] validating driver "virtualbox" against &{Name:minikube KeepContext:false EmbedCerts:false MinikubeISO:https://storage.googleapis.com/minikube/iso/minikube-v1.9.0.iso Memory:975 CPUs:2 DiskSize:20000 Driver:virtualbox HyperkitVpnKitSock: HyperkitVSockPorts:[] DockerEnv:[] InsecureRegistry:[] RegistryMirror:[] HostOnlyCIDR:192.168.99.1/24 HypervVirtualSwitch: HypervUseExternalSwitch:false HypervExternalAdapter: KVMNetwork:default KVMQemuURI:qemu:///system KVMGPU:false KVMHidden:false DockerOpt:[] DisableDriverMounts:false NFSShare:[] NFSSharesRoot:/nfsshares UUID: NoVTXCheck:false DNSProxy:false HostDNSResolver:true HostOnlyNicType:virtio NatNicType:virtio KubernetesConfig:{KubernetesVersion:v1.18.0 ClusterName:minikube APIServerName:minikubeCA APIServerNames:[] APIServerIPs:[] DNSDomain:cluster.local ContainerRuntime:docker CRISocket: NetworkPlugin: FeatureGates: ServiceCIDR:10.96.0.0/12 ImageRepository: ExtraOptions:[] ShouldLoadCachedImages:true EnableDefaultCNI:false NodeIP: NodePort:0 NodeName:} Nodes:[{Name:m01 IP: Port:8443 KubernetesVersion:v1.18.0 ControlPlane:true Worker:true}] Addons:map[] VerifyComponents:map[apiserver:true system_pods:true]}
I0415 09:07:50.218522    6690 start.go:662] status for virtualbox: {Installed:true Healthy:true Error:<nil> Fix: Doc:}
I0415 09:07:50.220280    6690 start.go:1004] Using suggested 975MB memory alloc based on sys=975MB, container=0MB
I0415 09:07:50.223267    6690 start.go:1210] Wait components to verify : map[apiserver:true system_pods:true]
I0415 09:07:50.225296    6690 iso.go:119] acquiring lock: {Name:mke94909b1bb868fc58254a6d3f4a3b7eb5ef9c5 Clock:{} Delay:500ms Timeout:10m0s Cancel:<nil>}
πŸ‘  Starting control plane node m01 in cluster minikube
I0415 09:07:50.244732    6690 preload.go:81] Checking if preload exists for k8s version v1.18.0 and runtime docker
I0415 09:07:50.249460    6690 preload.go:97] Found local preload: /home/dmadmin/.minikube/cache/preloaded-tarball/preloaded-images-k8s-v2-v1.18.0-docker-overlay2-amd64.tar.lz4
I0415 09:07:50.249614    6690 cache.go:46] Caching tarball of preloaded images
I0415 09:07:50.256432    6690 preload.go:123] Found /home/dmadmin/.minikube/cache/preloaded-tarball/preloaded-images-k8s-v2-v1.18.0-docker-overlay2-amd64.tar.lz4 in cache, skipping download
I0415 09:07:50.260449    6690 cache.go:49] Finished downloading the preloaded tar for v1.18.0 on docker
I0415 09:07:50.262212    6690 profile.go:138] Saving config to /home/dmadmin/.minikube/profiles/minikube/config.json ...
I0415 09:07:50.264357    6690 cache.go:117] Successfully downloaded all kic artifacts
I0415 09:07:50.265986    6690 start.go:260] acquiring machines lock for minikube: {Name:mkba127eff421cbdedba32941675c44c05b7834b Clock:{} Delay:500ms Timeout:15m0s Cancel:<nil>}
I0415 09:07:50.266641    6690 start.go:264] acquired machines lock for "minikube" in 494.732Β΅s
I0415 09:07:50.266920    6690 start.go:90] Skipping create...Using existing machine configuration
I0415 09:07:50.268335    6690 fix.go:53] fixHost starting: m01
I0415 09:07:50.273563    6690 main.go:110] libmachine: COMMAND: /usr/bin/VBoxManage showvminfo minikube --machinereadable
I0415 09:07:51.008065    6690 main.go:110] libmachine: STDOUT:
{
name="minikube"
groups="/"
ostype="Linux 2.6 / 3.x / 4.x (64-bit)"
UUID="8f1fabca-3e49-4432-b77a-4e776a5301c1"
CfgFile="/home/dmadmin/.minikube/machines/minikube/minikube/minikube.vbox"
SnapFldr="/home/dmadmin/.minikube/machines/minikube/minikube/Snapshots"
LogFldr="/home/dmadmin/.minikube/machines/minikube/minikube/Logs"
hardwareuuid="8f1fabca-3e49-4432-b77a-4e776a5301c1"
memory=975
pagefusion="off"
vram=8
cpuexecutioncap=100
hpet="on"
chipset="piix3"
firmware="BIOS"
cpus=2
pae="on"
longmode="on"
triplefaultreset="off"
apic="on"
x2apic="off"
cpuid-portability-level=0
bootmenu="disabled"
boot1="dvd"
boot2="dvd"
boot3="disk"
boot4="none"
acpi="on"
ioapic="on"
biosapic="apic"
biossystemtimeoffset=0
rtcuseutc="on"
hwvirtex="on"
nestedpaging="on"
largepages="on"
vtxvpid="on"
vtxux="on"
paravirtprovider="default"
effparavirtprovider="kvm"
VMState="aborted"
VMStateChangeTime="2020-04-15T15:06:24.000000000"
monitorcount=1
accelerate3d="off"
accelerate2dvideo="off"
teleporterenabled="off"
teleporterport=0
teleporteraddress=""
teleporterpassword=""
tracing-enabled="off"
tracing-allow-vm-access="off"
tracing-config=""
autostart-enabled="off"
autostart-delay=0
defaultfrontend=""
storagecontrollername0="SATA"
storagecontrollertype0="IntelAhci"
storagecontrollerinstance0="0"
storagecontrollermaxportcount0="30"
storagecontrollerportcount0="30"
storagecontrollerbootable0="on"
"SATA-0-0"="/home/dmadmin/.minikube/machines/minikube/boot2docker.iso"
"SATA-ImageUUID-0-0"="29fc1f32-c7a0-441a-bd3a-015656a59196"
"SATA-tempeject"="off"
"SATA-IsEjected"="off"
"SATA-1-0"="/home/dmadmin/.minikube/machines/minikube/disk.vmdk"
"SATA-ImageUUID-1-0"="ebe4b278-4e5f-4034-9ea4-b27bb9ea82b2"
"SATA-2-0"="none"
"SATA-3-0"="none"
"SATA-4-0"="none"
"SATA-5-0"="none"
"SATA-6-0"="none"
"SATA-7-0"="none"
"SATA-8-0"="none"
"SATA-9-0"="none"
"SATA-10-0"="none"
"SATA-11-0"="none"
"SATA-12-0"="none"
"SATA-13-0"="none"
"SATA-14-0"="none"
"SATA-15-0"="none"
"SATA-16-0"="none"
"SATA-17-0"="none"
"SATA-18-0"="none"
"SATA-19-0"="none"
"SATA-20-0"="none"
"SATA-21-0"="none"
"SATA-22-0"="none"
"SATA-23-0"="none"
"SATA-24-0"="none"
"SATA-25-0"="none"
"SATA-26-0"="none"
"SATA-27-0"="none"
"SATA-28-0"="none"
"SATA-29-0"="none"
natnet1="nat"
macaddress1="0800276F985F"
cableconnected1="on"
nic1="nat"
nictype1="virtio"
nicspeed1="0"
mtu="0"
sockSnd="64"
sockRcv="64"
tcpWndSnd="64"
tcpWndRcv="64"
Forwarding(0)="ssh,tcp,127.0.0.1,37006,,22"
hostonlyadapter2="vboxnet0"
macaddress2="0800278E816F"
cableconnected2="on"
nic2="hostonly"
nictype2="virtio"
nicspeed2="0"
nic3="none"
nic4="none"
nic5="none"
nic6="none"
nic7="none"
nic8="none"
hidpointing="ps2mouse"
hidkeyboard="ps2kbd"
uart1="off"
uart2="off"
uart3="off"
uart4="off"
lpt1="off"
lpt2="off"
audio="pulse"
clipboard="disabled"
draganddrop="disabled"
vrde="off"
usb="off"
ehci="off"
xhci="off"
SharedFolderNameMachineMapping1="hosthome"
SharedFolderPathMachineMapping1="/home"
vcpenabled="off"
vcpscreens=0
vcpfile="/home/dmadmin/.minikube/machines/minikube/minikube/minikube.webm"
vcpwidth=1024
vcpheight=768
vcprate=512
vcpfps=25
GuestMemoryBalloon=0
}
I0415 09:07:51.014217    6690 main.go:110] libmachine: STDERR:
{
}
I0415 09:07:51.014654    6690 fix.go:105] recreateIfNeeded on minikube: state=Stopped err=<nil>
I0415 09:07:51.014944    6690 fix.go:109] exists: true err=<nil>
I0415 09:07:51.015097    6690 fix.go:110] %!q(<nil>) vs "machine does not exist"
W0415 09:07:51.015349    6690 fix.go:130] unexpected machine state, will restart: <nil>
πŸ”„  Restarting existing virtualbox VM for "minikube" ...
I0415 09:07:51.019497    6690 main.go:110] libmachine: COMMAND: /usr/bin/VBoxManage showvminfo minikube --machinereadable
I0415 09:07:51.395470    6690 main.go:110] libmachine: STDOUT:
{
name="minikube"
groups="/"
ostype="Linux 2.6 / 3.x / 4.x (64-bit)"
UUID="8f1fabca-3e49-4432-b77a-4e776a5301c1"
CfgFile="/home/dmadmin/.minikube/machines/minikube/minikube/minikube.vbox"
SnapFldr="/home/dmadmin/.minikube/machines/minikube/minikube/Snapshots"
LogFldr="/home/dmadmin/.minikube/machines/minikube/minikube/Logs"
hardwareuuid="8f1fabca-3e49-4432-b77a-4e776a5301c1"
memory=975
pagefusion="off"
vram=8
cpuexecutioncap=100
hpet="on"
chipset="piix3"
firmware="BIOS"
cpus=2
pae="on"
longmode="on"
triplefaultreset="off"
apic="on"
x2apic="off"
cpuid-portability-level=0
bootmenu="disabled"
boot1="dvd"
boot2="dvd"
boot3="disk"
boot4="none"
acpi="on"
ioapic="on"
biosapic="apic"
biossystemtimeoffset=0
rtcuseutc="on"
hwvirtex="on"
nestedpaging="on"
largepages="on"
vtxvpid="on"
vtxux="on"
paravirtprovider="default"
effparavirtprovider="kvm"
VMState="aborted"
VMStateChangeTime="2020-04-15T15:06:24.000000000"
monitorcount=1
accelerate3d="off"
accelerate2dvideo="off"
teleporterenabled="off"
teleporterport=0
teleporteraddress=""
teleporterpassword=""
tracing-enabled="off"
tracing-allow-vm-access="off"
tracing-config=""
autostart-enabled="off"
autostart-delay=0
defaultfrontend=""
storagecontrollername0="SATA"
storagecontrollertype0="IntelAhci"
storagecontrollerinstance0="0"
storagecontrollermaxportcount0="30"
storagecontrollerportcount0="30"
storagecontrollerbootable0="on"
"SATA-0-0"="/home/dmadmin/.minikube/machines/minikube/boot2docker.iso"
"SATA-ImageUUID-0-0"="29fc1f32-c7a0-441a-bd3a-015656a59196"
"SATA-tempeject"="off"
"SATA-IsEjected"="off"
"SATA-1-0"="/home/dmadmin/.minikube/machines/minikube/disk.vmdk"
"SATA-ImageUUID-1-0"="ebe4b278-4e5f-4034-9ea4-b27bb9ea82b2"
"SATA-2-0"="none"
"SATA-3-0"="none"
"SATA-4-0"="none"
"SATA-5-0"="none"
"SATA-6-0"="none"
"SATA-7-0"="none"
"SATA-8-0"="none"
"SATA-9-0"="none"
"SATA-10-0"="none"
"SATA-11-0"="none"
"SATA-12-0"="none"
"SATA-13-0"="none"
"SATA-14-0"="none"
"SATA-15-0"="none"
"SATA-16-0"="none"
"SATA-17-0"="none"
"SATA-18-0"="none"
"SATA-19-0"="none"
"SATA-20-0"="none"
"SATA-21-0"="none"
"SATA-22-0"="none"
"SATA-23-0"="none"
"SATA-24-0"="none"
"SATA-25-0"="none"
"SATA-26-0"="none"
"SATA-27-0"="none"
"SATA-28-0"="none"
"SATA-29-0"="none"
natnet1="nat"
macaddress1="0800276F985F"
cableconnected1="on"
nic1="nat"
nictype1="virtio"
nicspeed1="0"
mtu="0"
sockSnd="64"
sockRcv="64"
tcpWndSnd="64"
tcpWndRcv="64"
Forwarding(0)="ssh,tcp,127.0.0.1,37006,,22"
hostonlyadapter2="vboxnet0"
macaddress2="0800278E816F"
cableconnected2="on"
nic2="hostonly"
nictype2="virtio"
nicspeed2="0"
nic3="none"
nic4="none"
nic5="none"
nic6="none"
nic7="none"
nic8="none"
hidpointing="ps2mouse"
hidkeyboard="ps2kbd"
uart1="off"
uart2="off"
uart3="off"
uart4="off"
lpt1="off"
lpt2="off"
audio="pulse"
clipboard="disabled"
draganddrop="disabled"
vrde="off"
usb="off"
ehci="off"
xhci="off"
SharedFolderNameMachineMapping1="hosthome"
SharedFolderPathMachineMapping1="/home"
vcpenabled="off"
vcpscreens=0
vcpfile="/home/dmadmin/.minikube/machines/minikube/minikube/minikube.webm"
vcpwidth=1024
vcpheight=768
vcprate=512
vcpfps=25
GuestMemoryBalloon=0
}
I0415 09:07:51.403576    6690 main.go:110] libmachine: STDERR:
{
}
I0415 09:07:51.404434    6690 main.go:110] libmachine: Check network to re-create if needed...
I0415 09:07:51.404911    6690 main.go:110] libmachine: COMMAND: /usr/bin/VBoxManage list hostonlyifs
I0415 09:07:51.640095    6690 main.go:110] libmachine: STDOUT:
{
Name:            vboxnet0
GUID:            786f6276-656e-4074-8000-0a0027000000
DHCP:            Disabled
IPAddress:       192.168.99.1
NetworkMask:     255.255.255.0
IPV6Address:     fe80:0000:0000:0000:0800:27ff:fe00:0000
IPV6NetworkMaskPrefixLength: 64
HardwareAddress: 0a:00:27:00:00:00
MediumType:      Ethernet
Status:          Up
VBoxNetworkName: HostInterfaceNetworking-vboxnet0

}
I0415 09:07:51.642434    6690 main.go:110] libmachine: STDERR:
{
}
I0415 09:07:51.645615    6690 main.go:110] libmachine: Searching for hostonly interface for IPv4: 192.168.99.1 and Mask: ffffff00
I0415 09:07:51.645938    6690 main.go:110] libmachine: Found: vboxnet0
I0415 09:07:51.646130    6690 main.go:110] libmachine: COMMAND: /usr/bin/VBoxManage list dhcpservers
I0415 09:07:51.908725    6690 main.go:110] libmachine: STDOUT:
{
NetworkName:    HostInterfaceNetworking-vboxnet0
IP:             192.168.99.16
NetworkMask:    255.255.255.0
lowerIPAddress: 192.168.99.100
upperIPAddress: 192.168.99.254
Enabled:        Yes

}
I0415 09:07:51.910338    6690 main.go:110] libmachine: STDERR:
{
}
I0415 09:07:51.910859    6690 main.go:110] libmachine: Removing orphan DHCP servers...
I0415 09:07:51.911125    6690 main.go:110] libmachine: COMMAND: /usr/bin/VBoxManage list hostonlyifs
I0415 09:07:52.144317    6690 main.go:110] libmachine: STDOUT:
{
Name:            vboxnet0
GUID:            786f6276-656e-4074-8000-0a0027000000
DHCP:            Disabled
IPAddress:       192.168.99.1
NetworkMask:     255.255.255.0
IPV6Address:     fe80:0000:0000:0000:0800:27ff:fe00:0000
IPV6NetworkMaskPrefixLength: 64
HardwareAddress: 0a:00:27:00:00:00
MediumType:      Ethernet
Status:          Up
VBoxNetworkName: HostInterfaceNetworking-vboxnet0

}
I0415 09:07:52.146652    6690 main.go:110] libmachine: STDERR:
{
}
I0415 09:07:52.146976    6690 main.go:110] libmachine: Adding/Modifying DHCP server "192.168.99.20" with address range "192.168.99.100" - "192.168.99.254"...
I0415 09:07:52.147088    6690 main.go:110] libmachine: COMMAND: /usr/bin/VBoxManage list dhcpservers
I0415 09:07:52.343840    6690 main.go:110] libmachine: STDOUT:
{
NetworkName:    HostInterfaceNetworking-vboxnet0
IP:             192.168.99.16
NetworkMask:    255.255.255.0
lowerIPAddress: 192.168.99.100
upperIPAddress: 192.168.99.254
Enabled:        Yes

}
I0415 09:07:52.345445    6690 main.go:110] libmachine: STDERR:
{
}
I0415 09:07:52.346179    6690 main.go:110] libmachine: COMMAND: /usr/bin/VBoxManage dhcpserver modify --netname HostInterfaceNetworking-vboxnet0 --ip 192.168.99.20 --netmask 255.255.255.0 --lowerip 192.168.99.100 --upperip 192.168.99.254 --enable
I0415 09:07:52.561113    6690 main.go:110] libmachine: STDOUT:
{
}
I0415 09:07:52.562220    6690 main.go:110] libmachine: STDERR:
{
}
I0415 09:07:52.563274    6690 main.go:110] libmachine: COMMAND: /usr/bin/VBoxManage modifyvm minikube --nic2 hostonly --nictype2 virtio --nicpromisc2 deny --hostonlyadapter2 vboxnet0 --cableconnected2 on
I0415 09:07:52.763800    6690 main.go:110] libmachine: STDOUT:
{
}
I0415 09:07:52.765174    6690 main.go:110] libmachine: STDERR:
{
}
I0415 09:07:52.766550    6690 main.go:110] libmachine: COMMAND: /usr/bin/VBoxManage modifyvm minikube --natpf1 delete ssh
I0415 09:07:52.986127    6690 main.go:110] libmachine: STDOUT:
{
}
I0415 09:07:52.986634    6690 main.go:110] libmachine: STDERR:
{
}
I0415 09:07:52.986986    6690 main.go:110] libmachine: COMMAND: /usr/bin/VBoxManage modifyvm minikube --natpf1 ssh,tcp,127.0.0.1,46812,,22
I0415 09:07:53.173212    6690 main.go:110] libmachine: STDOUT:
{
}
I0415 09:07:53.174240    6690 main.go:110] libmachine: STDERR:
{
}
I0415 09:07:53.175120    6690 main.go:110] libmachine: COMMAND: /usr/bin/VBoxManage startvm minikube --type headless
I0415 09:07:55.092757    6690 main.go:110] libmachine: STDOUT:
{
Waiting for VM "minikube" to power on...
VM "minikube" has been successfully started.
}
I0415 09:07:55.098521    6690 main.go:110] libmachine: STDERR:
{
}
I0415 09:07:55.099223    6690 main.go:110] libmachine: Checking vm logs: /home/dmadmin/.minikube/machines/minikube/minikube/Logs/VBox.log
I0415 09:07:55.101765    6690 main.go:110] libmachine: Waiting for an IP...
I0415 09:07:55.109789    6690 main.go:110] libmachine: Getting to WaitForSSH function...
I0415 09:07:55.110288    6690 main.go:110] libmachine: Using SSH client type: native
I0415 09:07:55.129975    6690 main.go:110] libmachine: &{{{<nil> 0 [] [] []} docker [0x7bf5d0] 0x7bf5a0 <nil>  [] 0s} 127.0.0.1 46812 <nil> <nil>}
I0415 09:07:55.130161    6690 main.go:110] libmachine: About to run SSH command:
exit 0
I0415 09:08:49.981257    6690 main.go:110] libmachine: Error dialing TCP: ssh: handshake failed: read tcp 127.0.0.1:33692->127.0.0.1:46812: read: connection reset by peer
I0415 09:08:53.049661    6690 main.go:110] libmachine: Error dialing TCP: dial tcp 127.0.0.1:46812: connect: connection refused
I0415 09:08:56.055373    6690 main.go:110] libmachine: Error dialing TCP: dial tcp 127.0.0.1:46812: connect: connection refused
I0415 09:08:59.057578    6690 main.go:110] libmachine: Error dialing TCP: dial tcp 127.0.0.1:46812: connect: connection refused
I0415 09:09:02.062116    6690 main.go:110] libmachine: Error dialing TCP: dial tcp 127.0.0.1:46812: connect: connection refused
I0415 09:09:05.097940    6690 main.go:110] libmachine: Error dialing TCP: dial tcp 127.0.0.1:46812: connect: connection refused
I0415 09:09:08.241149    6690 main.go:110] libmachine: Error dialing TCP: dial tcp 127.0.0.1:46812: connect: connection refused
I0415 09:09:11.339157    6690 main.go:110] libmachine: Error dialing TCP: dial tcp 127.0.0.1:46812: connect: connection refused
I0415 09:09:14.343977    6690 main.go:110] libmachine: Error dialing TCP: dial tcp 127.0.0.1:46812: connect: connection refused
I0415 09:09:17.389770    6690 main.go:110] libmachine: Error dialing TCP: dial tcp 127.0.0.1:46812: connect: connection refused
I0415 09:09:20.398748    6690 main.go:110] libmachine: Error dialing TCP: dial tcp 127.0.0.1:46812: connect: connection refused
I0415 09:09:23.403560    6690 main.go:110] libmachine: Error dialing TCP: dial tcp 127.0.0.1:46812: connect: connection refused
I0415 09:09:26.405182    6690 main.go:110] libmachine: Error dialing TCP: dial tcp 127.0.0.1:46812: connect: connection refused
I0415 09:09:29.409720    6690 main.go:110] libmachine: Error dialing TCP: dial tcp 127.0.0.1:46812: connect: connection refused
I0415 09:09:32.411414    6690 main.go:110] libmachine: Error dialing TCP: dial tcp 127.0.0.1:46812: connect: connection refused
I0415 09:09:35.412911    6690 main.go:110] libmachine: Error dialing TCP: dial tcp 127.0.0.1:46812: connect: connection refused
I0415 09:09:38.413916    6690 main.go:110] libmachine: Error dialing TCP: dial tcp 127.0.0.1:46812: connect: connection refused
I0415 09:09:41.415842    6690 main.go:110] libmachine: Error dialing TCP: dial tcp 127.0.0.1:46812: connect: connection refused
I0415 09:09:44.420495    6690 main.go:110] libmachine: Error dialing TCP: dial tcp 127.0.0.1:46812: connect: connection refused
I0415 09:09:47.426861    6690 main.go:110] libmachine: Error dialing TCP: dial tcp 127.0.0.1:46812: connect: connection refused
I0415 09:09:50.480203    6690 main.go:110] libmachine: Error dialing TCP: dial tcp 127.0.0.1:46812: connect: connection refused
I0415 09:09:53.485949    6690 main.go:110] libmachine: Error dialing TCP: dial tcp 127.0.0.1:46812: connect: connection refused
I0415 09:09:56.487655    6690 main.go:110] libmachine: Error dialing TCP: dial tcp 127.0.0.1:46812: connect: connection refused
I0415 09:09:59.489116    6690 main.go:110] libmachine: Error dialing TCP: dial tcp 127.0.0.1:46812: connect: connection refused
I0415 09:10:02.490132    6690 main.go:110] libmachine: Error dialing TCP: dial tcp 127.0.0.1:46812: connect: connection refused
I0415 09:10:05.491653    6690 main.go:110] libmachine: Error dialing TCP: dial tcp 127.0.0.1:46812: connect: connection refused
I0415 09:10:08.493445    6690 main.go:110] libmachine: Error dialing TCP: dial tcp 127.0.0.1:46812: connect: connection refused
I0415 09:10:11.495231    6690 main.go:110] libmachine: Error dialing TCP: dial tcp 127.0.0.1:46812: connect: connection refused
I0415 09:10:14.496977    6690 main.go:110] libmachine: Error dialing TCP: dial tcp 127.0.0.1:46812: connect: connection refused
I0415 09:10:17.498635    6690 main.go:110] libmachine: Error dialing TCP: dial tcp 127.0.0.1:46812: connect: connection refused
^C

@priyawadhwa priyawadhwa added the kind/support Categorizes issue or PR as a support question. label Apr 15, 2020
@tstromberg tstromberg changed the title virtualbox: creating: Maximum number of retries (5) exceeded virtualbo fails to start: Error dialing TCP: dial tcp 127.0.0.1:x: connect: connection refused Apr 15, 2020
@tstromberg
Copy link
Contributor

Just curious: It's unlikely, but does minikube delete fix the problem?

Basically, the VM appears to come up, but the port-forward to SSH doesn't seem to work.

@tstromberg tstromberg added the triage/needs-information Indicates an issue needs more information in order to work on it. label Apr 15, 2020
@jyobeer
Copy link
Author

jyobeer commented Apr 16, 2020

Nope. Still the same issue

@tstromberg tstromberg changed the title virtualbo fails to start: Error dialing TCP: dial tcp 127.0.0.1:x: connect: connection refused virtualbox: Error dialing TCP: dial tcp 127.0.0.1:x: connect: connection refused Apr 16, 2020
@tstromberg
Copy link
Contributor

Thank you!

Are you running minikube from inside of a VM? I ask because VirtualBox can have strange networking problems in a nested VM environment. If you are running minikube within a VM, I strongly recommend using --driver=docker instead.

If this is a physical machine running VirtualBox, upgrade to the latest VirtualBox 6.1.6, and if it has issues, please run the following commands:

VBoxManage controlvm minikube acpipowerbutton \
  && sleep 10 \
  &&  VBoxManage startvm minikube

Confirm that the VM boots up and results in a screen that shows a login prompt that says:

Welcome to minikube
minikube login:

example screenshot

If things look correct, please share the output of the following command:

  • VBoxManage showvminfo minikube | grep NIC

I'm specifically looking for a NIC rule like:

NIC 1:                       MAC: 08002708E9B7, Attachment: NAT, Cable connected: on, Trace: off (file: none), Type: virtio, Reported speed: 0 Mbps, Boot priority: 0, Promisc Policy: deny, Bandwidth group: none
NIC 1 Settings:  MTU: 0, Socket (send: 64, receive: 64), TCP Window (send:64, receive: 64)
NIC 1 Rule(0):   name = ssh, protocol = tcp, host ip = 127.0.0.1, host port = 61230, guest ip = , guest port = 22

Using the host port mentioned here, please share the output of:

nc -w1 -vvv localhost <port>
nc: connectx to localhost port 61230 (tcp) failed: Connection refused
Connection to localhost port 61230 [tcp/*] succeeded!
SSH-2.0-OpenSSH_7.9

I look forward to your reply, as I would like to update this error message to point to this conversation once we've come to a solution.

@jyobeer
Copy link
Author

jyobeer commented Apr 16, 2020

Yes am running a ubuntu VM and trying to run minikube from inside the ubuntu VM.
For --driver=docker, do i need to install docker after kubectl and minikube and then try?

@tstromberg
Copy link
Contributor

@jyobeer - Yes. Install Docker inside the VM: https://docs.docker.com/engine/install/ubuntu/

For more information about the Docker driver, see: https://minikube.sigs.k8s.io/docs/drivers/docker/

@tstromberg tstromberg added the needs-solution-message Issues where where offering a solution for an error would be helpful label Apr 16, 2020
@jyobeer
Copy link
Author

jyobeer commented Apr 17, 2020

I installed docker and then tried minikube start --driver=docker but it still fails -

dmadmin@ubuntu:~$ minikube start --driver=docker
πŸ˜„ minikube v1.9.2 on Ubuntu 16.04
✨ Using the docker driver based on user configuration

❗ 'docker' driver reported an issue: exit status 1
πŸ’‘ Suggestion: Docker is not running or is responding too slow. Try: restarting docker desktop.

πŸ‘ Starting control plane node m01 in cluster minikube
🚜 Pulling base image ...
E0416 22:06:06.166038 20919 cache.go:114] Error downloading kic artifacts: error loading image: Got permission denied while trying to connect to the Docker daemon socket at unix:///var/run/docker.sock: Post http://%2Fvar%2Frun%2Fdocker.sock/v1.24/images/load?quiet=0: dial unix /var/run/docker.sock: connect: permission denied
πŸ”₯ Creating Kubernetes in docker container with (CPUs=2) (0 available), Memory=975MB (0MB available) ...
🀦 StartHost failed, but will try again: creating host: create: creating: create kic node: creating volume for minikube container: output Got permission denied while trying to connect to the Docker daemon socket at unix:///var/run/docker.sock: Post http://%2Fvar%2Frun%2Fdocker.sock/v1.40/volumes/create: dial unix /var/run/docker.sock: connect: permission denied
: exit status 1
🀷 docker "minikube" container is missing, will recreate.
πŸ”₯ Creating Kubernetes in docker container with (CPUs=2) (0 available), Memory=975MB (0MB available) ...

πŸ’£ Failed to start docker container. "minikube start" may fix it.: recreate: creating host: create: creating: create kic node: creating volume for minikube container: output Got permission denied while trying to connect to the Docker daemon socket at unix:///var/run/docker.sock: Post http://%2Fvar%2Frun%2Fdocker.sock/v1.40/volumes/create: dial unix /var/run/docker.sock: connect: permission denied
: exit status 1

😿 minikube is exiting due to an error. If the above message is not useful, open an issue:
πŸ‘‰ https://github.com/kubernetes/minikube/issues/new/choose

@medyagh
Copy link
Member

medyagh commented Apr 17, 2020

@jyobeer
seems like u need to add your user to the docker user

unix:///var/run/docker.sock: Post http://%2Fvar%2Frun%2Fdocker.sock/v1.40/volumes/create: dial unix /var/run/docker.sock: connect: permission denied

  sudo usermod -aG docker your-user

here is the link to docker site how to add user to docker group
https://docs.docker.com/engine/install/ubuntu/#installation-methods

@medyagh medyagh added the priority/important-longterm Important over the long term, but may not be staffed and/or may need multiple releases to complete. label Apr 17, 2020
@medyagh
Copy link
Member

medyagh commented Apr 17, 2020

we could add a message in minikube if we detect this to direct user to add user permission

@jyobeer
Copy link
Author

jyobeer commented Apr 19, 2020

added the user to the group but still receiving the same error. Any other pointers please?

@tstromberg
Copy link
Contributor

@jyobeer - Can you share the output of:

  • groups
  • stat /var/run/docker.sock

I personally suspect that running logging out or running newgrp docker and then minikube start will fix the issue for you.

@tstromberg tstromberg removed the priority/important-longterm Important over the long term, but may not be staffed and/or may need multiple releases to complete. label Apr 20, 2020
@jyobeer
Copy link
Author

jyobeer commented Apr 20, 2020

@tstromberg please find below the output -

  • groups
    dmadmin adm cdrom sudo dip plugdev lpadmin sambashare docker

  • stat /var/run/docker.sock
    File: '/var/run/docker.sock'
    Size: 0 Blocks: 0 IO Block: 4096 socket
    Device: 12h/18d Inode: 433 Links: 1
    Access: (0660/srw-rw----) Uid: ( 0/ root) Gid: ( 999/ docker)
    Access: 2020-04-19 21:31:53.167999973 -0700
    Modify: 2020-04-19 21:31:53.167999973 -0700
    Change: 2020-04-19 21:31:53.171999973 -0700
    Birth: -

@priyawadhwa
Copy link

Hey @jyobeer that output looks correct to me.

Can you rundocker run hello-world successfully, or does only sudo docker run hello-world work?

If you need sudo, you could try following the docker instructions for running as a non-root user:

https://docs.docker.com/engine/install/linux-postinstall/#manage-docker-as-a-non-root-user

@priyawadhwa
Copy link

Hey @jyobeer any update here?

@priyawadhwa
Copy link

Hey @jyobeer -- hopefully it's OK if I close this - there wasn't enough information to make it actionable, and some time has already passed. If you are able to provide additional details, you may reopen it at any point by adding /reopen to your comment.

Thank you for sharing your experience!

@shengzhou1216
Copy link

Still the same issue.

groups

sheng root adm cdrom sudo dip plugdev lpadmin lxd sambashare mysql microk8s docker

stat /var/run/docker.sock

  File: /var/run/docker.sock
  Size: 0         	Blocks: 0          IO Block: 4096   socket
Device: 19h/25d	Inode: 1614        Links: 1
Access: (0660/srw-rw----)  Uid: (    0/    root)   Gid: (  998/  docker)
Access: 2022-03-08 12:31:53.034622311 +0800
Modify: 2022-03-08 12:30:32.418308361 +0800
Change: 2022-03-08 12:30:32.418308361 +0800

docker run hello-world

docker run hello-world                                                                                                                           at ο€— 13:54:16
Unable to find image 'hello-world:latest' locally
latest: Pulling from library/hello-world
2db29710123e: Pull complete 
Digest: sha256:97a379f4f88575512824f3b352bc03cd75e239179eea0fecc38e597b2209f49a
Status: Downloaded newer image for hello-world:latest

Hello from Docker!
This message shows that your installation appears to be working correctly.

To generate this message, Docker took the following steps:
 1. The Docker client contacted the Docker daemon.
 2. The Docker daemon pulled the "hello-world" image from the Docker Hub.
    (amd64)
 3. The Docker daemon created a new container from that image which runs the
    executable that produces the output you are currently reading.
 4. The Docker daemon streamed that output to the Docker client, which sent it
    to your terminal.

To try something more ambitious, you can run an Ubuntu container with:
 $ docker run -it ubuntu bash

Share images, automate workflows, and more with a free Docker ID:
 https://hub.docker.com/

For more examples and ideas, visit:
 https://docs.docker.com/get-started/

error info:

I0308 13:59:21.358186   96644 main.go:130] libmachine: Error dialing TCP: dial tcp 127.0.0.1:32878: connect: connection refused
- I0308 13:59:24.358851   96644 main.go:130] libmachine: Error dialing TCP: dial tcp 127.0.0.1:32878: connect: connection refused
| I0308 13:59:27.359263   96644 main.go:130] libmachine: Error dialing TCP: dial tcp 127.0.0.1:32878: connect: connection refused
- I0308 13:59:30.360111   96644 main.go:130] libmachine: Error dialing TCP: dial tcp 127.0.0.1:32878: connect: connection refused
| I0308 13:59:33.360557   96644 main.go:130] libmachine: Error dialing TCP: dial tcp 127.0.0.1:32878: connect: connection refused
- I0308 13:59:36.361059   96644 main.go:130] libmachine: Error dialing TCP: dial tcp 127.0.0.1:32878: connect: connection refused

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/support Categorizes issue or PR as a support question. needs-solution-message Issues where where offering a solution for an error would be helpful triage/needs-information Indicates an issue needs more information in order to work on it.
Projects
None yet
Development

No branches or pull requests

5 participants