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

Panic error on Windows Server 2022 running on a VM #137

Closed
ntilagoa opened this issue Jan 24, 2024 · 13 comments
Closed

Panic error on Windows Server 2022 running on a VM #137

ntilagoa opened this issue Jan 24, 2024 · 13 comments

Comments

@ntilagoa
Copy link

With label dns:v2.0.0-beta do not run. It gives error "panic: runtime error: index out of range [0] with length 0

@ntilagoa
Copy link
Author

ntilagoa commented Jan 24, 2024

Logs:

2024-01-24 14:34:01 ========================================
2024-01-24 14:34:01 ========================================
2024-01-24 14:34:01 ================= dns ==================
2024-01-24 14:34:01 ========================================
2024-01-24 14:34:01 =========== Made with ❤️ by ============
2024-01-24 14:34:01 ======= https://github.com/qdm12 =======
2024-01-24 14:34:01 ========================================
2024-01-24 14:34:01 ========================================
2024-01-24 14:34:01 
2024-01-24 14:34:01 Running version v2.0.0-beta built on 2024-01-03T20:25:41.307Z (commit 51ea21d)
2024-01-24 14:34:01 
2024-01-24 14:34:01 🔧 Need help? https://github.com/qdm12/dns/discussions/new
2024-01-24 14:34:01 🐛 Bug? https://github.com/qdm12/dns/issues/new
2024-01-24 14:34:01 ✨ New feature? https://github.com/qdm12/dns/issues/new
2024-01-24 14:34:01 ☕ Discussion? https://github.com/qdm12/dns/discussions/new
2024-01-24 14:34:01 💻 Email? quentin.mcgaw@gmail.com
2024-01-24 14:34:01 💰 Help me? https://www.paypal.me/qmcgaw https://github.com/sponsors/qdm12
2024-01-24 14:34:01 panic: runtime error: index out of range [0] with length 0

@ntilagoa
Copy link
Author

ntilagoa commented Jan 24, 2024

Inspect:

{
	"Id": "7da4abf91d943bbfa442af9cfd2eee90f98fabc0b3e41646c415a015f09d598c",
	"Created": "2024-01-24T14:33:59.752571321Z",
	"Path": "/entrypoint",
	"Args": [],
	"State": {
		"Status": "exited",
		"Running": false,
		"Paused": false,
		"Restarting": false,
		"OOMKilled": false,
		"Dead": false,
		"Pid": 0,
		"ExitCode": 2,
		"Error": "",
		"StartedAt": "2024-01-24T15:13:13.736330967Z",
		"FinishedAt": "2024-01-24T15:13:13.940955638Z",
		"Health": {
			"Status": "unhealthy",
			"FailingStreak": 0,
			"Log": []
		}
	},
	"Image": "sha256:4f68558837123aafea0d51a044fa486c7a16eebd256d5fbdeb56e025a3c36b86",
	"ResolvConfPath": "/var/lib/docker/containers/7da4abf91d943bbfa442af9cfd2eee90f98fabc0b3e41646c415a015f09d598c/resolv.conf",
	"HostnamePath": "/var/lib/docker/containers/7da4abf91d943bbfa442af9cfd2eee90f98fabc0b3e41646c415a015f09d598c/hostname",
	"HostsPath": "/var/lib/docker/containers/7da4abf91d943bbfa442af9cfd2eee90f98fabc0b3e41646c415a015f09d598c/hosts",
	"LogPath": "/var/lib/docker/containers/7da4abf91d943bbfa442af9cfd2eee90f98fabc0b3e41646c415a015f09d598c/7da4abf91d943bbfa442af9cfd2eee90f98fabc0b3e41646c415a015f09d598c-json.log",
	"Name": "/quizzical_kapitsa",
	"RestartCount": 0,
	"Driver": "overlay2",
	"Platform": "linux",
	"MountLabel": "",
	"ProcessLabel": "",
	"AppArmorProfile": "",
	"ExecIDs": null,
	"HostConfig": {
		"Binds": null,
		"ContainerIDFile": "",
		"LogConfig": {
			"Type": "json-file",
			"Config": {}
		},
		"NetworkMode": "default",
		"PortBindings": {
			"53/tcp": [
				{
					"HostIp": "",
					"HostPort": "53"
				}
			],
			"53/udp": [
				{
					"HostIp": "",
					"HostPort": "53"
				}
			]
		},
		"RestartPolicy": {
			"Name": "no",
			"MaximumRetryCount": 0
		},
		"AutoRemove": false,
		"VolumeDriver": "",
		"VolumesFrom": null,
		"ConsoleSize": [
			50,
			120
		],
		"CapAdd": null,
		"CapDrop": null,
		"CgroupnsMode": "host",
		"Dns": [],
		"DnsOptions": [],
		"DnsSearch": [],
		"ExtraHosts": null,
		"GroupAdd": null,
		"IpcMode": "private",
		"Cgroup": "",
		"Links": null,
		"OomScoreAdj": 0,
		"PidMode": "",
		"Privileged": false,
		"PublishAllPorts": false,
		"ReadonlyRootfs": false,
		"SecurityOpt": null,
		"UTSMode": "",
		"UsernsMode": "",
		"ShmSize": 67108864,
		"Runtime": "runc",
		"Isolation": "",
		"CpuShares": 0,
		"Memory": 0,
		"NanoCpus": 0,
		"CgroupParent": "",
		"BlkioWeight": 0,
		"BlkioWeightDevice": [],
		"BlkioDeviceReadBps": [],
		"BlkioDeviceWriteBps": [],
		"BlkioDeviceReadIOps": [],
		"BlkioDeviceWriteIOps": [],
		"CpuPeriod": 0,
		"CpuQuota": 0,
		"CpuRealtimePeriod": 0,
		"CpuRealtimeRuntime": 0,
		"CpusetCpus": "",
		"CpusetMems": "",
		"Devices": [],
		"DeviceCgroupRules": null,
		"DeviceRequests": null,
		"MemoryReservation": 0,
		"MemorySwap": 0,
		"MemorySwappiness": null,
		"OomKillDisable": false,
		"PidsLimit": null,
		"Ulimits": null,
		"CpuCount": 0,
		"CpuPercent": 0,
		"IOMaximumIOps": 0,
		"IOMaximumBandwidth": 0,
		"MaskedPaths": [
			"/proc/asound",
			"/proc/acpi",
			"/proc/kcore",
			"/proc/keys",
			"/proc/latency_stats",
			"/proc/timer_list",
			"/proc/timer_stats",
			"/proc/sched_debug",
			"/proc/scsi",
			"/sys/firmware",
			"/sys/devices/virtual/powercap"
		],
		"ReadonlyPaths": [
			"/proc/bus",
			"/proc/fs",
			"/proc/irq",
			"/proc/sys",
			"/proc/sysrq-trigger"
		]
	},
	"GraphDriver": {
		"Data": {
			"LowerDir": "/var/lib/docker/overlay2/acb29b9e6d44bc28099ce81229a690a54f6c2b5b6768731faadb63aa2061eced-init/diff:/var/lib/docker/overlay2/ff0f6efc2e4846fdded47a1a3f2cee2c3929efaf0958fe2038e93bd0a173243e/diff",
			"MergedDir": "/var/lib/docker/overlay2/acb29b9e6d44bc28099ce81229a690a54f6c2b5b6768731faadb63aa2061eced/merged",
			"UpperDir": "/var/lib/docker/overlay2/acb29b9e6d44bc28099ce81229a690a54f6c2b5b6768731faadb63aa2061eced/diff",
			"WorkDir": "/var/lib/docker/overlay2/acb29b9e6d44bc28099ce81229a690a54f6c2b5b6768731faadb63aa2061eced/work"
		},
		"Name": "overlay2"
	},
	"Mounts": [],
	"Config": {
		"Hostname": "7da4abf91d94",
		"Domainname": "",
		"User": "1000",
		"AttachStdin": false,
		"AttachStdout": false,
		"AttachStderr": false,
		"ExposedPorts": {
			"53/tcp": {},
			"53/udp": {}
		},
		"Tty": false,
		"OpenStdin": false,
		"StdinOnce": false,
		"Env": [
			"PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin",
			"UPSTREAM_TYPE=DoT",
			"DOT_RESOLVERS=cloudflare,google",
			"DOH_RESOLVERS=cloudflare,google",
			"DOT_TIMEOUT=3s",
			"DOH_TIMEOUT=3s",
			"LISTENING_ADDRESS=:53",
			"LOG_LEVEL=info",
			"MIDDLEWARE_LOG_ENABLED=off",
			"MIDDLEWARE_LOG_DIRECTORY=/var/log/dns/",
			"MIDDLEWARE_LOG_REQUESTS=on",
			"MIDDLEWARE_LOG_RESPONSES=off",
			"MIDDLEWARE_LOCALDNS_ENABLED=on",
			"MIDDLEWARE_LOCALDNS_RESOLVERS=",
			"CACHE_TYPE=lru",
			"CACHE_LRU_MAX_ENTRIES=10000",
			"BLOCK_MALICIOUS=on",
			"BLOCK_SURVEILLANCE=off",
			"BLOCK_ADS=off",
			"BLOCK_IPS=",
			"BLOCK_CIDRS=",
			"BLOCK_HOSTNAMES=",
			"ALLOWED_HOSTNAMES=",
			"ALLOWED_IPS=",
			"ALLOWED_CIDRS=",
			"METRICS_TYPE=noop",
			"METRICS_PROMETHEUS_ADDRESS=:9090",
			"METRICS_PROMETHEUS_SUBSYSTEM=dns",
			"CHECK_DNS=on",
			"UPDATE_PERIOD=24h"
		],
		"Cmd": null,
		"Healthcheck": {
			"Test": [
				"CMD",
				"/entrypoint",
				"healthcheck"
			],
			"Interval": 300000000000,
			"Timeout": 15000000000,
			"StartPeriod": 5000000000,
			"Retries": 1
		},
		"Image": "qmcgaw/dns:v2.0.0-beta",
		"Volumes": null,
		"WorkingDir": "/",
		"Entrypoint": [
			"/entrypoint"
		],
		"OnBuild": null,
		"Labels": {
			"org.opencontainers.image.authors": "quentin.mcgaw@gmail.com",
			"org.opencontainers.image.created": "2024-01-03T20:25:41.307Z",
			"org.opencontainers.image.description": "Docker DNS server on steroids to access DNS-over-TLS from Cloudflare, Google, Quad9, Quadrant or CleanBrowsing",
			"org.opencontainers.image.documentation": "https://github.com/qdm12/dns/blob/master/README.md",
			"org.opencontainers.image.licenses": "MIT",
			"org.opencontainers.image.revision": "51ea21dfa10dee4773beb08600febe0d059184f2",
			"org.opencontainers.image.source": "https://github.com/qdm12/dns",
			"org.opencontainers.image.title": "dns",
			"org.opencontainers.image.url": "https://github.com/qdm12/dns",
			"org.opencontainers.image.version": "v2.0.0-beta"
		}
	},
	"NetworkSettings": {
		"Bridge": "",
		"SandboxID": "25ebc6db8a9ca0dcbc9ace419083c769c2e8c985c7bb5656d86b37cd08e1a8a4",
		"HairpinMode": false,
		"LinkLocalIPv6Address": "",
		"LinkLocalIPv6PrefixLen": 0,
		"Ports": {},
		"SandboxKey": "/var/run/docker/netns/25ebc6db8a9c",
		"SecondaryIPAddresses": null,
		"SecondaryIPv6Addresses": null,
		"EndpointID": "",
		"Gateway": "",
		"GlobalIPv6Address": "",
		"GlobalIPv6PrefixLen": 0,
		"IPAddress": "",
		"IPPrefixLen": 0,
		"IPv6Gateway": "",
		"MacAddress": "",
		"Networks": {
			"bridge": {
				"IPAMConfig": null,
				"Links": null,
				"Aliases": null,
				"MacAddress": "",
				"NetworkID": "675738a2ac17d64a69892016c383b4a243a03e8367ef9e9c4a322fa52acb1304",
				"EndpointID": "",
				"Gateway": "",
				"IPAddress": "",
				"IPPrefixLen": 0,
				"IPv6Gateway": "",
				"GlobalIPv6Address": "",
				"GlobalIPv6PrefixLen": 0,
				"DriverOpts": null
			}
		}
	}
}

@ntilagoa
Copy link
Author

ntilagoa commented Jan 24, 2024

"Sure, just pasting the panic stack trace would help" - Sorry I don't know how to do this. Any help, appreciate.

@qdm12
Copy link
Owner

qdm12 commented Jan 24, 2024

The log just stops at panic: runtime error: index out of range [0] with length 0? That's strange, usually there is a "stack trace" after it (showing source file and line number where the panic happened). Would you please re-run it with LOG_CALLER=short so that the source code file and line number will show for every log lines? Thanks!!

@ntilagoa
Copy link
Author

ntilagoa commented Jan 24, 2024

Just stops here:

2024-01-24 17:25:49 panic: runtime error: index out of range [0] with length 0
2024-01-24 17:25:49 ========================================
2024-01-24 17:25:49 ========================================
2024-01-24 17:25:49 ================= dns ==================
2024-01-24 17:25:49 ========================================
2024-01-24 17:25:49 =========== Made with ❤️ by ============
2024-01-24 17:25:49 ======= https://github.com/qdm12 =======
2024-01-24 17:25:49 ========================================
2024-01-24 17:25:49 ========================================
2024-01-24 17:25:49 
2024-01-24 17:25:49 Running version v2.0.0-beta built on 2024-01-03T20:25:41.307Z (commit 51ea21d)
2024-01-24 17:25:49 
2024-01-24 17:25:49 🔧 Need help? https://github.com/qdm12/dns/discussions/new
2024-01-24 17:25:49 🐛 Bug? https://github.com/qdm12/dns/issues/new
2024-01-24 17:25:49 ✨ New feature? https://github.com/qdm12/dns/issues/new
2024-01-24 17:25:49 ☕ Discussion? https://github.com/qdm12/dns/discussions/new
2024-01-24 17:25:49 💻 Email? quentin.mcgaw@gmail.com
2024-01-24 17:25:49 💰 Help me? https://www.paypal.me/qmcgaw https://github.com/sponsors/qdm12

@ntilagoa
Copy link
Author

ntilagoa commented Jan 24, 2024

Inspect:

{
	"Id": "b76b10ea0232bba9e62627a14c660421af5f1cf672ac8f7c29ef1edcb61e3492",
	"Created": "2024-01-24T17:25:48.009510259Z",
	"Path": "/entrypoint",
	"Args": [],
	"State": {
		"Status": "exited",
		"Running": false,
		"Paused": false,
		"Restarting": false,
		"OOMKilled": false,
		"Dead": false,
		"Pid": 0,
		"ExitCode": 2,
		"Error": "",
		"StartedAt": "2024-01-24T17:25:48.938756722Z",
		"FinishedAt": "2024-01-24T17:25:49.052590905Z",
		"Health": {
			"Status": "unhealthy",
			"FailingStreak": 0,
			"Log": []
		}
	},
	"Image": "sha256:4f68558837123aafea0d51a044fa486c7a16eebd256d5fbdeb56e025a3c36b86",
	"ResolvConfPath": "/var/lib/docker/containers/b76b10ea0232bba9e62627a14c660421af5f1cf672ac8f7c29ef1edcb61e3492/resolv.conf",
	"HostnamePath": "/var/lib/docker/containers/b76b10ea0232bba9e62627a14c660421af5f1cf672ac8f7c29ef1edcb61e3492/hostname",
	"HostsPath": "/var/lib/docker/containers/b76b10ea0232bba9e62627a14c660421af5f1cf672ac8f7c29ef1edcb61e3492/hosts",
	"LogPath": "/var/lib/docker/containers/b76b10ea0232bba9e62627a14c660421af5f1cf672ac8f7c29ef1edcb61e3492/b76b10ea0232bba9e62627a14c660421af5f1cf672ac8f7c29ef1edcb61e3492-json.log",
	"Name": "/hungry_ishizaka",
	"RestartCount": 0,
	"Driver": "overlay2",
	"Platform": "linux",
	"MountLabel": "",
	"ProcessLabel": "",
	"AppArmorProfile": "",
	"ExecIDs": null,
	"HostConfig": {
		"Binds": null,
		"ContainerIDFile": "",
		"LogConfig": {
			"Type": "json-file",
			"Config": {}
		},
		"NetworkMode": "default",
		"PortBindings": {
			"53/tcp": [
				{
					"HostIp": "",
					"HostPort": "53"
				}
			],
			"53/udp": [
				{
					"HostIp": "",
					"HostPort": "53"
				}
			]
		},
		"RestartPolicy": {
			"Name": "no",
			"MaximumRetryCount": 0
		},
		"AutoRemove": false,
		"VolumeDriver": "",
		"VolumesFrom": null,
		"ConsoleSize": [
			50,
			120
		],
		"CapAdd": null,
		"CapDrop": null,
		"CgroupnsMode": "host",
		"Dns": [],
		"DnsOptions": [],
		"DnsSearch": [],
		"ExtraHosts": null,
		"GroupAdd": null,
		"IpcMode": "private",
		"Cgroup": "",
		"Links": null,
		"OomScoreAdj": 0,
		"PidMode": "",
		"Privileged": false,
		"PublishAllPorts": false,
		"ReadonlyRootfs": false,
		"SecurityOpt": null,
		"UTSMode": "",
		"UsernsMode": "",
		"ShmSize": 67108864,
		"Runtime": "runc",
		"Isolation": "",
		"CpuShares": 0,
		"Memory": 0,
		"NanoCpus": 0,
		"CgroupParent": "",
		"BlkioWeight": 0,
		"BlkioWeightDevice": [],
		"BlkioDeviceReadBps": [],
		"BlkioDeviceWriteBps": [],
		"BlkioDeviceReadIOps": [],
		"BlkioDeviceWriteIOps": [],
		"CpuPeriod": 0,
		"CpuQuota": 0,
		"CpuRealtimePeriod": 0,
		"CpuRealtimeRuntime": 0,
		"CpusetCpus": "",
		"CpusetMems": "",
		"Devices": [],
		"DeviceCgroupRules": null,
		"DeviceRequests": null,
		"MemoryReservation": 0,
		"MemorySwap": 0,
		"MemorySwappiness": null,
		"OomKillDisable": false,
		"PidsLimit": null,
		"Ulimits": null,
		"CpuCount": 0,
		"CpuPercent": 0,
		"IOMaximumIOps": 0,
		"IOMaximumBandwidth": 0,
		"MaskedPaths": [
			"/proc/asound",
			"/proc/acpi",
			"/proc/kcore",
			"/proc/keys",
			"/proc/latency_stats",
			"/proc/timer_list",
			"/proc/timer_stats",
			"/proc/sched_debug",
			"/proc/scsi",
			"/sys/firmware",
			"/sys/devices/virtual/powercap"
		],
		"ReadonlyPaths": [
			"/proc/bus",
			"/proc/fs",
			"/proc/irq",
			"/proc/sys",
			"/proc/sysrq-trigger"
		]
	},
	"GraphDriver": {
		"Data": {
			"LowerDir": "/var/lib/docker/overlay2/6a22f8b855fb67fa7d17f01ea703d11aef092146bf64bd9f5b508cfb910c5353-init/diff:/var/lib/docker/overlay2/ff0f6efc2e4846fdded47a1a3f2cee2c3929efaf0958fe2038e93bd0a173243e/diff",
			"MergedDir": "/var/lib/docker/overlay2/6a22f8b855fb67fa7d17f01ea703d11aef092146bf64bd9f5b508cfb910c5353/merged",
			"UpperDir": "/var/lib/docker/overlay2/6a22f8b855fb67fa7d17f01ea703d11aef092146bf64bd9f5b508cfb910c5353/diff",
			"WorkDir": "/var/lib/docker/overlay2/6a22f8b855fb67fa7d17f01ea703d11aef092146bf64bd9f5b508cfb910c5353/work"
		},
		"Name": "overlay2"
	},
	"Mounts": [],
	"Config": {
		"Hostname": "b76b10ea0232",
		"Domainname": "",
		"User": "1000",
		"AttachStdin": false,
		"AttachStdout": false,
		"AttachStderr": false,
		"ExposedPorts": {
			"53/tcp": {},
			"53/udp": {}
		},
		"Tty": false,
		"OpenStdin": false,
		"StdinOnce": false,
		"Env": [
			"LOG_CALLER=short",
			"PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin",
			"UPSTREAM_TYPE=DoT",
			"DOT_RESOLVERS=cloudflare,google",
			"DOH_RESOLVERS=cloudflare,google",
			"DOT_TIMEOUT=3s",
			"DOH_TIMEOUT=3s",
			"LISTENING_ADDRESS=:53",
			"LOG_LEVEL=info",
			"MIDDLEWARE_LOG_ENABLED=off",
			"MIDDLEWARE_LOG_DIRECTORY=/var/log/dns/",
			"MIDDLEWARE_LOG_REQUESTS=on",
			"MIDDLEWARE_LOG_RESPONSES=off",
			"MIDDLEWARE_LOCALDNS_ENABLED=on",
			"MIDDLEWARE_LOCALDNS_RESOLVERS=",
			"CACHE_TYPE=lru",
			"CACHE_LRU_MAX_ENTRIES=10000",
			"BLOCK_MALICIOUS=on",
			"BLOCK_SURVEILLANCE=off",
			"BLOCK_ADS=off",
			"BLOCK_IPS=",
			"BLOCK_CIDRS=",
			"BLOCK_HOSTNAMES=",
			"ALLOWED_HOSTNAMES=",
			"ALLOWED_IPS=",
			"ALLOWED_CIDRS=",
			"METRICS_TYPE=noop",
			"METRICS_PROMETHEUS_ADDRESS=:9090",
			"METRICS_PROMETHEUS_SUBSYSTEM=dns",
			"CHECK_DNS=on",
			"UPDATE_PERIOD=24h"
		],
		"Cmd": null,
		"Healthcheck": {
			"Test": [
				"CMD",
				"/entrypoint",
				"healthcheck"
			],
			"Interval": 300000000000,
			"Timeout": 15000000000,
			"StartPeriod": 5000000000,
			"Retries": 1
		},
		"Image": "qmcgaw/dns:v2.0.0-beta",
		"Volumes": null,
		"WorkingDir": "/",
		"Entrypoint": [
			"/entrypoint"
		],
		"OnBuild": null,
		"Labels": {
			"org.opencontainers.image.authors": "quentin.mcgaw@gmail.com",
			"org.opencontainers.image.created": "2024-01-03T20:25:41.307Z",
			"org.opencontainers.image.description": "Docker DNS server on steroids to access DNS-over-TLS from Cloudflare, Google, Quad9, Quadrant or CleanBrowsing",
			"org.opencontainers.image.documentation": "https://github.com/qdm12/dns/blob/master/README.md",
			"org.opencontainers.image.licenses": "MIT",
			"org.opencontainers.image.revision": "51ea21dfa10dee4773beb08600febe0d059184f2",
			"org.opencontainers.image.source": "https://github.com/qdm12/dns",
			"org.opencontainers.image.title": "dns",
			"org.opencontainers.image.url": "https://github.com/qdm12/dns",
			"org.opencontainers.image.version": "v2.0.0-beta"
		}
	},
	"NetworkSettings": {
		"Bridge": "",
		"SandboxID": "16beacd7aeb0fd7244d2b3728b1e46072ed5bb60c92aec551efe13d9003fee69",
		"HairpinMode": false,
		"LinkLocalIPv6Address": "",
		"LinkLocalIPv6PrefixLen": 0,
		"Ports": {},
		"SandboxKey": "/var/run/docker/netns/16beacd7aeb0",
		"SecondaryIPAddresses": null,
		"SecondaryIPv6Addresses": null,
		"EndpointID": "",
		"Gateway": "",
		"GlobalIPv6Address": "",
		"GlobalIPv6PrefixLen": 0,
		"IPAddress": "",
		"IPPrefixLen": 0,
		"IPv6Gateway": "",
		"MacAddress": "",
		"Networks": {
			"bridge": {
				"IPAMConfig": null,
				"Links": null,
				"Aliases": null,
				"MacAddress": "",
				"NetworkID": "675738a2ac17d64a69892016c383b4a243a03e8367ef9e9c4a322fa52acb1304",
				"EndpointID": "",
				"Gateway": "",
				"IPAddress": "",
				"IPPrefixLen": 0,
				"IPv6Gateway": "",
				"GlobalIPv6Address": "",
				"GlobalIPv6PrefixLen": 0,
				"DriverOpts": null
			}
		}
	}
}

@qdm12
Copy link
Owner

qdm12 commented Jan 29, 2024

My 100% bad, LOG_CALLER was not implemented in this project, it's now done in commit 482d1ba; would you mind please re-trying by pulling docker pull qmcgaw/dns:v2.0.0-beta and just reporting back with your logs? 🙏 No need for the docker inspect 😉 Thanks!!

You can set LOG_CALLER=short for it to log the file name + line number for every log line.

@qdm12
Copy link
Owner

qdm12 commented Jan 29, 2024

Oh never mind, 2024-01-24 17:25:49 is the date printed by your interface, not by the internal logger, so LOG_CALLER won't make a difference. Can you try running in a terminal docker logs <container-name-or-id> and report the output? The panic message (multiple lines) is probably hidden by the interface you're using, but it should be there when checking the log file with docker logs 🤔 Thank you!

@rapteev
Copy link

rapteev commented Jan 29, 2024

Hi
Ok, I will try that and report back (still have windows VM installed).
Anyway I already have it running on a VM running Alpine Linux. (Also have tried on Ubuntu and Centos - on both with beta version also get panic error) , on all that I tried beta version the only one that run ok is Alpine Linux.

@qdm12
Copy link
Owner

qdm12 commented Jan 29, 2024

Also have tried on Ubuntu and Centos - on both with beta version also get panic error

That's surprising, feel free to share the docker logs from these as well if you can 😉 Thanks again

@ntilagoa
Copy link
Author

ntilagoa commented Jan 30, 2024

Hi

No way... :)

PS C:\Users\vitor> docker run -d -p 53:53/udp -p 53:53/tcp qmcgaw/dns:v2.0.0-beta
851dc7b149ce9ade9c12a16cd2bd7195f0f261084e697f26a85c505fc7fa2302
PS C:\Users\vitor> docker ps
CONTAINER ID   IMAGE     COMMAND   CREATED   STATUS    PORTS     NAMES
PS C:\Users\vitor> docker logs stupefied_volhard
========================================
========================================
================= dns ==================
========================================
=========== Made with ❤️ by ============
======= https://github.com/qdm12 =======
========================================
========================================

Running version v2.0.0-beta built on 2024-01-03T20:25:41.307Z (commit 51ea21d)

🔧 Need help? https://github.com/qdm12/dns/discussions/new
🐛 Bug? https://github.com/qdm12/dns/issues/new
✨ New feature? https://github.com/qdm12/dns/issues/new
☕ Discussion? https://github.com/qdm12/dns/discussions/new
💻 Email? quentin.mcgaw@gmail.com
💰 Help me? https://www.paypal.me/qmcgaw https://github.com/sponsors/qdm12
panic: runtime error: index out of range [0] with length 0
PS C:\Users\vitor>

@qdm12
Copy link
Owner

qdm12 commented Jan 31, 2024

Feeling even guiltier now 😄
I could reproduce the bug locally, and it indeed did not print the panic stack trace which is strange (my guess is it's because it's in a source file specific to *nix, there is the same file for windows as well)
Anyway, the bug was coming from empty lines in /etc/resolv.conf (the file containing nameserver information), and on some systems there was no empty lines so it would work fine. This is fixed in 6233499 Thank you so much for taking the time to answer all my previous silly questions 😄

@qdm12 qdm12 closed this as completed Jan 31, 2024
@rapteev
Copy link

rapteev commented Jan 31, 2024

Hi
No problem. I like to test things 😀.
Thank you for all your work developing these great programs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants