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

[Build][restapi] Failed to build sonic-restapi deb because of incorrect read-only permissions #8611

Closed
vivekrnv opened this issue Aug 26, 2021 · 3 comments · Fixed by sonic-net/sonic-restapi#87
Assignees
Labels
Build Triaged this issue has been triaged

Comments

@vivekrnv
Copy link
Contributor

Description

Failed to build sonic-restapi deb because of incorrect read-only permissions

Steps to reproduce the issue:

  1. make INCLUDE_MGMT_FRAMEWORK=y INCLUDE_RESTAPI=y target/debs/stretch/sonic-rest-api_1.0.1_amd64.deb

Describe the results you received:

[2021-08-26T13:53:56.903Z] make[1]: Entering directory '/sonic/src/sonic-restapi'
[2021-08-26T13:53:56.903Z] dh clean  --with autotools-dev
[2021-08-26T13:53:56.903Z]    dh_auto_clean
[2021-08-26T13:53:56.903Z] 	make -j1 clean
[2021-08-26T13:53:56.903Z] make[2]: Entering directory '/sonic/src/sonic-restapi'
[2021-08-26T13:53:56.903Z] rm -rf /var/sw-r2d2-bot/go
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/satori/[email protected]/.travis.yml': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/satori/[email protected]/sql.go': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/satori/[email protected]/uuid_test.go': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/satori/[email protected]/generator_test.go': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/satori/[email protected]/LICENSE': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/satori/[email protected]/README.md': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/satori/[email protected]/codec_test.go': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/satori/[email protected]/sql_test.go': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/satori/[email protected]/generator.go': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/satori/[email protected]/uuid.go': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/satori/[email protected]/codec.go': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/gorilla/[email protected]/.circleci/config.yml': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/gorilla/[email protected]/test_helpers.go': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/gorilla/[email protected]/route.go': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/gorilla/[email protected]/.github/release-drafter.yml': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/gorilla/[email protected]/.github/stale.yml': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/gorilla/[email protected]/LICENSE': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/gorilla/[email protected]/mux_test.go': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/gorilla/[email protected]/regexp_test.go': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/gorilla/[email protected]/README.md': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/gorilla/[email protected]/middleware_test.go': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/gorilla/[email protected]/example_cors_method_middleware_test.go': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/gorilla/[email protected]/go.mod': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/gorilla/[email protected]/doc.go': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/gorilla/[email protected]/AUTHORS': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/gorilla/[email protected]/mux_httpserver_test.go': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/gorilla/[email protected]/mux.go': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/gorilla/[email protected]/bench_test.go': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/gorilla/[email protected]/regexp.go': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/gorilla/[email protected]/example_authentication_middleware_test.go': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/gorilla/[email protected]/example_route_test.go': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/gorilla/[email protected]/middleware.go': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/gorilla/[email protected]/old_test.go': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/comail/[email protected]/.travis.yml': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/comail/[email protected]/tty_linux.go': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/comail/[email protected]/LICENSE': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/comail/[email protected]/tty_windows.go': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/comail/[email protected]/tty.go': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/comail/[email protected]/colog_bench_test.go': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/comail/[email protected]/interfaces.go': Permission denied
[2021-08-26T13:53:56.903Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/comail/[email protected]/std_formatter.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/comail/[email protected]/README.md': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/comail/[email protected]/json_formatter.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/comail/[email protected]/std_formatter_test.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/comail/[email protected]/tty_bsd.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/comail/[email protected]/json_formatter_test.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/comail/[email protected]/std_extractor_test.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/comail/[email protected]/colog_test.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/comail/[email protected]/std_extractor.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/comail/[email protected]/colog.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/universal.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/.travis.yml': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/pubsub.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/testdata/redis.conf': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/example_test.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/main_test.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/pipeline.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/commands.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/cluster_commands.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/options.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/pipeline_test.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/LICENSE': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/iterator_test.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/pool_test.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/.gitignore': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/.golangci.yml': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/command_test.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/commands_test.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/README.md': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/script.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/example_instrumentation_test.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/tx.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/race_test.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/pubsub_test.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/internal/hashtag/hashtag_test.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/internal/hashtag/hashtag.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/internal/log.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/internal/proto/writer.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/internal/proto/reader.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/internal/proto/scan.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/internal/proto/scan_test.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/internal/proto/write_buffer_test.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/internal/proto/reader_test.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/internal/proto/proto_test.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/internal/util/unsafe.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/internal/util/strconv.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/internal/util/safe.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/internal/pool/main_test.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/internal/pool/pool_test.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/internal/pool/pool_single.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/internal/pool/pool.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/internal/pool/pool_sticky.go': Permission denied
[2021-08-26T13:53:56.904Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/internal/pool/export_test.go': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/internal/pool/bench_test.go': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/internal/pool/conn.go': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/internal/internal_test.go': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/internal/internal.go': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/internal/util.go': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/internal/once.go': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/internal/consistenthash/consistenthash_test.go': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/internal/consistenthash/consistenthash.go': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/tx_test.go': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/CHANGELOG.md': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/options_test.go': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/iterator.go': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/go.mod': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/internal_test.go': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/export_test.go': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/go.sum': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/doc.go': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/universal_test.go': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/result.go': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/sentinel.go': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/sentinel_test.go': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/Makefile': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/redis_test.go': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/ring.go': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/bench_test.go': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/cluster_test.go': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/redis.go': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/command.go': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/cluster.go': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/error.go': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/go-redis/redis/[email protected]/ring_test.go': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/vharitonsky/[email protected]/test_config2.ini': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/vharitonsky/[email protected]/LICENSE': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/vharitonsky/[email protected]/.gitignore': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/vharitonsky/[email protected]/README.md': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/vharitonsky/[email protected]/test_setconfigfile.ini': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/vharitonsky/[email protected]/test_config.ini': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/vharitonsky/[email protected]/iniflags.go': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/vharitonsky/[email protected]/iniflags_test.go': Permission denied
[2021-08-26T13:53:56.905Z] rm: cannot remove '/var/sw-r2d2-bot/go/pkg/mod/github.com/vharitonsky/[email protected]/test_bom.ini': Permission denied
[2021-08-26T13:53:56.905Z] Makefile:28: recipe for target 'clean' failed
[2021-08-26T13:53:56.905Z] make[2]: *** [clean] Error 1
[2021-08-26T13:53:56.905Z] make[2]: Leaving directory '/sonic/src/sonic-restapi'
[2021-08-26T13:53:56.905Z] dh_auto_clean: make -j1 clean returned exit code 2
[2021-08-26T13:53:56.905Z] debian/rules:22: recipe for target 'clean' failed
[2021-08-26T13:53:56.905Z] make[1]: *** [clean] Error 2
[2021-08-26T13:53:56.905Z] make[1]: Leaving directory '/sonic/src/sonic-restapi'
[2021-08-26T13:53:56.905Z] dpkg-buildpackage: error: fakeroot debian/rules clean gave error exit status 2
[2021-08-26T13:53:56.905Z] [  FAIL LOG END  ] [ target/debs/stretch/sonic-rest-api_1.0.1_amd64.deb ]
[2021-08-26T13:53:56.905Z] make: *** [target/debs/stretch/sonic-rest-api_1.0.1_amd64.deb] Error 1

Describe the results you expected:

make clean should be able to remove the directories

Output of show version:

(paste your output here)

Output of show techsupport:

(paste your output here or download and attach the file here )

Additional information you deem important (e.g. issue happens only occasionally):

@vivekrnv
Copy link
Contributor Author

@lguohan, I see your comment here which i think is the same issue. #3993 (comment), Although i don't see any noticeable commit after that which resolved the build failure.

@sumukhatv, can you shed some light as to how was it resolved back then

@vivekrnv
Copy link
Contributor Author

vivekrnv commented Aug 27, 2021

This simple change fixed the issue. This is a straightforward issue in the go community and from what i understand we should've seen this issue way before i.e. from the time this dep target/debs/stretch/sonic-rest-api_1.0.1_amd64.deb was introduced and i'm not sure why hasn't it come to light till now.

Fix Inferred from:

COMMIT
Relevant Issues: go#27161, go#35615

diff --git a/Makefile b/Makefile
index d95de76..41b573b 100644
--- a/Makefile
+++ b/Makefile
@@ -5,6 +5,7 @@ export GOROOT=/usr/local/go
 export GOPATH=$(HOME)/go
 export GOBIN=$(GOPATH)/bin
 export GO111MODULE=on
+export GOFLAGS=-modcacherw
 
 all: install build

@zhangyanzhao zhangyanzhao added Triaged this issue has been triaged Build labels Sep 1, 2021
@zhangyanzhao
Copy link
Collaborator

@sumukhatv can you please take a look and reply the mail? Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Build Triaged this issue has been triaged
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants