<?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 Deleting multiple users in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/deleting-multiple-users/m-p/4053299#M304853</link>
    <description>Hello,&lt;BR /&gt;&lt;BR /&gt;Can someone tell me the proper method for removing large numbers of users from /etc/passwd? This is a trusted system, and all users to be removed have the same group id.&lt;BR /&gt;&lt;BR /&gt;Thanks!&lt;BR /&gt;Nate</description>
    <pubDate>Fri, 10 Aug 2007 10:26:02 GMT</pubDate>
    <dc:creator>NateJones</dc:creator>
    <dc:date>2007-08-10T10:26:02Z</dc:date>
    <item>
      <title>Deleting multiple users</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/deleting-multiple-users/m-p/4053299#M304853</link>
      <description>Hello,&lt;BR /&gt;&lt;BR /&gt;Can someone tell me the proper method for removing large numbers of users from /etc/passwd? This is a trusted system, and all users to be removed have the same group id.&lt;BR /&gt;&lt;BR /&gt;Thanks!&lt;BR /&gt;Nate</description>
      <pubDate>Fri, 10 Aug 2007 10:26:02 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/deleting-multiple-users/m-p/4053299#M304853</guid>
      <dc:creator>NateJones</dc:creator>
      <dc:date>2007-08-10T10:26:02Z</dc:date>
    </item>
    <item>
      <title>Re: Deleting multiple users</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/deleting-multiple-users/m-p/4053300#M304854</link>
      <description>&lt;!--!*#--&gt;Hi Nate:&lt;BR /&gt;&lt;BR /&gt;Use 'userdel'.  See the manpages for more details.  You could do:&lt;BR /&gt;&lt;BR /&gt;#!/usr/bin/sh&lt;BR /&gt;while read USER&lt;BR /&gt;do&lt;BR /&gt;    userdel -r ${USER}&lt;BR /&gt;    RC=$?    &lt;BR /&gt;    if [ "${RC}" != 0 ]; then&lt;BR /&gt;        echo "error ${RC} for ${USER}"&lt;BR /&gt;    else&lt;BR /&gt;        echo "${USER} deleted_OK"&lt;BR /&gt;    fi&lt;BR /&gt;done &amp;lt; myuserlist&lt;BR /&gt;&lt;BR /&gt;...where "myuserlist" contains the user name to be deleted -- one name per line in the file.&lt;BR /&gt;&lt;BR /&gt;Regards!&lt;BR /&gt;&lt;BR /&gt;...JRF...</description>
      <pubDate>Fri, 10 Aug 2007 10:33:07 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/deleting-multiple-users/m-p/4053300#M304854</guid>
      <dc:creator>James R. Ferguson</dc:creator>
      <dc:date>2007-08-10T10:33:07Z</dc:date>
    </item>
    <item>
      <title>Re: Deleting multiple users</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/deleting-multiple-users/m-p/4053301#M304855</link>
      <description>How about a for loop with the "userdel" command:&lt;BR /&gt;&lt;BR /&gt;for USER in `cat userlist`&lt;BR /&gt; do&lt;BR /&gt;  userdel $USER&lt;BR /&gt; done&lt;BR /&gt;&lt;BR /&gt;Or something similar.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Pete</description>
      <pubDate>Fri, 10 Aug 2007 10:34:37 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/deleting-multiple-users/m-p/4053301#M304855</guid>
      <dc:creator>Pete Randall</dc:creator>
      <dc:date>2007-08-10T10:34:37Z</dc:date>
    </item>
    <item>
      <title>Re: Deleting multiple users</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/deleting-multiple-users/m-p/4053302#M304856</link>
      <description>I'd be reluctant to use the -r option on userdel unless you are 100% sure that they have unique isolated home directories. Although I typically don't use it, I did once at my last job ( I plead temporary insanity) and it just happened that user's home directory was right in the middle of an application directory. Removed the user and a good portion of the application along with him.</description>
      <pubDate>Fri, 10 Aug 2007 10:42:05 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/deleting-multiple-users/m-p/4053302#M304856</guid>
      <dc:creator>Jeff_Traigle</dc:creator>
      <dc:date>2007-08-10T10:42:05Z</dc:date>
    </item>
    <item>
      <title>Re: Deleting multiple users</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/deleting-multiple-users/m-p/4053303#M304857</link>
      <description>Dang you guys are fast! Thanks much, you're script is exactly what I needed.&lt;BR /&gt;&lt;BR /&gt;Nate</description>
      <pubDate>Fri, 10 Aug 2007 10:46:38 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/deleting-multiple-users/m-p/4053303#M304857</guid>
      <dc:creator>NateJones</dc:creator>
      <dc:date>2007-08-10T10:46:38Z</dc:date>
    </item>
    <item>
      <title>Re: Deleting multiple users</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/deleting-multiple-users/m-p/4053304#M304858</link>
      <description>Thanks Jeff. I took James' advice and read the manpages, and did catch the -r switch. It would have indeed been distastrous for us as all users share the same home directory.&lt;BR /&gt;&lt;BR /&gt;Nate</description>
      <pubDate>Fri, 10 Aug 2007 10:48:36 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/deleting-multiple-users/m-p/4053304#M304858</guid>
      <dc:creator>NateJones</dc:creator>
      <dc:date>2007-08-10T10:48:36Z</dc:date>
    </item>
  </channel>
</rss>

