{"id":361,"date":"2012-08-05T14:54:30","date_gmt":"2012-08-05T12:54:30","guid":{"rendered":"http:\/\/wp.oktay.com\/?p=361"},"modified":"2012-10-30T00:19:54","modified_gmt":"2012-10-29T22:19:54","slug":"linux-server-adm-decrease-monitor-hd-access","status":"publish","type":"post","link":"https:\/\/wp.oktay.com\/?p=361","title":{"rendered":"linux server adm &#8211; decrease \/ monitor hd access"},"content":{"rendered":"<p>first install<br \/>\napt-get install inotify-tools<br \/>\nmaybe also screen to have inotify running with screen in the background<\/p>\n<p>then monitor what is going on. directories after a @ are ignored.<\/p>\n<p>inotifywait -m -r \/  @\/dev   @\/media  @\/mnt  @\/opt  @\/proc  @\/root  @\/sbin  @\/sys  @\/tmp  @\/usr   @\/bin @\/etc @\/lib @\/var\/run\/samba\/ @\/var\/cache\/samba\/<\/p>\n<p>case &#8220;$1&#8221; in<br \/>\n        start)<br \/>\n                log_daemon_msg &#8220;Starting Samba daemons&#8221;<br \/>\n            <strong> <em>   mount -t tmpfs tmpfs \/var\/run\/samba<br \/>\n                mount -t tmpfs tmpfs \/var\/cache\/samba<\/em><\/strong><\/p>\n<p>                # Make sure we have our PIDDIR, even if it&#8217;s on a tmpfs<br \/>\n                install -o root -g root -m 755 -d $PIDDIR<\/p>\n<p>at stop)<\/p>\n<p>..<br \/>\n..<br \/>\n                        fi<br \/>\n                fi<\/p>\n<p>           <strong>   <em>  umount \/var\/run\/samba<br \/>\n                umount \/var\/cache\/samba<\/em><br \/>\n<\/strong><br \/>\n                log_end_msg 0<\/p>\n<p>                ;;<br \/>\n        reload)<\/p>\n<p>&#8212;&#8212;&#8212;-<br \/>\nfor me it did not do all the trick. samba was still trying to access:<br \/>\n\/var\/lib\/samba so:<br \/>\nmv \/var\/lib\/samba\/ \/var\/lib\/samba_<br \/>\ncp -ar \/var\/lib\/samba_ \/tmp\/samba_lib<br \/>\nln -sf \/tmp\/samba_lib \/var\/lib\/samba <\/p>\n<p>(this is what I am currently testing&#8230; but should work.. so unconfirmed yet \ud83d\ude42<\/p>\n","protected":false},"excerpt":{"rendered":"<p>first install apt-get install inotify-tools maybe also screen to have inotify running with screen in the background then monitor what is going on. directories after a @ are ignored. inotifywait -m -r \/ @\/dev @\/media @\/mnt @\/opt @\/proc @\/root @\/sbin @\/sys @\/tmp @\/usr @\/bin @\/etc @\/lib @\/var\/run\/samba\/ @\/var\/cache\/samba\/ case &#8220;$1&#8221; in start) log_daemon_msg &#8220;Starting Samba&hellip; <a class=\"more-link\" href=\"https:\/\/wp.oktay.com\/?p=361\">Continue reading <span class=\"screen-reader-text\">linux server adm &#8211; decrease \/ monitor hd access<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3],"tags":[],"class_list":["post-361","post","type-post","status-publish","format-standard","hentry","category-bash","entry"],"_links":{"self":[{"href":"https:\/\/wp.oktay.com\/index.php?rest_route=\/wp\/v2\/posts\/361","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/wp.oktay.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/wp.oktay.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/wp.oktay.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/wp.oktay.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=361"}],"version-history":[{"count":6,"href":"https:\/\/wp.oktay.com\/index.php?rest_route=\/wp\/v2\/posts\/361\/revisions"}],"predecessor-version":[{"id":393,"href":"https:\/\/wp.oktay.com\/index.php?rest_route=\/wp\/v2\/posts\/361\/revisions\/393"}],"wp:attachment":[{"href":"https:\/\/wp.oktay.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=361"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/wp.oktay.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=361"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/wp.oktay.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=361"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}