Thomas Vander Wal
05/03/2021, 10:32 PMEmptyStaticCreds: static credentials are empty
even though I’ve verified the keys are in the config file mounted in the pod. Scrubbed logs in more details in this thread. Has anyone ran into this issue and have a fix?Thomas Vander Wal
05/03/2021, 10:35 PMUsing config file: /etc/lakefs/config.yaml
time="2021-05-03T21:39:05Z" level=info msg="lakeFS run" func="pkg/logging.(*logrusEntryWrapper).Infof" file="build/pkg/logging/logger.go:115" version=0.33.1
time="2021-05-03T21:39:05Z" level=info msg="connecting to the DB" func=pkg/db.ConnectDBPool file="build/pkg/db/connect.go:54" conn_max_lifetime=5m0s driver=pgx max_idle_conns=25 max_open_conns=25 uri="<postgres://user:pass@aif-lakefs-db.dataops.svc.cluster.local:5432/lakefs?sslmode=disable|postgres://user:pass@aif-lakefs-db.dataops.svc.cluster.local:5432/lakefs?sslmode=disable>"
time="2021-05-03T21:39:05Z" level=info msg="initialized DB connection" func=pkg/db.ConnectDBPool file="build/pkg/db/connect.go:73" conn_max_lifetime=5m0s driver=pgx max_idle_conns=25 max_open_conns=25 uri="<postgres://user:pass@aif-lakefs-db.dataops.svc.cluster.local:5432/lakefs?sslmode=disable|postgres://user:pass@aif-lakefs-db.dataops.svc.cluster.local:5432/lakefs?sslmode=disable>"
time="2021-05-03T21:39:05Z" level=info msg="connecting to the DB" func=pkg/db.ConnectDBPool file="build/pkg/db/connect.go:54" conn_max_lifetime=5m0s driver=pgx max_idle_conns=25 max_open_conns=25 uri="<postgres://user:pass@aif-lakefs-db.dataops.svc.cluster.local:5432/lakefs?sslmode=disable|postgres://user:pass@aif-lakefs-db.dataops.svc.cluster.local:5432/lakefs?sslmode=disable>"
time="2021-05-03T21:39:05Z" level=info msg="initialized DB connection" func=pkg/db.ConnectDBPool file="build/pkg/db/connect.go:73" conn_max_lifetime=5m0s driver=pgx max_idle_conns=25 max_open_conns=25 uri="<postgres://user:pass@aif-lakefs-db.dataops.svc.cluster.local:5432/lakefs?sslmode=disable|postgres://user:pass@aif-lakefs-db.dataops.svc.cluster.local:5432/lakefs?sslmode=disable>"
time="2021-05-03T21:39:05Z" level=info msg="connecting to the DB" func=pkg/db.ConnectDBPool file="build/pkg/db/connect.go:54" conn_max_lifetime=5m0s driver=pgx max_idle_conns=25 max_open_conns=25 uri="<postgres://user:pass@aif-lakefs-db.dataops.svc.cluster.local:5432/lakefs?sslmode=disable|postgres://user:pass@aif-lakefs-db.dataops.svc.cluster.local:5432/lakefs?sslmode=disable>"
time="2021-05-03T21:39:05Z" level=info msg="initialized DB connection" func=pkg/db.ConnectDBPool file="build/pkg/db/connect.go:73" conn_max_lifetime=5m0s driver=pgx max_idle_conns=25 max_open_conns=25 uri="<postgres://user:pass@aif-lakefs-db.dataops.svc.cluster.local:5432/lakefs?sslmode=disable|postgres://user:pass@aif-lakefs-db.dataops.svc.cluster.local:5432/lakefs?sslmode=disable>"
time="2021-05-03T21:39:05Z" level=info msg="initialize blockstore adapter" func=pkg/block/factory.BuildBlockAdapter file="build/pkg/block/factory/build.go:38" type=s3
time="2021-05-03T21:39:05Z" level=info msg="initialized blockstore adapter" func=pkg/block/factory.buildS3Adapter file="build/pkg/block/factory/build.go:97" type=s3
time="2021-05-03T21:39:05Z" level=info msg="initialize blockstore adapter" func=pkg/block/factory.BuildBlockAdapter file="build/pkg/block/factory/build.go:38" type=s3
time="2021-05-03T21:39:05Z" level=info msg="initialized blockstore adapter" func=pkg/block/factory.buildS3Adapter file="build/pkg/block/factory/build.go:97" type=s3
time="2021-05-03T21:39:05Z" level=info msg="initialized Auth service" func=pkg/auth.NewDBAuthService file="build/pkg/auth/service.go:180"
time="2021-05-03T21:39:05Z" level=warning msg="EmptyStaticCreds: static credentials are empty: failed to get AWS account ID for BI" func="pkg/logging.(*logrusEntryWrapper).Warnf" file="build/pkg/logging/logger.go:119"
time="2021-05-03T21:39:05Z" level=info msg="initialize OpenAPI server" func=pkg/api.Serve file="build/pkg/api/serve.go:42" service=api_gateway
time="2021-05-03T21:39:06Z" level=info msg="initialized S3 Gateway handler" func=pkg/gateway.NewHandler file="build/pkg/gateway/handler.go:121" s3_bare_domain=<http://lakefs-s3.xxxx.xxxx.xxx.xxxx.xxx|lakefs-s3.xxxx.xxxx.xxx.xxxx.xxx> s3_region=us-east-1
time="2021-05-03T21:39:06Z" level=info msg="starting HTTP server" func=cmd/lakefs/cmd.glob..func9 file="cmd/run.go:158" listen_address="0.0.0.0:8000"
time="2021-05-03T21:39:06Z" level=info msg="Up and running (^C to shutdown)..." func=cmd/lakefs/cmd.gracefulShutdown file="cmd/run.go:220" version=0.33.1
██╗ █████╗ ██╗ ██╗███████╗███████╗███████╗
██║ ██╔══██╗██║ ██╔╝██╔════╝██╔════╝██╔════╝
██║ ███████║█████╔╝ █████╗ █████╗ ███████╗
██║ ██╔══██║██╔═██╗ ██╔══╝ ██╔══╝ ╚════██║
███████╗██║ ██║██║ ██╗███████╗██║ ███████║
╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚══════╝╚═╝ ╚══════╝
│
│ If you're running lakeFS locally for the first time,
│ complete the setup process at <http://127.0.0.1:8000/setup|http://127.0.0.1:8000/setup>
│
│
│ For more information on how to use lakeFS,
│ check out the docs at <https://docs.lakefs.io/quickstart/repository|https://docs.lakefs.io/quickstart/repository>
│
Version 0.33.1
time="2021-05-03T21:39:44Z" level=debug msg="rows done" func="pkg/db.(*LoggedRows).logDuration" file="build/pkg/db/logged_rows.go:34" args="[dataops ]" duration=3.082832ms query="\n\t WITH resolved_policies_view AS (\n SELECT <http://auth_policies.id|auth_policies.id>, auth_policies.created_at, auth_policies.display_name, auth_policies.statement, auth_users.display_name AS user_display_name\n FROM auth_policies INNER JOIN\n auth_user_policies ON (<http://auth_policies.id|auth_policies.id> = auth_user_policies.policy_id) INNER JOIN\n\t\t auth_users ON (<http://auth_users.id|auth_users.id> = auth_user_policies.user_id)\n UNION\n\t\tSELECT <http://auth_policies.id|auth_policies.id>, auth_policies.created_at, auth_policies.display_name, auth_policies.statement, auth_users.display_name AS user_display_name\n\t\tFROM auth_policies INNER JOIN\n\t\t auth_group_policies ON (<http://auth_policies.id|auth_policies.id> = auth_group_policies.policy_id) INNER JOIN\n\t\t auth_groups ON (<http://auth_groups.id|auth_groups.id> = auth_group_policies.group_id) INNER JOIN\n\t\t auth_user_gro...
time="2021-05-03T21:39:44Z" level=debug msg="performing API action" func="pkg/api.(*Controller).LogAction" file="build/pkg/api/controller.go:105" action=list_repos host=<http://lakefs.xxxx.xxxx.xxx.xxxx.com|lakefs.xxxx.xxxx.xxx.xxxx.com> message_type=action method=GET path="/api/v1/repositories?after=&amount=300" request_id=bfb89f1b-a036-4d96-8c83-eb5ce7645b2f service=api_gateway service_name=rest_api user=dataops
time="2021-05-03T21:39:44Z" level=debug msg="performing API action" func="pkg/api.(*Controller).LogAction" file="build/pkg/api/controller.go:105" action=create_repo host=<http://lakefs.xxxx.xxxx.xxx.xxxx.xxx|lakefs.xxxx.xxxx.xxx.xxxx.xxx> message_type=action method=POST path=/api/v1/repositories request_id=2d01c128-0339-4fef-8828-29dbe0fbbd17 service=api_gateway service_name=rest_api user=dataops
time="2021-05-03T21:39:44Z" level=error msg="failed to sign request" func="pkg/block/s3.(*Adapter).streamToS3" file="build/pkg/block/s3/adapter.go:174" error="EmptyStaticCreds: static credentials are empty" host=lakefs. <http://xxxx.xxxx.xxx.xxxx.xxx|xxxx.xxxx.xxx.xxxx.xxx> method=POST operation=PutObject path=/api/v1/repositories request_id=2d01c128-0339-4fef-8828-29dbe0fbbd17 service_name=rest_api user=dataops
time="2021-05-03T21:39:44Z" level=warning msg="Could not access storage namespace" func="pkg/api.(*Controller).CreateRepositoryHandler.func1" file="build/pkg/api/controller.go:567" error="EmptyStaticCreds: static credentials are empty" service=api_gateway storage_namespace="<s3://lakefs-store-43562dfe-e06b-4b9b-bf75-d0d0f6c8d1bb/|s3://lakefs-store-43562dfe-e06b-4b9b-bf75-d0d0f6c8d1bb/>"
time="2021-05-03T21:39:44Z" level=debug msg="HTTP call ended" func=pkg/httputil.DebugLoggingMiddleware.func1 file="build/pkg/httputil/logging.go:77" host=<http://lakefs.xxxx.xxxx.xxx.xxxx.xxx|lakefs.xxxx.xxxx.xxx.xxxx.xxx> method=POST path=/api/v1/repositories request_id=2d01c128-0339-4fef-8828-29dbe0fbbd17 sent_bytes=76 service_name=rest_api status_code=400 took=11.372304ms user=dataops
time="2021-05-03T21:39:44Z" level=debug msg="rows done" func="pkg/db.(*LoggedRows).logDuration" file="build/pkg/db/logged_rows.go:34" args="[ 1000]" duration="699.955µs" query="\n\t\t\tSELECT id, storage_namespace, creation_date, default_branch\n\t\t\tFROM graveler_repositories\n\t\t\tWHERE id >= $1\n\t\t\tORDER BY id ASC\n\t\t\tLIMIT $2" type="start query"
time="2021-05-03T21:39:44Z" level=debug msg="HTTP call ended" func=pkg/httputil.DebugLoggingMiddleware.func1 file="build/pkg/httputil/logging.go:77" host=lakefs. <http://xxxx.xxxx.xxx.xxxx.xxx|xxxx.xxxx.xxx.xxxx.xxx> method=GET path="/api/v1/repositories?after=&amount=300" request_id=bfb89f1b-a036-4d96-8c83-eb5ce7645b2f sent_bytes=79 service_name=rest_api status_code=200 took=11.944864ms user=dataops
time="2021-05-03T21:39:44Z" level=debug msg="performing API action" func="pkg/api.(*Controller).LogAction" file="build/pkg/api/controller.go:105" action=list_repos host=lakefs. <http://xxxx.xxxx.xxx.xxxx.xxx|xxxx.xxxx.xxx.xxxx.xxx> message_type=action method=GET path="/api/v1/repositories?after=&amount=300" request_id=ccc12af9-7f8b-464a-bc21-86e693201e4c service=api_gateway service_name=rest_api user=dataops
time="2021-05-03T21:39:44Z" level=debug msg="rows done" func="pkg/db.(*LoggedRows).logDuration" file="build/pkg/db/logged_rows.go:34" args="[ 1000]" duration="522.882µs" query="\n\t\t\tSELECT id, storage_namespace, creation_date, default_branch\n\t\t\tFROM graveler_repositories\n\t\t\tWHERE id >= $1\n\t\t\tORDER BY id ASC\n\t\t\tLIMIT $2" type="start query"
time="2021-05-03T21:39:44Z" level=debug msg="HTTP call ended" func=pkg/httputil.DebugLoggingMiddleware.func1 file="build/pkg/httputil/logging.go:77" host=lakefs. <http://xxxx.xxxx.xxx.xxxx.xxx|xxxx.xxxx.xxx.xxxx.xxx> method=GET path="/api/v1/repositories?after=&amount=300" request_id=ccc12af9-7f8b-464a-bc21-86e693201e4c sent_bytes=79 service_name=rest_api status_code=200 took="822.009µs" user=dataops
Thomas Vander Wal
05/03/2021, 10:35 PMObjectBucketClaims
for the underlying S3 bucket. We’re also behind a corporate proxy but I’ve already tried setting the environmental variables for that as well.
LakeFS logs:Thomas Vander Wal
05/03/2021, 10:36 PM/home/lakefs $ ls -ltrh /etc/lakefs/
total 0
lrwxrwxrwx 1 root root 18 May 3 21:39 config.yaml -> ..data/config.yaml
/home/lakefs $ cat /etc/lakefs/config.yaml
stats.enabled: false
logging.level: DEBUG
blockstore:
type: s3
s3:
region: us-east-1
endpoint: <https://s3-openshift-storage.xxxx.xxx.xxx.xxxx.xxx:443|https://s3-openshift-storage.xxxx.xxx.xxx.xxxx.xxx:443>
credentials:
access_key_id: accesskey
secret_access_key: secretkey
gateways:
s3:
domain_name: <http://lakefs-s3.xxxx.xxx.xxx.xxxx.xxx|lakefs-s3.xxxx.xxx.xxx.xxxx.xxx>
region: us-east-1
/home/lakefs $
Oz Katz
Oz Katz
Thomas Vander Wal
05/03/2021, 10:44 PMThomas Vander Wal
05/03/2021, 10:47 PMThomas Vander Wal
05/03/2021, 10:48 PMOz Katz
Oz Katz
Thomas Vander Wal
05/03/2021, 10:58 PMOz Katz
Oz Katz
blockstore.s3.credentials.secret_access_key
- this is true since version 0.40.0. For prior version the setting was called blockstore.s3.credentials.access_secret_key
.
I recommend either upgrading from 0.33.1 to current latest (0.40.3 at the time of writing).
Alternatively, if there's good reason to stick with 0.33.1 for now - replace the secret_access_key
directive with access_secret_key
.Oz Katz
Thomas Vander Wal
05/04/2021, 1:34 PMOz Katz
Thomas Vander Wal
05/04/2021, 2:26 PMOz Katz
Thomas Vander Wal
05/04/2021, 2:55 PMSSL_CERT_FILE
or whatever variable the go SDKs respect in the values file.Oz Katz
$AWS_CA_BUNDLE
env var which sounds very relevant for this. Would be happy to know if that works for you (and if it does we can add it to the official docs as well)Thomas Vander Wal
05/04/2021, 9:24 PM/etc/ssl/certs
did the trick and didn’t need to set the environmental variableOz Katz