How to mount a second hard drive? Debian
Solution 1:
All the files on /var/www/disk2 wont count towards the space on first drive.
Solution 2:
Everything that is written to the filesystem under a mount point is stored to whatever drive is mounted there, not the drive that contains the mountpoint.
For example /dev/sda1 is mounted at /, and /dev/sdb1 is mounted at /home: Writing a file to /home/user/file will only use space on /dev/sdb1, it has no effect whatsoever on the filesystem contained on /dev/sda1. The only thing that is on /dev/sda1 is the /home directory entry.
If by some chance, /dev/sdb1 was not mounted, then whatever is written to /home would then be on the filesystem contained on /dev/sda1.
Issue the mount command without any arguments to get a list of what is mounted and where.