Page 1 of 1

Is a separate MySQL Docker Container in future required?

Posted: Thu Sep 12, 2019 2:40 pm
by Schroeffu
Hi Only Office Team,

upgrading onlyoffice until v9 was working like a charm by using the following upgrade commands for me:
my docker reinstall copy-paste instructions
# 1. Delete Container
sudo docker rm -f $(docker ps | grep onlyoffice/communityserver | awk '{ print $1 }')
sudo docker rm -f $(docker ps | grep onlyoffice/documentserver | awk '{ print $1 }')

# 2. Delete Images
sudo docker rmi -f $(sudo docker images | grep onlyoffice/communityserver | grep latest | awk '{ print $3 }')
sudo docker rmi -f $(sudo docker images | grep onlyoffice/documentserver | grep latest | awk '{ print $3 }')

# 3. Re-Install Document Server
sudo docker run --net onlyoffice -i -t -d --restart=always --name onlyoffice-document-server \
-v /app/onlyoffice/DocumentServer/data:/var/www/onlyoffice/Data \
-v /app/onlyoffice/DocumentServer/logs:/var/log/onlyoffice \

# 4. Re-Install Community Server

sudo docker run --net onlyoffice -i -t -d --restart=always --name onlyoffice-community-server \
-p 8080:80 -p 5222:5222 -p 8443:443 \
-v /app/onlyoffice/CommunityServer/data:/var/www/onlyoffice/Data \
-v /app/onlyoffice/CommunityServer/mysql:/var/lib/mysql \
-v /app/onlyoffice/CommunityServer/logs:/var/log/onlyoffice \
-v /app/onlyoffice/DocumentServer/data:/var/www/onlyoffice/DocumentServerData \
-e DOCUMENT_SERVER_PORT_80_TCP_ADDR=onlyoffice-document-server \
Unfortunately Since v10 then suddenly "Runtime Error" appears after upgrade. I was ignoring the issue for weeks because was not using the instance. until today.
The logfile was telling me something like "Table 'performance_schema.session_variables' doesn't exist"

I could resolve the issue with:

- jump into onlyoffice docker image with "docker exec -it <container name> /bin/bash"
- run "mysql_upgrade -u root"
- CRTL + D
- docker ps restart <container name>

Now i was surprised, onlyoffice is starting and working. But the official documentation says i have to create an extra mysql5.7 docker container for onlyoffice. äh??

- Why is onlyoffice still working without? So you are shipping still a mysql instance inside of Docker Image CommunityServer , right?
- so is this separate mysql container in future really required, or can I run CommunityServer in future still with (...) -v /app/onlyoffice/CommunityServer/mysql:/var/lib/mysql (...)?

Thanks for any answer :-)

Re: Is a separate MySQL Docker Container in future required?

Posted: Fri Sep 20, 2019 8:27 am
by Andrew

We moved database to separate container for convenience of update process, even if there is no mapped folder deleting of Community Server container will not cause losing data in this case. It is recommended to use database in separate container as mentioned in documentation and you can use

Code: Select all

bash -u true
to update Community Edition.