当前位置:网站首页>Tdengine offline upgrade process

Tdengine offline upgrade process

2022-07-05 09:43:00 Tdengine

matters needing attention :

  1. It is strongly recommended that users who need to upgrade directly to the latest version of each version branch (  All download links - TDengine | Taosi data  );
  2. TDengine Version rollback is not allowed after upgrading . therefore , Please be sure to follow the upgrade process of the text , Backup ahead of time , So as to avoid unexpected problems ;
  3. After upgrade , Please verify the integrity of the database service as soon as possible ;
  4. For the use of RESTful Users of interface services , After upgrade , Remember to use systemctl start taosadapter start-up taosadapter service , In order to make sure RESTful Interface available ;
  5. With 2.0.16 For the dividing line , The upgrade steps are slightly different , Please check your database service version .( Version checking method : On the server side taos shell Internal execution select server_version());

Text :

2.0-2.0.15 edition , Upgrade up to 2.0.16 And any subsequent versions , The operation is as follows ( Including cluster and single machine ):

  1. Before upgrading , Please prepare the installation package of the new version on the server ( Download link : All download links - TDengine | Taosi data );
  2. Ensure that the current node is in a working state :
    1. ) show dnodes: various dnode status Are all ready;
    2. ) show mnodes: various mnode role Are all master perhaps slave;
    3. ) show Library name .vgroups: various vgroup status Are all ready, And role Are all master perhaps slave;
    4. ) The database reads and writes normally ;
  3. Stop the database service on all nodes :systemctl stop taosd
  4. Backup all node data files under the directory ( The default is :/var/lib/taos) All content to another path or store (vnode_bak Can be emptied );
  5. cd  Enter the data file directory of each node ;
  6. ls -ltR | grep -i “wal” Check ” All under the data file directory wal Whether the file is empty ;
  7. If it is empty , Enter steps 9;
  8. If it is not empty , Start the database process of the node and then shut down . Be sure to wait until the file is empty for all nodes , To move on .( If the directory is started and stopped repeatedly, it cannot be empty , Please contact the TDengine Official support );
  9. When the database service is stopped , Execute one by one on all nodes rmtaos( The uninstallation method depends on the type of installation package , May refer to :TDengine Installation and uninstallation of multiple installation packages - TDengine | Taosi data ), Then install the new version install.sh( Or other installation methods , See ibid );
  10. After all nodes are upgraded , At each node Linux shell Use in taosd –force-keep-file Command to start the service process ;
  11. Open a new one linux terminal , Input taos -h xxxx -p command ( Fill in the user password according to the actual situation ), Perform step... Again 2 , And check the data integrity .
  12. After confirmation , Cancelable taosd –force-keep-file The process of . Again systemctl start taosd Mode start taosd service .
  13. 【 Optional 】 Execute on demand : systemctl start taosadapter;
  14. Perform step... Again 2 , And check the data integrity .
  15. After checking that there is no mistake , Upgrade Complete .

2.0.16 Version and later , Upgrade to any version , The operation is as follows ( Including cluster and single machine ):

  1. Before upgrading , Please prepare the installation package of the new version on the server ( Download link : All download links - TDengine | Taosi data );
  2. Ensure that the current node is in a working state :
    1. ) show dnodes: various dnode status Are all ready;
    2. ) show mnodes: various mnode role Are all master perhaps slave;
    3. ) show Library name .vgroups: various vgroup status Are all ready, And role Are all master perhaps slave;
    4. ) The database reads and writes normally ;
  3. Stop the database service on all nodes :systemctl stop taosd
  4. Backup all node data files under the directory ( The default is :/var/lib/taos) All content to another path or store (vnode_bak Can be emptied );
  5. cd  Enter the data file directory of each node ;
  6. ls -ltR | grep -i “wal” Check ” All under the data file directory wal Whether the file is empty ;
  7. If it is empty , Enter steps 9;
  8. If it is not empty , Start the database process of the node and then shut down . Be sure to wait until the file is empty for all nodes , To move on .( If the directory is started and stopped repeatedly, it cannot be empty , Please contact the TDengine Official support );
  9. When the database service is stopped , Execute one by one on all nodes rmtaos( The uninstallation method depends on the type of installation package , May refer to :TDengine Installation and uninstallation of multiple installation packages - TDengine | Taosi data ), Then install the new version install.sh( Or other installation methods , See ibid );
  10. Start the database service at each node :systemctl start taosd;
  11. 【 Optional 】 Execute on demand : systemctl start taosadapter;
  12. Perform step... Again 2 , And check the data integrity .
  13. After checking that there is no mistake , Upgrade Complete .

Want to know more TDengine Database Specific details of , Welcome to GitHub View the relevant source code on .

 

原网站

版权声明
本文为[Tdengine]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/186/202207050927513460.html