Mailboxes on different disk?

NethServer Version: latest
Module: mail

I want to setup a Nethserver for a friend in a KVM system.
I want to install NS in a vdisk that is in his faster-smaller disks BUT I would like actual mailboxes of NS based mail server to use the second vdisk I want to have on larger-slower disks.

How can I implement this?

This could be a hint…
Don’t install Nethserver, but install CentOS 7. Then edit your configuration for mount in /var/lib/nethserver your “data” disk.
Ensure to fully update the installation.
Then “Nethify” as illustrated into documentation.
Create adequate documentation for reinstallation and restore among the disaster recovery instructions.

Downsides
This arrangement don’t work if you want to recover from bare metal starting from NethServer ISO.
This arrangement will put all NethServer “data” into a slower disk

Details about the path /var/lib/nethserver
https://docs.nethserver.org/en/v7/search.html?q=%2Fvar%2Flib%2Fnethserver%2F&check_keywords=yes&area=default
Documentation about to install NethServer on top of CentOS 7.
https://docs.nethserver.org/en/v7/installation.html#installation-centos

This suggestion can be refined for mailboxes only, leaving databases and other files like Samba share on the faster-smaller disk, but the mileage may vary for different desires.
If this custom filesystem structure is going to be the solution, try to break the installation several times for write down some verified steps/howto repair, restore, recreate the installation.

More time spent and issues found into setup stage, less tears, sweat and blood in case of troubles.

Also, this is only an idea, probably not the best one. Take your time to consider.

I don’t use much of the features of NS except the mail server.
At least for the install I plan to make for that friend.
Note (again) that the install will be as a VM in an UNRAID server (I already have used this setup before).

I just want to use a different vdisk for mailboxes, nothing else (there is plenty of space for the rest even on smaller disks).

My goal for the details was to letting you know what are the thing that can go wrong for what is my knowledge.

UNRAID VM installation is worth for some notes to share? Maybe could also spread the word for UNRAID users… :wink:

I definitely don’t want to install a clean CentOS and NS over it.
Even using symlinks will be enough if someone tells me what should point where.

Last NS on UNRAID I did was maybe a couple years ago (still fully working) and I don’t remember specific details if something should be noted down.
Will see when I do my next install (the one I am talking about here).

Would you please share why?

If you search for “symlinks” into community you will find some experiences for who used larger disk for file shares. And a “look for solution” for a restore of a poster, that took quite several steps to take place :sweat_smile:

I want the simplicity of installing using a single ISO and following simple setup steps.
As for symlinks I know how to use them (in general).
The problem is specific: Having mailboxes on different disk.
I don’t even know where the mailboxes are in an NS install.

I could totally miss the point, but if simplicity is the key point, personally I would pick a single mountpoint installation (or “one vdisk”). Only choose the “right vdisk” for your friend use.
Also… Consider that giving “a bit more RAM” than necessary won’t completely fill the snappiness gap between smaller-faster and larger-slower disks, but also make them a lot less painful to feel.

Just explaining my personal point of view :slight_smile:

I am still debating of indeed using a single disk (as is the default NS install) and that disk to be a vdisk on the slower larger disks, instead of “splitting” the install somehow.
Would be nice though. There must be a directory where mailboxes are that I can move and symlink to it.

I will use more RAM indeed. I don’t think with just 6-7 maiboxes (and VERY few other services) the users will notice much slowness.

@NLS

Hi Nick

I’d suggest a much simpler way:

Install NethServer as usual from it’s ISO image to your planned / prepared VM.
After the installation, add in a second VM Disk, making sure it is on the right underneath hardware disk / raid you’re planning to use.

Format with XFS, as NethServer itself uses that. (Less issues with Backup, Disaster Recovery, etc…).

Then create a simple symlink!

Use /var/lib/nethserver/vmail…

If all fails, it’s simple to reinstall, and symlink the second VM disk…
NethServer Disaster Recovery will also work, you just need to check the symlink.
NethServer’s built in backup will also work, but I’d still suggest saving the whole VM using whatever you use on your Hypervisor - I am a Proxmox user… :slight_smile:

My 2 cents
Andy

1 Like

This is the reply I was waiting for. Thanks.

1 Like