Why do I get error sorting credentials in Docker? - docker-compose

I just installed docker desktop, and now I want to use PostgreSQL, but when I try to log in docker by using the command -docker login I get the error Error saving credentials: error storing credentials - err: exit status 1, out: error getting credentials - err: exit status 1, out: no usernames for https://index.docker.io/v1/``
How can I solve this problem?

Related

Hyperledger iroha - schema error while connecting to postgres database

I am trying to deploy Hyperledger Iroha on MacOS (BigSUr) locally, and while running the following command
./build/bin/irohad --config example/config.postgres.sample --genesis_block example/genesis.block --keypair_name example/node0
I get the error
Storage initialization failed: Cannot execute query. Fatal error. ERROR: relation "schema_version" does not exist LINE 1: ... test, iroha_major, iroha_minor, iroha_patch from schema_ver... ^ while executing "select 1 test, iroha_major, iroha_minor, iroha_patch from schema_version;".
I have installed Postgresql DB locally and created the iroha_data database.
Is there a schema that i must load additionally or does it get auto created ?
I was able to overcome this issue by adding -drop_state while starting iroha daemon.

Dbeaver 7.1.5 . Dump database doesn't work

Linux Ubuntu. I try to dump data base and I see dialog error.
Error executing process Process failed (exit code = 2). See error log. Process failed (exit code = 2). See error log.
Oh only needs to change connection
--host=localhost
to
--host=127.0.0.1

GCloud SQL Proxy cannot connect, unclear errors

I am having difficulty getting the gcloud sql proxy working on my local machine. I have gone through all the steps here however I am getting the following errors. It is unclear to me what is actually going wrong. Important things to note, I am not using a service account, I am authenticating with my own account through gcloud auth login and I am following the TCP sockets steps.
MySQL
ERROR 2013 (HY000): Lost connection to MySQL server at 'reading initial communication packet', system error: 0
GCloud SQL Proxy
couldn't connect to "<my instance connection name>": googleapi: Error 400: This operation isn"t valid for this instance., invalidOperation
GCloud Logs
... status: {
code: 2
message: "UNKNOWN"
}
}
receiveTimestamp: "2017-09-08T15:45:10.179994989Z"
resource: {…}
severity: "ERROR"
timestamp: "2017-09-08T15:45:04.289Z"
}
The most likely reason you are receiving this error message is because you are using a First Generation instance.
Proxy connectivity is only supported for Second Generation instances.

Unable to shutdown mongodb server - unexpected error: "shutdownServer failed: unauthorized" at src/mongo/shell/assert.js:7

I am trying to shutdown one of the mongodb instance in a 3 node replica set. The config file has auth set to 1. I have a admin account that has userAdminAnyDatabase role and I logged to admin database with that account. However when I run db.shutdownServer() I get the following error
db.shutdownServer()
assert failed : unexpected error: "shutdownServer failed: unauthorized"
Error: Printing Stack Trace
at printStackTrace (src/mongo/shell/utils.js:37:15)
at doassert (src/mongo/shell/assert.js:6:5)
at assert (src/mongo/shell/assert.js:14:5)
at DB.shutdownServer (src/mongo/shell/db.js:346:9)
at (shell):1:4
Mon Jun 23 12:52:51.839 assert failed : unexpected error: "shutdownServer failed: unauthorized" at src/mongo/shell/assert.js:7
I created another user that has both dbAdminAnyDatabase and userAdminAnyDatabase roles and that also gets the same error.
Can someone help me with this error?
If running MongoDB 2.4 a user with the clusterAdmin role is needed to run db.shutdownServer(). A full list of user roles for MongoDB 2.4 is available here: http://docs.mongodb.org/v2.4/reference/user-privileges/
If on MongoDB 2.6 you would use the hostManager role instead. See the following page for 2.6 roles: http://docs.mongodb.org/manual/reference/built-in-roles/

MongoDB : Cloning Database error?

When I try to clone my mongo database from other machine, I see the following on client
db.cloneDatabase('10.10.124.110')
{ "errmsg" : "query failed staging.system.namespaces", "ok" : 0 }
and on server I see
Thu Nov 10 11:29:01 [conn10] assertion 10057 unauthorized db:staging lock type:-1 client:10.10.124.110 ns:staging.system.namespaces query:{}
How can I resolve this issue?
That error seems a lot like this one https://jira.mongodb.org/browse/SERVER-2846 where an error is thrown because copyDatabase() ... which cloneDatabase() uses ... requires Admin privileges. In that case the user is using a hosted MongoDB instance where they didn't have admin privileges.
You can see some more about how to use the copyDatabase() command here and here.
So, for example if you are using -auth a username/password you'll need to run the copyDatabase() command like this:
> db.copyDatabase(from_db, to_db, from_host, username, password);
I was able to just resolve this error by querying the PRIMARY host in a replicaSet, rather than the SECONDARY.