The disk (or 2 disks in a RAID 1) of a server is running full (96 %). I want to add a new SSD (not being part of the RAID).
What I don't understand is how or where to mount it, so I can use it seamlessly within the existing structures.
How do I mount sub-directory to a hard drive in Linux? doesn't make me smarter, even if it's probably what I am looking for.
I have something like /var/www/vhosts/example.com/httpdocs/images/dirA
.
Since it is important for me that the web servers (Apache and nginx) can access the files on the new disk immediately, I think I have to mount it somewhere inside of /var/www/vhosts/example.com/httpdocs/
so it won't end in limited access.
So can I just create /var/www/vhosts/example.com/httpdocs/images/dirB
and mount the new disk there? Will it affect the RAID in any way?
Or is it maybe more advisable to mount it "outside", like /newDiskX
and then symlink /newDiskX
to /var/www/vhosts/example.com/httpdocs/images/dirB
?
What I've understood from https://unix.stackexchange.com/questions/198542/what-happens-when-you-mount-over-an-existing-folder-with-contents is that I can't mount it directly to /var/www/vhosts/example.com/httpdocs/images/dirA
without complications or actually gaining more space overall.
My problem is, that I have only "one shot" and I can't do it myself; I have to tell my hoster to install the new disk and where to mount/bind/link it.
EDIT:
To visualize it, here the current/planned structure:
/
├── A/ (existing on old disk)
| ├── B/ (existing on old disk, access point for Apache etc.)
| | ├── C/ (existing on old disk)
| | | └── file.tmp (existing on old disk)
| | ├── D/ (existing on old disk)
| | ├── file.tmp (existing on old disk)
| | └── E/ (existing on old disk)
| | └── X/ (new to be on new disk)
| └── other stuff