Welcome to WebmasterWorld Guest from 54.145.222.231

Forum Moderators: bakedjake

Message Too Old, No Replies

(firefox-bin:): Gtk-WARNING **: cannot open display:

launching firefox with crontab

   
9:47 pm on Apr 9, 2008 (gmt 0)

10+ Year Member



Hi,

I have a crontab entry that supposed to launch firefox browser but it does not work. Here is the cron:

45 14 * * 3 DISPLAY=localhost:0.0;/usr/lib/firefox/firefox

I get the following error:
(firefox-bin:27852): Gtk-WARNING **: cannot open display:

It still does not work after i do 'xhost localhost'.

Ideas?

thanks,
tatarin

10:38 pm on Apr 9, 2008 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Not sure but try
export DISPLAY=localhost:0.0;/usr/lib/firefox/firefox
11:32 am on Apr 10, 2008 (gmt 0)

5+ Year Member



Or just remove the stray ; before the firefox command.

export sets the variable for the rest of the session, specifying it at the start of the command means it only applies for that command. You probably only need it for that command so just replace the ; with a space.

 

Featured Threads

Hot Threads This Week

Hot Threads This Month