Since you can run
geth --testnet successfull, there should be no problem with
geth. Please be sure to use latest version of
$ sudo apt-get install git
$ git clone https://github.com/ethereum/go-ethereum
$ sudo apt-get install -y build-essential libgmp3-dev golang
$ cd go-ethereum/
$ param update
$ git pull
$ make geth
Based on your comment:
geth is not supposed to run in background
You may have to run
geth as being sudo, my
geth.ipc file required root access.
Fatal: Unable to attach to remote geth: dial unix /Users/myname/Library/Ethereum/testnet/geth.ipc:
connect: permission denied
I had overcome this issue as follows:
First create a "server.sh" file:
nohup geth --testnet &
echo 'loadScript("pass.js")' | sudo geth ipc:/Users/myname/Library/Ethereum/testnet/geth.ipc console #You are not required to add this line.
echo 'net' | sudo geth ipc:/Users/myname/Library/Ethereum/testnet/geth.ipc console #You are not required to add this line.
//If you have an additional script you can load and/or check
net status after
geth starts running.
Than create "client.sh" file: I assume your datadir is at
sudo geth ipc:/Users/myname/Library/Ethereum/testnet/geth.ipc console
Run following command: //This will run geth on the background with the help of nohup.
$ sudo bash server.sh
At final step when you run this command, you will be attached:
$ bash client.sh
You can observe the log file on "nohup.out" file.
$ sudo cat nohup.out