"Well, this is embarrassing, we cannot connect to your document. Please try again." Error on Ubuntu Server 16.04

Hi I’ve installed the docker and Collabora with Nextcloud just as the guide instructs here: https://nextcloud.com/collaboraonline/

The problem is I can’t open any documents, I just get the error “Well, this is embarrassing, we cannot connect to your document. Please try again.”

Can anybody please help me fix this and help diagnose what the problem is?

Thanks for any help.

Hi Jonah!

Let’s summarize what we already now on a quick list.

  • Proxy
    ** Are you using 2 (sub)/domains, one for Nextcloud another for CODE?
    ** Did you copy paste the reverse proxy configuration from here changing only domain name and SSL paths?
  • Web Server
    ** What web server are you using? (I recommend Apache for this setup)
  • SSL
    ** Do you own a valid SSL cert, or are you getting it by using Let’s Encrypt?
  • Docker
    ** (I believe you have aufs support)
    ** Are you running the domain name of your Nextcloud with backslashes (\) as shown here.

Please check that and respond on the same order.

Hi thanks.

  1. Proxy - yes I’m using two subdomains one for nextcloud and one for Collabora. So cloud.mydomain.com and office.mydomain.com type setup.

I haven’t used the link with the reverse proxy you have linked there, but I used the one in the Nextcloud guide here: https://nextcloud.com/collaboraonline/

  1. The web server is Apache

  2. Yes I have a valid Let’s Encrypt SSL for the collabora subdomain and a Comodo purchased valid cert for the cloud subdomain.

  3. Yes we checked on the other thread and aufs support is enabled. I’ve also got my domain with backslashes in there.

Thanks again for any help to fix this.

This link https://www.collaboraoffice.com/code/ is the most up to date resource available.
Check your reverse proxy again to the collabora one.

Are you using an all in one setup?

Hi thanks, the vhost file settings all look to be the same as the ones from that link.

I’m not sure what an All in One Setup is, but I followed the guide here originally: https://nextcloud.com/collaboraonline/

Are there any logs or ways we can check why the document isn’t opening and it is showing that error message?

Jonah,

Are there any logs or ways we can check why the document isn’t opening and it is showing that error message?

There is few info in collabora/code logs, kind of it works or it doesn’t :thumbsdown:

If you can spare the time please try this from scratch,

It will guide you through the Nextcloud installation and also the Collabora CODE setup.
Cheers.

Hi thanks but my Nextcloud setup is already in production and being used by quite a few users. I’d rather if there is a way we can debug what is wrong with my current setup please?

Thanks.

You can run the script on a VM and see how different is your installation from your installation.

If you need dedicated support drop me a line.

I have Set up NextCloud Server on Ubuntu 16.04 with Apache, MariaDB and PHP7, I already have these settings:

Main websocket

ProxyPassMatch “/lool/(.*)/ws$” wss://127.0.0.1:9980/lool/$1/ws nocanon

but still I am getting this error

Well, this is embarrassing, we cannot connect to your document. Please try again.

Wrong WOPISrc, usage: WOPISrc=valid encoded URI, or file_path, usage: file_path=/path/to/doc/

In My Docker Logs I am only getting this following error:

wsd-00026-25124 06:07:05.542798 [ client_ws_003b ] ERR ClientRequestHandler::handleClientRequest: Exception: Invalid URI.| wsd/LOOLWSD.cpp:1245
wsd-00026-0030 06:07:07.603192 [ client_ws_003c ] ERR ClientRequestHandler::handleClientRequest: Exception: Invalid URI.| wsd/LOOLWSD.cpp:1245

can anyone help please ?

Hi @Asif_Khan !
In order to get help, you need to share more information than that.
Please use the installation guide to check that every point has been meet (and show here the output).
You can use this or this one.

That way it’s more likely for other users to help you, me included.
Cheers!

Hi @Ark74

I have use this installation guide

@Asif_Khan ok, please go trough every point.

Requirements,

  1. What filesystem use does your docker use?
  2. Do you have a dedicated subdomain for code/collabora?
  3. Are you using Apache? Did you enable all the modules?
  4. Do you have a valid SSL certificate for de subdomain (code)?
  5. Do you have a valid SSL certificate for de sub/domain (nextcloud)?

Is Collabra a “Must-have” feature or do you just need am Online-Office?

Hi just to update that my implementation IS now working just simply through Ubuntu fixing something, a package update etc with docker. I haven’t adjusted anything, rather just rechecked and retried things a few months later and now the documents load up great.

Thanks again for trying to help.

I’m noticing a further problem.

Periodically documents just won’t open. The only pattern I’ve noticed so far (due to not being to test too much on a production machine as yet) is that if I’ve had to restart bind or apache or something on the server - then if I log into Nextcloud and try edit a document I get that nasty error “Well, this is embarrassing, we cannot connect to your document. Please try again.”

After a full reboot of the server documents open again. It’s pretty frustrating. What is the correct procedure when managing your server day to day to make sure Collabora keeps working too? Is this a bug or normal behaviour, and is there a workaround such a script or something that can keep it “alive”?

The issue was DNS resolution inside the docker container that ran collabora. The DNS for my nextcloud domain was resolving to the public address, which is not reachable from the container or the nextcloud VM which had the container running in it. I connected to the docker instance, and added a line in the local hosts file that pointed back to my nextcloud VM’s docker address as follows. At that point the documents can be viewed/edited without issues.

Nextcloud VM’s docker IP address is 172.17.0.1.
I connected to the container instance as:

docker container ls (shows the active container list)
docker exec -i -t /bin/sh (replace with the found container id)

Once in the shell, run the command
echo “172.17.0.1 nextcloud.mydomain.com” >> /etc/hosts

exit from the shell and everything works fine.

Spoke too soon. It worked for a couple of new documents that I created and now doesn’t work again. Can’t imagine what is so hard about this integration. Pretty standard ubuntu 16.04 image for nextcloud and running the collabra configuration from the single script install as most people have done here.

@jayanm Thanks for the solution.
You can provide --add-host to the container when starting it to edit the containers /etc/hosts file.
This way it is reboot persistent.

I wrote a little article about the issue.
Maybe it can help someone someday that ends up here :slight_smile:
English:
https://blog.hackzenwerk.org/2019/08/23/integration-of-collabora-online-on-a-nextcloud-behind-nat-on-a-kvm-hypervisor/

German:
https://blog.hackzenwerk.org/2019/08/23/integration-von-collabora-online-auf-einer-nextcloud-hinter-nat-auf-kvm/