{"id":8436,"date":"2023-01-28T08:14:31","date_gmt":"2023-01-27T23:14:31","guid":{"rendered":"https:\/\/lab4ict.com\/system\/?p=8436"},"modified":"2023-07-20T05:54:22","modified_gmt":"2023-07-19T20:54:22","slug":"linux%e3%81%a7%e3%83%a6%e3%83%bc%e3%82%b6%e3%81%ae%e8%bf%bd%e5%8a%a0%e3%81%a8%e5%89%8a%e9%99%a4%e3%82%92%e8%a1%8c%e3%81%86%ef%bc%81%ef%bc%88useradd%ef%bc%8fuserdel%ef%bc%89","status":"publish","type":"post","link":"https:\/\/lab4ict.com\/system\/archives\/8436","title":{"rendered":"Linux\u3067\u30e6\u30fc\u30b6\u306e\u8ffd\u52a0\u3068\u524a\u9664\u3092\u884c\u3046\uff01\uff08useradd\uff0fuserdel\uff09"},"content":{"rendered":"<p>Linux\u3067\u30e6\u30fc\u30b6\u306e\u8ffd\u52a0\u3068\u524a\u9664\u3092\u884c\u3044\u307e\u3059\u3002<\/p>\n<h2>\u30e6\u30fc\u30b6\u306e\u8ffd\u52a0\u3092\u884c\u3046\uff01<\/h2>\n<p>Linux\u306e\u30e6\u30fc\u30b6\u306f\u3001\u5185\u90e8\u7684\u306b\u306fUID\u3067\u7ba1\u7406\u3055\u308c\u307e\u3059\u3002\u4ed6\u306eLinux\u30b5\u30fc\u30d0\u306b\u3082\u540c\u3058\u30e6\u30fc\u30b6\u3092\u4f5c\u6210\u3059\u308b\u5834\u5408\u306f\u3001\u540c\u3058UID\u304c\u671b\u307e\u3057\u3044\u306e\u3067\u3001\u30e6\u30fc\u30b6\u306e\u8ffd\u52a0\u3092\u884c\u3046\u5834\u5408\u306f\u3001UID\u3092\u6c7a\u3081\u3066\u4f5c\u6210\u3059\u308b\u3088\u3046\u306b\u3057\u307e\u3059\u30021000\u3088\u308a\u5c0f\u3055\u3044UID\u306f\u3001\u30b7\u30b9\u30c6\u30e0\u3067\u4f7f\u7528\u3055\u308c\u308b\u53ef\u80fd\u6027\u304c\u3042\u308b\u306e\u3067\u30011000\u4ee5\u964d\u3067\u672a\u4f7f\u7528\u306aUID\u3092\u6307\u5b9a\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002<\/p>\n<pre class=\"brush: plain; highlight: [1]; title: ; notranslate\" title=\"\">\r\n# useradd testuser -u 9000\r\n# grep testuser \/etc\/passwd\r\ntestuser:x:9000:9000::\/home\/testuser:\/bin\/bash\r\n# grep testuser \/etc\/group\r\ntestuser:x:9000:\r\n<\/pre>\n<p>GID\u306f\u3001\u30c7\u30d5\u30a9\u30eb\u30c8\u3067UID\u3068\u540c\u3058\u306b\u306a\u308a\u307e\u3059\u3002\u5fc5\u8981\u306b\u5fdc\u3058\u3066\u3001\u300cgpasswd\u300d\u30b3\u30de\u30f3\u30c9\u3067\u305d\u306e\u4ed6\u306e\u30b0\u30eb\u30fc\u30d7\u306b\u767b\u9332\u3057\u307e\u3059\u3002<\/p>\n<h2>\u30d1\u30b9\u30ef\u30fc\u30c9\u306e\u8a2d\u5b9a\u3092\u884c\u3046\uff01<\/h2>\n<p>\u30ed\u30b0\u30a4\u30f3\u3059\u308b\u30e6\u30fc\u30b6\u306e\u5834\u5408\u3001\u521d\u671f\u30d1\u30b9\u30ef\u30fc\u30c9\u3092\u8a2d\u5b9a\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002\u4ee5\u4e0b\u306e\u8a18\u4e8b\u3092\u53c2\u8003\u306b\u3057\u3066\u30d1\u30b9\u30ef\u30fc\u30c9\u3092\u8a2d\u5b9a\u3057\u307e\u3059\u3002<br \/>\n<div class=\"sc_getpost\"><a class=\"clearfix\" href=\"https:\/\/lab4ict.com\/system\/archives\/8294\" ><div class=\"sc_getpost_thumb post-box-thumbnail__wrap\"><img decoding=\"async\" src=\"data:image\/gif;base64,R0lGODdhAQABAPAAAN3d3QAAACwAAAAAAQABAAACAkQBADs=\" width=\"150\" height=\"150\" alt=\"Linux\u3067\u30d1\u30b9\u30ef\u30fc\u30c9\u306b\u95a2\u3059\u308b\u64cd\u4f5c\u3092\u884c\u3046\uff01\uff08passwd\uff0fchpasswd\uff09\" loading=\"lazy\" data-src=\"https:\/\/lab4ict.com\/system\/wp-content\/uploads\/2021\/02\/fi_linux_01-150x150.png\" class=\"lazyload\"><\/div><div class=\"title\">Linux\u3067\u30d1\u30b9\u30ef\u30fc\u30c9\u306b\u95a2\u3059\u308b\u64cd\u4f5c\u3092\u884c\u3046\uff01\uff08passwd\uff0fchpasswd\uff09<\/div><div class=\"substr\">Linux\u3067passwd\u30b3\u30de\u30f3\u30c9\u3067\u3001\u30d1\u30b9\u30ef\u30fc\u30c9\u306b\u95a2\u3059\u308b\u64cd\u4f5c\u3092\u884c\u3044\u307e\u3059\u3002...<\/div><\/a><\/div>\n<h2>\u30e6\u30fc\u30b6\u306e\u524a\u9664\u3092\u884c\u3046\uff01<\/h2>\n<p>\u30e6\u30fc\u30b6\u306e\u524a\u9664\u306f\u3001\u30e6\u30fc\u30b6\u540d\u306e\u6307\u5b9a\u306e\u307f\u3067\u53ef\u80fd\u3067\u3059\u3002<\/p>\n<pre class=\"brush: plain; highlight: [1]; title: ; notranslate\" title=\"\">\r\n# userdel testuser\r\n# grep testuser \/etc\/passwd\r\n# grep testuser \/etc\/group\r\n<\/pre>\n<p>\u30db\u30fc\u30e0\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u306f\u524a\u9664\u3055\u308c\u306a\u3044\u306e\u3067\u3001\u5225\u9014\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u306e\u524a\u9664\u30b3\u30de\u30f3\u30c9\u3067\u524a\u9664\u3057\u307e\u3059\u3002<\/p>\n<pre class=\"brush: plain; highlight: [3]; title: ; notranslate\" title=\"\">\r\n# ls -l \/home | grep testuser\r\ndrwx------.  3     9000     9000   78 Jan 26 20:06 testuser\r\n# rm -rf \/home\/testuser\r\n# ls -l \/home | grep testuser\r\n<\/pre>\n<p>\u30e1\u30fc\u30eb\u30dc\u30c3\u30af\u30b9\u304c\u4f5c\u6210\u3055\u308c\u3066\u3044\u308b\u3053\u3068\u304c\u3042\u308b\u306e\u3067\u3001\u78ba\u8a8d\u3057\u3066\u524a\u9664\u3057\u307e\u3059\u3002<\/p>\n<pre class=\"brush: plain; highlight: [1,35]; title: ; notranslate\" title=\"\">\r\n# ls -l \/var\/spool\/mail | grep testuser\r\n-rw-rw----. 1     9000 mail 0 Jan 26 20:06 testuser\r\n# rm \/var\/spool\/mail\/testuser\r\nrm: remove regular empty file '\/var\/spool\/mail\/testuser'? y\r\n# ls -l \/var\/spool\/mail\/testuser\r\nls: cannot access '\/var\/spool\/mail\/testuser': No such file or directory\r\n<\/pre>\n<h2>\u30e6\u30fc\u30b6\u540d\u306e\u5909\u66f4\u3092\u884c\u3046\u5834\u5408\u306f\u30fb\u30fb\u30fb<\/h2>\n<p>\u30e6\u30fc\u30b6\u540d\u306e\u5909\u66f4\u3092\u884c\u3046\u5834\u5408\u306f\u3001\u300cusermod\u300d\u30b3\u30de\u30f3\u30c9\u304c\u4f7f\u7528\u3067\u304d\u307e\u3059\u304c\u3001\u30e6\u30fc\u30b6\u540d\u306f\u30b7\u30b9\u30c6\u30e0\u8a2d\u5b9a\u306e\u5404\u6240\u3067\u4f7f\u7528\u3055\u308c\u308b\u3053\u3068\u304c\u3042\u308b\u305f\u3081\u3001\u300cusermod\u300d\u3067\u3059\u3079\u3066\u5909\u66f4\u3057\u304d\u308c\u308b\u3068\u306f\u9650\u308a\u307e\u305b\u3093\u3002\u5b89\u5168\u3092\u8003\u3048\u3066\u300cuserdel\u300d\u3057\u3066\u3001\u300cuseradd\u300d\u3057\u305f\u5f8c\u3001\u30c7\u30fc\u30bf\u79fb\u884c\u3084\u8a2d\u5b9a\u306e\u79fb\u884c\u3092\u884c\u3046\u307b\u3046\u304c\u78ba\u5b9f\u3068\u601d\u3044\u307e\u3059\u3002<\/p>\n<h2>\u304a\u308f\u308a\u306b<\/h2>\n<p>\u30e6\u30fc\u30b6\u540d\u306e\u8ffd\u52a0\u3068\u524a\u9664\u306f\u3001useradd\u3068userdel\u3067\u884c\u3044\u307e\u3059\u304c\u3001\u30e6\u30fc\u30b6\u4f5c\u6210\u306e\u969b\u306f\u3001UID\u3092\u3057\u3063\u304b\u308a\u7ba1\u7406\u3057\u3066\u4f5c\u6210\u3059\u308b\u3088\u3046\u306b\u3057\u307e\u3057\u3087\u3046\u3002<\/p>\n<h2>\u95a2\u9023\u8a18\u4e8b<\/h2>\n<div class=\"sc_getpost\"><a class=\"clearfix\" href=\"https:\/\/lab4ict.com\/system\/archives\/8660\" ><div class=\"sc_getpost_thumb post-box-thumbnail__wrap\"><img decoding=\"async\" src=\"data:image\/gif;base64,R0lGODdhAQABAPAAAN3d3QAAACwAAAAAAQABAAACAkQBADs=\" width=\"150\" height=\"150\" alt=\"\u3010\u8a18\u4e8b\u4e00\u89a7\u3011Linux\u3067\u30e6\u30fc\u30b6\u30a2\u30ab\u30a6\u30f3\u30c8\u3068\u6a29\u9650\u3092\u7ba1\u7406\u3059\u308b\uff01\" loading=\"lazy\" data-src=\"https:\/\/lab4ict.com\/system\/wp-content\/uploads\/2021\/02\/fi_linux_01-150x150.png\" class=\"lazyload\"><\/div><div class=\"title\">\u3010\u8a18\u4e8b\u4e00\u89a7\u3011Linux\u3067\u30e6\u30fc\u30b6\u30a2\u30ab\u30a6\u30f3\u30c8\u3068\u6a29\u9650\u3092\u7ba1\u7406\u3059\u308b\uff01<\/div><div class=\"substr\">Linux\u306e\u30e6\u30fc\u30b6\u30a2\u30ab\u30a6\u30f3\u30c8\u3092\u7ba1\u7406\u3059\u308b\u305f\u3081\u306e\u8a18\u4e8b\u4e00\u89a7\u3092\u63b2\u8f09\u3057\u307e\u3059\u3002...<\/div><\/a><\/div>\n<div class=\"sc_getpost\"><a class=\"clearfix\" href=\"https:\/\/lab4ict.com\/system\/archives\/7679\" ><div class=\"sc_getpost_thumb post-box-thumbnail__wrap\"><img decoding=\"async\" src=\"data:image\/gif;base64,R0lGODdhAQABAPAAAN3d3QAAACwAAAAAAQABAAACAkQBADs=\" width=\"150\" height=\"150\" alt=\"\u3010\u8a18\u4e8b\u4e00\u89a7\u3011Linux\u3092\u4f7f\u3044\u3053\u306a\u3059\uff01\" loading=\"lazy\" data-src=\"https:\/\/lab4ict.com\/system\/wp-content\/uploads\/2021\/02\/fi_linux_01-150x150.png\" class=\"lazyload\"><\/div><div class=\"title\">\u3010\u8a18\u4e8b\u4e00\u89a7\u3011Linux\u3092\u4f7f\u3044\u3053\u306a\u3059\uff01<\/div><div class=\"substr\">Linux\u3092\u4f7f\u3044\u3053\u306a\u3059\u305f\u3081\u306e\u8a18\u4e8b\u4e00\u89a7\u3092\u63b2\u8f09\u3057\u307e\u3059\u3002...<\/div><\/a><\/div>\n<h2>\u95a2\u9023\u66f8\u7c4d\uff08Amazon\uff09<\/h2>\n<p><a href=\"https:\/\/amzn.to\/3H5qkUu\" rel=\"noopener\" target=\"_blank\"><img decoding=\"async\" class=\"paapi5-pa-product-image-source lazyload\" data-src=\"https:\/\/m.media-amazon.com\/images\/I\/51ZPkoBGdZL._SL160_.jpg\" alt=\"N\/A\"><\/a><\/p>\n<hr \/>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Linux\u3067\u30e6\u30fc\u30b6\u306e\u8ffd\u52a0\u3068\u524a\u9664\u3092\u884c\u3044\u307e\u3059\u3002 \u30e6\u30fc\u30b6\u306e\u8ffd\u52a0\u3092\u884c\u3046\uff01 Linux\u306e\u30e6\u30fc\u30b6\u306f\u3001\u5185\u90e8\u7684\u306b\u306fUID\u3067\u7ba1\u7406\u3055\u308c\u307e\u3059\u3002\u4ed6\u306eLinux\u30b5\u30fc\u30d0\u306b\u3082\u540c\u3058\u30e6\u30fc\u30b6\u3092\u4f5c\u6210\u3059\u308b\u5834\u5408\u306f\u3001\u540c\u3058UID\u304c\u671b\u307e\u3057\u3044\u306e\u3067\u3001\u30e6\u30fc\u30b6\u306e\u8ffd\u52a0\u3092\u884c\u3046\u5834\u5408\u306f\u3001UID\u3092\u6c7a\u3081\u3066\u4f5c\u2026<\/p>\n","protected":false},"author":1,"featured_media":5527,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[188],"tags":[282,791,792,25,666,673,654],"class_list":["post-8436","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-account","tag-linux","tag-useradd","tag-userdel","tag-25","tag-666","tag-673","tag-654"],"_links":{"self":[{"href":"https:\/\/lab4ict.com\/system\/wp-json\/wp\/v2\/posts\/8436","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/lab4ict.com\/system\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/lab4ict.com\/system\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/lab4ict.com\/system\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/lab4ict.com\/system\/wp-json\/wp\/v2\/comments?post=8436"}],"version-history":[{"count":1,"href":"https:\/\/lab4ict.com\/system\/wp-json\/wp\/v2\/posts\/8436\/revisions"}],"predecessor-version":[{"id":13151,"href":"https:\/\/lab4ict.com\/system\/wp-json\/wp\/v2\/posts\/8436\/revisions\/13151"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/lab4ict.com\/system\/wp-json\/wp\/v2\/media\/5527"}],"wp:attachment":[{"href":"https:\/\/lab4ict.com\/system\/wp-json\/wp\/v2\/media?parent=8436"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/lab4ict.com\/system\/wp-json\/wp\/v2\/categories?post=8436"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/lab4ict.com\/system\/wp-json\/wp\/v2\/tags?post=8436"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}