Skip to content
Prev 366688 / 398502 Next

xvfb? cron job updates R packages, fails on some requiring X11

In Centos 7 systems, I wrote a script that runs on the cron and I
notice some package updates and installs fail like this:


Error : .onLoad failed in loadNamespace() for 'iplots', details:
  call: .jnew("org/rosuda/iplots/Framework")
  error: java.awt.HeadlessException:
No X11 DISPLAY variable was set, but this program performed an
operation which requires it.
Error: loading failed
Execution halted
ERROR: loading failed
* removing ?/usr/share/R/library/iplots?
* restoring previous ?/usr/share/R/library/iplots?


I can log in interactively and run  the same install successfully.

I understand I need something like xvfb to simulate an X11 session,
but I don't understand how to make it work.  Can one of you give me an
idiot's guide on what to do?

pj