{"id":3332,"date":"2019-07-31T14:07:10","date_gmt":"2019-07-31T05:07:10","guid":{"rendered":"https:\/\/tech.akat.info\/?p=3332"},"modified":"2019-07-31T14:15:08","modified_gmt":"2019-07-31T05:15:08","slug":"linux%e6%95%99%e7%a7%91%e6%9b%b8-lpic%e3%83%ac%e3%83%99%e3%83%ab2-%e3%82%b9%e3%83%94%e3%83%bc%e3%83%89%e3%83%9e%e3%82%b9%e3%82%bf%e3%83%bc%e5%95%8f%e9%a1%8c%e9%9b%86-version4-5%e5%af%be%e5%bf%9c","status":"publish","type":"post","link":"https:\/\/tech.akat.info\/?p=3332","title":{"rendered":"Linux\u6559\u79d1\u66f8 LPIC\u30ec\u30d9\u30eb2 \u30b9\u30d4\u30fc\u30c9\u30de\u30b9\u30bf\u30fc\u554f\u984c\u96c6 Version4.5\u5bfe\u5fdc \u3092\u53c2\u8003\u306bLPIC2\u306e\u52c9\u5f37\u3092\u3057\u305f"},"content":{"rendered":"<p><a href=\"https:\/\/www.amazon.co.jp\/dp\/4798151238\">Linux\u6559\u79d1\u66f8 LPIC\u30ec\u30d9\u30eb2 \u30b9\u30d4\u30fc\u30c9\u30de\u30b9\u30bf\u30fc\u554f\u984c\u96c6 Version4.5\u5bfe\u5fdc<\/a>\u3092\u53c2\u8003\u306bLPIC2\u306e\u52c9\u5f37\u3092\u3057\u305f\u3002<br \/>\n\u77e5\u3089\u306a\u304b\u3063\u305f\u3053\u3068\u3084\u8a66\u3057\u3066\u307f\u305f\u3053\u3068\u3092\u30e1\u30e2\u3057\u3066\u304a\u304f\u3002<\/p>\n<h2>\u30d5\u30a1\u30a4\u30eb\u30b7\u30b9\u30c6\u30e0<\/h2>\n<h3>fuser\u30b3\u30de\u30f3\u30c9\u3067\u30d5\u30a1\u30a4\u30eb\u3084\u30d5\u30a1\u30a4\u30eb\u30b7\u30b9\u30c6\u30e0\u306b\u30a2\u30af\u30bb\u30b9\u3057\u3066\u3044\u308b\u30d7\u30ed\u30bb\u30b9\u3092\u8868\u793a\u3059\u308b<\/h3>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n# fuser -v \/mnt\/test.txt\r\n                     USER        PID ACCESS COMMAND\r\n\/mnt\/test.txt:       root      20719 f.... lv\r\n<\/pre>\n<h3>mke2fs\u30b3\u30de\u30f3\u30c9\u3067ext3\u30d5\u30a1\u30a4\u30eb\u30b7\u30b9\u30c6\u30e0\u3092\u4f5c\u6210\u3059\u308b<\/h3>\n<p>config\u30d5\u30a1\u30a4\u30eb\u306f\/etc\/mke2fs.conf\u306b\u5b58\u5728\u3059\u308b<\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n# mke2fs -j disk.img\r\n...\r\n# mke2fs -t ext3 disk.img\r\n...\r\n<\/pre>\n<h3>Btrfs(B-tree filesystem)\u30d5\u30a1\u30a4\u30eb\u30b7\u30b9\u30c6\u30e0\u3067\u30b9\u30ca\u30c3\u30d7\u30b7\u30e7\u30c3\u30c8\u3092\u53d6\u5f97\u3057\u3066\u307f\u308b<\/h3>\n<p>\u30fbBtrfs\u306f2009\u5e74\u306b\u30ea\u30ea\u30fc\u30b9\u3055\u308c\u30012014\u5e748\u6708\u306bstable\u3068\u306a\u308a\u3001\u540c\u5e7410\u6708\u306bSUSE Enterprise Linux 12\u306e\u30c7\u30d5\u30a9\u30eb\u30c8\u30d5\u30a1\u30a4\u30eb\u30b7\u30b9\u30c6\u30e0\u3068\u306a\u3063\u305f<br \/>\n\u30fbBtrfs\u306fsnapshot\u3092subvolume\u5358\u4f4d\u3067\u53d6\u5f97\u3059\u308b<br \/>\nhttps:\/\/qiita.com\/termoshtt\/items\/d3b3b6c36a97fea60a14<\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n# dd if=\/dev\/zero of=disk.img bs=1M count=256\r\n...\r\n# mkfs.btrfs disk.img\r\nbtrfs-progs v4.15.1\r\nSee http:\/\/btrfs.wiki.kernel.org for more information.\r\n\r\nLabel:              (null)\r\nUUID:               3bbf3295-23d4-44d9-bcd4-759cf3b8c40a\r\nNode size:          16384\r\nSector size:        4096\r\nFilesystem size:    256.00MiB\r\nBlock group profiles:\r\n  Data:             single            8.00MiB\r\n  Metadata:         DUP              32.00MiB\r\n  System:           DUP               8.00MiB\r\nSSD detected:       no\r\nIncompat features:  extref, skinny-metadata\r\nNumber of devices:  1\r\nDevices:\r\n   ID        SIZE  PATH\r\n    1   256.00MiB  disk.img\r\n\r\n# btrfs subvolume create \/mnt\/sub-data\r\nCreate subvolume '\/mnt\/sub-data'\r\n# btrfs subvolume create \/mnt\/sub-data2\r\nCreate subvolume '\/mnt\/sub-data2'\r\n# btrfs subvolume list \/mnt\/\r\nID 256 gen 7 top level 5 path sub-data\r\nID 257 gen 8 top level 5 path sub-data2\r\n\r\n# btrfs subvolume snapshot \/mnt\/sub-data \/mnt\/snapshot\r\nCreate a snapshot of '\/mnt\/sub-data' in '\/mnt\/snapshot\/sub-data'\r\n<\/pre>\n<h3>XFS\u30d5\u30a1\u30a4\u30eb\u30b7\u30b9\u30c6\u30e0\u3092\u30d0\u30c3\u30af\u30a2\u30c3\u30d7\u3057\u3066\u307f\u308b<\/h3>\n<p>\u30fb2014\u5e746\u6708\u306b\u30ea\u30ea\u30fc\u30b9\u3055\u308c\u305fRedHat Enterprise linux 7\u306b\u3066\u30c7\u30d5\u30a9\u30eb\u30c8\u306e\u30d5\u30a1\u30a4\u30eb\u30b7\u30b9\u30c6\u30e0\u306b\u306a\u3063\u305f<\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n# dd if=\/dev\/zero of=disk.img bs=1M count=256\r\n...\r\n# mkfs -t xfs disk.img\r\nmeta-data=disk.img               isize=512    agcount=4, agsize=16384 blks\r\n         =                       sectsz=512   attr=2, projid32bit=1\r\n         =                       crc=1        finobt=1, sparse=0, rmapbt=0, reflink=0\r\ndata     =                       bsize=4096   blocks=65536, imaxpct=25\r\n         =                       sunit=0      swidth=0 blks\r\nnaming   =version 2              bsize=4096   ascii-ci=0 ftype=1\r\nlog      =internal log           bsize=4096   blocks=855, version=2\r\n         =                       sectsz=512   sunit=0 blks, lazy-count=1\r\nrealtime =none                   extsz=4096   blocks=0, rtextents=0\r\n\r\n# mount -t xfs disk.img \/mnt\/\r\n# df | grep mnt\r\n\/dev\/loop1        258724   13616    245108   6% \/mnt\r\n\r\n# xfs_info \/dev\/loop1\r\nmeta-data=\/dev\/loop0             isize=512    agcount=4, agsize=16384 blks\r\n         =                       sectsz=512   attr=2, projid32bit=1\r\n         =                       crc=1        finobt=1 spinodes=0 rmapbt=0\r\n         =                       reflink=0\r\ndata     =                       bsize=4096   blocks=65536, imaxpct=25\r\n         =                       sunit=0      swidth=0 blks\r\nnaming   =version 2              bsize=4096   ascii-ci=0 ftype=1\r\nlog      =internal               bsize=4096   blocks=855, version=2\r\n         =                       sectsz=512   sunit=0 blks, lazy-count=1\r\nrealtime =none                   extsz=4096   blocks=0, rtextents=0\r\n\r\n# xfsdump -f \/backup\/data.dump -L &quot;full backup&quot; -M &quot;data.dump&quot; \/dev\/loop1\r\n...\r\nxfsdump:   stream 0 \/backup\/data.dump OK (success)\r\nxfsdump: Dump Status: SUCCESS\r\n\r\n# xfsrestore -r -f \/backup\/data.dump \/mnt\r\n...\r\nxfsrestore:   stream 0 \/backup\/data.dump OK (success)\r\nxfsrestore: Restore Status: SUCCESS\r\n<\/pre>\n<h3>Windows\u3067\u3082\u8aad\u3081\u308bISO\u30d5\u30a1\u30a4\u30eb\u3092\u4f5c\u6210\u3059\u308b<\/h3>\n<p>\u30fb-J\u30aa\u30d7\u30b7\u30e7\u30f3\u3092\u3064\u3051\u308b\u3053\u3068\u3067ISO9660+Joliet\u62e1\u5f35\u306e\u30d5\u30a1\u30a4\u30eb\u3092\u4f5c\u6210\u3059\u308b<\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n# mkisofs -R -T -J -o lpic2.iso lpic2\r\nI: -input-charset not specified, using utf-8 (detected in locale settings)\r\nTotal translation table size: 220\r\nTotal rockridge attributes bytes: 330\r\nTotal directory bytes: 488\r\nPath table size(bytes): 10\r\nMax brk space used 0\r\n183 extents written (0 MB)\r\n<\/pre>\n<h2>\u30ab\u30fc\u30cd\u30eb<\/h2>\n<h3>diff\u30b3\u30de\u30f3\u30c9\u3067\u53d6\u5f97\u3057\u305f\u5dee\u5206\u3092patch\u30b3\u30de\u30f3\u30c9\u3067\u9069\u7528\u3059\u308b<\/h3>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n# cat test.txt\r\nthis is test\r\n# cat test2.txt\r\nthis is test\r\nthis is test2\r\n# diff -up test.txt test2.txt &gt; diff.patch\r\n# patch test.txt &lt; diff.patch\r\npatching file test.txt\r\n# cat test.txt\r\nthis is test\r\nthis is test2\r\n# patch -R test.txt &lt; diff.patch\r\npatching file test.txt\r\n# cat test.txt\r\nthis is test\r\n<\/pre>\n<p>https:\/\/qiita.com\/astro_super_nova\/items\/e30dcaf4d106deebc63c<\/p>\n<h3>\u30e2\u30b8\u30e5\u30fc\u30eb\u306e\u30d5\u30a1\u30a4\u30eb\u306e\u5834\u6240\u3092\u8868\u793a\u3059\u308b<\/h3>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n# modinfo -n xfs\r\n\/lib\/modules\/4.15.0-1043-aws\/kernel\/fs\/xfs\/xfs.ko\r\n<\/pre>\n<h3>\u5404\u30e2\u30b8\u30e5\u30fc\u30eb\u306e\u4f9d\u5b58\u95a2\u4fc2\u3092\u8a18\u8f09\u3057\u305f\u30d5\u30a1\u30a4\u30eb<\/h3>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n# cat \/lib\/modules\/4.15.0-1043-aws\/modules.dep\r\n<\/pre>\n<h3>\u73fe\u5728\u7a3c\u50cd\u3057\u3066\u3044\u308b\u30ab\u30fc\u30cd\u30eb\u30d1\u30e9\u30e1\u30fc\u30bf\u30fc<\/h3>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n# cat \/proc\/cmdline\r\nBOOT_IMAGE=\/boot\/vmlinuz-4.15.0-1043-aws root=UUID...\r\n<\/pre>\n<h2>\u30b7\u30b9\u30c6\u30e0\u306e\u8d77\u52d5<\/h2>\n<p>\u5909\u66f4\u3055\u308c\u305f\u8a2d\u5b9a\u30d5\u30a1\u30a4\u30eb\u3092\u8868\u793a\u3059\u308b<\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n# systemd-delta\r\n&#x5B;OVERRIDDEN] \/etc\/tmpfiles.d\/screen-cleanup.conf \u2192 \/usr\/lib\/tmpfiles.d\/screen-cleanup.conf\r\n\r\n--- \/usr\/lib\/tmpfiles.d\/screen-cleanup.conf     2017-07-01 21:07:57.000000000 +0900\r\n+++ \/etc\/tmpfiles.d\/screen-cleanup.conf 2018-09-13 00:58:27.539635430 +0900\r\n@@ -1 +1 @@\r\n-d \/run\/screen 0777 root utmp\r\n+d \/run\/screen 1777 root utmp\r\n\r\n&#x5B;EXTENDED]   \/lib\/systemd\/system\/rc-local.service \u2192 \/lib\/systemd\/system\/rc-local.service.d\/debian.conf\r\n&#x5B;EXTENDED]   \/lib\/systemd\/system\/user@.service \u2192 \/lib\/systemd\/system\/user@.service.d\/timeout.conf\r\n&#x5B;MASKED]     \/etc\/udev\/rules.d\/60-cdrom_id.rules \u2192 \/lib\/udev\/rules.d\/60-cdrom_id.rules\r\n<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>Linux\u6559\u79d1\u66f8 LPIC\u30ec\u30d9\u30eb2 \u30b9\u30d4\u30fc\u30c9\u30de\u30b9\u30bf\u30fc\u554f\u984c\u96c6 Version4.5\u5bfe\u5fdc\u3092\u53c2\u8003\u306bLPIC2\u306e\u52c9\u5f37\u3092\u3057\u305f\u3002 \u77e5\u3089\u306a\u304b\u3063\u305f\u3053\u3068\u3084\u8a66\u3057\u3066\u307f\u305f\u3053\u3068\u3092\u30e1\u30e2\u3057\u3066\u304a\u304f\u3002 \u30d5\u30a1\u30a4\u30eb\u30b7\u30b9\u30c6\u30e0 fuser\u30b3\u30de\u30f3\u30c9\u3067\u30d5\u30a1\u30a4\u30eb\u3084\u30d5\u30a1 [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"footnotes":""},"categories":[2],"tags":[],"_links":{"self":[{"href":"https:\/\/tech.akat.info\/index.php?rest_route=\/wp\/v2\/posts\/3332"}],"collection":[{"href":"https:\/\/tech.akat.info\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/tech.akat.info\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/tech.akat.info\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/tech.akat.info\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=3332"}],"version-history":[{"count":2,"href":"https:\/\/tech.akat.info\/index.php?rest_route=\/wp\/v2\/posts\/3332\/revisions"}],"predecessor-version":[{"id":3334,"href":"https:\/\/tech.akat.info\/index.php?rest_route=\/wp\/v2\/posts\/3332\/revisions\/3334"}],"wp:attachment":[{"href":"https:\/\/tech.akat.info\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=3332"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/tech.akat.info\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=3332"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/tech.akat.info\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=3332"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}