Last modified by superadmin on 2026/08/14 17:53

Show last authors
1 Configuring the server externally allows administrators to manage the OpenOffice server process manually, giving more control over the server’s startup parameters. To configure your wiki to work with an office server ([[LibreOffice>>http://www.libreoffice.org/]] or [[OpenOffice>>http://www.openoffice.org/]]):
2
3 1. Install [[LibreOffice>>http://www.libreoffice.org/]] or [[OpenOffice>>http://www.openoffice.org/]].
4 1. Navigate to the ##xwiki/WEB-INF/## and open the file ##xwiki.properties## with a text editor.
5 1. Search for the "Settings for the OpenOffice server instance consumed by the OfficeImporter component". The content looks like this:(((
6 {{code language="properties"}}
7 #-# [Since 1.9M2]
8 #-# Type of the openoffice server instance used by officeimporter component.
9 #-# 0 - Internally managed server instance. (Default)
10 #-# 1 - Externally managed (local) server instance.
11 # openoffice.serverType = 0
12
13 #-# [Since 12.1RC1]
14 #-# Port numbers used for connecting to the openoffice server instance.
15 #-# For an internally managed server instance, it will create the process for all ports.
16 #-# For an externally managed server instance, only the first server port is taken into account.
17 # openoffice.serverPorts = 8100,8101
18
19 #-# [Since 1.9M2]
20 #-# If the openoffice server should be started / connected upon XE start.
21 #-# Default value is false
22 # openoffice.autoStart = false
23
24 #-# [Since 1.8RC3]
25 #-# Path to openoffice installation (serverType:0 only).
26 #-# If no path is provided, a default value will be calculated based on the operating environment.
27 # openoffice.homePath = /opt/openoffice.org3/
28
29 #-# [Since 1.8RC3]
30 #-# Path to openoffice execution profile (serverType:0 only).
31 #-# If no path is provided, a default value will be calculated based on the operating environment.
32 # openoffice.profilePath = /home/user/.openoffice.org/3
33
34 #-# [Since 1.8RC3]
35 #-# Maximum number of simultaneous conversion tasks to be handled by a single openoffice process (serverType:0 only).
36 #-# Default value is 50
37 # openoffice.maxTasksPerProcess = 50
38
39 #-# [Since 1.8RC3]
40 #-# Timeout for conversion tasks (in milliseconds) (serverType:0 only).
41 #-# Default value is 60 seconds
42 # openoffice.taskExecutionTimeout = 60000
43
44 #-# [Since 16.8.0]
45 #-# [Since 16.4.4]
46 #-# [Since 15.10.13]
47 #-# The output image format to use when importing an office presentation in XWiki.
48 # officeimporter.presentation.imageFormat = jpg
49
50 #-# [Since 16.8.0]
51 #-# [Since 16.4.4]
52 #-# [Since 15.10.13]
53 #-# Quality of the output image when importing an office presentation: the quality value is between 0 and 100.
54 #-# Be aware that this option overrides any filter configuration provided in custom-document-formats.json for html
55 #-# presentations. Also this configuration is ignored if the image format is png.
56 # officeimporter.presentation.quality = 95
57
58 #-# [Since 16.8.0]
59 #-# [Since 16.4.4]
60 #-# [Since 15.10.13]
61 #-# Width of the output image when importing an office presentation: the value is given in pixel.
62 # officeimporter.presentation.slideWidth = 1920
63 {{/code}}
64 )))
65 1. Set ##openoffice.serverType=1## and ##openoffice.autoStart=false## and uncomment these lines by deleting the # at the beginning of the lines.
66 1. Save the changes.
67 1. Create /OpenOffice Profile Directory in case your server environment doesn’t allow launching OpenOffice. You need an OpenOffice profile created on your system. You can create the profile (##profilePath##) on a local computer and upload it to the server running XWiki.(((
68 Example for Windows:
69 {{code language="none"}}openoffice.profilePath=C:/Users/{user}/AppData/Roaming/OpenOffice.org/3{{/code}}
70 Example for Linux:
71 {{code language="none"}}openoffice.profilePath=/home/{user}/.openoffice.org/3{{/code}}
72 )))
73 1. Manually start OpenOffice server.(((
74 {{code language="none"}}"soffice" -headless -accept="socket,host=127.0.0.1,port=8100;urp;" -nofirststartwizard{{/code}}, where ##<soffice>## is the path to your OpenOffice executable.
75 Windows Example:
76 {{code language="none"}}"C:/Program Files (x86)/OpenOffice 3/program/soffice.exe" -headless -accept="socket,host=127.0.0.1,port=8100;urp;" -nofirststartwizard{{/code}}
77 This command starts the OpenOffice server in headless mode, accepting connections on port 8100.
78 )))
79 1. Verify the server is running by going to [[Administer the Wiki>>documentation.xs.admin.base.content-organization.administer-wiki.WebHome]] and then selecting "Content", "Office Server" from the dropdown.(((
80 {{image reference="office-server-externally.png" size="large" alt="The Office Importer admin UI"/}}
81 )))
82 1. Once the OpenOffice server is running and connected, you can use the Office Importer to [[Import Office Documents into Wiki Pages>>documentation.xs.user.base.page.create.import-office-documents.WebHome]], convert office documents (e.g., .docx, .xlsx) to XWiki format, and to [[export Pages in ODT or RTF formats>>documentation.xs.user.exports.export-page.export-odt-rtf.WebHome]].
83
84

Get Connected