经过 3 年的 24x7 服务,1TB 希捷 Barracuda ES.2 企业级硬盘出现故障迹象。SMART 重新分配的扇区数很高。
维基百科文章表明,如果重新映射的扇区未使用,该驱动器仍可用于不太敏感的用途,例如阵列外的暂存存储。
A workaround which will preserve drive speed at the expense of capacity
is to create a disk partition over the region which contains remaps and
instruct the operating system to not use that partition.
Run Code Online (Sandbox Code Playgroud)
为了创建这样的分区,有必要获取重新映射的扇区列表。但是,操作系统看不到坏块。即badblocks
返回一个空列表。
有没有办法恢复重新分配的扇区列表?
编辑:此驱动器来自阵列。我们每年都会有一些失败,把它们扔掉似乎是一种浪费。我正在考虑给盘子中更好的部分第二次机会。
这是 SMART 报告现在的样子。
=== START OF INFORMATION SECTION ===
Model Family: Seagate Barracuda ES.2
Device Model: ST31000340NS
Serial Number: **********
Firmware Version: SN05
...
ID# ATTRIBUTE_NAME FLAG …
Run Code Online (Sandbox Code Playgroud) 我有一个系统,其中多个用户正在运行chmod
相同文件的应用程序。我尝试使用setacl
将两个用户添加为文件的用户所有者来执行此操作,但它不起作用。由于chmod
系统调用失败,应用程序出错。
见示例:
[jacob@macbook-debian ~/Projects/test] getfacl bin/testfile
# file: bin/testfile
# owner: root
# group: root
user::rwx
user:jacob:rwx
user:jason:rwx
group::r-x
group:www-data:rwx
mask::rwx
other::r-x
[jacob@macbook-debian ~/Projects/test] chmod 0755 bin/testfile
chmod: changing permissions of 'bin/testfile': Operation not permitted
Run Code Online (Sandbox Code Playgroud) 我确实认为以下命令等效,但它们产生不同的校验和:
tar -cvzf ...
并且tar -cvf ...; gzip ...
不会产生相同的输出。
sha1sum
不同。
会是什么gzip
,将完全匹配的命令tar -cvzf
的行为吗?
bad-blocks ×1
checksum ×1
chmod ×1
compression ×1
gnu ×1
gzip ×1
hard-drive ×1
linux ×1
posix ×1
setfacl ×1
smart ×1
tar ×1