Terminating reseller accounts without primary domain

apc1

Well-Known Member
Oct 18, 2004
123
0
166
Some time ago transferred a couple of accounts from another server with reseller priveledges.

I need to terminate these accounts and all user accounts under them, but they have no domain associated with the reseller account, and consequently do not appear in the list of accounts in reseller center account termination.

How can I get around this from the command line if necessary?

Thanks.
 

brendanrtg

Well-Known Member
Oct 4, 2006
311
0
166
This is going to be a TEDIOUS & LONG processs as far as I know.

For a start, you can try adding the missing main domain back by editing /var/cpanel/users/YSERNAME

If that fails to you cannot remember the user (unlikely), then:

1. Terminate those you can see under WHM > TERMINATE MULTIPLE ACCOUNTS
2. Terminate their Zones under WHM > DELETE ZONE ENTRIES (those you cannot see)
3. EDIT as root /etc/passwd, /etc/group and remove their usernames
4. Go to /home and remove their directories with rm -rf /USERNAME
5. Go to /var/cpanel/users and DELETE their USERNAME

The above "should" make a "clean" delete of those stealth accounts, although there are other entries which in my opinion are safe to ignore.

I am sure there must be an easier way and I have yet to figure them out :)
 

cPanelKenneth

cPanel Development
Staff member
Apr 7, 2006
4,607
79
458
cPanel Access Level
Root Administrator
Along with what brendanrtg said, you'll also need to modify the /var/cpanel/reseller* files to remove all instances of the reseller account name
 

apc1

Well-Known Member
Oct 18, 2004
123
0
166
This is going to be a TEDIOUS & LONG processs as far as I know.

For a start, you can try adding the missing main domain back by editing /var/cpanel/users/YSERNAME

If that fails to you cannot remember the user (unlikely), then:

1. Terminate those you can see under WHM > TERMINATE MULTIPLE ACCOUNTS
2. Terminate their Zones under WHM > DELETE ZONE ENTRIES (those you cannot see)
3. EDIT as root /etc/passwd, /etc/group and remove their usernames
4. Go to /home and remove their directories with rm -rf /USERNAME
5. Go to /var/cpanel/users and DELETE their USERNAME

The above "should" make a "clean" delete of those stealth accounts, although there are other entries which in my opinion are safe to ignore.

I am sure there must be an easier way and I have yet to figure them out :)

Thanks.

The account file does not exist in /var/cpanel/users

I can see his accounts in terminate multiple accounts, but I would like to zap everything.

Surely terminating multiple accounts will zap the directories and DNS anyway?

I just need to remove the reseller account itself then.