|
June 07, 2013, 01:11:53 PM |
|
Hello, i've got a strange problem on Ubuntu lts with sudoers
Here it is : I bought a usb block erupter so i want to configure my startup script to launch cgminer automatically. The usb block erupter need some sudo right on cgminer to works so manually i wrote a very simple asic.sh file : ./cgminer [blah blah] and it works just fine
Then i change my .sh file to sudo ./cgminer [blah blah]
and i change visudo with that worker-2 ALL=(ALL) NOPASSWD: ALL (yeah i know not very secure but this is just for the exemple)
now i can start cgminer without entering my sudo password and it works.
The problem is that my boot script as commands like that: gnome-terminal -x sh command1.sh & gnome-terminal -x sh command2.sh & gnome-terminal -x sh ~/cgminer-3.2.1/asic.sh and this open 3 terminal BUT it ask for the password of worker-2. how is it even possible?
I changed asic.sh to add whoami before and it says that i am worker-2... To sum up i change sudoers to give worker-2 all the rights without password ( and it works manually). Then i launch a script on startup that need sudo (with worker-2) and it asked me a password..
Not sure i am very clear.
|