From bd87e5dc6a7e9662c9ca862859baac87c77d51f8 Mon Sep 17 00:00:00 2001 From: orangeji11 Date: Fri, 27 Sep 2024 02:25:29 +0000 Subject: [PATCH] =?UTF-8?q?=E5=85=BC=E5=AE=B9=E4=BD=8E=E7=89=88=E6=9C=ACut?= =?UTF-8?q?il-linux?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: orangeji11 --- KubeOS-Rust/manager/src/utils/partition.rs | 2 +- cmd/agent/server/utils.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/KubeOS-Rust/manager/src/utils/partition.rs b/KubeOS-Rust/manager/src/utils/partition.rs index 799b4b35..9fafb697 100644 --- a/KubeOS-Rust/manager/src/utils/partition.rs +++ b/KubeOS-Rust/manager/src/utils/partition.rs @@ -24,7 +24,7 @@ pub struct PartitionInfo { /// get_partition_info returns the current partition info and the next partition info. pub fn get_partition_info(executor: &T) -> Result<(PartitionInfo, PartitionInfo), anyhow::Error> { - let lsblk = executor.run_command_with_output("lsblk", &["-lno", "NAME,MOUNTPOINTS,FSTYPE"])?; + let lsblk = executor.run_command_with_output("lsblk", &["-lno", "NAME,MOUNTPOINT,FSTYPE"])?; // After split whitespace, the root directory line should have 3 elements, which are "sda2 / ext4". let mut cur_partition = PartitionInfo::default(); let mut next_partition = PartitionInfo::default(); diff --git a/cmd/agent/server/utils.go b/cmd/agent/server/utils.go index fdddc7d5..ba4cb0c2 100644 --- a/cmd/agent/server/utils.go +++ b/cmd/agent/server/utils.go @@ -110,7 +110,7 @@ func getNextPart(partA string, partB string) (string, string, error) { } func getRootfsDisks() (string, string, error) { - out, err := runCommandWithOut("lsblk", "-lno", "NAME,MOUNTPOINTS") + out, err := runCommandWithOut("lsblk", "-lno", "NAME,MOUNTPOINT") if err != nil { logrus.Errorln("get rootfs disks error " + err.Error()) return "", "", err -- Gitee