{"id":2030,"date":"2019-05-26T23:42:45","date_gmt":"2019-05-26T15:42:45","guid":{"rendered":"https:\/\/www.linuxcool.com\/?p=2030"},"modified":"2022-05-20T17:01:04","modified_gmt":"2022-05-20T09:01:04","slug":"groupadd","status":"publish","type":"post","link":"https:\/\/www.linuxcool.com\/groupadd","title":{"rendered":"groupadd\u547d\u4ee4 – \u521b\u5efa\u65b0\u7684\u7528\u6237\u7ec4"},"content":{"rendered":"\n

groupadd\u547d\u4ee4\u6765\u81ea\u4e8e\u82f1\u6587\u8bcd\u7ec4\u201cgroup add\u201d\uff0c\u5176\u529f\u80fd\u662f\u7528\u4e8e\u521b\u5efa\u65b0\u7684\u7528\u6237\u7ec4\u3002\u6bcf\u4e2a\u7528\u6237\u5728\u521b\u5efa\u65f6\u90fd\u6709\u4e00\u4e2a\u4e0e\u5176\u540c\u540d\u7684\u57fa\u672c\u7ec4\uff0c\u540e\u671f\u53ef\u4ee5\u4f7f\u7528groupadd\u547d\u4ee4\u521b\u5efa\u51fa\u65b0\u7684\u7528\u6237\u7ec4\u4fe1\u606f\uff0c\u8ba9\u591a\u4e2a\u7528\u6237\u52a0\u5165\u5230\u6307\u5b9a\u7684\u6269\u5c55\u7ec4\u4e2d\uff0c\u4e3a\u540e\u7eed\u7684\u5de5\u4f5c\u63d0\u4f9b\u4e86\u826f\u597d\u7684\u6587\u6863\u5171\u4eab\u73af\u5883\u3002<\/p>\n\n\n\n

\u8bed\u6cd5\u683c\u5f0f\uff1a<\/strong>groupadd [\u53c2\u6570] \u7528\u6237\u7ec4<\/p>\n\n\n\n

\u5e38\u7528\u53c2\u6570\uff1a<\/strong><\/p>\n\n\n\n

-g<\/td>\u6307\u5b9a\u65b0\u5efa\u5de5\u4f5c\u7ec4\u7684id<\/td><\/tr>
-r<\/td>\u521b\u5efa\u7cfb\u7edf\u5de5\u4f5c\u7ec4<\/td><\/tr>
-K<\/td>\u8986\u76d6\u914d\u7f6e\u6587\u4ef6\u201c\/ect\/login.defs\u201d<\/td><\/tr>
-o<\/td>\u5141\u8bb8\u6dfb\u52a0\u7ec4ID\u53f7\u4e0d\u552f\u4e00\u7684\u5de5\u4f5c\u7ec4<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n

\u53c2\u8003\u5b9e\u4f8b<\/strong><\/p>\n\n\n\n

\u521b\u5efa\u4e00\u4e2a\u65b0\u7684\u7528\u6237\u7ec4\uff1a<\/p>\n\n\n\n

[root@linuxcool ~]# groupadd linuxcool<\/strong><\/pre>\n\n\n\n

\u521b\u5efa\u4e00\u4e2a\u65b0\u7684\u7528\u6237\u7ec4\uff0c\u5e76\u6307\u5b9aGID\u53f7\u7801\uff1a<\/p>\n\n\n\n

[root@linuxcool ~]# groupadd -g 6688 linuxcool<\/strong>\r<\/pre>\n\n\n\n

\u521b\u5efa\u4e00\u4e2a\u65b0\u7684\u7528\u6237\u7ec4\uff0c\u8bbe\u5b9a\u4e3a\u7cfb\u7edf\u5de5\u4f5c\u7ec4\uff1a<\/p>\n\n\n\n

[root@linuxcool ~]# groupadd -r linuxcool<\/strong><\/pre>\n","protected":false},"excerpt":{"rendered":"

groupadd\u547d\u4ee4\u6765\u81ea\u4e8e\u82f1\u6587\u8bcd\u7ec4\u201cgroup add\u201d\uff0c\u5176\u529f\u80fd\u662f\u7528\u4e8e\u521b\u5efa\u65b0\u7684\u7528\u6237\u7ec4\u3002\u6bcf\u4e2a\u7528\u6237\u5728\u521b\u5efa\u65f6\u90fd\u6709\u4e00\u4e2a […]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":[],"categories":[7],"tags":[],"_links":{"self":[{"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/posts\/2030"}],"collection":[{"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/comments?post=2030"}],"version-history":[{"count":14,"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/posts\/2030\/revisions"}],"predecessor-version":[{"id":9889,"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/posts\/2030\/revisions\/9889"}],"wp:attachment":[{"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/media?parent=2030"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/categories?post=2030"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/tags?post=2030"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}