Can you explain how you are going to accomplish this?
http://www.ipnetcontrol.net/en/item-products-en/p-4r1t1a-bgNo English version you can use google translate from Bulgarian
There are two options
1. power device can be controlled via snmp and power off / on each of the four power lines independently. It has web interface also which can be used for power off/on manually. The process of monitoring and restarting four independent power lines can be automated via shell sell script
2. Automatic way that is what i am going to use first when more Avalons come one of them will monitor the rest and control power lines via snmp accordingly
How it will be done Power Device has a built in function to monitor every minute via ping given IP address and when ping fails it can restart (power off/on) one of the configured power lines where avalon unit is connected. So there is built in script inside avalon which does soft restart when accepted shares are not changing or when cg miner is dead
#!/bin/sh
# This file is for cron job
C=`pidof cgminer | wc -w`
if [ "$C" != "1" ]; then
/etc/init.d/cgminer stop
/etc/init.d/cgminer start
exit 0;
fi
A=`cat /tmp/cm.log`
B=`cgminer-api | grep "^ \[Accepted\]"`
cgminer-api | grep "^ \[Accepted\]" > /tmp/cm.log
if [ "$A" == "$B" ]; then
/etc/init.d/cgminer stop
/etc/init.d/cgminer start
exit 0;
fi
https://github.com/BitSyncom/cgminer-openwrt-packages/blob/master/cgminer/files/cgminer-monitorThe quick and dirty hack to this script is changing
/etc/init.d/cgminer stop
/etc/init.d/cgminer start
to ip a f dev br-lan or whatever interface name is
then power device will not be able to ping avalon unit and within a minute it will be rebooted powerd off and on:)
Nice easy and clean:)