Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error: Unable to connect or start own listener. Aborting. #155

Closed
vishalvnair opened this issue Jul 29, 2013 · 2 comments
Closed

Error: Unable to connect or start own listener. Aborting. #155

vishalvnair opened this issue Jul 29, 2013 · 2 comments

Comments

@vishalvnair
Copy link

Hi,
I am using the converter ,
I have installed openoffice3

openofffice path : /opt/openoffice.org3/program/python
my unoconv is in my projects root directory and i created a doctopdf text file and run that file using exec() form a function in my project.
The content of doctopdf text file is as follows

directory=$1
filename=$2
extension=$3
SERVICE='soffice'
if [ "ps ax|grep -v grep|grep -c $SERVICE" -lt 1 ]; then
unset DISPLAY
/opt/openoffice.org3/program ./soffice.bin -headless -accept="socket,host=127.0.0.1,port=2002;urp;" -nofirststartwizard -display 0.0 &
sleep 5s
fi
/opt/openoffice.org3/program/python unoconv -f $directory$filename.pdf $directory$filename.$extension

But am getting the error
Error: Unable to connect or start own listener. Aborting.

Please help
Thanks in advance

@dagwieers
Copy link
Member

I would suggest using a newer LibreOffice release and use the latest unoconv, or the one from the master branch !

Please feel free to reopen if your issue is still pertinent.

@gsw945
Copy link

gsw945 commented Apr 14, 2017

I got same error in php, but I solved problem with 'running a unoconv listener', and It refer to Kopz Kyoto's answer

launch a unoconv listener
sudo unoconv --listener

do transcode by call unoconv
unoconv -f docx file.doc

when i execute the same command in terminal or using python to execute, it's ok.
I guess: my php is called by apache2 which belongs to www-data group, so it hasn't permission to call LibreOffice(unoconv will call LibreOffice to transcode), so there are some ways to solve the prblem:

  1. grant permission to LibreOffice so that it can be called by which source process from www-data group;
  2. launch a unoconv listener process to receive transcode request (Kopz Kyoto's answer, i preference this way).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants