diff --git a/gofsutil_mount_linux.go b/gofsutil_mount_linux.go index b01b915..8f21de6 100644 --- a/gofsutil_mount_linux.go +++ b/gofsutil_mount_linux.go @@ -575,10 +575,10 @@ func reReadPartitionTable(ctx context.Context, devicePath string) error { if err := validatePath(path); err != nil { return fmt.Errorf("Failed to validate path: %s error %v", devicePath, err) } - args := []string{"--rereadpt", path} - _, err := exec.Command("blockdev", args...).CombinedOutput() + args := []string{path} + _, err := exec.Command("partprobe", args...).CombinedOutput() if err != nil { - log.Errorf("Failed to execute blockdev on %s: %v", devicePath, err) + log.Errorf("Failed to execute partprobe on %s: %s", devicePath, err.Error()) return err } return nil