This guide is based on a real WHM/cPanel server running AlmaLinux, where a DigitalOcean volume was added, mounted as /home2, used for cPanel accounts, and later expanded from 100 GB → 200 GB → 300 GB.
The goal is simple:
Add extra disk space to your WHM server and use it for hosting cPanel accounts without changing DNS, IPs, or moving to another server.
What we were trying to fix
The server had:
16 GB RAM
8 vCPUs
480 GB main disk
Additional DigitalOcean volume
WHM/cPanel on AlmaLinux 8
The main disk was getting full, so we added a DigitalOcean volume. DigitalOcean automatically mounted it at:
/mnt/volume_blr1_01
But WHM/cPanel does not normally create hosting accounts there. For cPanel accounts, the practical mount point should be:
/home2
cPanel’s own WHM Basic Setup documentation explains that /home is the default home directory, and if more than one home directory is configured, cPanel can use the directory with the most free space for new accounts. It also says the additional home directory value must be a mount point.
Part 1: Check the new disk
First, check what disk DigitalOcean attached:
lsblk -f
df -h
In our case, the extra disk was:
/dev/sda
It was formatted as:
ext4
And it was originally mounted at:
/mnt/volume_blr1_01
Also check the stable DigitalOcean disk path:
ls -l /dev/disk/by-id/ | grep -i DO_Volume
Example output:
scsi-0DO_Volume_volume-blr1-01 -> ../../sda
This stable path is better than using /dev/sda directly because /dev/sda can theoretically change after reboot.
Part 2: Create /home2
Create the mount point:
mkdir -p /home2
chown root:root /home2
chmod 0711 /home2
Check it:
ls -ld /home2
Expected:
drwx--x--x root root /home2
Part 3: Stop DigitalOcean from auto-mounting the disk somewhere else
This was the important issue in our case.
DigitalOcean/systemd had created an auto-mount unit that kept mounting the disk at:
/mnt/volume_blr1_01
Check for such a mount unit:
systemctl list-units --type=mount | egrep 'home2|mnt.*volume|sda'
We found:
mnt-volume_blr1_01.mount
Inspect it:
systemctl cat mnt-volume_blr1_01.mount
It showed:
Where=/mnt/volume_blr1_01
What=/dev/disk/by-uuid/...
Type=ext4
So this unit was overriding our intended /home2 mount.
Disable it:
systemctl disable --now mnt-volume_blr1_01.mount
systemctl daemon-reload
Confirm it is no longer active:
systemctl list-units --type=mount | grep volume_blr1_01 || echo "not active"
Expected:
not active
cPanel has a support article on changing the mount point of a disk drive. It also notes that some providers automatically mount new drives under /mnt/..., and that the server owner or system administrator must handle these OS-level mount changes.
Part 4: Create a reliable systemd mount for /home2
Instead of relying only on /etc/fstab, we created a clean systemd mount unit.
Create:
nano /etc/systemd/system/home2.mount
Paste this, but replace the What= line with your actual DigitalOcean by-id path:
[Unit]
Description=Mount DO Volume at /home2
[Mount]
What=/dev/disk/by-id/scsi-0DO_Volume_volume-blr1-01
Where=/home2
Type=ext4
Options=defaults,nofail,_netdev
[Install]
WantedBy=multi-user.target
Save and exit.
Now enable and start it:
systemctl daemon-reload
systemctl enable --now home2.mount
Verify:
findmnt /home2
df -h /home2
Expected:
/dev/sda 100G ... /home2
or, after resizing:
/dev/sda 299G ... /home2
Part 5: Avoid duplicate mounts in /etc/fstab
Use either systemd mount or /etc/fstab, not both for the same mount.
If you had already added /home2 to /etc/fstab, comment that line:
cp /etc/fstab /etc/fstab.bak
sed -i 's#^\(.*[[:space:]]/home2[[:space:]].*\)$#\# \1#' /etc/fstab
Check:
grep -n '/home2' /etc/fstab
It should show the /home2 line commented with #.
cPanel’s /etc/fstab guide explains that storage devices can be added to /etc/fstab for boot-time mounting, but this is an operating-system task, not something cPanel manages directly.
Part 6: Configure WHM to recognize /home2
Go to:
WHM → Server Configuration → Basic WebHost Manager Setup
Set:
Default Home Directory: /home
Home Directory Prefix: home
Additional home directories: /home2
Use closest matching directory: Yes
Important distinction:
/home = default home directory
home = home directory prefix
/home2 = additional home directory mount point
Do not put /home2 in the Home Directory Prefix field.
cPanel’s support article on creating users on a different home directory explains that WHM has two relevant settings: the default location for new users’ home directories, and the additional home directory pattern. It also says that if multiple directories are available, the one with the most free space can be used automatically.
Part 7: Move existing cPanel accounts to /home2
You do not need DNS changes.
The domain still points to the same server IP. Only the local file path changes from:
/home/username
to:
/home2/username
GUI method
Go to:
WHM → Account Functions → Rearrange an Account
Select the account and move it to /home2.
cPanel’s Rearrange an Account documentation says this tool changes which home directory stores an account, useful when a server has another hard drive. It also warns that scripts using hardcoded paths may need to be updated.
CLI method
Replace USERNAME with the actual cPanel username:
/usr/local/cpanel/scripts/homemove USERNAME /home2
Verify:
grep ^HOMEDIR /var/cpanel/users/USERNAME
df -h /home2/USERNAME
Expected:
HOMEDIR=/home2/USERNAME
In WHM → List Accounts, the partition should show:
/home2
Part 8: Create new accounts directly on /home2
Sometimes WHM does not show a manual home directory field while creating an account. That is normal.
You can create an account directly on /home2 using CLI:
whmapi1 createacct domain=example.com username=user123 password='StrongPasswordHere' homedir=/home2
Or create normally and move it later:
/usr/local/cpanel/scripts/homemove user123 /home2
Part 9: Resize the DigitalOcean volume later
In our case, the volume was increased:
100 GB → 200 GB → 300 GB
After resizing in the DigitalOcean panel, WHM still showed the old size until the Linux filesystem was expanded.
This is normal.
DigitalOcean’s documentation explains that after increasing a volume size, you must expand the filesystem so the operating system can use the extra space. It also recommends taking a snapshot before resizing and notes that volume size cannot be decreased later.
Step 1: Check what Linux sees
lsblk -o NAME,SIZE,FSTYPE,MOUNTPOINT /dev/sda
If it shows the new size, continue.
If it still shows the old size, rescan:
echo 1 > /sys/class/block/sda/device/rescan
lsblk -o NAME,SIZE,FSTYPE,MOUNTPOINT /dev/sda
Step 2: Expand the ext4 filesystem
Because our /home2 volume used ext4, we ran:
resize2fs /dev/disk/by-id/scsi-0DO_Volume_volume-blr1-01
Then verify:
df -h /home2
Expected after 300 GB resize:
/dev/sda 299G ... /home2
DigitalOcean’s quickstart also states that after resizing a volume, ext4 filesystems should be expanded with resize2fs, while XFS filesystems use xfs_growfs.
Part 10: Final health checks
After everything is done, run:
df -h | egrep '/$|/home2$'
findmnt /home2
systemctl status home2.mount --no-pager
Check account locations:
awk -F= '/^HOMEDIR/{print $2}' /var/cpanel/users/* | sed 's#/[^/]*$##' | sort | uniq -c
This will show how many accounts are on:
/home
/home2
Common mistakes to avoid
1. Do not format an existing disk with data
Never run this on a disk that already contains accounts:
mkfs.ext4 /dev/sda
That destroys data.
Only format a brand-new empty disk.
2. Do not leave the DigitalOcean auto-mount active
If the volume keeps going back to:
/mnt/volume_blr1_01
check:
systemctl list-units --type=mount | grep volume
Disable the old unit:
systemctl disable --now mnt-volume_blr1_01.mount
systemctl daemon-reload
3. Do not confuse WHM fields
Correct:
Default Home Directory: /home
Home Directory Prefix: home
Additional home directories: /home2
Wrong:
Home Directory Prefix: /home2
4. No DNS change is required
Moving an account from /home to /home2 does not change:
Domain
IP address
Nameserver
DNS zone
Mail routing
DNS changes are only needed if you change the server IP, move to another server, or change nameservers.
Quick copy-paste version
Mount new DO volume as /home2
lsblk -f
ls -l /dev/disk/by-id/ | grep -i DO_Volume
mkdir -p /home2
chown root:root /home2
chmod 0711 /home2
systemctl list-units --type=mount | grep volume || true
systemctl disable --now mnt-volume_blr1_01.mount
systemctl daemon-reload
cat >/etc/systemd/system/home2.mount <<'EOF'
[Unit]
Description=Mount DO Volume at /home2
[Mount]
What=/dev/disk/by-id/scsi-0DO_Volume_volume-blr1-01
Where=/home2
Type=ext4
Options=defaults,nofail,_netdev
[Install]
WantedBy=multi-user.target
EOF
systemctl daemon-reload
systemctl enable --now home2.mount
findmnt /home2
df -h /home2
Move account to /home2
/usr/local/cpanel/scripts/homemove USERNAME /home2
grep ^HOMEDIR /var/cpanel/users/USERNAME
df -h /home2/USERNAME
Resize volume after increasing size in DigitalOcean
lsblk -o NAME,SIZE,FSTYPE,MOUNTPOINT /dev/sda
echo 1 > /sys/class/block/sda/device/rescan
lsblk -o NAME,SIZE,FSTYPE,MOUNTPOINT /dev/sda
resize2fs /dev/disk/by-id/scsi-0DO_Volume_volume-blr1-01
df -h /home2
Useful official resources
- cPanel: Basic WebHost Manager Setup — home directory and additional home directory settings.
- cPanel: Create new users on a different home directory.
- cPanel: Change the mount point of a disk drive.
- cPanel: Add storage devices to
/etc/fstab. - cPanel: Rearrange an Account.
- DigitalOcean: Increase the size of Volumes Block Storage.
- DigitalOcean: Volume quickstart and filesystem expansion notes.