<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: adding second secondray group to a user using command in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/adding-second-secondray-group-to-a-user-using-command/m-p/2884203#M935223</link>
    <description>Hi Ravi,&lt;BR /&gt;&lt;BR /&gt; Sorry my previous post has a error on the sed. use the following.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;  When using secondary group to a user, it changes the existing secondary group. &lt;BR /&gt;But you can use my script to add additional secondary groups &lt;BR /&gt;&lt;BR /&gt;EG=`/usr/bin/groups $1|sed 's/ /,/g'`&lt;BR /&gt;NG=$EG,$2&lt;BR /&gt;/usr/sbin/usermod -G $NG $1&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;You can pass username and the secondary group name that has to be added. &lt;BR /&gt;&lt;BR /&gt;Hope this helps u.&lt;BR /&gt;&lt;BR /&gt;Srini.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;</description>
    <pubDate>Fri, 17 Jan 2003 07:23:45 GMT</pubDate>
    <dc:creator>avsrini</dc:creator>
    <dc:date>2003-01-17T07:23:45Z</dc:date>
    <item>
      <title>adding second secondray group to a user using command</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/adding-second-secondray-group-to-a-user-using-command/m-p/2884197#M935217</link>
      <description>Hi all&lt;BR /&gt;&lt;BR /&gt;We knew that we can change the second secondary  group to user(s) using sam. but how to achieve the same using command line. &lt;BR /&gt;groupmod changes the existing secondary group to the specified group.&lt;BR /&gt;Guys do u aware of any other alternatives.&lt;BR /&gt;&lt;BR /&gt;thanx in advance</description>
      <pubDate>Fri, 17 Jan 2003 06:51:51 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/adding-second-secondray-group-to-a-user-using-command/m-p/2884197#M935217</guid>
      <dc:creator>Ravi_8</dc:creator>
      <dc:date>2003-01-17T06:51:51Z</dc:date>
    </item>
    <item>
      <title>Re: adding second secondray group to a user using command</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/adding-second-secondray-group-to-a-user-using-command/m-p/2884198#M935218</link>
      <description>usermod -G secondary_groups is the one you are lokking for.&lt;BR /&gt;&lt;BR /&gt;check usermod man page for details.</description>
      <pubDate>Fri, 17 Jan 2003 06:54:01 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/adding-second-secondray-group-to-a-user-using-command/m-p/2884198#M935218</guid>
      <dc:creator>RAC_1</dc:creator>
      <dc:date>2003-01-17T06:54:01Z</dc:date>
    </item>
    <item>
      <title>Re: adding second secondray group to a user using command</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/adding-second-secondray-group-to-a-user-using-command/m-p/2884199#M935219</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;I am sorry, instead of usermod i have mentioned as groupmod in my question</description>
      <pubDate>Fri, 17 Jan 2003 06:59:01 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/adding-second-secondray-group-to-a-user-using-command/m-p/2884199#M935219</guid>
      <dc:creator>Ravi_8</dc:creator>
      <dc:date>2003-01-17T06:59:01Z</dc:date>
    </item>
    <item>
      <title>Re: adding second secondray group to a user using command</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/adding-second-secondray-group-to-a-user-using-command/m-p/2884200#M935220</link>
      <description>modify /etc/group and adding user to groups.&lt;BR /&gt;&lt;BR /&gt;run grpck afterwards.</description>
      <pubDate>Fri, 17 Jan 2003 07:09:39 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/adding-second-secondray-group-to-a-user-using-command/m-p/2884200#M935220</guid>
      <dc:creator>RAC_1</dc:creator>
      <dc:date>2003-01-17T07:09:39Z</dc:date>
    </item>
    <item>
      <title>Re: adding second secondray group to a user using command</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/adding-second-secondray-group-to-a-user-using-command/m-p/2884201#M935221</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;see man groupadd&lt;BR /&gt;&lt;BR /&gt;Regs&lt;BR /&gt;Armin</description>
      <pubDate>Fri, 17 Jan 2003 07:12:31 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/adding-second-secondray-group-to-a-user-using-command/m-p/2884201#M935221</guid>
      <dc:creator>Armin Feller</dc:creator>
      <dc:date>2003-01-17T07:12:31Z</dc:date>
    </item>
    <item>
      <title>Re: adding second secondray group to a user using command</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/adding-second-secondray-group-to-a-user-using-command/m-p/2884202#M935222</link>
      <description>Hi Ravi,&lt;BR /&gt;  When using secondary group to a user, it changes the existing secondary group. &lt;BR /&gt;But you can use my script to add additional secondary groups &lt;BR /&gt;&lt;BR /&gt;EG=`/usr/bin/groups $1|sed 's/ /.g'`&lt;BR /&gt;NG=$EG,$2&lt;BR /&gt;/usr/sbin/usermod -G $NG $1&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;You can pass username and the secondary group name that has to be added. &lt;BR /&gt;&lt;BR /&gt;Hope this helps u.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Srini.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Fri, 17 Jan 2003 07:22:37 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/adding-second-secondray-group-to-a-user-using-command/m-p/2884202#M935222</guid>
      <dc:creator>avsrini</dc:creator>
      <dc:date>2003-01-17T07:22:37Z</dc:date>
    </item>
    <item>
      <title>Re: adding second secondray group to a user using command</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/adding-second-secondray-group-to-a-user-using-command/m-p/2884203#M935223</link>
      <description>Hi Ravi,&lt;BR /&gt;&lt;BR /&gt; Sorry my previous post has a error on the sed. use the following.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;  When using secondary group to a user, it changes the existing secondary group. &lt;BR /&gt;But you can use my script to add additional secondary groups &lt;BR /&gt;&lt;BR /&gt;EG=`/usr/bin/groups $1|sed 's/ /,/g'`&lt;BR /&gt;NG=$EG,$2&lt;BR /&gt;/usr/sbin/usermod -G $NG $1&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;You can pass username and the secondary group name that has to be added. &lt;BR /&gt;&lt;BR /&gt;Hope this helps u.&lt;BR /&gt;&lt;BR /&gt;Srini.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Fri, 17 Jan 2003 07:23:45 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/adding-second-secondray-group-to-a-user-using-command/m-p/2884203#M935223</guid>
      <dc:creator>avsrini</dc:creator>
      <dc:date>2003-01-17T07:23:45Z</dc:date>
    </item>
    <item>
      <title>Re: adding second secondray group to a user using command</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/adding-second-secondray-group-to-a-user-using-command/m-p/2884204#M935224</link>
      <description>Hi, srini&lt;BR /&gt;&lt;BR /&gt;thanx, your script worked</description>
      <pubDate>Fri, 17 Jan 2003 08:53:15 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/adding-second-secondray-group-to-a-user-using-command/m-p/2884204#M935224</guid>
      <dc:creator>Ravi_8</dc:creator>
      <dc:date>2003-01-17T08:53:15Z</dc:date>
    </item>
  </channel>
</rss>

