Software: Ubuntu on VirtualBox

Update, tried putting two dashes, on allow-insecure-unlock, doesn't work

solidity@solidity:~$ geth attach --allow-insecure-unlock
Incorrect Usage: flag provided but not defined: -allow-insecure-unlock

attach [command options] [arguments...]

The Geth console is an interactive shell for the JavaScript runtime environment
which exposes a node admin interface as well as the Ðapp JavaScript API.
See https://github.com/ethereum/go-ethereum/wiki/JavaScript-Console.
This command allows to open a console on a running geth node.

                                      --datadir value                       Data directory for the databases and keystore (default: "/home/solidity/.ethereum")

                                      --jspath loadScript                   JavaScript root path for loadScript (default: ".")
                                      --exec value                          Execute JavaScript statement
                                      --preload value                       Comma separated list of JavaScript files to preload into the console

flag provided but not defined: -allow-insecure-unlock

I am on the Rinkeby test network, following the Pluralsight tutorial.

I am having an issue with unlocking account, and many places suggest starting geth with allow-insecure-unlock.

Still doesn't work

solidity@solidity:~$ geth attach allow-insecure-unlock
Welcome to the Geth JavaScript console!

instance: Geth/v1.9.7-stable-a718daa6/linux-amd64/go1.13.4
at block: 5493433 (Sat, 23 Nov 2019 15:24:19 EST)
 modules: eth:1.0 net:1.0 personal:1.0 rpc:1.0 txpool:1.0 web3:1.0

> personal.unlockAccount("0x97b7d25255b6664e8defac7895c6d6ee7e21d2f5")
Unlock account 0x97b7d25255b6664e8defac7895c6d6ee7e21d2f5
Error: account unlock with HTTP access is forbidden
  • You can only use --allow-insecure-unlock when starting a geth instance. It will not work when attaching to a running instance. – Ismael Nov 24 '19 at 15:17
  • You mean like this, sudo geth --rinkeby --rpc --rpcapi="eth,net,web3,personal,txpool" --syncmode=light --allow-insecure-unlock – Marium Nov 24 '19 at 17:22
  • Yes, it should when you start geth instance. – Ismael Nov 24 '19 at 19:00
  • Thanks, it now works! – Marium Nov 24 '19 at 21:26

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.