synology-docker icon indicating copy to clipboard operation
synology-docker copied to clipboard

Adjust update of log driver configuration

Open markdumay opened this issue 4 years ago • 8 comments

The syno_docker_update.sh script updates the file /var/packages/Docker/etc/dockerd.json to fix an issue with Synology's db log driver. However, the script replaces the entire configuration file, instead of fixing the offending log driver only. This might introduce unwanted side effects.

markdumay avatar Nov 30 '20 06:11 markdumay

Getting Error response from daemon: failed to initialize logging driver: failed to get logging factory: logger: no log driver named 'db' is registered: error looking up logging plugin db: plugin "db" not found after docker update and trying to start container

merlin-zaraza avatar Nov 30 '20 12:11 merlin-zaraza

Can you share the full log of the syno_docker_update.sh command you ran? And what is the current content of your /var/packages/Docker/etc/dockerd.json file?

markdumay avatar Nov 30 '20 12:11 markdumay

Update Docker Engine and Docker Compose on Synology to target version

Current DSM version: 6.2.3
Current Docker version: 18.09.8
Current Docker Compose version: 1.24.0
Target Docker version: 19.03.13
Target Docker Compose version: 1.27.4

WARNING! This will replace:
  - Docker Engine
  - Docker Compose
  - Docker daemon log driver

Are you sure you want to continue? [y/N] y
Step 1 from 10: Downloading target Docker binary (https://download.docker.com/linux/static/stable/x86_64/docker-19.03.13.tgz)
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 59.3M  100 59.3M    0     0  10.3M      0  0:00:05  0:00:05 --:--:-- 10.9M
Step 2 from 10: Downloading target Docker Compose binary (https://github.com/docker/compose/releases/download/1.27.4/docker-compose-Linux-x86_64)
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100   651  100   651    0     0   4691      0 --:--:-- --:--:-- --:--:--  4717
100 11.6M  100 11.6M    0     0  2430k      0  0:00:04  0:00:04 --:--:-- 2615k
Step 3 from 10: Stopping Docker service
pkgctl-Docker stoped.
Step 4 from 10: Backing up current Docker binaries (/volume1/homes/vitalii/github/synology-docker/docker_backup_20201130_140242.tgz)
bin/
bin/docker
bin/docker-proxy
bin/containerd
bin/docker-compose
bin/auplink
bin/docker-init
bin/dockerd
bin/containerd-shim
bin/ctr
bin/runc
dockerd.json
start-stop-status
Step 5 from 10: Extracting target Docker binary (/tmp/docker_update/docker-19.03.13.tgz)
docker/
docker/ctr
docker/runc
docker/containerd-shim
docker/docker-init
docker/docker-proxy
docker/docker
docker/dockerd
docker/containerd
Step 6 from 10: Installing binaries
Step 7 from 10: Configuring log driver
Step 8 from 10: Enabling IP forwarding
Step 9 from 10: Starting Docker service
pkgctl-Docker started.
Step 10 from 10: Cleaning the temp folder
Done.
{
    "data-root" : "/var/packages/Docker/target/docker",
    "log-driver" : "json-file",
    "registry-mirrors" : [],
    "group": "administrators"
}

merlin-zaraza avatar Nov 30 '20 12:11 merlin-zaraza

Both the script and daemon configuration appear to be fine. Can you try stopping and restarting the container(s)? It seems to refer to the now obsolete db log driver.

markdumay avatar Nov 30 '20 13:11 markdumay

yep, remove old container and add it again helps thank you

merlin-zaraza avatar Nov 30 '20 13:11 merlin-zaraza

Great! I'll add an instruction to the README too ;-)

markdumay avatar Nov 30 '20 13:11 markdumay

Start container portainer failed: {"message":"failed to initialize logging driver: failed to get logging factory: logger: no log driver named 'db' is registered: error looking up logging plugin db: plugin "db" not found"}.

Any variants of /var/packages/Docker/etc/dockerd.json from Updated binaries are incompatible with btrfs #22 was not help. Recreating containers have the same error, i cant run, pull any container and can`t delete images by GUI and by console

Current DSM version: 6.2.3
Current Docker version: 19.03.14
Current Docker Compose version: 1.27.4

restore is ok.

exotsk avatar Dec 04 '20 02:12 exotsk

hi @exotsk, to help me identify potential causes of your issue, would you mind submitting a new issue using the bug report template?

markdumay avatar Dec 04 '20 07:12 markdumay