{"id":294,"date":"2023-02-11T19:19:38","date_gmt":"2023-02-11T10:19:38","guid":{"rendered":"https:\/\/intinfinity.com\/?p=294"},"modified":"2023-02-11T19:19:42","modified_gmt":"2023-02-11T10:19:42","slug":"s-m-a-r-t-%e3%81%ae%e7%95%b0%e5%b8%b8%e3%82%92nextcloud%e3%81%ab%e9%80%9a%e7%9f%a5%e3%81%99%e3%82%8b","status":"publish","type":"post","link":"https:\/\/intinfinity.com\/index.php\/archives\/294","title":{"rendered":"S.M.A.R.T.\u306e\u7570\u5e38\u3092Nextcloud\u306b\u901a\u77e5\u3059\u308b"},"content":{"rendered":"\n<p><a href=\"https:\/\/intinfinity.com\/index.php\/archives\/265\" data-type=\"post\" data-id=\"265\">OS\u306e\u901a\u77e5\u3092Nextcloud\u306b\u9001\u308b\u6a5f\u80fd<\/a>\u3092\u4f7f\u3063\u3066\u3001\u5b9f\u969b\u306bOS\u306e\u901a\u77e5\u3092\u9001\u4fe1\u3057\u3066\u307f\u307e\u3059\u3002<\/p>\n\n\n\n<p>\u4eca\u56de\u306f\u3001HDD\u306a\u3069\u306e\u30b9\u30c8\u30ec\u30fc\u30b8\u306e\u72b6\u614b\u3092\u76e3\u8996\u3059\u308bsmartmontools\u304c\u9001\u4fe1\u3059\u308b\u30e1\u30fc\u30eb\u306e\u5185\u5bb9\u3060\u3051\u3092\u53d6\u308a\u51fa\u3057\u3066Nextcloud\u306b\u901a\u77e5\u3057\u307e\u3059\u3002(\u30e1\u30fc\u30eb\u306e\u5185\u5bb9\u3092\u53d6\u308a\u51fa\u3059\u3068\u66f8\u304d\u307e\u3057\u305f\u304c\u3001\u30e1\u30fc\u30eb\u95a2\u4fc2\u306e\u6a5f\u80fd\u306f\u4e00\u5207\u4f7f\u3044\u307e\u305b\u3093\u3002)<\/p>\n\n\n\n<p>\u3064\u3044\u3067\u306b\u3001\u5b9a\u671f\u7684\u306bS.M.A.R.T.\u306e\u30bb\u30eb\u30d5\u30c6\u30b9\u30c8\u3092\u884c\u3046\u3088\u3046\u306b\u8a2d\u5b9a\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">\u5b9f\u88c5<\/h2>\n\n\n\n<p>smartmontools\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo apt install smartmontools<\/code><\/pre>\n\n\n\n<p>smartmontools\u306e\u30c7\u30fc\u30e2\u30f3\u3067\u3042\u308bsmartd\u304b\u3089\u547c\u3073\u51fa\u3055\u308c\u308b\u30b9\u30af\u30ea\u30d7\u30c8\u3092\u5b9f\u88c5\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo vi \/root\/sh\/smartd.sh<\/code><\/pre>\n\n\n\n<pre class=\"wp-block-code\"><code>#!\/bin\/bash\n\/root\/sh\/nextcloud_notification.sh \"$SMARTD_MESSAGE\" \"$SMARTD_FULLMESSAGE\"<\/code><\/pre>\n\n\n\n<p>smartd\u306econfig\u3092\u7de8\u96c6\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo vi \/etc\/smartd.conf<\/code><\/pre>\n\n\n\n<p>\u3082\u3068\u3082\u3068\u5165\u3063\u3066\u3044\u308b\"DEVICESCAN\"\u304b\u3089\u59cb\u307e\u308b\u884c\u3092\u3059\u3079\u3066\u30b3\u30e1\u30f3\u30c8\u30a2\u30a6\u30c8\u3059\u308b<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>#DEVICESCAN -d removable -n standby -m root -M exec \/usr\/share\/smartmontools\/smartd-runner<\/code><\/pre>\n\n\n\n<p>\u30d5\u30a1\u30a4\u30eb\u306e\u672b\u5c3e\u306b\u4ee5\u4e0b\u3092\u8ffd\u8a18<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>DEVICESCAN -a -o on -S on -s (O\/..\/..\/.\/(00|06|12|18)|S\/..\/..\/.\/01|L\/..\/..\/6\/03) -W 4,35,40 -m root -M exec \/root\/sh\/smartd.sh<\/code><\/pre>\n\n\n\n<p>\u30b5\u30fc\u30d3\u30b9\u3092\u518d\u8d77\u52d5\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo systemctl restart smartmontools<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">\u52d5\u4f5c\u78ba\u8a8d<\/h2>\n\n\n\n<p>\u30c6\u30b9\u30c8\u30e1\u30c3\u30bb\u30fc\u30b8\u3092\u51fa\u3059\u306b\u306f\u3001config\u3092\u5909\u66f4\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<p>DEVICESCAN ... \u306e\u672b\u5c3e\u306b\"-M test\"\u3092\u8ffd\u8a18\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>DEVICESCAN -a -o on -S on -s (O\/..\/..\/.\/(00|06|12|18)|S\/..\/..\/.\/01|L\/..\/..\/6\/03) -W 4,35,40 -m root -M exec \/root\/sh\/smartd.sh -M test<\/code><\/pre>\n\n\n\n<p>smartmontools\u3092\u518d\u8d77\u52d5\u3059\u308b\u3068\u3001\u901a\u77e5\u304c\u884c\u308f\u308c\u307e\u3059\u3002<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo systemctl restart smartmontools<\/code><\/pre>\n\n\n\n<p>smartmontools\u8d77\u52d5\u6642\u306b\u901a\u77e5\u304c\u884c\u308f\u308c\u307e\u3059\u3002\u554f\u984c\u306a\u3044\u3053\u3068\u3092\u78ba\u8a8d\u3057\u305f\u3089\u3001\u8ffd\u52a0\u3057\u305f\u672b\u5c3e\u306e\"-M test\"\u3092\u524a\u9664\u3057\u3066smartmontools\u3092\u518d\u8d77\u52d5\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">\u53c2\u8003\u8cc7\u6599<\/h2>\n\n\n\n<p><a href=\"https:\/\/linux.die.net\/man\/5\/smartd.conf\" target=\"_blank\" rel=\"noreferrer noopener\">smartd.conf(5) - Linux man page<\/a><\/p>\n\n\n\n<p><a href=\"http:\/\/blue-red.ddo.jp\/~ao\/wiki\/wiki.cgi?page=Linux%A4%C7HDD%A4%CESMART%A4%F2%A5%E2%A5%CB%A5%BF%A5%EA%A5%F3%A5%B0%A4%B9%A4%EB\" target=\"_blank\" rel=\"noreferrer noopener\">Linux\u3067HDD\u306eSMART\u3092\u30e2\u30cb\u30bf\u30ea\u30f3\u30b0\u3059\u308b - \u3075\u306aWiki<\/a><\/p>\n\n\n\n<p>\u30b5\u30f3\u30d7\u30eb\u30b9\u30af\u30ea\u30d7\u30c8(smartmontools \u3068\u4e00\u7dd2\u306b\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3055\u308c\u308b)<br>\/usr\/share\/doc\/smartmontools\/examplescripts\/<\/p>\n","protected":false},"excerpt":{"rendered":"<p>OS\u306e\u901a\u77e5\u3092Nextcloud\u306b\u9001\u308b\u6a5f\u80fd\u3092\u4f7f\u3063\u3066\u3001\u5b9f\u969b\u306bOS\u306e\u901a\u77e5\u3092\u9001\u4fe1\u3057\u3066\u307f\u307e\u3059\u3002 \u4eca\u56de\u306f\u3001HDD\u306a\u3069\u306e\u30b9\u30c8\u30ec\u30fc\u30b8\u306e\u72b6\u614b\u3092\u76e3\u8996\u3059\u308bsmartmontools\u304c\u9001\u4fe1\u3059\u308b\u30e1\u30fc\u30eb\u306e\u5185\u5bb9\u3060\u3051\u3092\u53d6\u308a\u51fa\u3057\u3066Nextcloud\u306b\u901a\u77e5 [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[6,5],"tags":[],"class_list":["post-294","post","type-post","status-publish","format-standard","hentry","category-linux","category-server-application"],"_links":{"self":[{"href":"https:\/\/intinfinity.com\/index.php\/wp-json\/wp\/v2\/posts\/294","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/intinfinity.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/intinfinity.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/intinfinity.com\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/intinfinity.com\/index.php\/wp-json\/wp\/v2\/comments?post=294"}],"version-history":[{"count":13,"href":"https:\/\/intinfinity.com\/index.php\/wp-json\/wp\/v2\/posts\/294\/revisions"}],"predecessor-version":[{"id":319,"href":"https:\/\/intinfinity.com\/index.php\/wp-json\/wp\/v2\/posts\/294\/revisions\/319"}],"wp:attachment":[{"href":"https:\/\/intinfinity.com\/index.php\/wp-json\/wp\/v2\/media?parent=294"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/intinfinity.com\/index.php\/wp-json\/wp\/v2\/categories?post=294"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/intinfinity.com\/index.php\/wp-json\/wp\/v2\/tags?post=294"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}