Skip to content

Deployment and Maintenance / Upgrade and Restart

This article mainly introduces how to upgrade and restart DataFlux Func.

1. Upgrade System

The current version of DataFlux Func does not require any additional special operations during upgrades; simply follow the normal installation steps with the new version.

The installation script will automatically identify the already installed DataFlux Func, complete a series of operations such as stopping services, replacing images, and restarting.

Additionally, after the first installation of DataFlux Func, the installation directory is written into the /etc/dataflux-func file. Therefore, during an upgrade, the installation script can also automatically locate the previous installation directory, preserving all user data.

You can use cat /etc/dataflux-func in the command line to view the currently recorded installation directory

For detailed installation documentation, please refer to Deployment and Maintenance / Installation Deployment / Single-Machine Deployment

1.2 Automatic Update of Docker Version

The Docker version bundled with different versions of DataFlux Func may vary:

DataFlux Func Version Bundled Docker Version
5.1.0 and later 24.0.9
3.4.0 ~ 5.0.5 23.0.6
3.3.3 and earlier 20.10.8

Therefore, when upgrading DataFlux Func, the automatic installation script will detect the current Docker version and prompt whether to reinstall Docker:

Text Only
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
The current version of the DataFlux Func prefers another version of Docker
  Current Docker (docker --version):
    -> 20.10.8
  DataFlux Func prefers:
    -> 23.0.6

Reinstalling Docker will stop the docker service and shut down all running containers, this will make all your services unavailable!

Do you want to reinstall Docker 23.0.6 (current: 20.10.8) ?
  -> abort    : Stop and do nothing
  -> skip     : Skip reinstalling Docker, use current version of Docker and continue to install DataFlux Func
  -> reinstall: Reinstall Docker and install DataFlux Func
Your choice:

Users can input the specific action they wish to perform:

Input Description
abort Abort the installation, do nothing
skip Do not update Docker, directly upgrade DataFlux Func
reinstall Reinstall the new Docker version, then upgrade DataFlux Func

If the Docker on the host machine is not automatically installed by the DataFlux Func installation package, please manually upgrade Dockets, do not use the one-click installation package to reinstall

If the Docker on the host machine runs services other than DataFlux Func, confirm whether reinstalling Docker will impact your business

After the user selects reinstall, there will be a 10-second wait for the user to press CTRL + C to interrupt the reinstallation of Docker:

Text Only
1
2
3
Your choice: reinstall
[Reinstall Docker and install DataFlux Func]
You have 10 seconds to interrupt this action by pressing CTRL + C

2. Restart System

To restart, please follow these steps:

  1. Use the docker stack rm dataflux-func command to shut down DataFlux Func (this step may take some time)
  2. Use docker ps to confirm that all containers have exited
  3. Use docker stack deploy dataflux-func -c {installation directory}/docker-stack.yaml --resolve-image never to restart all services

Since the image files in the installation package have already been imported locally, adding the --resolve-image never parameter avoids unnecessary image checks by Docker when starting containers

If you find it troublesome, you can also use the original installation package to reinstall DataFlux Func to complete the 'restart'