{"id":3330,"date":"2023-01-09T10:12:18","date_gmt":"2023-01-09T10:12:18","guid":{"rendered":"https:\/\/linuxsimply.com\/?p=3330"},"modified":"2024-03-31T10:39:26","modified_gmt":"2024-03-31T10:39:26","slug":"groupadd-command-in-linux","status":"publish","type":"post","link":"https:\/\/linuxsimply.com\/groupadd-command-in-linux\/","title":{"rendered":"The \u201cgroupadd\u201d Command in Linux [7 Practical Examples]"},"content":{"rendered":"<p style=\"text-align: justify;\"><strong>Groups<\/strong>\u00a0in <strong>Linux<\/strong>\u00a0are used to assign common<strong>\u00a0privileges<\/strong>\u00a0and <strong>permissions<\/strong>\u00a0to <strong>multiple users<\/strong>\u00a0rather than managing them at the <strong>individual user level<\/strong>. The <strong>groupadd<\/strong>\u00a0command in <strong>Linux<\/strong>\u00a0allows <strong>administrators<\/strong>\u00a0to create new user<strong>\u00a0groups<\/strong>\u00a0in order to manage <strong>privileges<\/strong>\u00a0and <strong>permissions<\/strong>\u00a0for multiple users more easily. In this article, I will describe all the features and uses of the<strong>\u00a0groupadd<\/strong>\u00a0command in <strong>Linux<\/strong>\u00a0with multiple examples.<\/p>\n<div class=\"su-youtube su-u-responsive-media-yes\"><iframe width=\"600\" height=\"400\" src=\"https:\/\/www.youtube.com\/embed\/YOV45IdtWZw?\" frameborder=\"0\" allowfullscreen allow=\"autoplay; encrypted-media; picture-in-picture\" title=\"\"><\/iframe><\/div>\n<div id=\"ez-toc-container\" class=\"ez-toc-v2_0_82_2 counter-hierarchy ez-toc-counter ez-toc-grey ez-toc-container-direction\">\n<div class=\"ez-toc-title-container\">\n<p class=\"ez-toc-title\" style=\"cursor:inherit\">Table of Contents<\/p>\n<span class=\"ez-toc-title-toggle\"><a href=\"#\" class=\"ez-toc-pull-right ez-toc-btn ez-toc-btn-xs ez-toc-btn-default ez-toc-toggle\" aria-label=\"Toggle Table of Content\"><span class=\"ez-toc-js-icon-con\"><span class=\"\"><span class=\"eztoc-hide\" style=\"display:none;\">Toggle<\/span><span class=\"ez-toc-icon-toggle-span\"><svg style=\"fill: #999;color:#999\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" class=\"list-377408\" width=\"20px\" height=\"20px\" viewBox=\"0 0 24 24\" fill=\"none\"><path d=\"M6 6H4v2h2V6zm14 0H8v2h12V6zM4 11h2v2H4v-2zm16 0H8v2h12v-2zM4 16h2v2H4v-2zm16 0H8v2h12v-2z\" fill=\"currentColor\"><\/path><\/svg><svg style=\"fill: #999;color:#999\" class=\"arrow-unsorted-368013\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"10px\" height=\"10px\" viewBox=\"0 0 24 24\" version=\"1.2\" baseProfile=\"tiny\"><path d=\"M18.2 9.3l-6.2-6.3-6.2 6.3c-.2.2-.3.4-.3.7s.1.5.3.7c.2.2.4.3.7.3h11c.3 0 .5-.1.7-.3.2-.2.3-.5.3-.7s-.1-.5-.3-.7zM5.8 14.7l6.2 6.3 6.2-6.3c.2-.2.3-.5.3-.7s-.1-.5-.3-.7c-.2-.2-.4-.3-.7-.3h-11c-.3 0-.5.1-.7.3-.2.2-.3.5-.3.7s.1.5.3.7z\"\/><\/svg><\/span><\/span><\/span><\/a><\/span><\/div>\n<nav><ul class='ez-toc-list ez-toc-list-level-1 eztoc-toggle-hide-by-default' ><ul class='ez-toc-list-level-3' ><li class='ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-1\" href=\"https:\/\/linuxsimply.com\/groupadd-command-in-linux\/#A_Description\" >A. Description<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-2\" href=\"https:\/\/linuxsimply.com\/groupadd-command-in-linux\/#B_Syntax\" >B. Syntax<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-3\" href=\"https:\/\/linuxsimply.com\/groupadd-command-in-linux\/#C_Options\" >C.\u00a0Options<\/a><\/li><\/ul><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-4\" href=\"https:\/\/linuxsimply.com\/groupadd-command-in-linux\/#Practical_Examples_of_the_%E2%80%9Cgroupadd%E2%80%9D_Command_in_Linux\" >Practical Examples of the \u201cgroupadd\u201d Command in Linux<\/a><ul class='ez-toc-list-level-3' ><li class='ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-5\" href=\"https:\/\/linuxsimply.com\/groupadd-command-in-linux\/#Example_1_Adding_a_New_Group_With_the_%E2%80%9Cgroupadd%E2%80%9D_Command_in_Linux\" >Example 1: Adding a New Group With the \u201cgroupadd\u201d Command in Linux<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-6\" href=\"https:\/\/linuxsimply.com\/groupadd-command-in-linux\/#Example_2_Create_a_Group_With_a_Specific_GID_With_the_%E2%80%9Cgroupadd%E2%80%9D_Command_in_Linux\" >Example 2: Create a Group With a Specific GID With the \u201cgroupadd\u201d Command in Linux<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-7\" href=\"https:\/\/linuxsimply.com\/groupadd-command-in-linux\/#Example_3_Specify_a_Custom_GID_Range_for_New_Groups_Instead_of_Using_the_Default_Values\" >Example 3: Specify a Custom GID Range for New Groups Instead of Using the Default Values<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-8\" href=\"https:\/\/linuxsimply.com\/groupadd-command-in-linux\/#Example_4_Create_a_New_Group_With_a_Non-Unique_GID_With_the_%E2%80%9Cgroupadd%E2%80%9D_Command\" >Example 4: Create a New Group With a Non-Unique GID With the &#8220;groupadd&#8221; Command<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-9\" href=\"https:\/\/linuxsimply.com\/groupadd-command-in-linux\/#Example_5_Create_a_New_Group_With_a_Name_That_is_Already_in_Use_by_an_Existing_Group\" >Example 5: Create a New Group With a Name That is Already in Use by an Existing Group<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-10\" href=\"https:\/\/linuxsimply.com\/groupadd-command-in-linux\/#Example_6_Create_a_System_Group_With_the_%E2%80%9Cgroupadd%E2%80%9D_Command\" >Example 6: Create a System Group With the &#8220;groupadd&#8221; Command<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-11\" href=\"https:\/\/linuxsimply.com\/groupadd-command-in-linux\/#Example_7_Use_an_Encrypted_Password_for_The_New_Group\" >Example 7: Use an Encrypted Password for The New Group<\/a><\/li><\/ul><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-12\" href=\"https:\/\/linuxsimply.com\/groupadd-command-in-linux\/#Conclusion\" >Conclusion<\/a><\/li><\/ul><\/nav><\/div>\n<h3><span class=\"ez-toc-section\" id=\"A_Description\"><\/span>A. Description<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>The <strong>groupadd<\/strong>\u00a0command in <strong>Linux<\/strong>\u00a0is a useful tool that helps to create several <strong>groups<\/strong>\u00a0with one or more <strong>users<\/strong>\u00a0to maintain their permissions and privileges in a more efficient way. This command helps to avoid the time-consuming task of setting <strong>permissions<\/strong>\u00a0and <strong>privileges<\/strong>\u00a0for each user individually, which can also be prone to <strong>errors<\/strong>.<\/p>\n<h3><span class=\"ez-toc-section\" id=\"B_Syntax\"><\/span>B. Syntax<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>The syntax of the<strong>\u00a0groupadd<\/strong>\u00a0command in <strong>Linux<\/strong>\u00a0is pretty simple, as shown below.<\/p>\n<pre><code class=\"language-bash\" data-line=\"\">groupadd [OPTION]... GROUP_NAME<\/code><\/pre>\n<div class=\"su-note\"  style=\"border-color:#cedfe2;\"><div class=\"su-note-inner su-u-clearfix su-u-trim\" style=\"background-color:#E8F9FC;border-color:#ffffff;color:#333333;\">\n<p><strong>Note: <\/strong>In the syntax above, the <strong>OPTION<\/strong>\u00a0enclosed by the square bracket means it is not mandatory and three dots after the square bracket mean multiple <strong>OPTIONS <\/strong>can be used after the <strong>groupadd <\/strong>command.<\/p>\n<\/div><\/div>\n<h3><span class=\"ez-toc-section\" id=\"C_Options\"><\/span>C.\u00a0Options<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p style=\"text-align: justify;\">There are numerous <strong>options<\/strong>\u00a0available for the <strong>groupadd<\/strong>\u00a0command. I have listed a few of them. You can learn more about the <strong>groupadd <\/strong>command, its <strong>options<\/strong>\u00a0and their uses by checking the <strong>man<\/strong>\u00a0page.<\/p>\n<pre><code class=\"language-bash\" data-line=\"\">man groupadd\n<\/code><\/pre>\n<p><span style=\"color: #800080;\"><strong>Useful Options<\/strong><\/span><\/p>\n<div class=\"su-list\" style=\"margin-left:20px\">\n<ul>\n<li><i class=\"sui sui-arrow-right\" style=\"color:#000000\"><\/i> <strong>-f, &#8211;force: <\/strong>Exits with success status if the specified group already exists, and turns off -g if specified <strong>GID<\/strong>already exists.<\/li>\n<li><i class=\"sui sui-arrow-right\" style=\"color:#000000\"><\/i> <strong>-g, &#8211;gid GID: <\/strong>Specifies the numerical value of the<strong>\u00a0group&#8217;s ID<\/strong>, which must be unique unless <strong>-o<\/strong> is used and must be non-negative.<\/li>\n<li><i class=\"sui sui-arrow-right\" style=\"color:#000000\"><\/i> <strong>-h, &#8211;help: <\/strong>Displays help message.<\/li>\n<li><i class=\"sui sui-arrow-right\" style=\"color:#000000\"><\/i> <strong>-K, &#8211;key KEY=VALUE: <\/strong>Overrides \/etc\/login.defs defaults with specified KEY and VALUE, multiple -K options can be used.<\/li>\n<li><i class=\"sui sui-arrow-right\" style=\"color:#000000\"><\/i> <strong>-o, &#8211;non-unique: <\/strong>Allows adding a group with a non-unique GID.<\/li>\n<li><i class=\"sui sui-arrow-right\" style=\"color:#000000\"><\/i> <strong>-p, &#8211;password PASSWORD: <\/strong>Sets an encrypted password for the group, default is to disable the password.<\/li>\n<li><i class=\"sui sui-arrow-right\" style=\"color:#000000\"><\/i> <strong>-r, &#8211;system: <\/strong>creates a system group.<\/li>\n<li><i class=\"sui sui-arrow-right\" style=\"color:#000000\"><\/i> <strong>-R, &#8211;root CHROOT_DIR: <\/strong>This option is used to specify a different root directory than the default root directory.<\/li>\n<li><i class=\"sui sui-arrow-right\" style=\"color:#000000\"><\/i> <strong>-P, &#8211;prefix PREFIX_DIR: <\/strong>This option specifies a different prefix than the default prefix to use when creating a new group.<\/li>\n<\/ul>\n<\/div>\n<div class=\"su-note\"  style=\"border-color:#cedfe2;\"><div class=\"su-note-inner su-u-clearfix su-u-trim\" style=\"background-color:#E8F9FC;border-color:#ffffff;color:#333333;\"><strong>Note: <\/strong>Commands and their <strong>options<\/strong>\u00a0are <strong>case-sensitive <\/strong>in <strong>Linux<\/strong>. So, be careful while using them.<\/p>\n<\/div><\/div>\n<h2><span class=\"ez-toc-section\" id=\"Practical_Examples_of_the_%E2%80%9Cgroupadd%E2%80%9D_Command_in_Linux\"><\/span>Practical Examples of the \u201cgroupadd\u201d Command in Linux<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p style=\"text-align: justify;\">In <strong>Linux<\/strong>, the <strong>groupadd<\/strong>\u00a0command is a helpful tool to create new groups that are useful for maintaining a large number of users with the same <strong>privileges<\/strong>\u00a0and <strong>permissions<\/strong>. In the section below, I will show you some of the most useful applications for the <strong>groupadd<\/strong>\u00a0command in <strong>Linux<\/strong>.<\/p>\n<div class=\"su-note\"  style=\"border-color:#cedfe2;\"><div class=\"su-note-inner su-u-clearfix su-u-trim\" style=\"background-color:#E8F9FC;border-color:#ffffff;color:#333333;\"><strong>Note: <\/strong>You must be <strong>logged in<\/strong>\u00a0as the<strong>\u00a0root user<\/strong>\u00a0or you must use the<strong>\u00a0\u201csudo\u201d<\/strong>\u00a0command to execute the<strong>\u00a0\u201cgroupadd\u201d<\/strong>\u00a0command with<strong>\u00a0root privileges<\/strong>.<\/p>\n<\/div><\/div>\n<h3><span class=\"ez-toc-section\" id=\"Example_1_Adding_a_New_Group_With_the_%E2%80%9Cgroupadd%E2%80%9D_Command_in_Linux\"><\/span>Example 1: Adding a New Group With the \u201cgroupadd\u201d Command in Linux<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p style=\"text-align: justify;\">The <strong>groupadd<\/strong>\u00a0command in <strong>Linux<\/strong>\u00a0allows you to <strong>add<\/strong>\u00a0a<strong>\u00a0new group <\/strong>to your <strong>system<\/strong>\u00a0by simply running the <strong>groupadd<\/strong>\u00a0command. Here, I will<strong>\u00a0create<\/strong>\u00a0a new group named \u201c<strong>group1<\/strong>\u201d with the <strong>groupadd <\/strong>command. You can do the same by following the steps below.<\/p>\n<p><span style=\"color: #800080;\"><strong>Steps to Follow &gt;<\/strong><\/span><\/p>\n<p>\u278a At first, open the <a href=\"https:\/\/linuxsimply.com\/what-is-terminal-in-linux\/\" target=\"_blank\" rel=\"noopener\"><strong>Ubuntu Terminal<\/strong><\/a>.<\/p>\n<p>\u278b<strong>\u00a0<\/strong>Run the command below:<\/p>\n<pre><code class=\"language-bash\" data-line=\"\">sudo groupadd group1<\/code><\/pre>\n<p>\u278c Now, press the <strong>ENTER<\/strong>\u00a0button.<\/p>\n<p>\u278d Type your <strong>Password<\/strong>.<\/p>\n<p>\u278e Press <strong>ENTER<\/strong>\u00a0again.<\/p>\n<p>\u278f Now, type the following command into the command prompt:<\/p>\n<pre><code class=\"language-bash\" data-line=\"\">getent group group1<\/code><\/pre>\n<p>\u2790 Tap the <strong>ENTER<\/strong> button.<\/p>\n<p><span style=\"color: #800080;\"><strong>Output &gt;<\/strong><\/span><\/p>\n<p style=\"text-align: justify;\">In the following image, you can see that I have created a<strong>\u00a0new group <\/strong>named <strong>group1 <\/strong>with the <strong>groupadd<\/strong> command.<img fetchpriority=\"high\" decoding=\"async\" class=\"aligncenter size-full wp-image-3336\" src=\"https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-1.png\" alt=\"Showing the creation of a new group named group1 with the groupadd command.\" width=\"650\" height=\"162\" srcset=\"https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-1.png 650w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-1-300x75.png 300w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-1-1024x255.png 1024w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-1-766x191.png 766w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-1-1536x383.png 1536w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-1-2048x510.png 2048w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-1-602x150.png 602w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-1-100x25.png 100w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-1-1404x350.png 1404w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-1-788x196.png 788w\" sizes=\"(max-width: 650px) 100vw, 650px\" \/><\/p>\n<hr \/>\n<p><span style=\"color: #000080; font-size: 18pt;\"><strong>Similar Readings<\/strong><\/span><\/p>\n<ul>\n<li><strong><a class=\"in-cell-link\" href=\"https:\/\/linuxsimply.com\/time-command-in-linux\/\" target=\"_blank\" rel=\"noopener\">The \u201ctime\u201d Command in Linux [4 Practical Examples]<\/a><\/strong><\/li>\n<li><strong><a class=\"in-cell-link\" href=\"https:\/\/linuxsimply.com\/tty-command-in-linux\/\" target=\"_blank\" rel=\"noopener\">The \u201ctty\u201d Command in Linux [4 Practical Examples]<\/a><\/strong><\/li>\n<li><strong><a class=\"in-cell-link\" href=\"https:\/\/linuxsimply.com\/uptime-command-in-linux\/\" target=\"_blank\" rel=\"noopener\">The \u201cuptime\u201d Command in Linux [5 Practical Examples]<\/a><\/strong><\/li>\n<li><strong><a class=\"in-cell-link\" href=\"https:\/\/linuxsimply.com\/vmstat-command-in-linux\/\" target=\"_blank\" rel=\"noopener\">The \u201cvmstat\u201d Command in Linux [6 Practical Examples]<\/a><\/strong><\/li>\n<li><strong><a class=\"in-cell-link\" href=\"https:\/\/linuxsimply.com\/uname-command-in-linux\/\" target=\"_blank\" rel=\"noopener\">The \u201cuname\u201d Command in Linux [11 Practical Examples]<\/a><\/strong><\/li>\n<li><strong><a class=\"in-cell-link\" href=\"https:\/\/linuxsimply.com\/apt-get-command-in-linux\/\" target=\"_blank\" rel=\"noopener\">The \u201capt-get\u201d Command in Linux [10 Practical Examples]<\/a><\/strong><\/li>\n<\/ul>\n<hr \/>\n<h3><span class=\"ez-toc-section\" id=\"Example_2_Create_a_Group_With_a_Specific_GID_With_the_%E2%80%9Cgroupadd%E2%80%9D_Command_in_Linux\"><\/span>Example 2: Create a Group With a Specific GID With the \u201cgroupadd\u201d Command in Linux<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>You can create a<strong>\u00a0new group<\/strong>\u00a0with a specific <strong>GID <\/strong>by running the <strong>groupadd<\/strong>\u00a0command with the <strong>option -g <\/strong>or <strong>&#8211;gid<\/strong>. Here, I will<strong>\u00a0<\/strong>create a new group called &#8220;<strong>group2<\/strong>&#8220;<strong>\u00a0<\/strong>by giving it the<strong>\u00a0GID \u201c2023\u201d <\/strong>with<strong>\u00a0<\/strong>the <strong>groupadd<\/strong>\u00a0command. You can do the same by following the steps below.<\/p>\n<p><span style=\"color: #800080;\"><strong>Steps to Follow &gt;<\/strong><\/span><\/p>\n<p>\u278a Open the <strong>Ubuntu Terminal<\/strong>\u00a0first.<\/p>\n<p>\u278b<strong>\u00a0<\/strong>Type the following command into the command prompt:<\/p>\n<pre><code class=\"language-bash\" data-line=\"\">sudo groupadd -g 2023 group2<\/code><\/pre>\n<p><span style=\"color: #800080;\"><strong>OR,<\/strong><\/span><\/p>\n<pre><code class=\"language-bash\" data-line=\"\">sudo groupadd --gid 2023 group2<\/code><\/pre>\n<p>\u278c Tap the <strong>ENTER<\/strong> button.<\/p>\n<p>\u278d Type your <strong>Password<\/strong>.<\/p>\n<p>\u278e Press <strong>ENTER<\/strong>\u00a0again.<\/p>\n<p>\u278f You can check the GID by typing the following command.<\/p>\n<pre><code class=\"language-bash\" data-line=\"\">getent group group2<\/code><\/pre>\n<p>\u2790 Now, Hit the <strong>ENTER<\/strong> key.<\/p>\n<p><span style=\"color: #800080;\"><strong>Output &gt;<\/strong><\/span><\/p>\n<p style=\"text-align: justify;\">In the image below, you can see that I have created <strong>group2<\/strong>\u00a0with the <strong>GID &#8220;2023&#8221;<\/strong>.<img decoding=\"async\" class=\"aligncenter size-full wp-image-3337\" src=\"https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-2.png\" alt=\"Showing the creation of a new group named group2 (GID 2023) with the groupadd command.\" width=\"651\" height=\"158\" srcset=\"https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-2.png 651w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-2-300x73.png 300w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-2-1024x249.png 1024w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-2-766x186.png 766w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-2-1536x373.png 1536w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-2-2048x497.png 2048w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-2-618x150.png 618w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-2-100x24.png 100w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-2-1442x350.png 1442w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-2-788x191.png 788w\" sizes=\"(max-width: 651px) 100vw, 651px\" \/><\/p>\n<h3><span class=\"ez-toc-section\" id=\"Example_3_Specify_a_Custom_GID_Range_for_New_Groups_Instead_of_Using_the_Default_Values\"><\/span>Example 3: Specify a Custom GID Range for New Groups Instead of Using the Default Values<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p style=\"text-align: justify;\">The <strong>groupadd<\/strong>\u00a0command in <strong>Linux<\/strong>\u00a0allows you to <strong>add<\/strong>\u00a0a<strong>\u00a0new group <\/strong>to your <strong>system <\/strong>within a specified range of <strong>GID<\/strong>\u00a0values by running the <strong>groupadd<\/strong>\u00a0command followed by the option <strong>-K <\/strong>or <strong>&#8211;key<\/strong>. The <strong>-K<\/strong>\u00a0or <strong>&#8211;key <\/strong>option followed by KEY=VAL (here, the KEY may be GID_MIN, GID_MAX and others) allows you to override the default values specified in the \/etc\/login.defs file. Here, I will<strong>\u00a0create<\/strong>\u00a0a new group named \u201c<strong>group3<\/strong>\u201d within a specified range of GID 5000\u20137000 with the <strong>groupadd <\/strong>command. You can do the same by following the steps below.<\/p>\n<p><span style=\"color: #800080;\"><strong>Steps to Follow &gt;<\/strong><\/span><\/p>\n<p>\u278a At first, open the <strong>Ubuntu Terminal<\/strong>.<\/p>\n<p>\u278b<strong>\u00a0<\/strong>Type the following command into the command prompt:<\/p>\n<pre><code class=\"language-bash\" data-line=\"\">sudo groupadd -K GID_MIN=5000 -K GID_MAX=7000 group3<\/code><\/pre>\n<p><span style=\"color: #800080;\"><strong>OR,<\/strong><\/span><\/p>\n<pre><code class=\"language-bash\" data-line=\"\">sudo groupadd --key GID_MIN=5000 --key GID_MAX=7000 group3<\/code><\/pre>\n<p>\u278c Hit the ENTER key.<\/p>\n<p>\u278d Type your <strong>Password<\/strong>.<\/p>\n<p>\u278e Press <strong>ENTER<\/strong>\u00a0again.<\/p>\n<p>\u278fType the following command into the command prompt:<\/p>\n<pre><code class=\"language-bash\" data-line=\"\">getent group group3<\/code><\/pre>\n<p>\u2790 Tap <strong>ENTER<\/strong>\u00a0key.<\/p>\n<p><span style=\"color: #800080;\"><strong>Output &gt;<\/strong><\/span><\/p>\n<p style=\"text-align: justify;\">In the following image, you can see that I have created a<strong>\u00a0new group <\/strong>named <strong>group3 <\/strong>with the <strong>groupadd<\/strong>\u00a0command within the range of <strong>GID (5000-7000).<img decoding=\"async\" class=\"aligncenter size-full wp-image-3338\" src=\"https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-3.png\" alt=\"Showing the creation of a new group named group3 with a GID range from 5000 to 7000 with the groupadd command.\" width=\"825\" height=\"134\" srcset=\"https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-3.png 825w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-3-300x49.png 300w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-3-1024x166.png 1024w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-3-763x124.png 763w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-3-1536x249.png 1536w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-3-2048x333.png 2048w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-3-924x150.png 924w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-3-100x16.png 100w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-3-788x127.png 788w\" sizes=\"(max-width: 825px) 100vw, 825px\" \/><\/strong><\/p>\n<hr \/>\n<p><span style=\"color: #000080; font-size: 18pt;\"><strong>Similar Readings<\/strong><\/span><\/p>\n<ul>\n<li><strong><a class=\"in-cell-link\" href=\"https:\/\/linuxsimply.com\/free-command-in-linux\/\" target=\"_blank\" rel=\"noopener\">The \u201cfree\u201d Command in Linux [8 Practical Examples]<\/a><\/strong><\/li>\n<li><strong><a class=\"in-cell-link\" href=\"https:\/\/linuxsimply.com\/getent-command-in-linux\/\" target=\"_blank\" rel=\"noopener\">The \u201cgetent\u201d Command in Linux [11 Practical Examples]<\/a><\/strong><\/li>\n<li><strong><a class=\"in-cell-link\" href=\"https:\/\/linuxsimply.com\/passwd-command-in-linux\/\" target=\"_blank\" rel=\"noopener\">The &#8220;passwd&#8221; Command in Linux [7 Practical Examples]<\/a><\/strong><\/li>\n<li><strong><a class=\"in-cell-link\" href=\"https:\/\/linuxsimply.com\/addgroup-command-in-linux\/\" target=\"_blank\" rel=\"noopener\">The \u201caddgroup\u201d Command in Linux [7 Practical Examples]<\/a><\/strong><\/li>\n<li><strong><a class=\"in-cell-link\" href=\"https:\/\/linuxsimply.com\/groups-command-in-linux\/\" target=\"_blank\" rel=\"noopener\">The \u201cgroups\u201d Command in Linux [6 Practical Examples]<\/a><\/strong><\/li>\n<li><strong><a class=\"in-cell-link\" href=\"https:\/\/linuxsimply.com\/firewall-cmd-command-in-linux\/\" target=\"_blank\" rel=\"noopener\">The \u201cfirewall-cmd\u201d Command in Linux [7 Practical Examples]<\/a><\/strong><\/li>\n<\/ul>\n<hr \/>\n<h3><span class=\"ez-toc-section\" id=\"Example_4_Create_a_New_Group_With_a_Non-Unique_GID_With_the_%E2%80%9Cgroupadd%E2%80%9D_Command\"><\/span>Example 4: Create a New Group With a Non-Unique GID With the &#8220;groupadd&#8221; Command<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p style=\"text-align: justify;\">The <strong>group ID<\/strong>\u00a0needs to be an <strong>individual<\/strong>, <strong>non-negative<\/strong>\u00a0number. However, you can create groups with <strong>duplicate<\/strong>\u00a0(non-unique) <strong>group IDs<\/strong>\u00a0by using the<strong>\u00a0-o<\/strong>\u00a0or <strong>&#8211;non-unique<\/strong>\u00a0option. Here, I will<strong>\u00a0<\/strong>create a new group called &#8220;<strong>group4<\/strong>&#8220;<strong>\u00a0<\/strong>with the same <strong>GID <\/strong>of<strong>\u00a0\u201cgroup2\u201d<\/strong>\u00a0using<strong>\u00a0<\/strong>the <strong>groupadd<\/strong>\u00a0command. You can do the same by following the steps below.<\/p>\n<p><span style=\"color: #800080;\"><strong>Steps to Follow &gt;<\/strong><\/span><\/p>\n<p>\u278a Open the <strong>Ubuntu Terminal<\/strong>\u00a0first.<\/p>\n<p>\u278b<strong>\u00a0<\/strong>Type the following command into the command prompt:<\/p>\n<pre><code class=\"language-bash\" data-line=\"\">getent group group2<\/code><\/pre>\n<p>\u278c Press the <strong>ENTER<\/strong>\u00a0button.<\/p>\n<p style=\"text-align: justify;\">In the following image, you can see that the group named <strong>group2<\/strong>\u00a0has a <strong>GID<\/strong> 2023.<img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-3339\" src=\"https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-4.png\" alt=\"Showing the GID of group2.\" width=\"519\" height=\"97\" srcset=\"https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-4.png 519w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-4-300x56.png 300w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-4-1024x191.png 1024w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-4-765x143.png 765w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-4-1536x287.png 1536w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-4-2048x383.png 2048w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-4-803x150.png 803w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-4-100x19.png 100w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-4-1873x350.png 1873w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-4-788x147.png 788w\" sizes=\"(max-width: 519px) 100vw, 519px\" \/>\u278d Now, enter the following command into the command prompt:<\/p>\n<pre><code class=\"language-bash\" data-line=\"\">sudo groupadd -o -g 2023 group4<\/code><\/pre>\n<p><span style=\"color: #800080;\"><strong>OR,<\/strong><\/span><\/p>\n<pre><code class=\"language-bash\" data-line=\"\">sudo groupadd --non-unique -g 2023 group4<\/code><\/pre>\n<p>\u278e Type your <strong>Password<\/strong>.<\/p>\n<p>\u278f Press <strong>ENTER<\/strong>\u00a0again.<\/p>\n<p>\u2790 You can check the GID by typing the following command.<\/p>\n<pre><code class=\"language-bash\" data-line=\"\">getent group group2 group4<\/code><\/pre>\n<p>\u2791 Hit the <strong>ENTER<\/strong>\u00a0button.<\/p>\n<p><span style=\"color: #800080;\"><strong>Output &gt;<\/strong><\/span><\/p>\n<p style=\"text-align: justify;\">In the image below, you can see that I have created <strong>group4<\/strong>\u00a0with the same <strong>GID <\/strong>as <strong>group2<\/strong>.<img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-3340\" src=\"https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-4_1.png\" alt=\"Showing the creation of a new group named group4 with the GID of group2 with groupadd command.\" width=\"649\" height=\"186\" srcset=\"https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-4_1.png 649w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-4_1-300x86.png 300w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-4_1-1024x293.png 1024w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-4_1-768x220.png 768w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-4_1-1536x440.png 1536w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-4_1-2048x587.png 2048w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-4_1-523x150.png 523w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-4_1-100x29.png 100w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-4_1-1221x350.png 1221w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-4_1-788x225.png 788w\" sizes=\"(max-width: 649px) 100vw, 649px\" \/><\/p>\n<h3><span class=\"ez-toc-section\" id=\"Example_5_Create_a_New_Group_With_a_Name_That_is_Already_in_Use_by_an_Existing_Group\"><\/span>Example 5: Create a New Group With a Name That is Already in Use by an Existing Group<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p style=\"text-align: justify;\">The <strong>group name<\/strong>\u00a0needs to be <strong>Unique<\/strong>. However, you can create groups with <strong>duplicate<\/strong>\u00a0(non-unique) <strong>group names<\/strong>\u00a0by using the option<strong>\u00a0-f<\/strong>\u00a0or <strong>&#8211;force<\/strong>. Here, I will<strong>\u00a0<\/strong>create a new group called &#8220;<strong>group4<\/strong>&#8220;<strong>, <\/strong>which already exists and has <strong>GID 2023<\/strong>. You can do the same by following the steps below.<\/p>\n<p><span style=\"color: #800080;\"><strong>Steps to Follow &gt;<\/strong><\/span><\/p>\n<p>\u278a Open the <strong>Ubuntu Terminal<\/strong>\u00a0first.<\/p>\n<p>\u278b<strong>\u00a0<\/strong>Type the following command into the command prompt:<\/p>\n<pre><code class=\"language-bash\" data-line=\"\">sudo groupadd group4<\/code><\/pre>\n<p>\u278c Press the <strong>ENTER<\/strong>\u00a0button.<\/p>\n<p>\u278d Type your <strong>Password<\/strong>.<\/p>\n<p>\u278e Hit <strong>ENTER<\/strong>\u00a0key again.<\/p>\n<p style=\"text-align: justify;\">As shown in the image below, you will be informed that group4 already exists.<img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-3341\" src=\"https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-5.png\" alt=\"Showing the existence message of group4. \" width=\"568\" height=\"115\" srcset=\"https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-5.png 568w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-5-300x61.png 300w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-5-1024x207.png 1024w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-5-766x155.png 766w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-5-1536x311.png 1536w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-5-2048x415.png 2048w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-5-741x150.png 741w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-5-100x20.png 100w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-5-1729x350.png 1729w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-5-788x159.png 788w\" sizes=\"(max-width: 568px) 100vw, 568px\" \/>\u278f You can check the groups existence group4 by typing the following command.<\/p>\n<pre><code class=\"language-bash\" data-line=\"\">getent group group4<\/code><\/pre>\n<p>\u2790 Tap the <strong>ENTER<\/strong>\u00a0button.<\/p>\n<p>\u2791 Now, enter the following command into the command prompt to create group4 forcefully.<\/p>\n<pre><code class=\"language-bash\" data-line=\"\">sudo groupadd -f group4<\/code><\/pre>\n<p><span style=\"color: #800080;\"><strong>OR,<\/strong><\/span><\/p>\n<pre><code class=\"language-bash\" data-line=\"\">sudo groupadd --force group4<\/code><\/pre>\n<p>\u2792 Press <strong>ENTER<\/strong>\u00a0again.<\/p>\n<p><span style=\"color: #800080;\"><strong>Output &gt;<\/strong><\/span><\/p>\n<p style=\"text-align: justify;\">You can see in the image below that I have created a group with the name &#8220;<strong>group4<\/strong>&#8221; which already exists as an existing group name.<img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-3342\" src=\"https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-5_1.png\" alt=\"showing the forceful creation of group4.\" width=\"563\" height=\"120\" srcset=\"https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-5_1.png 563w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-5_1-300x64.png 300w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-5_1-1024x218.png 1024w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-5_1-765x163.png 765w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-5_1-1536x327.png 1536w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-5_1-2048x437.png 2048w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-5_1-704x150.png 704w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-5_1-100x21.png 100w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-5_1-1642x350.png 1642w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-5_1-788x167.png 788w\" sizes=\"(max-width: 563px) 100vw, 563px\" \/><\/p>\n<hr \/>\n<p><span style=\"color: #000080; font-size: 18pt;\"><strong>Similar Readings<\/strong><\/span><\/p>\n<ul>\n<li><strong><a class=\"in-cell-link\" href=\"https:\/\/linuxsimply.com\/groupmod-command-in-linux\/\" target=\"_blank\" rel=\"noopener\">The \u201cgroupmod\u201d Command in Linux [5+ Practical Examples]<\/a><\/strong><\/li>\n<li><strong><a class=\"in-cell-link\" href=\"https:\/\/linuxsimply.com\/id-command-in-linux\/\" target=\"_blank\" rel=\"noopener\">The \u201cid\u201d Command in Linux [7+ Practical Examples]<\/a><\/strong><\/li>\n<li><strong><a class=\"in-cell-link\" href=\"https:\/\/linuxsimply.com\/service-command-in-linux\/\" target=\"_blank\" rel=\"noopener\">The \u201cservice\u201d Command in Linux [6 Practical Examples]<\/a><\/strong><\/li>\n<li><strong><a class=\"in-cell-link\" href=\"https:\/\/linuxsimply.com\/sestatus-command-in-linux\/\" target=\"_blank\" rel=\"noopener\">The \u201csestatus\u201d Command in Linux [4 Practical Examples]<\/a><\/strong><\/li>\n<li><strong><a class=\"in-cell-link\" href=\"https:\/\/linuxsimply.com\/shutdown-command-in-linux\/\" target=\"_blank\" rel=\"noopener\">The \u201cshutdown\u201d Command in Linux [7 Practical Examples]<\/a><\/strong><\/li>\n<li><strong><a class=\"in-cell-link\" href=\"https:\/\/linuxsimply.com\/finger-command-in-linux\/\" target=\"_blank\" rel=\"noopener\">The \u201cfinger\u201d Command in Linux [6 Practical Examples]<\/a><\/strong><\/li>\n<\/ul>\n<hr \/>\n<h3><span class=\"ez-toc-section\" id=\"Example_6_Create_a_System_Group_With_the_%E2%80%9Cgroupadd%E2%80%9D_Command\"><\/span>Example 6: Create a System Group With the &#8220;groupadd&#8221; Command<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p style=\"text-align: justify;\">You can create a<strong>\u00a0system group<\/strong>\u00a0using the <strong>groupadd<\/strong>\u00a0command with the <strong>option -r <\/strong>or <strong>&#8211;system<\/strong>. Here, I will<strong>\u00a0<\/strong>create a new system group called &#8220;<strong>sgroup<\/strong>&#8220;<strong>\u00a0<\/strong>with<strong>\u00a0<\/strong>the <strong>groupadd<\/strong>\u00a0command. You can do the same by following the steps below.<\/p>\n<p><span style=\"color: #800080;\"><strong>Steps to Follow &gt;<\/strong><\/span><\/p>\n<p>\u278a At first,open the <strong>Ubuntu Terminal<\/strong>.<\/p>\n<p>\u278b<strong>\u00a0<\/strong>Run the following command:<\/p>\n<pre><code class=\"language-bash\" data-line=\"\">sudo groupadd -r sgroup<\/code><\/pre>\n<p><span style=\"color: #800080;\"><strong>OR,<\/strong><\/span><\/p>\n<pre><code class=\"language-bash\" data-line=\"\">sudo groupadd --system sgroup<\/code><\/pre>\n<p>\u278c Now, press the <strong>ENTER<\/strong>\u00a0button.<\/p>\n<p>\u278d Type your <strong>Password<\/strong>.<\/p>\n<p>\u278e Hit <strong>ENTER<\/strong>.<\/p>\n<p>\u278f You can check the GID by typing the following command.<\/p>\n<pre><code class=\"language-bash\" data-line=\"\">getent group sgroup<\/code><\/pre>\n<p>\u2790 Press <strong>ENTER<\/strong>\u00a0button.<\/p>\n<p><span style=\"color: #800080;\"><strong>Output &gt;<\/strong><\/span><\/p>\n<p style=\"text-align: justify;\">In the image below, you can see that I have created <strong>a system group <\/strong>named \u201csgroup\u201d.<img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-3343\" src=\"https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-6.png\" alt=\"showing the creation of system group named &quot;sgroup&quot;.\" width=\"646\" height=\"162\" srcset=\"https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-6.png 646w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-6-300x75.png 300w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-6-1024x257.png 1024w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-6-766x192.png 766w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-6-1536x385.png 1536w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-6-2048x514.png 2048w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-6-598x150.png 598w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-6-100x25.png 100w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-6-1396x350.png 1396w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-6-788x197.png 788w\" sizes=\"(max-width: 646px) 100vw, 646px\" \/><\/p>\n<div class=\"su-note\"  style=\"border-color:#cedfe2;\"><div class=\"su-note-inner su-u-clearfix su-u-trim\" style=\"background-color:#E8F9FC;border-color:#ffffff;color:#333333;\"><strong>Note: <\/strong>The <strong>GID <\/strong>for user-created <strong>system groups<\/strong>\u00a0ranges from 100 to 999.<\/p>\n<\/div><\/div>\n<hr \/>\n<p><span style=\"color: #000080; font-size: 18pt;\"><strong>Similar Readings<\/strong><\/span><\/p>\n<ul>\n<li><strong><a class=\"in-cell-link\" href=\"https:\/\/linuxsimply.com\/dmesg-command-in-linux\/\" target=\"_blank\" rel=\"noopener\">The \u201cdmesg\u201d Command in Linux [7+ Practical Examples]<\/a><\/strong><\/li>\n<li><strong><a class=\"in-cell-link\" href=\"https:\/\/linuxsimply.com\/install-command-in-linux\/\" target=\"_blank\" rel=\"noopener\">The \u201cinstall\u201d Command in Linux [6+ Practical Examples]<\/a><\/strong><\/li>\n<li><strong><a class=\"in-cell-link\" href=\"https:\/\/linuxsimply.com\/reboot-command-in-linux\/\" target=\"_blank\" rel=\"noopener\">The \u201creboot\u201d Command in Linux [3 Practical Examples]<\/a><\/strong><\/li>\n<li><strong><a class=\"in-cell-link\" href=\"https:\/\/linuxsimply.com\/sync-command-in-linux\/\" target=\"_blank\" rel=\"noopener\">The \u201csync\u201d Command in Linux [8 Practical Examples]<\/a><\/strong><\/li>\n<li><strong><a class=\"in-cell-link\" href=\"https:\/\/linuxsimply.com\/chage-command-in-linux\/\" target=\"_blank\" rel=\"noopener\">The \u201cchage\u201d Command in Linux [7 Practical Examples]<\/a><\/strong><\/li>\n<li><strong><a class=\"in-cell-link\" href=\"https:\/\/linuxsimply.com\/env-command-in-linux\/\" target=\"_blank\" rel=\"noopener\">The \u201cenv \u201d Command in Linux [9 Practical Examples]<\/a><\/strong><\/li>\n<\/ul>\n<hr \/>\n<h3><span class=\"ez-toc-section\" id=\"Example_7_Use_an_Encrypted_Password_for_The_New_Group\"><\/span>Example 7: Use an Encrypted Password for The New Group<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p style=\"text-align: justify;\">At the time of creating a <strong>group<\/strong>, you may set a<strong>\u00a0password<\/strong>\u00a0by using the <strong>groupadd<\/strong>\u00a0command followed by the<strong>\u00a0option -p <\/strong>or <strong>&#8211;password<\/strong>. Here, I will set a <strong>password<\/strong>\u00a0for a new group called &#8220;<strong>group7<\/strong>&#8220;. You can do the same by following the steps below.<\/p>\n<p><span style=\"color: #800080;\"><strong>Steps to Follow &gt;<\/strong><\/span><\/p>\n<p>\u278a First, open the <strong>Ubuntu Terminal<\/strong>.<\/p>\n<p>\u278b<strong>\u00a0<\/strong>Type the following command into the command prompt:<\/p>\n<pre><code class=\"language-bash\" data-line=\"\">sudo groupadd -p abcdef123 group7<\/code><\/pre>\n<p><span style=\"color: #800080;\"><strong>OR,<\/strong><\/span><\/p>\n<pre><code class=\"language-bash\" data-line=\"\">sudo groupadd --password abcdef123 group7<\/code><\/pre>\n<p>\u278c Now, press the <strong>ENTER<\/strong>\u00a0button.<\/p>\n<p>\u278d Type your <strong>Password<\/strong>.<\/p>\n<p>\u278e Tap <strong>ENTER<\/strong>\u00a0again.<\/p>\n<p>Now type the following command into the command prompt:<\/p>\n<pre><code class=\"language-bash\" data-line=\"\">sudo grep group7 \/etc\/gshadow<\/code><\/pre>\n<p>\u2790 Press <strong>ENTER<\/strong>\u00a0key.<\/p>\n<p><span style=\"color: #800080;\"><strong>Output &gt;<\/strong><\/span><\/p>\n<p style=\"text-align: justify;\">You can see that I have created a new group named \u201c<strong>group7<\/strong>\u201d along with setting its password.<img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-3344\" src=\"https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-7.png\" alt=\"Showing the creation of group7 with desired password.\" width=\"685\" height=\"169\" srcset=\"https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-7.png 685w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-7-300x74.png 300w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-7-1024x253.png 1024w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-7-766x189.png 766w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-7-1536x379.png 1536w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-7-2048x505.png 2048w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-7-608x150.png 608w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-7-100x25.png 100w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-7-1419x350.png 1419w, https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux-7-788x194.png 788w\" sizes=\"(max-width: 685px) 100vw, 685px\" \/><\/p>\n<h2><span class=\"ez-toc-section\" id=\"Conclusion\"><\/span>Conclusion<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p style=\"text-align: justify;\">In this article, I&#8217;ve provided some relevant examples of the <strong>groupadd<\/strong>\u00a0command in Linux, which will help you on your journey to becoming a <strong>power user<\/strong>\u00a0at the<strong>\u00a0Linux<\/strong>\u00a0command line. \u00a0By properly reading through the article and following the guidelines, you should be able to use the <strong>groupadd <\/strong>command to manage <strong>groups<\/strong>\u00a0on your <strong>Linux<\/strong>\u00a0system.<\/p>\n<hr \/>\n<p><span style=\"color: #000080; font-size: 18pt;\"><strong>Similar Readings<\/strong><\/span><\/p>\n<ul>\n<li><strong><a class=\"in-cell-link\" href=\"https:\/\/linuxsimply.com\/sudo-command-in-linux\/\" target=\"_blank\" rel=\"noopener\">The \u201csudo\u201d Command in Linux [8 Practical Examples]<\/a><\/strong><\/li>\n<li><strong><a class=\"in-cell-link\" href=\"https:\/\/linuxsimply.com\/df-command-in-linux\/\" target=\"_blank\" rel=\"noopener\">The \u201cdf\u201d Command in Linux [11 Practical Examples]<\/a><\/strong><\/li>\n<li><strong><a class=\"in-cell-link\" href=\"https:\/\/linuxsimply.com\/apt-command-in-linux\/\" target=\"_blank\" rel=\"noopener\">The \u201capt\u201d Command in Linux [13+ Practical Examples]<\/a><\/strong><\/li>\n<li><strong><a class=\"in-cell-link\" href=\"https:\/\/linuxsimply.com\/top-command-in-linux\/\" target=\"_blank\" rel=\"noopener\">The &#8220;top&#8221; Command in Linux [8 Practical Examples]<\/a><\/strong><\/li>\n<li><strong><a class=\"in-cell-link\" href=\"https:\/\/linuxsimply.com\/htop-command-in-linux\/\" target=\"_blank\" rel=\"noopener\">The &#8220;htop&#8221; Command in Linux [7 Practical Examples]<\/a><\/strong><\/li>\n<li><strong><a class=\"in-cell-link\" href=\"https:\/\/linuxsimply.com\/enable-command-in-linux\/\" target=\"_blank\" rel=\"noopener\">The \u201cenable\u201d Command in Linux [6 Practical Examples]<\/a><\/strong><\/li>\n<\/ul>\n\n\n<div class=\"kk-star-ratings kksr-auto kksr-align-center kksr-valign-bottom\"\n    data-payload='{&quot;align&quot;:&quot;center&quot;,&quot;id&quot;:&quot;3330&quot;,&quot;slug&quot;:&quot;default&quot;,&quot;valign&quot;:&quot;bottom&quot;,&quot;ignore&quot;:&quot;&quot;,&quot;reference&quot;:&quot;auto&quot;,&quot;class&quot;:&quot;&quot;,&quot;count&quot;:&quot;0&quot;,&quot;legendonly&quot;:&quot;&quot;,&quot;readonly&quot;:&quot;&quot;,&quot;score&quot;:&quot;0&quot;,&quot;starsonly&quot;:&quot;&quot;,&quot;best&quot;:&quot;5&quot;,&quot;gap&quot;:&quot;5&quot;,&quot;greet&quot;:&quot;Rate this post&quot;,&quot;legend&quot;:&quot;0\\\/5 - (0 votes)&quot;,&quot;size&quot;:&quot;24&quot;,&quot;title&quot;:&quot;The \u201cgroupadd\u201d Command in Linux [7 Practical Examples]&quot;,&quot;width&quot;:&quot;0&quot;,&quot;_legend&quot;:&quot;{score}\\\/{best} - ({count} {votes})&quot;,&quot;font_factor&quot;:&quot;1.25&quot;}'>\n            \n<div class=\"kksr-stars\">\n    \n<div class=\"kksr-stars-inactive\">\n            <div class=\"kksr-star\" data-star=\"1\" style=\"padding-right: 5px\">\n            \n\n<div class=\"kksr-icon\" style=\"width: 24px; height: 24px;\"><\/div>\n        <\/div>\n            <div class=\"kksr-star\" data-star=\"2\" style=\"padding-right: 5px\">\n            \n\n<div class=\"kksr-icon\" style=\"width: 24px; height: 24px;\"><\/div>\n        <\/div>\n            <div class=\"kksr-star\" data-star=\"3\" style=\"padding-right: 5px\">\n            \n\n<div class=\"kksr-icon\" style=\"width: 24px; height: 24px;\"><\/div>\n        <\/div>\n            <div class=\"kksr-star\" data-star=\"4\" style=\"padding-right: 5px\">\n            \n\n<div class=\"kksr-icon\" style=\"width: 24px; height: 24px;\"><\/div>\n        <\/div>\n            <div class=\"kksr-star\" data-star=\"5\" style=\"padding-right: 5px\">\n            \n\n<div class=\"kksr-icon\" style=\"width: 24px; height: 24px;\"><\/div>\n        <\/div>\n    <\/div>\n    \n<div class=\"kksr-stars-active\" style=\"width: 0px;\">\n            <div class=\"kksr-star\" style=\"padding-right: 5px\">\n            \n\n<div class=\"kksr-icon\" style=\"width: 24px; height: 24px;\"><\/div>\n        <\/div>\n            <div class=\"kksr-star\" style=\"padding-right: 5px\">\n            \n\n<div class=\"kksr-icon\" style=\"width: 24px; height: 24px;\"><\/div>\n        <\/div>\n            <div class=\"kksr-star\" style=\"padding-right: 5px\">\n            \n\n<div class=\"kksr-icon\" style=\"width: 24px; height: 24px;\"><\/div>\n        <\/div>\n            <div class=\"kksr-star\" style=\"padding-right: 5px\">\n            \n\n<div class=\"kksr-icon\" style=\"width: 24px; height: 24px;\"><\/div>\n        <\/div>\n            <div class=\"kksr-star\" style=\"padding-right: 5px\">\n            \n\n<div class=\"kksr-icon\" style=\"width: 24px; height: 24px;\"><\/div>\n        <\/div>\n    <\/div>\n<\/div>\n                \n\n<div class=\"kksr-legend\" style=\"font-size: 19.2px;\">\n            <span class=\"kksr-muted\">Rate this post<\/span>\n    <\/div>\n    <\/div>\n","protected":false},"excerpt":{"rendered":"<p>Groups\u00a0in Linux\u00a0are used to assign common\u00a0privileges\u00a0and permissions\u00a0to multiple users\u00a0rather than managing them at the individual user level. The groupadd\u00a0command in &#8230; <\/p>\n<p class=\"read-more-container\"><a title=\"The \u201cgroupadd\u201d Command in Linux [7 Practical Examples]\" class=\"read-more button\" href=\"https:\/\/linuxsimply.com\/groupadd-command-in-linux\/#more-3330\" aria-label=\"Read more about The \u201cgroupadd\u201d Command in Linux [7 Practical Examples]\">Read more<\/a><\/p>\n","protected":false},"author":314892,"featured_media":3345,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[11],"tags":[51],"class_list":["post-3330","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-linux-commands","tag-system-commands","generate-columns","tablet-grid-50","mobile-grid-100","grid-parent","grid-33"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.3 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>The \u201cgroupadd\u201d Command in Linux [7 Practical Examples]<\/title>\n<meta name=\"description\" content=\"The groupadd command in Linux allows you to create groups with one or more users to manage their permissions and privileges.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/linuxsimply.com\/groupadd-command-in-linux\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"The \u201cgroupadd\u201d Command in Linux [7 Practical Examples]\" \/>\n<meta property=\"og:description\" content=\"The groupadd command in Linux allows you to create groups with one or more users to manage their permissions and privileges.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/linuxsimply.com\/groupadd-command-in-linux\/\" \/>\n<meta property=\"og:site_name\" content=\"LinuxSimply\" \/>\n<meta property=\"article:published_time\" content=\"2023-01-09T10:12:18+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2024-03-31T10:39:26+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux..png\" \/>\n\t<meta property=\"og:image:width\" content=\"400\" \/>\n\t<meta property=\"og:image:height\" content=\"400\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"S. M. Amdadul Islam\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"S. M. Amdadul Islam\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"10 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/linuxsimply.com\\\/groupadd-command-in-linux\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/linuxsimply.com\\\/groupadd-command-in-linux\\\/\"},\"author\":{\"name\":\"S. M. Amdadul Islam\",\"@id\":\"https:\\\/\\\/linuxsimply.com\\\/#\\\/schema\\\/person\\\/d0ccfa2e6c3bddb8ae34898f9d45b4ee\"},\"headline\":\"The \u201cgroupadd\u201d Command in Linux [7 Practical Examples]\",\"datePublished\":\"2023-01-09T10:12:18+00:00\",\"dateModified\":\"2024-03-31T10:39:26+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/linuxsimply.com\\\/groupadd-command-in-linux\\\/\"},\"wordCount\":1765,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\\\/\\\/linuxsimply.com\\\/#organization\"},\"image\":{\"@id\":\"https:\\\/\\\/linuxsimply.com\\\/groupadd-command-in-linux\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/linuxsimply.com\\\/wp-content\\\/uploads\\\/2023\\\/01\\\/groupadd-command-in-linux..png\",\"keywords\":[\"system commands\"],\"articleSection\":[\"Linux Commands\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/linuxsimply.com\\\/groupadd-command-in-linux\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/linuxsimply.com\\\/groupadd-command-in-linux\\\/\",\"url\":\"https:\\\/\\\/linuxsimply.com\\\/groupadd-command-in-linux\\\/\",\"name\":\"The \u201cgroupadd\u201d Command in Linux [7 Practical Examples]\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/linuxsimply.com\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/linuxsimply.com\\\/groupadd-command-in-linux\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/linuxsimply.com\\\/groupadd-command-in-linux\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/linuxsimply.com\\\/wp-content\\\/uploads\\\/2023\\\/01\\\/groupadd-command-in-linux..png\",\"datePublished\":\"2023-01-09T10:12:18+00:00\",\"dateModified\":\"2024-03-31T10:39:26+00:00\",\"description\":\"The groupadd command in Linux allows you to create groups with one or more users to manage their permissions and privileges.\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/linuxsimply.com\\\/groupadd-command-in-linux\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/linuxsimply.com\\\/groupadd-command-in-linux\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/linuxsimply.com\\\/groupadd-command-in-linux\\\/#primaryimage\",\"url\":\"https:\\\/\\\/linuxsimply.com\\\/wp-content\\\/uploads\\\/2023\\\/01\\\/groupadd-command-in-linux..png\",\"contentUrl\":\"https:\\\/\\\/linuxsimply.com\\\/wp-content\\\/uploads\\\/2023\\\/01\\\/groupadd-command-in-linux..png\",\"width\":400,\"height\":400,\"caption\":\"groupadd command in linux\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/linuxsimply.com\\\/groupadd-command-in-linux\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/linuxsimply.com\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"The \u201cgroupadd\u201d Command in Linux [7 Practical Examples]\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/linuxsimply.com\\\/#website\",\"url\":\"https:\\\/\\\/linuxsimply.com\\\/\",\"name\":\"LinuxSimply\",\"description\":\"All About Linux\",\"publisher\":{\"@id\":\"https:\\\/\\\/linuxsimply.com\\\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/linuxsimply.com\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/linuxsimply.com\\\/#organization\",\"name\":\"LinuxSimply\",\"url\":\"https:\\\/\\\/linuxsimply.com\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/linuxsimply.com\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"https:\\\/\\\/linuxsimply.com\\\/wp-content\\\/uploads\\\/2023\\\/09\\\/LinuxSimply-New-Logo-Without-Icon.png\",\"contentUrl\":\"https:\\\/\\\/linuxsimply.com\\\/wp-content\\\/uploads\\\/2023\\\/09\\\/LinuxSimply-New-Logo-Without-Icon.png\",\"width\":355,\"height\":48,\"caption\":\"LinuxSimply\"},\"image\":{\"@id\":\"https:\\\/\\\/linuxsimply.com\\\/#\\\/schema\\\/logo\\\/image\\\/\"}},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/linuxsimply.com\\\/#\\\/schema\\\/person\\\/d0ccfa2e6c3bddb8ae34898f9d45b4ee\",\"name\":\"S. M. Amdadul Islam\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/linuxsimply.com\\\/wp-content\\\/uploads\\\/2023\\\/09\\\/S.-M.-Amdadul-Islam-II-96x96.png\",\"url\":\"https:\\\/\\\/linuxsimply.com\\\/wp-content\\\/uploads\\\/2023\\\/09\\\/S.-M.-Amdadul-Islam-II-96x96.png\",\"contentUrl\":\"https:\\\/\\\/linuxsimply.com\\\/wp-content\\\/uploads\\\/2023\\\/09\\\/S.-M.-Amdadul-Islam-II-96x96.png\",\"caption\":\"S. M. Amdadul Islam\"},\"description\":\"Hello everyone. I am S. M. Amdadul Islam, currently working as a Linux Content Developer Executive at SOFTEKO. I am a Naval Architecture and Marine Engineering (NAME) graduate from the Bangladesh University of Engineering and Technology. In addition to my regular work, I enjoy watching Youtube, discovering new things, gossiping with friends, visiting new places, and taking photos of landscapes. Read Full Bio\",\"sameAs\":[\"https:\\\/\\\/www.linkedin.com\\\/in\\\/amdadul-islam\"],\"url\":\"https:\\\/\\\/linuxsimply.com\\\/author\\\/amdad\\\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"The \u201cgroupadd\u201d Command in Linux [7 Practical Examples]","description":"The groupadd command in Linux allows you to create groups with one or more users to manage their permissions and privileges.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/linuxsimply.com\/groupadd-command-in-linux\/","og_locale":"en_US","og_type":"article","og_title":"The \u201cgroupadd\u201d Command in Linux [7 Practical Examples]","og_description":"The groupadd command in Linux allows you to create groups with one or more users to manage their permissions and privileges.","og_url":"https:\/\/linuxsimply.com\/groupadd-command-in-linux\/","og_site_name":"LinuxSimply","article_published_time":"2023-01-09T10:12:18+00:00","article_modified_time":"2024-03-31T10:39:26+00:00","og_image":[{"width":400,"height":400,"url":"https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux..png","type":"image\/png"}],"author":"S. M. Amdadul Islam","twitter_card":"summary_large_image","twitter_misc":{"Written by":"S. M. Amdadul Islam","Est. reading time":"10 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/linuxsimply.com\/groupadd-command-in-linux\/#article","isPartOf":{"@id":"https:\/\/linuxsimply.com\/groupadd-command-in-linux\/"},"author":{"name":"S. M. Amdadul Islam","@id":"https:\/\/linuxsimply.com\/#\/schema\/person\/d0ccfa2e6c3bddb8ae34898f9d45b4ee"},"headline":"The \u201cgroupadd\u201d Command in Linux [7 Practical Examples]","datePublished":"2023-01-09T10:12:18+00:00","dateModified":"2024-03-31T10:39:26+00:00","mainEntityOfPage":{"@id":"https:\/\/linuxsimply.com\/groupadd-command-in-linux\/"},"wordCount":1765,"commentCount":0,"publisher":{"@id":"https:\/\/linuxsimply.com\/#organization"},"image":{"@id":"https:\/\/linuxsimply.com\/groupadd-command-in-linux\/#primaryimage"},"thumbnailUrl":"https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux..png","keywords":["system commands"],"articleSection":["Linux Commands"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/linuxsimply.com\/groupadd-command-in-linux\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/linuxsimply.com\/groupadd-command-in-linux\/","url":"https:\/\/linuxsimply.com\/groupadd-command-in-linux\/","name":"The \u201cgroupadd\u201d Command in Linux [7 Practical Examples]","isPartOf":{"@id":"https:\/\/linuxsimply.com\/#website"},"primaryImageOfPage":{"@id":"https:\/\/linuxsimply.com\/groupadd-command-in-linux\/#primaryimage"},"image":{"@id":"https:\/\/linuxsimply.com\/groupadd-command-in-linux\/#primaryimage"},"thumbnailUrl":"https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux..png","datePublished":"2023-01-09T10:12:18+00:00","dateModified":"2024-03-31T10:39:26+00:00","description":"The groupadd command in Linux allows you to create groups with one or more users to manage their permissions and privileges.","breadcrumb":{"@id":"https:\/\/linuxsimply.com\/groupadd-command-in-linux\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/linuxsimply.com\/groupadd-command-in-linux\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/linuxsimply.com\/groupadd-command-in-linux\/#primaryimage","url":"https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux..png","contentUrl":"https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/01\/groupadd-command-in-linux..png","width":400,"height":400,"caption":"groupadd command in linux"},{"@type":"BreadcrumbList","@id":"https:\/\/linuxsimply.com\/groupadd-command-in-linux\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/linuxsimply.com\/"},{"@type":"ListItem","position":2,"name":"The \u201cgroupadd\u201d Command in Linux [7 Practical Examples]"}]},{"@type":"WebSite","@id":"https:\/\/linuxsimply.com\/#website","url":"https:\/\/linuxsimply.com\/","name":"LinuxSimply","description":"All About Linux","publisher":{"@id":"https:\/\/linuxsimply.com\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/linuxsimply.com\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/linuxsimply.com\/#organization","name":"LinuxSimply","url":"https:\/\/linuxsimply.com\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/linuxsimply.com\/#\/schema\/logo\/image\/","url":"https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/09\/LinuxSimply-New-Logo-Without-Icon.png","contentUrl":"https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/09\/LinuxSimply-New-Logo-Without-Icon.png","width":355,"height":48,"caption":"LinuxSimply"},"image":{"@id":"https:\/\/linuxsimply.com\/#\/schema\/logo\/image\/"}},{"@type":"Person","@id":"https:\/\/linuxsimply.com\/#\/schema\/person\/d0ccfa2e6c3bddb8ae34898f9d45b4ee","name":"S. M. Amdadul Islam","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/09\/S.-M.-Amdadul-Islam-II-96x96.png","url":"https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/09\/S.-M.-Amdadul-Islam-II-96x96.png","contentUrl":"https:\/\/linuxsimply.com\/wp-content\/uploads\/2023\/09\/S.-M.-Amdadul-Islam-II-96x96.png","caption":"S. M. Amdadul Islam"},"description":"Hello everyone. I am S. M. Amdadul Islam, currently working as a Linux Content Developer Executive at SOFTEKO. I am a Naval Architecture and Marine Engineering (NAME) graduate from the Bangladesh University of Engineering and Technology. In addition to my regular work, I enjoy watching Youtube, discovering new things, gossiping with friends, visiting new places, and taking photos of landscapes. Read Full Bio","sameAs":["https:\/\/www.linkedin.com\/in\/amdadul-islam"],"url":"https:\/\/linuxsimply.com\/author\/amdad\/"}]}},"_links":{"self":[{"href":"https:\/\/linuxsimply.com\/wp-json\/wp\/v2\/posts\/3330","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/linuxsimply.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/linuxsimply.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/linuxsimply.com\/wp-json\/wp\/v2\/users\/314892"}],"replies":[{"embeddable":true,"href":"https:\/\/linuxsimply.com\/wp-json\/wp\/v2\/comments?post=3330"}],"version-history":[{"count":0,"href":"https:\/\/linuxsimply.com\/wp-json\/wp\/v2\/posts\/3330\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/linuxsimply.com\/wp-json\/wp\/v2\/media\/3345"}],"wp:attachment":[{"href":"https:\/\/linuxsimply.com\/wp-json\/wp\/v2\/media?parent=3330"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/linuxsimply.com\/wp-json\/wp\/v2\/categories?post=3330"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/linuxsimply.com\/wp-json\/wp\/v2\/tags?post=3330"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}