How to get a list of total cPanel users under a specific re-seller via command line – WHM/cPanel server

Yes, It’s very simple to list all cPanel users’ name via command line. There is a file ‘/etc/trueuserowners‘ in your WHM server which has cPanel username and it’s owner’s name. We can simply grep out our requirement from this file.

File which has user:owner details

/etc/trueuserowners

List only all users under a reseller?
You can use the grep and cut command to list all users’ name from /etc/trueuserowners.

Syntax:

# grep $Re-seller's-name /etc/trueuserowners | cut -d : -f 1

$Re-seller’s : replace it with the re-seller name

Example:

# grep crybit /etc/trueuserowners | cut -d : -f 1
tieuwn
sinwe8
crybit
dewan

That’s it 🙂

 

Related:
check the version of your WHM/cPanel from command line
Important cPanel service’s configuration file, path, service name, port – Command line view
How to terminate/delete a cPanel account through SSH

Something more about cPanel  , See the category CPANEL

Arunlal Ashok

Linux Server Administrator. I'm dealing with Linux servers since 2012. I started this blog to share and discuss my ideas with the world. Check My Profile!! in uPwork (oDesk) and let me know if you need any assistance. Thanks!!

You may also like...

Leave a Reply

Your email address will not be published. Required fields are marked *