0
Under review

java.awt.AWTError: Can't connect to X11 window server using ':0.0' as the value of the DISPLAY variable.

Ivar Kramer 4 years ago updated by Tom 4 years ago 1

I just installed Ubooquity and get the follwing when starting headless.


20170107 14:57:36 [Scanner thread] ERROR com.ubooquity.Ubooquity - Uncaught exception on thread: Scanner threadjava.awt.AWTError: Can't connect to X11 window server using ':0.0' as the value of the DISPLAY variable.
      at sun.awt.X11GraphicsEnvironment.initDisplay(Native Method) ~[na:1.8.0_111]
      at sun.awt.X11GraphicsEnvironment.access$200(X11GraphicsEnvironment.java:65) ~[na:1.8.0_111]
      at sun.awt.X11GraphicsEnvironment$1.run(X11GraphicsEnvironment.java:115) ~[na:1.8.0_111]
      at java.security.AccessController.doPrivileged(Native Method) ~[na:1.8.0_111]
      at sun.awt.X11GraphicsEnvironment.(X11GraphicsEnvironment.java:74) ~[na:1.8.0_111]
      at java.lang.Class.forName0(Native Method) ~[na:1.8.0_111]
      at java.lang.Class.forName(Class.java:264) ~[na:1.8.0_111]
      at java.awt.GraphicsEnvironment.createGE(GraphicsEnvironment.java:103) ~[na:1.8.0_111]
      at java.awt.GraphicsEnvironment.getLocalGraphicsEnvironment(GraphicsEnvironment.java:82) ~[na:1.8.0_111]
      at java.awt.image.BufferedImage.createGraphics(BufferedImage.java:1181) ~[na:1.8.0_111]
      at org.apache.pdfbox.rendering.PDFRenderer.renderImage(PDFRenderer.java:129) ~[pdfbox-2.0.0.jar.3733332883789124729.tmp:2.0.0]
      at org.apache.pdfbox.rendering.PDFRenderer.renderImageWithDPI(PDFRenderer.java:94) ~[pdfbox-2.0.0.jar.3733332883789124729.tmp:2.0.0]
      at com.ubooquity.fileformat.pdf.b.a(SourceFile:71) ~[Ubooquity.jar:1.10.1]
      at com.ubooquity.fileformat.pdf.b.a(SourceFile:44) ~[Ubooquity.jar:1.10.1]
      at com.ubooquity.data.feeder.a.b(SourceFile:382) ~[Ubooquity.jar:1.10.1]
      at com.ubooquity.data.feeder.a.a(SourceFile:212) ~[Ubooquity.jar:1.10.1]
      at com.ubooquity.data.feeder.a.b(SourceFile:316) ~[Ubooquity.jar:1.10.1]
      at com.ubooquity.data.feeder.a.a(SourceFile:35) ~[Ubooquity.jar:1.10.1]
      at com.ubooquity.data.feeder.a$1.run(SourceFile:116) ~[Ubooquity.jar:1.10.1]
      at java.lang.Thread.run(Thread.java:745) ~[na:1.8.0_111]

I started it using the .sh script in the download section. I altered it a bit (added -headless in the command line) because for some reason the server went down if that was not in?!


If I start the jar file in the GUI, the scanner works but the Themes do not work. And since this is my media server i want it to run headless and be accessible from the browser only.


20170107 14:57:34 [main] INFO com.ubooquity.Ubooquity - Running with the following parameters - headless: true, port: 2202, webadmin: true, host: null, debug: false, execdir: /opt/ubooquity
20170107 14:57:34 [main] INFO com.ubooquity.Ubooquity - #############################
20170107 14:57:34 [main] INFO com.ubooquity.Ubooquity - # Starting Ubooquity #
20170107 14:57:34 [main] INFO com.ubooquity.Ubooquity - #############################
20170107 14:57:34 [main] INFO com.ubooquity.Ubooquity - Java version: 1.8.0_111
20170107 14:57:34 [main] INFO com.ubooquity.Ubooquity - Java vendor: Oracle Corporation
20170107 14:57:34 [main] INFO com.ubooquity.Ubooquity - Max heap size available: 483 MB
20170107 14:57:34 [main] INFO com.ubooquity.Ubooquity - OS name: Linux
20170107 14:57:34 [main] INFO com.ubooquity.Ubooquity - OS version: 3.2.0-4-amd64
20170107 14:57:34 [main] INFO com.ubooquity.Ubooquity - OS architecture: amd64
20170107 14:57:34 [main] INFO com.ubooquity.Ubooquity - Loading local version info
20170107 14:57:34 [main] INFO com.ubooquity.Ubooquity - Ubooquity 1.10.1 built on 2016-05-10 at 20:36
20170107 14:57:34 [main] INFO com.ubooquity.Ubooquity - Creating application folders
20170107 14:57:34 [main] INFO com.ubooquity.Ubooquity - Loading preferences
20170107 14:57:35 [main] INFO com.ubooquity.c - Starting internal server...
20170107 14:57:35 [Scanner thread] INFO com.ubooquity.data.feeder.a - Scanning books directories
20170107 14:57:35 [Scanner thread] INFO com.ubooquity.fileformat.pdf.b - Reading metadata of pdf file: /home/ivar/Downloads/Media/eBooks/3x PDF For Dummies Windows 10 for dummies-Word 2016 for professionals-SAR for dummies/Word 2016 For Professionals.pdf
20170107 14:57:35 [main] INFO com.ubooquity.c - Reverse proxy prefix is not activated
20170107 14:57:35 [main] INFO com.ubooquity.c - Internal server started. Listening on port 2202
20170107 14:57:36 [Timer-1] INFO com.ubooquity.Ubooquity - Checking latest available Ubooquity version from website

Under review

The "-headless" parameter is supposed to prevent errors like the one you posted.


Are you saying you have this error even with the "-headless" parameter ? If so, could you post your command line ?


As for the themes, did you copy your uncompressed theme in the theme directory, selected it in the settings and restarted Ubooquity ?