Pages:
Author

Topic: [Linux] Autominer v0.3.2.6 - GPU Monitor, Downtime Swapper, New Interface - page 8. (Read 23494 times)

inh
full member
Activity: 155
Merit: 100
Cool script Smiley

Am I the only one that uses a single screen session for all my miners? :-/
full member
Activity: 140
Merit: 100
firstbits: 1kwc1p
Glad to be helping people out, I'm uploading v0.2 right now and adding it to first post.
full member
Activity: 126
Merit: 100
Great! Thank you.
I'm also using a much more "simpler" bash script, nice to have a backup server now.
This also helps me to learn more about script writing, so thumbs up for you. Smiley
full member
Activity: 140
Merit: 100
firstbits: 1kwc1p
Oops, I some how missed that you used screen already. Script skimming comprehension fail. Its early (for me at least), ignore my blather.

I'm beating my head against the wall for not thinking about checking for bum miners with gpu load. I was using wget and grep to check deepbit's api for statuses, which is fine i guess, but not good for solo miners or pools without an api like db's.

Yeah I'm just doing a check for GPU load below 90%, then sleeping 15 sec to make sure it's not an anomoly, then killing the miner and changing to backup pool if it's not fixed.

Also, version 0.2 should be up soon, with regular status reports to the main window so that you can see everything is mining, removing the annoying 'All seems fine' message every 2 minutes, and timestamps in the main window.
mf
newbie
Activity: 24
Merit: 0
Start the miners each in their own GNU Screen sessions [..] will allow users to view the miners though SSH.

I use tmux for my miner(s), as:
- it can be split horizontally/vertically, so I can have a number of miners in one "window"
- its launch can be scripted, so you can have one .sh script launch a number of miners each with their own details *and* detach the whole
- it can be scripted and the buffer saved somewhere, to be later handled via other GNU tools

For example: on screen 0, window 1, pane 0 I have a miner; on pane 1 another.

Code:
echo "Miners' info:"
for pane in 0 1; do
  tmux capture-pane -t 0:1.$pane # captures the contents of the pane for the 1st miner
  tmux save-buffer /tmp/buff-01$pane # saves it to a file
  echo "Miner $pane: $(tail -n 1 /tmp/buff-01$pane)" # gets the latest line, usually the one with MHash/sec
done


I also modify the miners to report found/rejected blocks on STDERR, then munge it with some Perl and display the graph on a site, but having only one graphics card I'm not sure how useful the thing is to you guys Wink
newbie
Activity: 49
Merit: 0
Oops, I some how missed that you used screen already. Script skimming comprehension fail. Its early (for me at least), ignore my blather.

I'm beating my head against the wall for not thinking about checking for bum miners with gpu load. I was using wget and grep to check deepbit's api for statuses, which is fine i guess, but not good for solo miners or pools without an api like db's.
full member
Activity: 140
Merit: 100
firstbits: 1kwc1p
Nice work, I made some similar scripts myself but never incorporated pool detection/switching.

Start the miners each in their own GNU Screen sessions and set this to run at start up in your DE of choice (and set automatic log in of course) and bam, this script is now ideal for headless mining. The screen sessions will allow users to view the miners though SSH. I like to start an extra session as well just so i can run aticonfig if i need to check my temps/adjust fan speed/what have you.

I've been working on a way to detect locked up miners, I'll let you know if I find anything interesting.

I'm just detecting GPU load via aticonfig --adapter=X --odgc and killing GPUs which aren't under load.

Also, yeah this works for headless I guess, screens are named $identifier-MINER so if you set an identifier to 'Radeon5850' the screen would be called 'Radeon5850-MINER'. Temp screen is called 'temps'.
newbie
Activity: 49
Merit: 0
Nice work, I made some similar scripts myself but never incorporated pool detection/switching.

Start the miners each in their own GNU Screen sessions and set this to run at start up in your DE of choice (and set automatic log in of course) and bam, this script is now ideal for headless mining. The screen sessions will allow users to view the miners though SSH. I like to start an extra session as well just so i can run aticonfig if i need to check my temps/adjust fan speed/what have you.

I've been working on a way to detect locked up miners, I'll let you know if I find anything interesting.
full member
Activity: 140
Merit: 100
firstbits: 1kwc1p
Autominer 0.3.2.6 - New Interface Baby!

I decided to redo the thread from scratch to better explain Autominer. I felt that the old thread rambled a bit and didn't explain enough, so this one should be better designed to take care of the users' needs.

About Donate Mode

A few people were saying they'd like to donate but have no BTC up front, so if you want to, just edit common.lib (on v0.3.2.3 or above) and put the following line at the bottom:

donateMode=1

It will automatically give me 1 out of every 200 mining cycles (0.5% of your mining time). I will implement an option later so you can decide how much to donate.

This option is off by default, it's purely optional, and thanks if anyone decides to use it.


Download Autominer v0.3.2.6




What is Autominer?
Autominer is a bash script (technically, a set of bash scripts) written to automate the process of mining on a Linux rig. After a relatively short configuration time, you can just type a single command to start mining on all of your GPUs, in screen sessions for remote monitoring, with a temperature monitor and automatic pool monitoring and swapping in the case of downtime. Interested? Good.

And some history...

v0.3.2.6
- Bug fix of the checkphoenix.sh script (it was connecting to the wrong pool)
- Bug fix in screen settings

v0.3.2.5
- Added a 'countTarget' variable to change the frequency of 'successfully mining' updates
- Added a checkphoenix.sh script for diagnostic purposes
- Added better output to configure.sh when no workers are chosen
- Fixed a bug that was causing configure.sh to ask about donateMode for each GPU

v0.3.2.4
- Fixed a bug in configure.sh where it was writing Worksize variable to queuesize.
- Cleaned up configure.sh

v0.3.2.3
- Fixed a bug with the 'kill process' function.
- Cleaned up some text outputs.
- Added getting the CHANGELOG when using an outdated version.
- Fixed the loop function in the main program.
- Added 'donation mode' (optional, of course). To donate 0.5% of your mining to aid Autominer
development, just add 'donateMode=1' to common.lib. This will cause one in every two hundred cycles
to be donated.

v0.3.2.2
- Added support for PLATFORM in Phoenix.

v0.3.2.1
- Fixed a bug which caused pool switching not to work on machines with both monitoring modes enabled
if the downtime was picked up by GPU load first.

v0.3.2
- Added support for hashrate-based pool downtime detection in addition to GPU-load based, works even
if overdrive won't report GPU load (it's an issue for some people with risers) - needs XML RPC enabled
- Fixed a bug with downloading 'LATEST' file

v0.3.1
- Added experimental support for thejfk's getRate.py hack to display hashrate in miner window
- Rewrote the entire interface to use a single screen window, takes some getting used to

v0.3
- Added defaults files in order to avoid overriding a user's config upon update
- Added warning and disabled pool monitoring if GPU load can't be found (previously caused error spew)
- Added a stopmining.sh script which should look through screens and kill all Autominer screens
- Added detection for obsolete versions
- Added an experimental configuration script
- Removed version numbers from several script headers
- Moved opening the temps window to the main script
- Changed the temps window so that height corresponds to number of GPUs

v0.2
- Added status update to monitor where cards are mining and if cards are mining
- Added timestamps to output in main window

v0.1b
- Added support for phoenix failures, added workers

v0.1
- Got it working


What does Autominer need?
Autominer needs a relatively standard set of Linux tools, plus a mining program, those are:
tar - To extract the archive in the first place
wget - To check for updates to the package
screen - For monitoring sessions
xterm - To load the terminal windows themselves
phoenix-miner - To mine delicious coins!

To get this short list of tools (other than Phoenix, that's here in the forum) in the main distros is easy, fire up a command line and type:

Ubuntu Natty: sudo apt-get install screen tar wget xterm
Debian: sudo apt-get install screen tar wget xterm
Arch Linux: pacman -S screen tar wget xterm
Gentoo: emerge screen tar wget xterm

In addition, you need to be running X11 in order to take advantage of ATI Overdrive & multiple Xterm windows, and you need a few minutes to go through configuration the first time you run it.


So, how do I install it?

Well, download the tar.gz file at the top, then go to your favourite command line and navigate to where you put it. Do:

tar xvfz Autominer-x.x.tar.gz (where x.x is the version number)
cd Autominer
./configure.sh

Follow the instructions in the configuration script, assuming it works it will spit out two files called cards.lib and common.lib, with all the information you put into the script contained in them.


I'm running Autominer, how do I update it?

If your existing version is 0.3 or above, follow these instructions. If you're on 0.1, 0.1b or 0.2, you'll need to remove your existing Autominer & follow the install instructions as above. This is because 0.3 changed the file structure and the variable names, and is fairly incompatible with lte v0.2 config files.

Assuming you're running v0.3 already, simply download the .tar.gz and extract the files into your Autominer directory. This will not overwrite cards.lib or common.lib, as I have modified the file structure to preserve these files which contain your settings.


How do I *RUN* this beast?

First of all kill any miners you have open, then go to the Autominer directory and run ./startmining.sh /path/to/Autominer

Controls for the window:
F1-F6 = Windows 0-5
F7 = Previous window
F8 = Next window
Ctrl-a then a number = That number window
Ctrl-a then d = Detach screen (keeps miner running)


You have MH/S in your 'amm' window... how do I get that?

This technique relies upon a patch to Phoenix developed by thejfk, but it's relatively easy.

1. Open up a command line
2. cd to your phoenix directory
3. wget http://robertlacroix.com/files/phoenix-xmlrpc.diff
4. patch -p0 < phoenix-xmlrpc.diff
5. Send thejfk a tip: 1EhQ1dbeZnxs7wZKngegsHLheAjUK37k7m
6. cd to your Autominer directory
7. Edit common.lib, at the bottom write on a new line:
xmlRPCEnabled=1;
8. Start up your miner, the rest should happen automatically


And how do I monitor it over ssh?

If you want to open over ssh, do DISPLAY=:0 ./startmining.sh /path/to/Autominer

Connect to the screen using screen -x amm -p 0


So, what happened to the file structure?

Previously, whenever you updated Autominer, it came with a new cards.lib and common.lib, this meant you had to re-configure everything every time. Now, I've created files called cards.defaults.lib and common.defaults.lib.

These files allow me to define new variables without overwriting the variables you've saved in your configuration scripts. Obviously, you shouldn't edit the defaults files (they'll be overwritten when you update) but if you want to change something in there, simply copy the variable into cards.lib or common.lib and change it there.

Variables in cards.lib and common.lib OVERRIDE those in cards.defaults.lib and common.defaults.lib. The only time the defaults will be used is if something isn't defined in YOUR config settings.


Can I still manually modify the .lib files?

Sure can. Just copy cards.sample.lib to cards.lib and common.sample.lib to common.lib and modify. Don't edit the defaults, they will be overwritten when you update again.


Common Problems & Troubleshooting

Computer clearly mining but autominer won't connect to the display - Often caused by starting an identifier name with a number. Check your identifier names start with a letter.
Pages:
Jump to: