[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

RE: [K12OSN] End Of Year Cleaning



Well, I am using Samba-LDAP server, I looked in webmin and can't seem to
follow what you're talking about. I used the scripts provided (IDEALX) to
create the user account. I see there is a delete script but not sure if it
can be used to delete user accounts from just one group.

Mark Sarria
Sylmar High School
LAUSD
(818) 367-0299
 

-----Original Message-----
From: k12osn-bounces redhat com [mailto:k12osn-bounces redhat com] On Behalf
Of Scott Sherrill
Sent: Thursday, June 15, 2006 11:30 AM
To: Support list for opensource software in schools.
Subject: Re: [K12OSN] End Of Year Cleaning

Huck wrote:
> I would like to just delete all the accounts in one group the STUDENT 
> group,
> is there a way of doing this?

> you can use the webmin batch to do that...
> extract the usernames
> create a file:
> deletethese.txt  that contains the following:
> delete:usernameX
> delete:usernameY
> delete:usernameZ
> etc...
>
> then with the webmin useradmin module..
> use that file to delete the users&homedirs.
>
>

To build on Huck's suggestion if the students are all in group 100 (for 
example) you could do something like:

cat /etc/passwd | grep ":100:" | cut -d: -f1 | awk '{print "delete:"$1}'

from the command line

which will give you output similar to:
delete:games
delete:scott
delete:eric
delete:sherial
....

Double check before send the list into webmin - for example because I 
chose :100: as my search criteria,  there is a system account called 
games that is has a userid of 100 and it picked it up as well.

Scott

_______________________________________________
K12OSN mailing list
K12OSN redhat com
https://www.redhat.com/mailman/listinfo/k12osn
For more info see <http://www.k12os.org>


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]