cd
git clone https://github.com/mimblewimble/grin.git
cd grin
cargo build --release
(If you failed to build command for ‘croaring-sys …’, issue “sudo apt-get purge --auto-remove clang” then re-try)
Add command grin to environment variables for current user permanently
cd
vi .profile
Add the following line to the last line of .profile and save
export PATH="$HOME/grin/target/release:$PATH"
Add file grin-server.toml to folder grin
cd
source ~/.profile
cd grin
grin server config
Revise file grin-server.toml to enable stratum server and save
enable_stratum_server = true
C. Prepare Grin Miner step by step
Open a new command line terminal session
Install required packages
sudo apt install make libncurses5-dev libncursesw5 zlib1g-dev linux-headers-$(uname -r)
Install Grin miner
cd
git clone https://github.com/mimblewimble/grin-miner.git
cd grin-miner
git submodule update --init
cargo build
Add command grin-miner to environment variables for current user permanently
cd
vi .profile
Add the following line to the last line of .profile and save
export PATH="$HOME/grin-miner/target/debug:$PATH"
Assign more processors for mining, 1 processor will get no new job.
nthreads = 4
[Optional] To enable avx support(new CPU) or cuda support(Navidia GPU) you have to modify both grin-miner.toml and Cargo.toml files before start grin-miner, if you changed Cargo.toml, please rebuild grin. Please check steps on GitHub.
D. Restart Ubuntu to have environment variables take effect for all sessions
reboot
E. Start Grin node&wallet&miner services one by one
Start a grin node under folder grin with a terminal session and keep session live
Figured it out. just had to rebuild with cargo build after changing the Cargo.toml. Also, just as a side note, I unknowingly uncommented a bunch of tweaking parameters in grin-miner.toml originally, so I went back and commented them out again, leaving my changes to the grin-miner.toml file as:
“can’t establish server connection to 127.0.0.1:3416”
in my grin-server.toml file i have this: #what port and address for the stratum server to listen on
stratum_server_addr = “127.0.0.1:3416”
should work but doesn’t. i have both GUI’S up and running. i see cuckaroo_cuda_29 plugins for both my gpu’s with OK status but no mining. it says “Waiting for server”.
in my Grin node it says “false” for both mining server enabled and mining server running.
I found that many people encountered problems like setting up rust, compiling. Since the project release binary each time, maybe you want to change it to use binary directly. All you need to do is download the correct binary from github, uncompress and run it. The building from source code won’t make any difference but bring a lot difficulties. For those knows about building from source code, they will not need such a step.