-
Notifications
You must be signed in to change notification settings - Fork 18k
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
cmd/link: cannot open file ... cannot allocate memory #52716
Comments
Assume I know nothing about kubernetes and have never installed it. Can you provide me with a shell script, end-to-end, that would reproduce this? Partly this is because I'm skeptical it's a linker bug, and partly it's because I don't know much about k8s and my failure to reproduce would not be definitive information. |
Oh, I should add this bit of evidence too: root@ubu22:/home/mspreitz/go/src/k8s.io/kubernetes# df -h
Filesystem Size Used Avail Use% Mounted on
tmpfs 2.5G 1.1M 2.5G 1% /run
/dev/mapper/ubuntu--vg-ubuntu--lv 96G 8.9G 83G 10% /
tmpfs 13G 0 13G 0% /dev/shm
tmpfs 5.0M 0 5.0M 0% /run/lock
go 932G 604G 328G 65% /home/mspreitz/go
/dev/sda2 2.0G 126M 1.7G 7% /boot
tmpfs 2.5G 4.0K 2.5G 1% /run/user/0 I will see if I can narrow down the scenario. |
Here is a slightly simpler way to produce the problem. It is odd. First, do a successful build. Then try building again, and the problem happens! Following is a typescript.
|
By using
Oddly, when I try that directly from the shell, I get a complaint about accessing the "VCS status". Indeed,
If I take the hint, I can issue a
I once saw the direct |
Hey, @dr2chase , thanks for responding. My latest theory is that the fault lies not with go, nor even Kubernetes, but with the VirtualBox mechanism I am using to mount part of the host filesystem into the guest. The troubles I reported here are from inside a VM I just made using VirtualBox. I posted on a VBox forum at https://forums.virtualbox.org/viewtopic.php?f=3&t=105969 |
Timed out in state WaitingForInfo. Closing. (I am just a bot, though. Please speak up if this is a mistake or you have the requested information.) |
What version of Go are you using (
go version
)?Does this issue reproduce with the latest release?
I am using the latest release.
What operating system and processor architecture are you using (
go env
)?go env
OutputWhat did you do?
I tried to use
hack/local-up-cluster.sh
of Kubernetes release-1.24 in a freshly constructed VM that has plenty of memory, but everything I try fails with the linker complaining that it can not open a file and can not allocate memory.I monitored with
htop
in a separate window, the memory usage never got above about 25%.Here is some more evidence in typescript form.
I ran the local-up-cluster script as root, after first removing the _output and /tmp files/directories owned by my ordinary user. Following is the latest trial.
Here is more information about the VM.
And, in the shell I used to run the local-up-cluster script:
What did you expect to see?
No complaints about memory from inside a VM with plenty of memory.
What did you see instead?
See the error messages about memory above.
The text was updated successfully, but these errors were encountered: