How to run grin-miner?

When I run “cd grin-miner
grin-miner” ,
It appears:
/grin-miner$ grin-miner
grin-miner: command not found

Can you help me ?

First check that your binaries (grin-miner) is in the directory you are expecting.
When compiling from source the binaries are created in the ~/grin-miner/target/debug directory.

Linux handles the searchpath a little strange.
If you type “echo $PATH” you get all the paths that are searched for with your command.
Your local position “./” is not included within your $PATH variable.
You need to include your current position when executing your command, ./grin-miner

There is a .profile file that should exist in your /home/username directory if you’re on linux or Users/username directory if you’re on mac.

In your terminal enter these commands

  • cd
  • nano .profile

Copy and paste the following lines at the end of your now open .profile file

  • export PATH="$HOME/grin-miner/target/debug:$PATH"
  • export PATH="$HOME/grin/target/release:$PATH"

Now save an exit your edited .profile with:

  • Ctrl and x keys to exit
  • y to save
  • enter to confirm

Finally, update your path with this command

  • source ~/.profile

Now try grin-miner and see if it runs.

I do. But the problem has not been solved.
I use VM Ubuntu 16.04.
When I run :

git clone
cd grin-miner
git submodule update --init
cargo build "

It appear:

" = note: /usr/bin/ld: cannot find -lOpenCL
/usr/bin/ld: cannot find -lOpenCL
collect2: error: ld returned 1 exit status

error: aborting due to previous error

error: Could not compile ocl_cuckatoo. "

I don’t know where the problem is.

Info from grin-miner instructions…

Building the OpenCL plugins

OpenCL plugins are not enabled by default. Run script to build and install them.


You must install OpenCL libraries for your operating system before. If you just need to compile them (for development or testing purposes) build grin-miner the following way:

cargo build --features opencl

I solved the installation problem.
On VM Ubuntu ,you should First switch to ROOT(Input command: sudo -i ).
Then installation Grin v0.5 Step by Step.

But there is another problem.
When I run grin-miner it cannot connect.
Grin miner version 0.5.0 appears:
“Connection status: can’t establish server connection to Will retry every 5 seconds
Mining status: waiting for server "
My Grin version 0.5.0 is connected. It appears:
" Current status: running”
"connected peers: 27 "
What should I do ?