Tuesday, May 7, 2024
 Popular · Latest · Hot · Upcoming
3
rated 0 times [  3] [ 0]  / answers: 1 / hits: 2307  / 2 Years ago, thu, may 12, 2022, 3:55:09

I am trying to run a program that pops up a graphical notice to me. As a simple example, I have my cron settings as



@hourly xlogo


and if I launch xlogo from an interactive command, it works fine. However, when run by cron, the xlogo window never launches. How can I get cron to let xlogo launch a window, or is it just fundamentally not designed to do that?


More From » cron

 Answers
0

It is totally possible to do this with crontab.



You need to tell the script which screen you want xlogo to run on.



Try changing the line to this:



@hourly /usr/bin/env DISPLAY=:0.0 /usr/bin/xlogo


to tell crontab what display you want it to use. Depending on the program you might need to add in more enviornment variables as well.


[#36010] Saturday, May 14, 2022, 2 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
bleger

Total Points: 468
Total Questions: 108
Total Answers: 100

Location: Belarus
Member since Wed, Dec 7, 2022
1 Year ago
bleger questions
Wed, Mar 1, 23, 03:00, 1 Year ago
Mon, Feb 6, 23, 14:44, 1 Year ago
Wed, Dec 29, 21, 13:59, 2 Years ago
;