unoconv / unoserver

MIT License
592 stars 81 forks source link

Unoserver Hangs randomly #108

Closed kotso closed 4 months ago

kotso commented 8 months ago

I have issue with Unoserver + Libreoffice.

Randomly Unoserver stops responding to it's port (telnet fails) and same time libreoffice process started by unoserver using 100% of single core, constantly. Waited more then hour and it never ended, solution is only to restart Unoserver.

Any idea how to debug issue or how to make libreoffice log errors?

Environment is:

Unoserver running under systemd service with following systemd unit configuration file:

[Unit]
Description=unoserver
After=network.target

[Install]
WantedBy=multi-user.target

[Service]
Type=simple
User=root
Group=root
ExecStart=/usr/local/bin/unoserver --interface 0.0.0.0 --uno-interface 0.0.0.0  --port 2003  --uno-port 2002
Environment=PYTHONUNBUFFERED=true
KillSignal=SIGKILL
Restart=on-failure
RestartSec=1

I have added KillSignal=SIGKILL to make service restart quickly.

Will appreciate any recommendation how to debug this issue.

regebro commented 8 months ago

Unfortunately I have not found a way to get Libreoffice to produce any useful logs. It is common, or at least used to be, that there are certain documents that it gets stuck on, if this is the case I can take a look at it. It might get solved with certain filter parameters f ex.

kotso commented 8 months ago

ok, after some more digging came up to fact that there are certain files that cause this issue.

uploading one of such here.

First idea about file is that it can be because of Unicode characters, but not, this document is made of one template, and other files then these work perfect with unoserver.

@regebro will appreciate any idea how to debug it further.

like I have multiple files that work, and this single once that causes things to fail. 03-1111-contract.docx

regebro commented 6 months ago

I couldn't replicate it, it might be dependent on Libreoffice version. I was using 7.3.7.2. Or maybe it could be a font issue?