update the status of the migration phase
This commit is contained in:
parent
64341a18bb
commit
4c57ab5040
38
0023-update-the-status-of-the-migration-phase.patch
Normal file
38
0023-update-the-status-of-the-migration-phase.patch
Normal file
@ -0,0 +1,38 @@
|
||||
From c92f1168709c3974b33ae04553c58f739909ba99 Mon Sep 17 00:00:00 2001
|
||||
From: xuezhixin <xuezhixin@uniontech.com>
|
||||
Date: Fri, 10 Nov 2023 10:38:27 +0800
|
||||
Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0=E8=BF=81=E7=A7=BB=E9=98=B6?=
|
||||
=?UTF-8?q?=E6=AE=B5=E7=9A=84=E7=8A=B6=E6=80=81?=
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
---
|
||||
sysmig_agent/share.py | 11 +++++++++++
|
||||
1 file changed, 11 insertions(+)
|
||||
|
||||
diff --git a/sysmig_agent/share.py b/sysmig_agent/share.py
|
||||
index abbe452..5a51266 100644
|
||||
--- a/sysmig_agent/share.py
|
||||
+++ b/sysmig_agent/share.py
|
||||
@@ -45,6 +45,17 @@ def sql_online_statue(statue, task_id):
|
||||
except:
|
||||
pass
|
||||
|
||||
+
|
||||
+def sql_mig_statue(statue):
|
||||
+ # sql = "UPDATE agent_task SET task_statues = {} , task_Updatetime = NOW() WHERE task_id = '{}';".format(statue, task_id)
|
||||
+ sql = "UPDATE agent_task SET task_data = '{}' , task_Updatetime = NOW() WHERE agent_ip = '{}';".format(statue,
|
||||
+ get_local_ip())
|
||||
+ try:
|
||||
+ ret = DBHelper().execute(sql)
|
||||
+ except:
|
||||
+ pass
|
||||
+
|
||||
+
|
||||
def sql_show_tables():
|
||||
sql = "SELECT task_progress,task_data FROM agent_task WHERE agent_ip = '{}';".format(get_local_ip())
|
||||
ret_sql_msg_info = DBHelper().execute(sql)
|
||||
--
|
||||
2.20.1
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
Name: migration-tools
|
||||
Version: 1.0.2
|
||||
Release: 22
|
||||
Release: 23
|
||||
License: MulanPSL-2.0
|
||||
Summary: A tool to help users migrate the Centos system to the UOS system and openEuler system
|
||||
Source0: %{name}-%{version}.tar.gz
|
||||
@ -29,7 +29,7 @@ Patch19: 0019-update-abi-result-to-database.patch
|
||||
Patch20: 0020-get-task-process-and-migration-stage-information.patch
|
||||
Patch21: 0021-get-agent-ip-interface.patch
|
||||
Patch22: 0022-udpate-agent-host-status-online.patch
|
||||
|
||||
Patch23: 0023-update-the-status-of-the-migration-phase.patch
|
||||
|
||||
BuildArch: noarch
|
||||
BuildRequires: systemd
|
||||
@ -128,6 +128,9 @@ rm -rf /usr/bin/migration-tools
|
||||
%endif
|
||||
|
||||
%changelog
|
||||
* Mon Nov 4 2024 xuezhixin <xuezhixin@uniontech.com> - 1.0.2-23
|
||||
- 0023-update-the-status-of-the-migration-phase.patch
|
||||
|
||||
* Mon Nov 4 2024 xuezhixin <xuezhixin@uniontech.com> - 1.0.2-22
|
||||
- 0022-udpate-agent-host-status-online.patch
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user