WebFaction
Community site: login faq

A while ago, I asked about installing Open Office in the user directory.
I run this command:

~/bin/openoffice.org3/program/soffice.bin -headless -nologo -nofirststartwizard -accept=socket,host=127.0.0.1,port=8100;

Apparently, I can't figure out a way to connect to it. A python script to do file conversions raises the error:

ERROR! failed to connect to OpenOffice.org on port 8100

Johns (I believe) mentioned that every server was equipped with version 2.0, so I went to find it. I searched through existing processes and couldn't find it on Web135. I did however find, what I think is the binary. So I ran:

/usr/bin/ooffice -headless -nologo -nofirststartwizard -accept=socket,host=127.0.0.1,port=8100;

Again, a connection error.

I need to do conversions of xlsx and docx to pdf. If I'm not mistaken, 2.0 can't do that but 3.0 can.
Can someone help me find the correct port or command to be able to use Open Office for conversions?

asked 05 Feb '11, 00:56

holtkampw
26138
accept rate: 0%

Hi, Did ~/bin/openoffice.org3/program/soffice.bin -headless -nologo -nofirststartwizard -accept=socket,host=127.0.0.1,port=8100; produce any error?

Also, this port may already be allotted to some other customer on the server as such you should not use ports which are not allotted to you.

To get a port simply create a Custom Application(Listening on port) from the Panel.

(05 Feb '11, 01:44) neeravk

I didn't run soffice in the background (sent it to the bg later) so I didn't see any errors at starup. Should I look if there were any runtime errors from trying to use it somewhere?

Also I did create a custom port and tried it instead of 8100. I should have mentioned that in the original post. I tried it immediately after creation, so unless applications take some time to open the port then that attempt should have been ok (but wasn't).

(05 Feb '11, 09:22) holtkampw

Just to be clear: are you trying to connect to OO externally? I.e. access port 8100 (or your custom) port from outside of the server?

(05 Feb '11, 09:31) David L ♦♦

No, my goal was for an app that exists on Webfaction to use the OO service.

(05 Feb '11, 11:12) holtkampw

Have you tried connecting to your OO daemon using some command line utility? E.g. 'telnet 127.0.0.1 port_number'.

If this fails as well, then your background OO process is not really running. If you do establish a connection, this would suggest that your Python script is not using the correct hostname/port to connect to the OO daemon.

(05 Feb '11, 11:42) tie

Good Call tie. You're absolutely right, I can telnet to my other apps but I can't to this one:

telnet localhost 24496 telnet: connect to address 127.0.0.1: Connection refused telnet: Unable to connect to remote host: Connection refused

However, I see that its "running"

ps -u username -o pid,command 28754 /home/username/bin/openoffice.org3/program/soffice.bin -headless -nologo -nofirststartwizard -accept=socket,host=127.0.0.1,port=24496

Suggestions?

(05 Feb '11, 12:26) holtkampw
showing 5 of 6 show 1 more comments

OK So I found the issues thanks to tie's debugging method.

For anyone else with the problem, I first had to create a custom application (to get an open port). Then I had to modify the above command to:

~/bin/openoffice.org3/program/soffice.bin -headless -accept="socket,port=<CUSTOMPORT>;urp" -nofirststartwizard -display 0.0 &

I believe the important part was missing 'urp' from the accept string.

Thanks all for your debugging help

permanent link

answered 05 Feb '11, 13:22

holtkampw
26138
accept rate: 0%

Thanks for letting us know, glad you found a solution.

(05 Feb '11, 13:29) johns
Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×5
×4
×3

question asked: 05 Feb '11, 00:56

question was seen: 3,620 times

last updated: 05 Feb '11, 13:29

WEBFACTION
REACH US
SUPPORT
AFFILIATE PROGRAM
LEGAL
© COPYRIGHT 2003-2019 SWARMA LIMITED - WEBFACTION IS A SERVICE OF SWARMA LIMITED
REGISTERED IN ENGLAND AND WALES 5729350 - VAT REGISTRATION NUMBER 877397162
5TH FLOOR, THE OLD VINYL FACTORY, HAYES, UB3 1HA, UNITED KINGDOM