会员
周边
新闻
博问
闪存
众包
赞助商
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
吃吃吃大王
博客园
首页
新随笔
联系
订阅
管理
2023年7月18日
获取虚拟机运行时长的脚本
摘要: #!/bin/bash # 获取虚拟机启动时间戳 boot_timestamp=$(date -d "$(uptime -s)" +%s) # 当前时间戳 current_timestamp=$(date +%s) # 计算运行时长(以秒为单位) runtime=$((current_timesta
阅读全文
posted @ 2023-07-18 15:10 吃吃吃大王
阅读(121)
评论(0)
推荐(0)
公告