Failed to initialize build cache

49 views
Skip to first unread message

Eric Sum

unread,
Nov 29, 2023, 1:58:26 PM11/29/23
to tast-users
Hi,

I'm getting this error:

(cr) esum@esum /mnt/host/source/src/scripts $ tast -verbose run 127.0.0.1:2228 login.Chrome
2023-11-29T18:53:16.692729Z [tast setup] Command line: tast -verbose run 127.0.0.1:2228 login.Chrome
2023-11-29T18:53:16.692779Z [tast setup] Tast version: tast-cmd-0.0.1-r2234
2023-11-29T18:53:16.692788Z [tast setup] Using SSH key /home/esum/chromiumos/chromite/ssh_keys/testing_rsa
2023-11-29T18:53:16.692795Z [tast setup] Using SSH dir /home/esum/.ssh
2023-11-29T18:53:16.692801Z [tast setup] Writing results to /tmp/tast/results/20231129-105316
2023-11-29T18:53:16.692810Z Phase "tast setup" ended after 7.762679ms
2023-11-29T18:53:16.693281Z Starting ephemeral devserver at http://127.0.0.1:45791 for remote tests
2023-11-29T18:53:16.693745Z Connecting to 127.0.0.1:2228
2023-11-29T18:53:17.061323Z Running ssh cmd: cat /proc/sys/kernel/random/boot_id
2023-11-29T18:53:17.123187Z Building remote_test_runner, cros
2023-11-29T18:53:19.717510Z failed to initialize build cache at /home/esum/.cache/go-build: mkdir /home/esum/.cache/go-build: permission denied
2023-11-29T18:53:19.751372Z failed to initialize build cache at /home/esum/.cache/go-build: mkdir /home/esum/.cache/go-build: permission denied
2023-11-29T18:53:19.773247Z Failed to run tests: failed to build and push primary DUT: build failed: failed to build go.chromium.org/tast/core/cmd/remote_test_runner: exit status 1


Yesterday, I synced, re-created the chroot, setup the board, built all packages, and ran update_chroot. I also tried the fix for this issue in go/croskit, but it still doesn't work. Any suggestions?

Seewai Fu

unread,
Nov 29, 2023, 4:05:52 PM11/29/23
to Eric Sum, tast-users
I have seen multiple reports that some people experienced similar issues. My guess is that somehow e-build used go cache and some files have the root ownership instead of user ownership. Take a look at 
 /home/esum/.cache/go-build inside chroot. See if changing ownership back to user will help.

I couldn’t reproduce the problem myself.

Hope it helps.

Seewai

--
You received this message because you are subscribed to the Google Groups "tast-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to tast-users+...@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/tast-users/51d4d005-b6a7-4f8d-82c5-0fc79176618en%40chromium.org.

Mengqi Guo

unread,
Jan 5, 2024, 4:34:58 AMJan 5
to Seewai Fu, Eric Sum, tast-users
Ran into this too 

(cr) mqg@mqgrand /mnt/host/source/src/platform/tast $ ./fast_build.sh
failed to initialize build cache at /home/mqg/.cache/go-build: mkdir /home/mqg/.cache/go-build: permission denied



--
Best,
Mengqi

Jason Hsiao

unread,
Jan 7, 2024, 11:50:04 PMJan 7
to tast-users, Mengqi Guo, Eric Sum, tast-users, Seewai Fu
I met the same issue too, and deleting /.cache/go-build with root permission fix the issue for me.
Reply all
Reply to author
Forward
0 new messages