Ask Your Question

Error converting thousands of documents with LibreOffice [closed]

asked 2012-08-02 18:54:17 +0200

Luis Alvarado gravatar image

updated 2015-10-17 14:47:30 +0200

Alex Kemp gravatar image

0 down vote favorite You can't vote for your own post. (click on this box to dismiss)

I am trying to convert several thousand documents from LWP (Lotus Word Pro) to DOC. When the converting process gets to around 229 documents converted it just quits.

The terminal lines I am using to convert this are:

soffice --headless --convert-to doc --outdir /home/cyrex/work/biopsias/2007 *.lwp


libreoffice --headless --convert-to doc --outdir /home/cyrex/work/biopsias/2007 *.lwp

both work but up to 229. I have 60K documents to convert I doing them 200 at a time would take A LOT of time.

Converting them to ODT also has the same problem.

I have LibreOffice version 3.5 in Ubuntu 12.04

edit retag flag offensive reopen merge delete

Closed for the following reason the question is answered, right answer was accepted by Alex Kemp
close date 2015-10-17 14:47:39.107526


I think @w_whalley is right pointing to shell limitations. Another idea: does the conversion stop while working on a certain file? Or does the problem occur independent of the individual files to convert?

tohuwawohu gravatar imagetohuwawohu ( 2012-08-03 17:45:57 +0200 )edit

1 Answer

Sort by » oldest newest most voted

answered 2012-08-02 23:15:54 +0200

w_whalley gravatar image

It could be a shell limitation. I tried a set of 500 files using your command line and it stopped at 248 conversions. I then tried using xargs and all 500 converted. Here is the command converted to your case. Test before committing to all 60,000 files.

find . -name "*.lwp" -type f -print0 |xargs -0 -I {} libreoffice --headless --convert-to doc --outdir /home/cyrex/work/biopsias/2007 {}

edit flag offensive delete link more

Question Tools


Asked: 2012-08-02 18:54:17 +0200

Seen: 816 times

Last updated: Aug 02 '12