mirror of
https://github.com/oneclickvirt/basics.git
synced 2025-10-18 22:44:45 +08:00
feat: 支持raid检测(虽然几乎没有服务器有查得到的)
This commit is contained in:
@@ -5,5 +5,21 @@ import (
|
||||
)
|
||||
|
||||
func TestGetSystemInfo(t *testing.T) {
|
||||
// 检测整体
|
||||
GetSystemInfo()
|
||||
// 检测raid - 在服务器上几乎没有查得到的,不加入检测
|
||||
// raidInfo, err := detectRAID()
|
||||
// if err != nil {
|
||||
// fmt.Printf("检测RAID时发生错误: %v\n", err)
|
||||
// return
|
||||
// }
|
||||
// if raidInfo.Exists {
|
||||
// fmt.Println("检测到RAID配置:")
|
||||
// fmt.Printf("RAID类型: %s\n", raidInfo.Type)
|
||||
// fmt.Printf("磁盘数量: %d\n", raidInfo.DiskCount)
|
||||
// fmt.Printf("控制器: %s\n", raidInfo.Controller)
|
||||
// // fmt.Printf("详细信息: %s\n", raidInfo.Details)
|
||||
// } else {
|
||||
// fmt.Println("未检测到RAID配置")
|
||||
// }
|
||||
}
|
||||
|
Reference in New Issue
Block a user