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

monero-wallet-rpc not connecting to monerod #3622

Closed
skinderis opened this issue Apr 12, 2018 · 3 comments
Closed

monero-wallet-rpc not connecting to monerod #3622

skinderis opened this issue Apr 12, 2018 · 3 comments
Labels

Comments

@skinderis
Copy link

skinderis commented Apr 12, 2018

Hi, I am trying to connect monero-wallet-rpc to monerod, both binaries are running on the same docker container. When I run method getheight on my wallet it returns height: 1 (not synced with daemon).
monero.conf:

data-dir=/root/monero/data
rpc-bind-ip=0.0.0.0
rpc-bind-port=18556
p2p-bind-port=18555
p2p-bind-ip=0.0.0.0
rpc-login=user:password

monero-wallet.conf:

daemon-address=127.0.0.1:18556
rpc-bind-ip=0.0.0.0
rpc-bind-port=18557
rpc-login=user:password
wallet-dir=/root/monero/data/monero-wallets

start.sh

#!/bin/bash 
./monerod --restricted-rpc --confirm-external-bind --non-interactive --config-file /root/monero/data/monero.conf --detach && \
./monero-wallet-rpc --config-file /root/monero/data/monero-wallet.conf --confirm-external-bind

Error log:

monero_1  | Monero 'Lithium Luna' (v0.12.0.0-master-8361d60)
monero_1  | Logging to ./monero-wallet-rpc.log
monero_1  | 2018-04-12 15:43:20.782	    7f73ac5c0780	INFO 	global	contrib/epee/include/net/http_server_impl_base.h:76	Binding on 0.0.0.0:18557
monero_1  | 2018-04-12 15:43:20.782	    7f73ac5c0780	WARN 	wallet.rpc	src/wallet/wallet_rpc_server.cpp:3001	Starting wallet RPC server
monero_1  | 2018-04-12 15:44:35.751	[RPC0]	WARN 	wallet.wallet2	src/wallet/wallet2.cpp:3709	Loaded wallet keys file, with public address: 41pLNkSGSJK8pWAG9dd57YcWB82gH5ucHNEPnGt1FBN59PrdYqKUGB1SfZxGQPcYcDEbctmpN2kpVbtupm6yCRf16oXkjuY
monero_1  | 2018-04-12 15:44:35.928	[RPC0]	ERROR	net.http	contrib/epee/include/net/http_client.h:424	Client has incorrect username/password for server requiring authentication
monero_1  | 2018-04-12 15:44:35.928	[RPC0]	ERROR	wallet.wallet2	src/wallet/wallet2.cpp:5583	!r. THROW EXCEPTION: error::no_connection_to_daemon
monero_1  | 2018-04-12 15:44:35.928	[RPC0]	WARN 	net.http	src/wallet/wallet_errors.h:794	/home/igoris/Desktop/monero/src/wallet/wallet2.cpp:5583:N5tools5error23no_connection_to_daemonE: no connection to daemon, request = gettransactions
monero_1  | 2018-04-12 15:44:35.967	[RPC0]	ERROR	wallet.wallet2	src/wallet/wallet2.cpp:3818	Failed to save rings, will try again next time
monero_1  | 2018-04-12 15:44:40.830	[RPC0]	ERROR	net.http	contrib/epee/include/net/http_client.h:424	Client has incorrect username/password for server requiring authentication
monero_1  | 2018-04-12 15:44:40.830	[RPC0]	ERROR	wallet.wallet2	src/wallet/wallet2.cpp:1681	!r. THROW EXCEPTION: error::no_connection_to_daemon
monero_1  | 2018-04-12 15:44:40.830	[RPC0]	WARN 	net.http	src/wallet/wallet_errors.h:794	/home/igoris/Desktop/monero/src/wallet/wallet2.cpp:1681:N5tools5error23no_connection_to_daemonE: no connection to daemon, request = gethashes.bin
monero_1  | 2018-04-12 15:44:40.834	[RPC0]	ERROR	wallet.rpc	src/wallet/wallet_rpc_server.cpp:109	Exception at while refreshing, what=no connection to daemon

Anyone knows how I can connect monero-wallet-rpc to daemon which is running in the same docker container?

@stoffu
Copy link
Contributor

stoffu commented Apr 13, 2018

As the log says, the wallet RPC is failing the authentication required by the daemon:

monero_1  | 2018-04-12 15:44:35.928	[RPC0]	ERROR	net.http	contrib/epee/include/net/http_client.h:424	Client has incorrect username/password for server requiring authentication

which needs to be set via the daemon-login setting. The rpc-login setting of the wallet RPC is another authentication that the wallet RPC requires from the users accessing the wallet RPC.

@skinderis
Copy link
Author

skinderis commented Apr 13, 2018

@stoffu, Yep that was exactly my issue! I just removed rpc login and pass from daemon conf file and wallet syncs with the daemon 👍

@dEBRUYNE-1
Copy link
Contributor

+resolved

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants