Update All cPanel Passwords

Upon request of changing all the passwords on a server, we created a script to change all the passwords on a cPanel server. This script enables passwords to be changed from the command line, sends a list of users to a text file, generates a random 10 character password, saves the new passwords to a file, and updates all FTP/MySQL/cPanel passwords for the users. Although passwords should be changed through WHM, this allows you to change hundreds of passwords within a few seconds.

#Changes every cPanel password on the server and stores the credentials in ~/newCredentials
#$newPassword is a randomly generated password with 10 characters
ls -la /home | awk ‘{print $3}’ | grep -v root | grep -v wheel | grep -v cpanel | grep -v apache | grep -v csf | grep -v ‘^$’ > /tmp/usersforchpass
for i in `more /tmp/usersforchpass `
newPassword=$(</dev/urandom tr -dc ‘A-Za-z0-9’ | head -c10)
echo “Username: $i” >> ~/newCredentials
echo “Password: $newPassword” >> ~/newCredentials
echo “” >> ~/newCredentials
/scripts/chpass $i $newPassword
/scripts/mysqlpasswd $i $newPassword
rm -f /tmp/usersforchpass


We don't mean to brag but...

These are some of our statistics:

Avg Response Time
Coffees Consumed
Server Uptime
Issues Fixed

What Our Customers
Have To Say

About three years ago we were looking for a new server provider, the problem that we were having was we are not “server guys” and we had over 400 clients to take care of. So anytime we tried to get support we had to submit a ticket, try to explain what was going on, and then pray that the response was in some form that we could understand.

After the on-boarding with Green Olive Tree, they told us that we had twice as much server than we needed and they were not set up right. Thank goodness we have found someone that really looked at what we want to do and gave us real actionable advice. It is safe to say that we have found our server company, and now we can focus on growing out business and not have to worry about the reliability of our support.

Thanks again Green Olive Tree, You Guys Rock!

John Owens

Green Olive Tree has been an invaluable resource to my company allowing me to focus more on my business instead of the management of servers. In the five years I have done business with GOT I have had zero downtime. Knowing that everything is being kept up-to-date and they are proactively patching system flaws gives me peace of mind that I didn’t have before finding Green Olive Tree. Jon has always made himself available when I’ve needed advice or help on upgrading servers or software and I can’t imagine ever going back to managing a server without GOT.

Chris Smith

Green Olive Tree has been very good to us. Jon has helped us scale from 200,000 unique’s visitors a day to over 3 million per day. From 1 server to now 14 on a well-structured load balanced failsafe system. Not only that he has managed to reduce our server resources 3 fold by installing the right kind of software so we’re getting more power out of each server for the same price. He always responds very quickly and stays up at all kinds of crazy hours to help us out, the man never sleeps! I guess that’s why he was a Navy Chief, he brings that discipline into his work and that’s what we love.

Anthony Lipari

Call us today at (800) 269-6465
We can help, contact us today.