I have a script that I run with
geth attach, and then I use:
primary = eth.accounts; personal.unlockAccount(primary, "password");
like I saw in the example script.
Doing this in geth usually takes about one or two seconds. I learned there was another way to unlock accounts. I was wondering if it was faster to unlock directly with
geth --unlock "0xaddress" --password "password" attach. What does it do differently ?
How can I know if it unlocked successfully ? If I use a random address or password instead of the correct ones,
attach still opens correctly.
Geth attach "opens correctly" because it ignores those flags. You can run
geth --unlock "0xaddress" --password "password" attach or
geth --password --testnet --testnet attach and it will open like
geth attach (flag order seems to be important sometimes though, you can't use
testnet or it ignores