1. test whether the local OpenOffice service can be started: Enter the following command in the command line: openoffice installation directory soffice-headle-accept = & quot; socket, host = localhost, port = 8100; urp; & quot;-nofirststartwizard & amp; if an error occurs
1. test whether the local OpenOffice service can be started
Method: Enter the following command in the command line:
/Openoffice installation directory/soffice-headle-accept = "socket, host = localhost, port = 8100; urp;"-nofirststartwizard &
If an error occurs, the startup fails or OpenOffice is not installed.
If it succeeds, the following similar content will appear:
[1] 2342
This information indicates the process number that starts the service, that is, the pid.
2. if the java code is used to start the service, the connect method may be called because the port listener has not been set up, resulting in an error in the background: The service is not started, note that two parameters need to be added during command execution, as shown below:
Runtime.getruntime(cmd.exe c ("/bin/sh", "-c", "/openoffice installation directory/soffice-headle-accept =" socket, host = localhost, port = 8100; urp; "-nofirststartwizard ");
The first two parameters are specific in Linux.
After executing this command, a service process starts.