Trying to convert a bunch of .doc files to .pdf's. I want to use libreoffice to convert them.
I ssh into the remote box and run the command and I get a X11 error:
[%]$ libreoffice --headless --invisible --convert-to pdf --outdir /tmp /tmp/test.doc /usr/lib64/libreoffice/program/soffice.bin X11 error: Can't open display: Set DISPLAY environment variable, use -display option or check permissions of your X-Server (See "man X" resp. "man xhost" for details)
Once I enabled X11 Forwarding to the remote server, reconnect with a new session, and it works:
[%]$ libreoffice --headless --invisible --convert-to pdf --outdir /tmp /tmp/test.doc Gtk-Message: Failed to load module "canberra-gtk-module" convert /tmp/test.doc -> /tmp/test.pdf using writer_pdf_Export
So if it's "headless" on a remote server, then why does it have an X11 requirement?