DocumentServer icon indicating copy to clipboard operation
DocumentServer copied to clipboard

Installation problem with external RabbitMQ

Open tisonv opened this issue 1 year ago • 1 comments

This issue is unique.

  • [X] I have used the search tool and did not find an issue describing my bug.

Operating System of DocumentServer

Windows Server

Version information

8.1.0

Expected Behavior

When installing onlyoffice-documentserver.exe, I should be able to connect another RabbitMQ instance Previous version connected successfully (< 8.1.0)

Actual Behavior

If I choose to install DocumentServer without RabbitMQ => I get an error RabbitMQ when clicking 'Next'. image

II I choose to install DocumentServer with RabbitMQ => Installation works nice. If I change the RabbitMQ settings afterwards, it works nicely.

Reproduction Steps

  • Have a working DocumentServer linked to an external RMQ
  • Uninstall
  • Install new version
  • RabbitMQ settings should be preset in the screen

Additional information

No response

tisonv avatar Jun 25 '24 08:06 tisonv

Hello @tisonv, thank you for detailed report, i reproduced this, ticket #68870

igwyd avatar Jun 26 '24 13:06 igwyd

It's fixed at https://github.com/ONLYOFFICE/document-server-package/commit/604319d3973f33f024dba7ceb1df5759a98cfe0d and will be released in the next hotfix.

igwyd avatar Jul 04 '24 06:07 igwyd

Awesome ! Thank you !

tisonv avatar Jul 04 '24 06:07 tisonv

DocumentServer v8.1.1 is released so I close this issue. Feel free to comment or reopen it if you got further questions.

Rita-Bubnova avatar Jul 17 '24 08:07 Rita-Bubnova

@Rita-Bubnova We tried to install 8.1.1.26 but the problem is still present. Same error message.

tisonv avatar Jul 18 '24 14:07 tisonv

@igwyd, Please take a look.

Rita-Bubnova avatar Jul 18 '24 15:07 Rita-Bubnova

@tisonv i rechecked update from 8.1.0 to 8.1.1, connection external rabbitmq with vhost succefull. There may be some data that I did not see in your case, please show the settings of your connection to the RabbitMQ without private data in local.json. My succefull connection looks like that:

  "rabbitmq": {
    "url": "amqp://test:[email protected]/OnlyOffice"
  },

rabbitmq

igwyd avatar Jul 31 '24 11:07 igwyd

@igwyd Here you are:

"rabbitmq": {
    "url": "amqp://user OnlyOffice:XXXXXXXXXXX@server/OnlyOffice"
}

image

We tried creating a RabbitMQ user without a space in it. But the problem remains

tisonv avatar Aug 01 '24 07:08 tisonv

I think the problem is in the space, because I got the same error. And could you tell me what special characters you use in your password?

igwyd avatar Aug 02 '24 10:08 igwyd

We retried a 'onlyoffice' user with 'azerty' as password but it doesn't work.

I see you use the IP and not the name of the server. Would it change something ? (Can't test anymore before monday)

tisonv avatar Aug 02 '24 11:08 tisonv

We retried a 'onlyoffice' user with 'azerty' as password but it doesn't work.

Have you granted rights 'onlyoffice' user to the /OnlyOffice vhost in RabbitMQ-server? For example like this and restart service in my external stand with rabbitmq:

sudo rabbitmqctl set_permissions -p OnlyOffice onlyoffice ".*" ".*" ".*"
sudo systemctl restart rabbitmq-server

Can you show rabbitmq log when you try to connect?

igwyd avatar Aug 02 '24 12:08 igwyd

It had all permissions and all topic permissions on the vhost. We didn't restart the server though.

In which log would we find this trace ? We are running rabbitmq on Windows We were unable to find any info so far. I don't know if we have to enable something.

tisonv avatar Aug 02 '24 12:08 tisonv

In Windows, the default logs is C:\Users\Administrator\AppData\Roaming\RabbitMQ\log There is no need to reboot the server, just restart the service.

igwyd avatar Aug 02 '24 12:08 igwyd

Anyway, there is an error with connecting a user with a space in the name and I created a ticket #69531

igwyd avatar Aug 02 '24 12:08 igwyd

I won't have access until monday to test any further.

Would it be the screen is not using what is typed ? Just in case, we're not using the EE, only the community edition.

tisonv avatar Aug 02 '24 12:08 tisonv

I recheked also in opensource, validation connection to the rabbitms is the same in EE and opensource.

Would it be the screen is not using what is typed ?

I have tested with different users, the fields in the installation work. Including I created the same user as you 'onlyoffice' user with password 'azerty' - it's work. I assume you haven't created a user or given him the necessary rights: https://www.rabbitmq.com/docs/man/rabbitmqctl.8#list_users https://www.rabbitmq.com/docs/man/rabbitmqctl.8#set_permissions Or you use special characters in your password: https://www.rabbitmq.com/docs/uri-spec

igwyd avatar Aug 02 '24 13:08 igwyd

I managed to get some more probing done. We ended up using ProcessMonitor

When spying the network, there are no activity going to our rabbitmq server. Nothing at all. No query is sent. Therefore no log on our rabbitmq server.

Python tries to reach an IP owned by Fastly but our server have very limited internet access (only needed urls can go through).

We removed the OpenOffice registry key to get a clean install: no change.

Maybe a thing, maybe not : When we start the installer, we are asked for a path. We always install everything on the D:\ drive. Never on the C:\. It's a company policy. Nonetheless Python is installed on the root of C:\. We don't get the choice. This may happen with Microsoft product but never on the root. This was slightly irritating. We saw the installer calling python and getting some errors in ProcessMonitor.

So we tried installing on the default path C:\Program Files\.... but to no success.

Can the installer generate any logs ?

tisonv avatar Aug 05 '24 15:08 tisonv

I see you use the IP and not the name of the server. Would it change something ?

No, the same.

Can the installer generate any logs ?

yes, you need to run the installation with the key /LOG, but the connection check to the rabbitmq is not logged.

Regarding your network, I found out from the developers that a library for python is downloaded there and that is probably why you are not getting validation. I think the solution for you would be to skip the connection validation. To do, remove Python and do not install it, then you can skip validation during the installation.

igwyd avatar Aug 06 '24 12:08 igwyd

YES !!! It worked smoothly ! A HUGE thank you for your help and your time to help me resolve this problem !!!

Regarding the matter : No release note where issued in 8.1.0 on these changes. It may seem a bit of an overkill to have python as a new prerequisite during the install process if the 300Mb of Python + additional library are only used to check the rabbitmq settings. As I previously said , the C:\ install of Python wasn't very welcomed. We had to add firewall exceptions to allow the download while ultimately not necessary. (It might be easier to achieve the same result through the rabbitmq API but I don't know if it is activated when rabbit is installed locally)

I feel really sorry to have wasted a bit of your time on the subject but again a big thank you !

tisonv avatar Aug 07 '24 08:08 tisonv