@@ -11,7 +11,6 @@ A set of convenience scripts, written in bash, to help manage installation, conf
11There is allot to install so the install script will do most of the heavy lifting.
11There is allot to install so the install script will do most of the heavy lifting.
12At the start the expectation is that you have:
12At the start the expectation is that you have:
13* Computer running Ubuntu 18.04 (LTS)
13* Computer running Ubuntu 18.04 (LTS)
15* User account with sudo privileges
14* User account with sudo privileges
16* Installed git
15* Installed git
17* Optionally installed [xmrig-proxy](https://github.com/xmrig/xmrig-proxy)
16* Optionally installed [xmrig-proxy](https://github.com/xmrig/xmrig-proxy)
@@ -20,64 +19,58 @@ At the start the expectation is that you have:
21Some knowledge of:
20Some knowledge of:
22* Linux Command Line Interface
21* Linux Command Line Interface
23−* Linux shell `bash`
22+* Unix shell `bash`
25−### Installation
24+There is more to install but the install script will install the rest.
271. Change to your user home directory.
281. Change to your user home directory.
29−1. Install git.
31+2. Install git.
30 `sudo apt install git`
32 `sudo apt install git`
31−1. Clone this project.
34+3. Clone this project.
32 `git clone https://github.com/seanwhe/xmrig-bash-scripts`
35 `git clone https://github.com/seanwhe/xmrig-bash-scripts`
33−1. Change into the cloned directory.
37+4. Change into the cloned directory.
34 `cd xmrig-bash-scripts`
38 `cd xmrig-bash-scripts`
40+5. Edit the settings file to your preference.
35−1. Run the install script
43+6. Run the install script
36 `./install.sh`
44 `./install.sh`
37−1. When prompted: "Enter your own settings?" enter 'y'es.
45+
38−1. Enter values for your:
40− 1. Pool server TCP port
41− 1. Receive wallet address
43− 1. Miner identifier name
44−1. After install is complete. Attach to the screen session created during the installation.
46+7. Attach to the screen session created during the installation.
45 `screen -r`
47 `screen -r`
47### Operation
49### Operation
49−Defaults - The settings.sh contains a number of variables. With the exception of the 'xmrig' binary, which is installed to `/usr/bin/xmrig`, all files remain in the cloned project directory `~/xmrig-bash-scripts`. Any files generated while running the scripts are also created in this directory.
51+With the exception of the 'xmrig' binary, which is installed to `/usr/bin/xmrig`, all files remain in the cloned project directory `~/xmrig-bash-scripts`. Any files generated while running the scripts are created in this directory.
51−During install the folder source for [xmrig cpu](https://github.com/xmrig/xmrig) is cloned to `~/xmrig-bash-scripts/xmrig-cpu/`. The file `config.json`, used to configure xmrig, is also created in this path and is passed to xmrig at startup.
53+During install the folder source for [xmrig cpu](https://github.com/xmrig/xmrig) is cloned to `xmrig-cpu/`in the path. The `config.json` is also created in this path.
53−During installation it is recomended to enter your own settings. This creates a file named 'mysettings.sh' which will not be overwritten during future installs or upgrades. Values for variables found in 'mysettings.sh' are used to create 'config.json'.
55+This should work out the box, if you edit only the top section of `settings.sh`.
55−This should work out the box, if you follow the installation steps and enter your own values for 'mysettings.sh.
57Once you have a running xmrig then you can start playing around and tweaking to suite requirements.
57Once you have a running xmrig then you can start playing around and tweaking to suite requirements.
59−What follows is a brief of the shell scripts you will find. The names are mostly self explanatory.
60−Comments and notes are used liberally in the scripts to help give you hints as to how it works.
61−The scripts are designed to be modular to promote resuse, execute exclusion and standalone execution.
59+What follows is a brief of the shell scripts you will find. The names are mostly self explanatory. Comments and notes are used liberally in the scripts to help give you hints as to how it works. The scripts are designed to be modular to promote resuse, execute exclusion and standalone execution.
63* build.sh - clones xmrig to ``~/xmrig-bash-scripts`/xmrig-cpu`, configures, builds and copies xmrig to `/usr/bin/`
61* build.sh - clones xmrig to ``~/xmrig-bash-scripts`/xmrig-cpu`, configures, builds and copies xmrig to `/usr/bin/`
64* config.sh - contains variables that aid in defining the values for the attributes found in config.json.
62* config.sh - contains variables that aid in defining the values for the attributes found in config.json.
65* crontab.sh - installs a cron to start and a cron to stop at specific times (Can be commented out of install if desired).
63* crontab.sh - installs a cron to start and a cron to stop at specific times (Can be commented out of install if desired).
66−* crontab-off - removed the users crontab created during install.
67−* crontab-on.sh - redefines the users crontab as created during install.
68* depends.sh - installs dependancies required by xmrig and these scripts.
64* depends.sh - installs dependancies required by xmrig and these scripts.
69* functions.sh - a collection of functions used in various of the scripts.
65* functions.sh - a collection of functions used in various of the scripts.
70−* input.sh - prompts to enter values for creating 'mysettings.sh'
71* install.sh - the main entry point when first installing.
66* install.sh - the main entry point when first installing.
72−* maintenance.sh - performs apt update, upgrade, autoremove and autoclean operations.
67+* maintenance.sh - performs apt update and upgrade.
73* settings.sh - contains variables used by these scripts.
68* settings.sh - contains variables used by these scripts.
74* start.sh - starts xmrig in a screen session.
69* start.sh - starts xmrig in a screen session.
75* stop.sh - stops xmrig screen session.
70* stop.sh - stops xmrig screen session.
77### Viewing the log
72### Viewing the log
78−Default of the start script is to create a screen session named 'xmrig-cpu'.
79−This can be changed in the settings script if required.
80−To view the log after installation is finished or after running the start script, used the following command:
73+Default of the start script is to create a screen session named 'xmrig-cpu'. This can be changed in the settings script if required. To view the log after installation is finished or after running the start script, used the following command:
81`screen -r xmrig-cpu`
74`screen -r xmrig-cpu`
83### Updating
76### Updating
@@ -86,14 +79,11 @@ A simple `git update` in `~/xmrig-bash-scripts` will update these scripts.
86The install script can be run at any time to update the xmrig source found `~/xmrig-bash-scripts/xmrig-cpu`.
79The install script can be run at any time to update the xmrig source found `~/xmrig-bash-scripts/xmrig-cpu`.
87The branch checkout is taken from the `_XMRIG_BRANCH` variable in `settings.sh`.
80The branch checkout is taken from the `_XMRIG_BRANCH` variable in `settings.sh`.
89−A script named update.sh is provided to perform both these steps in a single command.
91## Reporting issues
82## Reporting issues
93[xmrig cpu](https://github.com/xmrig/xmrig) and [xmrig bash scripts](https://github.com/seanwhe/xmrig-bash-scripts.git) are different projects run by different people.
84[xmrig cpu](https://github.com/xmrig/xmrig) and [xmrig bash scripts](https://github.com/seanwhe/xmrig-bash-scripts.git) are different projects run by different people.
95−While the developers of both projects may be seen interacting with one another on either project, we ask that you report issues to the respective projects.
86+While the developers of both projects may be seen interacting with one another on either project, we ask that you report issues to the respective projects. In other words, post issues for:
96−In other words, post issues for:
97* xmrig, the Monero (XMR) CPU miner, over at [xmrig issues tracker](https://github.com/xmrig/xmrig/issues)
87* xmrig, the Monero (XMR) CPU miner, over at [xmrig issues tracker](https://github.com/xmrig/xmrig/issues)
98* xmrig-bash-scripts, these conveniece scripts, over at [xmrig-bash-scripts](https://github.com/seanwhe/xmrig-bash-scripts/issues)
88* xmrig-bash-scripts, these conveniece scripts, over at [xmrig-bash-scripts](https://github.com/seanwhe/xmrig-bash-scripts/issues)