How to run cgminer on boot?
5,367
put the following code into :
/etc/init.d/rc.local
:
/home/pi/cgminer-4.5.0/cgminer -o http://xxxxxxxxxxx -u xxxxxxxx -p xxxxxxxxxx
Related videos on Youtube
Author by
user1685880
Updated on September 18, 2022Comments
-
user1685880 over 1 year
I have the following commands I want to run when the raspberry pi boots up, it is for my bitcoin minner to start:
cd /home/pi/cgminer-4.5.0 sudo ./cgminer -o http://xxxxxxxxxxx -u xxxxxxxx -p xxxxxxxxxx
How can I do this? As I have currently set it up using nohup but this only autostarts when I ssh into the pi and stops working when I close the connection. I want this code to run automatically on startup and keep running constantly. I am running Raspbian.
-
smw over 9 yearsCrossposted from here askubuntu.com/questions/526323/how-to-run-a-script-on-boot
-
terdon over 9 years@steeldriver yes, I asked them to delete the AU one since it's off topic there and I suggested the OP post here instead.
-
Ludwig Schulze over 9 yearsAny reason why you should start cgminer with root permissions?
-
user1685880 over 9 yearsI have tried starting it without root permissions, but get the error no usb connected, by starting it in root fixes the error for some reason
-
Ludwig Schulze over 9 yearsI would recommend you to ask another question about that problem. cgminer should work fine without root privileges.
-
-
user1685880 over 9 yearsThanks this seem to be working fine for me and so simple thanks :)