Help Center
Optimize accounts with manual rearrange
Performing a rearrange of an account hosted in cPanel may be necessary in certain situations. This process involves changing the partition where the account is hosted and can be beneficial for several reasons:
Improved Performance: If you notice that your account's performance has decreased due to the load from other accounts on the same partition, a rearrange can help distribute resources better and enhance overall performance.
Additional Space: If your account needs more disk space, and the current partition is nearly full, a rearrange allows you to move it to a partition with more available space.
Organization and Management: Sometimes, it's convenient to group related accounts or those from the same project in the same partition to facilitate resource management and organization.
Remember that rearranging involves a process that can temporarily affect the account's availability, so it's essential to do it during periods of low activity. Make sure to back up important data before proceeding.
Below, we present a step-by-step tutorial on how to perform a rearrange or change the partition of an account hosted in cPanel. Follow the instructions carefully to complete the process safely and efficiently.
- Create a "screen." If your internet connection is lost, the process will remain active
# screen -S [SCREEN_NAME]
- Synchronize your content by sending an email to your email account when it finishes. This will help you know when a large account synchronization is completed without needing to monitor the computer
# rsync -avhzo /source_home/USERNAME/ /destination_home/USERNAME && echo "USERNAME synchronized" | mail -s "account synchronized" notification.email@domain.com
- Once synchronization is complete, you'll need to make partition changes within the "userdata" and "proftpd" folders
# sed -i 's/source_home/destination_home/g' /var/cpanel/userdata/USERNAME/* && sed -i 's/source_home/destination_home/g' /etc/proftpd/USERNAME
- Modify the location of your application passwords. You'll need to manually search for your USERNAME and replace source_home with destination_home
# nano /etc/passwd
- Adjust email parameters, restart services, and update cagefs for this user (if you use CloudLinux)
# sed -i 's/source_home/destination_home/g' /destination_home/USERNAME/etc/*/passwd && /scripts/rebuildhttpdconf && service httpd restart && service pure-ftpd restart && /scripts/updateuserdatacache && cagefsctl -m USERNAME
Remember, you should only change the following data:
- source_home
- destination_home
- USERNAME
Related articles
- Screen command in CentOs: more efficient sessions
- Solution: 'Service Unavailable' on CloudLinux servers
- Database export via command line
- Protect your data: configure RAID notifications with S.M.A.R.T.
- List CronJobs for all cPanel users
- Delete unnecessary files from the /tmp partition
- Change reserved disk space in CentOS
- Know your hardware: get accurate information on CentOS 7
- Basic SSH commands
- IP blocking in CSF via command line
- Clear DNS cache: solution to resolution problems
- Change file permissions via command line
- How to open and close ports using CSF in WHM?
- How to Modify the Hosts File in Windows, Linux, and macOS
- How to Use Telnet to Test SMTP Connectivity on Port 25
- Adjusting reserved space on Linux disks
- Adjusting reconstruction speed in RAID on Linux
- Where are NGINX logs stored?
- Configuring RAID failure notifications with mdadm
- Differences between Legacy VPS and Cloud VPS
- Install cPanel in your server or VPS
- How to send emails via SSH?
- Manage screen session