user14002: I trying to script the launch of cgminer based on a crontab.
Using a crontab entry that fires up a bash shell script that launches cgminer. Running the script directly launches cgminer flawlessly. Running the script from crontab always give the "no gpus usable" error.
I have triple checked that all vars are set (DISPLAY, GPU_MAX_ALLOC_PERCENT, GPU_USE_SYNC_OBJECTS=1), that the paths are correct, etc.
The entry is in the crontab accessible when being (sudo -s).
Any clues on what could be wrong ?
Again, drivers and SDK are installed correctly as everything works correctly when I launch the script manually.
The script launches cgminer with a basic cmd : 
cd dir_where_cgminer_is_stored 
./cgminer -c /folder/myconfig.conf

Thanks

user14002: Actually, I forgot to start cgminer with the user running X (being autologged in).
Doing 
su user_running_the_x_session -c "/home/user/mine.sh"

worked perfectly.
BTW Art Shayderov, yes, cron is used for repeated jobs, like for example the one I am talking about here ;)

14002: <p>I trying to script the launch of cgminer based on a crontab.</p>

<p>Using a crontab entry that fires up a bash shell script that launches cgminer. Running the script directly launches cgminer flawlessly. Running the script from crontab always give the "no gpus usable" error.</p>

<p>I have triple checked that all vars are set (DISPLAY, GPU_MAX_ALLOC_PERCENT, GPU_USE_SYNC_OBJECTS=1), that the paths are correct, etc.</p>

<p>The entry is in the crontab accessible when being (sudo -s).</p>

<p>Any clues on what could be wrong ?</p>

<p>Again, drivers and SDK are installed correctly as everything works correctly when I launch the script manually.</p>

<p>The script launches cgminer with a basic cmd : </p>

<pre><code>cd dir_where_cgminer_is_stored 
./cgminer -c /folder/myconfig.conf
</code></pre>

<p>Thanks</p>
 14002: <p>Actually, I forgot to start cgminer with the user running X (being autologged in).</p>

<p>Doing </p>

<pre><code>su user_running_the_x_session -c "/home/user/mine.sh"
</code></pre>

<p>worked perfectly.</p>

<p>BTW Art Shayderov, yes, cron is used for repeated jobs, like for example the one I am talking about here ;)</p>
