Pages:
Author

Topic: cgmon - mining monitor for Linux - auto restart, reboot, sick gpu, ASIC, &more - page 8. (Read 48363 times)

newbie
Activity: 56
Merit: 0
Just what I've been looking for. Thanks for this
sr. member
Activity: 269
Merit: 250
I'm not getting any mail. Also if I debug, I get the message
Code:
invalid bareword "exited"
in expression "exited - 11";
should be "$exited" or "{exited}" or "exited(...)" or ...
    (parsing expression "exited - 11")
    invoked from within
"expr  $current_accepted($n) -  $previous_accepted($n)"
    (procedure "check_status" line 190)
    invoked from within
"check_status"
    (file "./cgmon.tcl" line 579)

Run this command and send me the output please.
Code:
php -f /tmp/cgmon-api.php devs | grep "Accepted] =>" | grep -v Diff
sr. member
Activity: 269
Merit: 250
In the file change "Ubuntu: apt-get install libtcl tcl-tls" to "Ubuntu: apt-get install tcllib tcl-tls"

Fixed, thanks!
newbie
Activity: 34
Merit: 0
Hi,

if I add the following to the end of the cgminer command in cgmon-mine.sh shouldn't it capture the output?

2>> ~/log/_cgminer_log.txt

I want to be able to track whenever a pool failover happens.

This creates the log file but nothing is written to it.


cgmon-mine.sh is created whenever cgmon starts cgminer.  So you actually make that change within cgmon.tcl.  Try adding it to the end of your $cgminer_gpu_options line in cgmon.tcl

Actually the issue is with screen...  When I try logging to a file it only works when NOT using screen...  

You can log cgminer ouput by adding -L to the screen options in cgmon.tcl.

Code:
set screen_cmd "screen -mdL"

Will leave a screenlog.0 file in the current working directory.  Let me know if you find another way to do it.



Thanks jdape.

This works.

You can also copy /etc/screenrc file to your working directory and rename it .screenrc to modify screen variables.

E.g. add the following line to customise your log filename to cgminer_log_2014_02_15.txt:

logfile "/home/user/log/cgminer_log_20%y_%m_%d.txt"
hero member
Activity: 773
Merit: 528
I'm not getting any mail. Also if I debug, I get the message
Code:
invalid bareword "exited"
in expression "exited - 11";
should be "$exited" or "{exited}" or "exited(...)" or ...
    (parsing expression "exited - 11")
    invoked from within
"expr  $current_accepted($n) -  $previous_accepted($n)"
    (procedure "check_status" line 190)
    invoked from within
"check_status"
    (file "./cgmon.tcl" line 579)
hero member
Activity: 773
Merit: 528
In the file change "Ubuntu: apt-get install libtcl tcl-tls" to "Ubuntu: apt-get install tcllib tcl-tls"
sr. member
Activity: 269
Merit: 250
FYI, to debug SMTP AUTH, change line 480 from:
Code:
			-debug false \
to
Code:
			-debug true \
sr. member
Activity: 269
Merit: 250
cgmon 1.0 through 1.0.3 have just been released.

New features:
  • SMTP Authentication support! Works with gmail.
  • Automatic version check and script updating.   If you run
Code:
./cgmon.tcl update
cgmon will determine if there's a new version available.  If so, it will download the new version and migrate your existing configuration settings into cgmon.tcl.tmp.   Then you can move the temp file to cgmon.tcl.

# 1.0
#   Added auto update procedure:  ./cgmon.tcl update
#   Added SMTP AUTH support.
#   Added screen command syntax to output when starting.
# 1.0.1 & 1.0.2
#   Bug fixes
# 1.0.3
#   Added new version notifications to emails, when applicable.



Update procedure in action:

Code:
apex@miner3:~$ ./cgmon.tcl update
--2014-02-15 00:06:37--  http://www.forked.net/~apex/cgmon/cgmon.tcl
Resolving www.forked.net (www.forked.net)... 38.103.167.118
Connecting to www.forked.net (www.forked.net)|38.103.167.118|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 25702 (25K) [application/x-tcl]
Saving to: `cgmon.tcl.autoupdate'

     0K .......... .......... .....                           100%  657K=0.04s

2014-02-15 00:06:37 (657 KB/s) - `cgmon.tcl.autoupdate' saved [25702/25702]

Version Check:  You have 1.0.2, latest is 1.0.3.
Updating now...
Update successful! cgmon 1.0.3 is now located at /home/apex/cgmon.tcl.tmp. To finish the update process run this command:
mv /home/apex/cgmon.tcl.tmp /home/apex/cgmon.tcl
apex@miner3:~$ mv /home/apex/cgmon.tcl.tmp /home/apex/cgmon.tcl
apex@miner3:~$ ./cgmon.tcl
Feb 15 00:13:34 miner3 - cgmon 1.0.3 - cgminer running and all GPUs healthy.
hero member
Activity: 773
Merit: 528
Has anyone found a free SMTP server to use for email receiving? My ISP's needs authentication..
sr. member
Activity: 269
Merit: 250
Hi,

if I add the following to the end of the cgminer command in cgmon-mine.sh shouldn't it capture the output?

2>> ~/log/_cgminer_log.txt

I want to be able to track whenever a pool failover happens.

This creates the log file but nothing is written to it.


cgmon-mine.sh is created whenever cgmon starts cgminer.  So you actually make that change within cgmon.tcl.  Try adding it to the end of your $cgminer_gpu_options line in cgmon.tcl

Actually the issue is with screen...  When I try logging to a file it only works when NOT using screen...  

You can log cgminer ouput by adding -L to the screen options in cgmon.tcl.

Code:
set screen_cmd "screen -mdL"

Will leave a screenlog.0 file in the current working directory.  Let me know if you find another way to do it.
newbie
Activity: 26
Merit: 0
MrBob I appreciate the help. I have put in a call to someone who will hopefully know. If all else fails I will switch out of SMOS and move over to pure BAMT.
member
Activity: 110
Merit: 10
Possibly an SMOS issue, though not likely.  Unfortunately friend, I've gone through the list of things I thought it could be, unless there is a problem with syntax somewhere in your /etc/crontab on a different line?
newbie
Activity: 26
Merit: 0
Something is up with my cron. I tried to start the service with this:
/etc/init.d/cron start


And I get this:
Starting periodic command scheduler: cron failed!
newbie
Activity: 26
Merit: 0
I tried "user" and it did not work. I just now even downloaded a new cgmon.tcl file to the "user" profile. Ran the chmod, and did everything like I am suppose to, pointed the cron to the correct place. Once again it will run manually but will not run with cron. I am using 1.3 SMOS which runs on BAMT.
member
Activity: 110
Merit: 10
No, I have that too.  That wouldn't impact the ability to just run the monitoring and output the cgmon.log file. That could be it with the root user.  Mine is "user." Try that.  I'm thinking there must be something different between yours and mine.  Your user being "root" could be it.  What version of BAMT are you using?  I use 1.3.
newbie
Activity: 26
Merit: 0
I did do this command recommended by Angela earlier in the thread:

set cgminer_gpu_options "-c /etc/bamt/cgminer.conf"

Thats because i would like to be able to set my gpu options via the cgminer.conf file. Not sure if maybe that messed things up.
newbie
Activity: 26
Merit: 0
Yes.

"api-listen" : true,
member
Activity: 110
Merit: 10
Do you have "api-listen" : true in your /etc/bamt/cgminer.conf?
newbie
Activity: 26
Merit: 0
Just so this is clear. I check the log after a manual run of the script and its been recorded in the log. I do not see any other runs in the log other then the ones that I have done manually.
newbie
Activity: 26
Merit: 0
chmod 755 /home/cgmon.tcl

check the settings to see where the log file is pointed to.

Also, did you do the following?

apt-get update
apt-get install tcl
apt-get install php5-cli
apt-get install php5

When I did this for the first time, just php5 wasn't enough, I needed php5-cli.  This is not in the instructions.
I did the chmod again.

For the log I have two outputs it seems:
/root/cgmon.log
/live/cow/root/cgmon.log

I just tried to install php5-cli and it showed to already be installed.

Also, for the "user" in the cgmon.tcl file I have it designated "root".  

I can still run the file manually, but cron will not run it. 
Pages:
Jump to: