User-Profile-Image
hankin
  • 5
  • 首页
  • 分类
    • Windows
    • Web
    • VoIP
    • Virtualization
    • Trading
    • Smart Home
    • SEO
    • Security
    • Python
    • Program
    • PHP
    • OSX
    • OS
    • OpenSource
    • Nginx
    • MySQL
    • Mood
    • Linux
    • Life
    • Injection
    • Hosting
    • Exploits
    • CDN
  • 页面
    • About
  • 友链
    • 维酷科技
    • Tesra超算网络
Help?

Please contact us on our email for need any support

Support
  • 首页
    首页   ›   OS   ›   Linux   ›   正文
Linux

Linux/CentOS下怎么查看硬盘使用时间

2014-01-09 19:09:56
778  0 0

对于需要租用服务器的朋友,新服务器到手后最好检查下硬盘的使用情况,以便心里有底。

在CentOS下通过一个简单的命令就可以看到硬盘的通电时间

smartctl -a /dev/sda

如果有多个硬盘 更换/dev/sda这部分就行

针对Datashack的SAS硬盘

smartctl
-i 指定设备
-d 指定设备类型,例如:ata, scsi, marvell, sat, 3ware,N
-a 或A 显示所有信息
-l 指定日志的类型,例如:TYPE: error, selftest, selective, directory,background, scttemp[sts,hist]
-H 查看硬盘健康状态
-t short 后台检测硬盘,消耗时间短
-t long 后台检测硬盘,消耗时间长
-C -t short 前台检测硬盘,消耗时间短
-C -t long 前台检测硬盘,消耗时间长
-X 中断后台检测硬盘
-l selftest 显示硬盘检测日志
HP硬盘:
smartctl -s on -d  cciss,0 /dev/cciss/c0d0 开启SMART
smartctl  -a  -d cciss,0 -i /dev/cciss/c0d0  显示所有SMART信息
smartctl  -l error  -d cciss,0 -i /dev/cciss/c0d0 查看磁盘错误日志

ProdigYu
163文章 10评论 2点赞 80571浏览
随机文章
基于Python的socket编程
11年前
Sublime Text
9年前
总结Apache 2.2.X 动态添加mod_perl
11年前
CentOS/Ubuntu/Debian等Linux查看端口占用
4年前
通过ASP,PHP,JS,HTML实现301跳转
10年前
Tags
Apache CentOS CMD DDOS Debian DNS FastCGI Google IIS IP iptables Linux Mac MySQL Nginx Opensource PHP Python Skill Spawn-FCGI SSH Ubuntu Vim VMware VPN web.py Windows 删除 命令 命令提示符 安装 开源 技巧 插件 漏洞 百度 系统 组件 终端 缓存 网络电话 脚本 自建 详解 错误
Meta
  • Log in
  • Entries feed
  • Comments feed
  • WordPress.org
Copyright © 2021
Designed by hankin
主页
页面
  • About
博主
ProdigYu 管理员
Something about myself
163 文章 10 评论 80571 浏览
测试
测试