{"id":1864,"date":"2013-06-24T15:01:31","date_gmt":"2013-06-24T06:01:31","guid":{"rendered":"http:\/\/lovely-moon.com\/blog\/?p=1864"},"modified":"2015-08-11T16:38:09","modified_gmt":"2015-08-11T07:38:09","slug":"%e5%82%99%e5%bf%98%e9%8c%b2-%e4%b8%8d%e8%a6%81%e3%83%95%e3%82%a1%e3%82%a4%e3%83%ab%e3%81%ae%e5%9c%a7%e7%b8%ae%e3%82%92%e4%bc%b4%e3%81%86%e9%80%80%e9%81%bflinux2","status":"publish","type":"post","link":"https:\/\/lovely-moon.com\/blog\/?p=1864","title":{"rendered":"\u5099\u5fd8\u9332 \u4e0d\u8981\u30d5\u30a1\u30a4\u30eb\u306e\u5727\u7e2e\u3092\u4f34\u3046\u9000\u907f (Linux) #2"},"content":{"rendered":"<h4><span style=\"color: #a52a2a;\">\uff3b\u5b9f\u65bd\u65b9\u6cd5\uff3d<\/span><\/h4>\n<ul>\n<li>\u4e0b\u8a18\u3001\u30b9\u30af\u30ea\u30d7\u30c8\u3092\u5b9f\u884c<\/li>\n<\/ul>\n<h4><span style=\"color: #a52a2a;\">\uff3b\u4f7f\u7528\u72b6\u6cc1\uff3d<\/span><\/h4>\n<ul>\n<li>\u6307\u5b9a\u3057\u305f\u5bb9\u91cf\u4ee5\u4e0a\u306e\u30d5\u30a1\u30a4\u30ebA\u306b\u5bfe\u3057\u3001\u5727\u7e2e\u3092\u4f34\u3046\u9000\u907f\u3092\u5b9f\u65bd\u3057\u305f\u3044<\/li>\n<li>\u6307\u5b9a\u3057\u305f\u30d5\u30a1\u30a4\u30ebB\u306b\u5bfe\u3057\u3001\u5727\u7e2e\u3092\u4f34\u3046\u9000\u907f\u3092\u5b9f\u65bd\u3057\u305f\u3044<\/li>\n<\/ul>\n<h4><span style=\"color: #a52a2a;\">\uff3b\u5177\u4f53\u7684\u51e6\u7406\uff3d<\/span><\/h4>\n<ul>\n<li>\u30d5\u30a1\u30a4\u30ebA\u304c\u6307\u5b9a\u5bb9\u91cf\u3088\u308a\u5927\u304d\u3044\u5834\u5408\u306b\u3001\u30d5\u30a1\u30a4\u30ebA\u3092\u683c\u7d0d\u5148\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u3078\u79fb\u52d5\u3059\u308b<\/li>\n<li>\u30d5\u30a1\u30a4\u30ebB\u304c\u5b58\u5728\u3059\u308b\u5834\u5408\u306b\u3001\u30d5\u30a1\u30a4\u30ebB\u3092\u683c\u7d0d\u5148\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u3078\u79fb\u52d5\u3057\u5727\u7e2e\u3059\u308b<\/li>\n<li>\u79fb\u52d5\u5bfe\u8c61\u30d5\u30a1\u30a4\u30eb\u304c\u5b58\u5728\u3059\u308b\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u304c\u5b58\u5728\u3057\u306a\u3044\u5834\u5408\u306f\u3001\u4f55\u3082\u305b\u305a\u51e6\u7406\u3092\u7d42\u4e86\u3059\u308b<\/li>\n<li>\u6761\u4ef6\u306b\u5408\u3063\u305f\u30d5\u30a1\u30a4\u30eb\u304c\u5b58\u5728\u3057\u306a\u3044\u5834\u5408\u306f\u3001\u305d\u306e\u307e\u307e\u4f55\u3082\u305b\u305a\u51e6\u7406\u3092\u7d42\u4e86\u3059\u308b<\/li>\n<li>\u683c\u7d0d\u5148\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u306b\u306f\u3001\u300c_YYMMDD\u300d\u304c\u4ed8\u4e0e\u3055\u308c\u308b<\/li>\n<\/ul>\n<h4><span style=\"color: #a52a2a;\">\uff3b\u8a18\u8f09\u540d\u79f0\u8aac\u660e\uff3d<\/span><\/h4>\n<ul>\n<li>\u79fb\u52d5\u5bfe\u8c61\u30d5\u30a1\u30a4\u30eb\u304c\u5b58\u5728\u3059\u308b\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u3092\u300c\u30c7\u30a3\u30ec\u30af\u30c8\u30eaA\u300d\u3068\u3059\u308b<\/li>\n<li>\u6307\u5b9a\u5bb9\u91cf\u3088\u308a\u5927\u304d\u3044\u304b\u5224\u5b9a\u3059\u308b\u30d5\u30a1\u30a4\u30eb\u3092\u300c\u30d5\u30a1\u30a4\u30ebA\u300d\u3068\u3059\u308b<\/li>\n<li>\u5b58\u5728\u3059\u308b\u304b\u5224\u5b9a\u3059\u308b\u30d5\u30a1\u30a4\u30eb\u3092\u300c\u30d5\u30a1\u30a4\u30ebB\u300d\u3068\u3059\u308b<\/li>\n<li>\u683c\u7d0d\u5148\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u3092\u300c\u30c7\u30a3\u30ec\u30af\u30c8\u30eaB\u300d\u3068\u3059\u308b<\/li>\n<li>\u683c\u7d0d\u5148\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u304c\u5b58\u5728\u3059\u308b\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u3092\u300c\u30c7\u30a3\u30ec\u30af\u30c8\u30eaC\u300d\u3068\u3059\u308b<\/li>\n<\/ul>\n<h4><span style=\"color: #a52a2a;\">\uff3b\u30b9\u30af\u30ea\u30d7\u30c8\uff3d<\/span><\/h4>\n<ol>\n<li>SOURCE<\/li>\n<p>\t#\/bin\/bash<br \/>\n\tDATE=`date &#8216;+%Y%m%d&#8217;`<br \/>\n\t## Check of the directory.<br \/>\n\tif test -d \u30c7\u30a3\u30ec\u30af\u30c8\u30eaA ; then<br \/>\n\tcd \u30c7\u30a3\u30ec\u30af\u30c8\u30eaA<br \/>\n\telse<br \/>\n\texit<br \/>\n\tfi<br \/>\n\t## Moving a file.<br \/>\n\tDUSK=`du -sk \u30d5\u30a1\u30a4\u30ebA | cut -f 1`<br \/>\n\tif test $DUSK -gt \u5224\u5b9a\u5bb9\u91cf -a -f \u30d5\u30a1\u30a4\u30ebB ; then<br \/>\n\tmkdir \u30c7\u30a3\u30ec\u30af\u30c8\u30eaB_$DATE<br \/>\n\tmv \u30d5\u30a1\u30a4\u30ebA \u30d5\u30a1\u30a4\u30ebB \u30c7\u30a3\u30ec\u30af\u30c8\u30eaB_$DATE &#038;&#038; cd \u30c7\u30a3\u30ec\u30af\u30c8\u30eaC<br \/>\n\ttar cfjv \u30c7\u30a3\u30ec\u30af\u30c8\u30eaB_$DATE.tar.bz2 \u30c7\u30a3\u30ec\u30af\u30c8\u30eaB_$DATE<br \/>\n\trm -rf \u30c7\u30a3\u30ec\u30af\u30c8\u30eaB_$DATE<br \/>\n\texit<br \/>\n\telif test $DUSK -gt \u5224\u5b9a\u3059\u308b\u5bb9\u91cf ; then<br \/>\n\tmkdir \u30c7\u30a3\u30ec\u30af\u30c8\u30eaB_$DATE<br \/>\n\tmv \u30d5\u30a1\u30a4\u30ebA \u30c7\u30a3\u30ec\u30af\u30c8\u30eaB_$DATE &#038;&#038; cd \u30c7\u30a3\u30ec\u30af\u30c8\u30eaC<br \/>\n\ttar cfjv \u30c7\u30a3\u30ec\u30af\u30c8\u30eaB_$DATE.tar.bz2 \u30c7\u30a3\u30ec\u30af\u30c8\u30eaB_$DATE<br \/>\n\trm -rf \u30c7\u30a3\u30ec\u30af\u30c8\u30eaB_$DATE<br \/>\n\texit<br \/>\n\telif test -f \u30d5\u30a1\u30a4\u30ebB ; then<br \/>\n\tmkdir \u30c7\u30a3\u30ec\u30af\u30c8\u30eaB_$DATE<br \/>\n\tmv \u30d5\u30a1\u30a4\u30ebB \u30c7\u30a3\u30ec\u30af\u30c8\u30eaB_$DATE &#038;&#038; cd \u30c7\u30a3\u30ec\u30af\u30c8\u30eaC<br \/>\n\ttar cfjv \u30c7\u30a3\u30ec\u30af\u30c8\u30eaB_$DATE.tar.bz2 \u30c7\u30a3\u30ec\u30af\u30c8\u30eaB_$DATE<br \/>\n\trm -rf \u30c7\u30a3\u30ec\u30af\u30c8\u30eaB_$DATE<br \/>\n\telse<br \/>\n\texit<br \/>\n\tfi\n<\/ol>\n<p><!-- Ads --> <script async src=\"\/\/pagead2.googlesyndication.com\/pagead\/js\/adsbygoogle.js\"><\/script><br \/>\n<!-- Ads --> <!-- Advertising-Rectangle --><br \/>\n<!-- Ads --> <ins class=\"adsbygoogle\" style=\"display:inline-block;width:300px;height:250px\" data-ad-client=\"ca-pub-0658343697312886\" data-ad-slot=\"8784431573\"><\/ins><br \/>\n<!-- Ads --> <script>(adsbygoogle = window.adsbygoogle || []).push({});<\/script><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\uff3b\u5b9f\u65bd\u65b9\u6cd5\uff3d \u4e0b\u8a18\u3001\u30b9\u30af\u30ea\u30d7\u30c8\u3092\u5b9f\u884c \uff3b\u4f7f\u7528\u72b6\u6cc1\uff3d \u6307\u5b9a\u3057\u305f\u5bb9\u91cf\u4ee5\u4e0a\u306e\u30d5\u30a1\u30a4\u30ebA\u306b\u5bfe\u3057\u3001\u5727\u7e2e\u3092\u4f34\u3046\u9000\u907f\u3092\u5b9f\u65bd\u3057\u305f\u3044 \u6307\u5b9a\u3057\u305f\u30d5\u30a1\u30a4\u30ebB\u306b\u5bfe\u3057\u3001\u5727\u7e2e\u3092\u4f34\u3046\u9000\u907f\u3092\u5b9f\u65bd\u3057\u305f\u3044 \uff3b\u5177\u4f53\u7684\u51e6\u7406\uff3d \u30d5\u30a1\u30a4\u30ebA\u304c\u6307\u5b9a\u5bb9\u91cf\u3088\u308a\u5927\u304d\u3044\u5834\u5408 &hellip;<\/p>\n<p class=\"read-more\"> <a class=\"more-link\" href=\"https:\/\/lovely-moon.com\/blog\/?p=1864\"> <span class=\"screen-reader-text\">\u5099\u5fd8\u9332 \u4e0d\u8981\u30d5\u30a1\u30a4\u30eb\u306e\u5727\u7e2e\u3092\u4f34\u3046\u9000\u907f (Linux) #2<\/span> \u7d9a\u304d\u3092\u8aad\u3080 &raquo;<\/a><\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3],"tags":[8],"class_list":["post-1864","post","type-post","status-publish","format-standard","hentry","category-3","tag-memorandum"],"_links":{"self":[{"href":"https:\/\/lovely-moon.com\/blog\/index.php?rest_route=\/wp\/v2\/posts\/1864","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/lovely-moon.com\/blog\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/lovely-moon.com\/blog\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/lovely-moon.com\/blog\/index.php?rest_route=\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/lovely-moon.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=1864"}],"version-history":[{"count":15,"href":"https:\/\/lovely-moon.com\/blog\/index.php?rest_route=\/wp\/v2\/posts\/1864\/revisions"}],"predecessor-version":[{"id":3676,"href":"https:\/\/lovely-moon.com\/blog\/index.php?rest_route=\/wp\/v2\/posts\/1864\/revisions\/3676"}],"wp:attachment":[{"href":"https:\/\/lovely-moon.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=1864"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/lovely-moon.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=1864"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/lovely-moon.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=1864"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}