Nethserver 8 & samba shares location

Hi,

This is going to sound like a stupid question…

But in Nethserver 8, how can i define the default locations/disks for samba shares, this was an option in version 7 but for the life of me i can’t find it in version 8.

Any help appreciated.

Karl

We don’t have a preferred method yet. Some approaches were discussed in this thread:

As an alternative, the disk could be mounted under a volume _data/ path, but I prefer the previous approach because it preserves[1] disk data if the module is removed and doesn’t rely on Podman’s default volume path.


  1. Adding --one-file-system argument to rm -rf of remove-module action could be a future improvement. ↩︎

Thanks for the info Davide.

Seems a bit of an oversight for this not to have been included in the setup for Samba shares though.

E.G you create a hardware server with a small NVME for the OS and large redundant Drives for data, but shares will only be created on the original installation target drive.

Anyhoo thanks for the heads up.

4 Likes

What you’ve described is a reasonable scenario, and we’ll work on improving NS8 to address it.

3 Likes

Hi,
I fully support the suggestion of @uncle_numpty , so we can put the small actually needed data shares on fast OS-disk or separate SSD, and the very large archieved data-stores on slower but much bigger spinners, instead of using separate NAS.
By the way (haven’t took a deeper look until now), how to put the maildir on a separate larger disk ?
Greetings, Mario

3 Likes

@davidep
First of all, thanks for all the work done on Nethserver 8.

I did a test and saw that Samba stores the shared folder in /home and it is considered good practice to point the home folder to a dedicated partition. Is there any advice on pointing the home folder to a disk dedicated to Samba? That would solve my problem.

Hi Fernando, welcome to our community!

We are still working on improving support for different storage
configurations tailored to specific tasks. Here’s what we currently have:

  • A single small, fast disk for everything, which works well for test and
    small installations.
  • A small, fast root disk with /home mounted on a separate small and
    fast disk. Rootless modules still require a fast disk to read container
    images, especially during service startups. You can find a script in the
    manual to help move /home to a new disk
    here.

In the coming weeks, we plan to add support for a third scenario: allowing each volume of every module instance to be mounted to a custom location. This would accommodate large, slower disks or even remote filesystems.

6 Likes

Are there any progress on this? Having the option to define the location.

Not that much. As we can see on the project board, a complete feature is not coming soon: NethServer · GitHub.

We are experimenting with the alternative home path for new modules, which also requires some SELinux setup on EL distros. The patch is available here: Define HOME_BASEDIR node variable by DavidePrincipi · Pull Request #772 · NethServer/ns8-core · GitHub.

1 Like

The alternative home path for modules is a good idea. I think it is safe to assume that /home will eventually grow to a size that is less ideal to store on costly SSD/NVMe storage.
I understand the importance of having the containers on low latency storage, but I think it is generally accepted that network file storage(like Samba shares) can reside on older spinner drives.
Although it is fairly simple to move /home to an extra disk (spinner drive), we would be in a much better position to optimize it by specifying the foldera for each samba share.
Certain Samba shares I would optimize/backup and some are just for “junk” storage that don’t need backing up.

1 Like

Think again, we have 2025 now!

No PC or notebook you can buy uses spinners anymore, people are used to extremly fast disk responces. And this for over 5 years now…

Only older people (Add me in!) accept spinners.

And: If spinners, only Enterprise class, with 7200 or 10K RPM…

And a lot expect - if spinners, at least 1-2 cache SSDs…

→ Reality Check!

My 2 cents
Andy

1 Like

Hi Andy,

Thank you for sharing your thoughts! Noted and you’re absolutely right that disk performance expectations have shifted drastically over the past several years. SSD/NVMe have indeed become the norm for consumer devices, and their blazing speeds have reshaped what users expect from storage systems.

While spinners are still around, they’ve certainly carved out a more niche role, primarily in enterprise settings or for bulk storage. The 7200 RPM and 10K RPM enterprise-class drives you mentioned, often paired with caching SSDs, highlight how even traditional HDD setups aim to keep up with modern demands, like you point out.

That said, in my eyes, spinners remain an acceptable and cost-efficient storage solution, especially when considering the bigger picture. Many end users still rely on crappy Wi-Fi connections for their office laptops and offsite cloud services, both of which introduce much higher latencies than those found in older spinner drives on a local NAS.

It’s important to consider how evolving technology shapes user habits and expectations, but also to recognize that cost-effective solutions like spinners still have their place in many scenarios and budgets. Having the flexibility to determine the best storage options—and by extension, the placement of different parts of a system—within a given budget is crucial.

Hi @TheManWithOnlyOneArm

Don’t ever forget a major advantage spinners have over todays digital storage:

They come with built in “acoustic feedback”, not only SMART software. You can usually hear in advance before they die.
Digital storage dies quietly. One moment they work, the next moment they’re dead…

Even though no one actually “like” hearing grinding or clicking noises coming from their disks, it’s still there!

For long term storage, good spinners are still a good option. But no “reused” disks like “I have an old 1TB disk from my PC which is still usable…”.
Well planned and implemented, a good Spinner / SSD cache combo can be an excellent choice.

It all depends on what’s needed, what’s planned and what the budget allows…

I’ve supported clients having backup solutions encompassing full 10 GB/S redundant fiber connectivity - and fully NVMe equipped large servers.
But when your institution is moving 7-12 digit figures daily, you need adequate storage and backup solutions!

If you’re on the market, a SEC fine (or whatever) might entail much higher costs than a few thou for hardware!

:slight_smile:

My 2 cents
Andy

1 Like

Andy:
I’m new to this forum(and Nethserver) and you seem very dedicated to Nethserver solutions. What is your take on the current storage configurations provided by NS8?

Hi Nick

I am 60 now, and been working in Networking since 40+ years, from large corporations to what I now prefer, SME (Small and Medium Enterprises).

I like the fact that Debian is now offered as a base platform, I’ve been using Debian before RedHat came on the scene. I do not trust anything Big Blue or Red Hat anymore.

I am one of the first users of virtualization, I started with VMWare before they actually became a company! (Before 2000 !) I moved on to Proxmox in about 2015, as a much better solution, be it supported hardware.

Since about 10 years now, I have hardly installed any servers without virtualisation underneath.
Rock solid disaster recovery - without ANY driver issues, even on new, different hardware.
Fast live migrations, free clustering and HA options. And so simple pricing:

I use for all clients the community option, that’s about 100 USD per CPU socket (Not per cores!) and entails me to the enterprise repo. This provides about 30% less reboots / year, important for my clients!

As such, I don’t have much issues with Storage. It’s all handled by Proxmox, and dedicated Shared Storage (NAS, mostly RAID10, 4 SSDs or NVMEs nowadays), and Enterprise Spinners for LongTerm.

Here’s a simple example:

Synology DS1819+ NAS, 2 Volumes. RAID10 for VM Storage, RAID5 for Long Term.
Long Term ist synched to an identical NAS at Home for Offsite Backup, VMs use PBS locally and Offsite.

A small starter for Virtualization can be found here:
https://wiki.nethserver.org/doku.php?id=userguide:nethserver_and_proxmox
(I wrote that in 2020, most is still valid!)

I’ve been using SME Server (A predecessor of NethServer) since about 2010, and in 2016 moved to NethServer.

I am known on this forum as the local Proxmox Guru (or Matador or whatever).
I’ll admit to nudging a lot of users, devs, supporters to move to Proxmox - but all for the best, and none so far regretted their move!

I’m also known here for pushing Zabbix, an enterprise monitoring solution.

I am available for a free Anydesk / Telegram (Audio, nothing from Zucki!) session to show you the possibilities, and how a small SME can use IT like a huge global corporation!

Drop me a PM, and I’ll provide details.

My 2 cents
Andy

Hi old boy, :smile:

Welcome in the club. But remember that 60 is the new forty.

2 Likes

Very impressive, and thank you for offering to assist!
However, in relation to the thread, what is your perceiption on the current storage configurations provided by NS8?
Do you feel that the current offering, limited to Samba, is sufficient for most installs? I do not have any data on the avg. size Nethserver installation, but I assume that they come in all shapes and sizes.
I realize that you often work with larger systems, where dedicated NAS is a must. But what if you only had a single Nethserver to work with? Would that be sufficient or would you feel a bit restrained?

I would feel highly restrained, and in constant stress of disaster situations.
I do prefer the relief a virtualization offers, even in small and smallest enviroments.

And: I’m a longtime advocate of a dedicated firewall, mostly OPNsense.

See this “One User” SOHO environment:

A single small Proxmox Server (Odroid H3+ based, very low power consumption!), an older HP Microserver, repositioned as PBS, and a small 4 bay Synology NAS.

With a single NethServer, where would you put backups of the PC and of the Mac?
On expensive NethServer Storage? :slight_smile:
And where would you put backups of NethServer?
I do not trust USB attached stuff on a server, nor would I trust a connected disk from a compromised system…

I can restore the VM PC, providing RDP access, on ANY hardware, no matter if Intel or AMD, within 30 minutes flat. No driver issues whatsoever. That gives me peace of mind.

The same peace of mind I have at a doctors practice, where all X-Ray images (DICOM) are stored and managed by a virtualised System (Mac!), which I can restore on any sufficient powerful hardware…

My 2 cents
Andy

Both Univention and Zentyal offers the option of defining(within the GUI) the location(filesystem path) of each Samba share separatly.
Using Proxmox, you can then define if you want your data on the same virtuel disk or splitting each one up in separate virtual drives, in different pools with different backends(spinner, nvme, ssd, etc.) and if you even want to back them up.
I am really missing this feature.

2 Likes

I understand your problem very well. Choosing the right drive (size, speed, security) for each service (or container) should always be within the administrator’s control. Traditionally, Linux offers reliable and transparent methods for this (via path mounts) that work seamlessly with nearly any application. Conversely, every Linux application should not only support these methods but must never sabotage them.

This freedom is essentially available with Neth8 as well—not only with the /home directory but also deeper within the container structure. And it works reliably at first—until Neth8 takes the liberty, during restores, migrations, or upgrades, to independently define or rename container paths (incremental numbering). At this point, you can forget your mounts, and thus the service as well. For me, this is a major issue.

I’m glad the developers have now recognized the problem (choosing the right drive for the purpose) and I’m eagerly waiting for this feature. However, I disagree with their basic approach to solving it. From what I’ve been told about this concept, Neth8 would still decide where my data ends up. Moreover, drive assignment would apply to the entire container, and within the container, I still wouldn’t have the freedom to decide—just because of this ridiculous, arbitrary numbering system.

But I personally don’t want the entire Samba container on a single drive. I want to determine this for each share individually. Similarly, I’d like to assign individual mailboxes (e.g., the mail archive) to specific drives. This concept doesn’t support that, so it doesn’t help me.

Now, the developers aren’t responsible for my specific requirements; that’s entirely my responsibility. And I can handle it myself—if only Neth8’s relentless numbering system didn’t interfere.

There are plenty of straightforward ways to fix this.
I understand why the naming convention is as it is and that /home is the simplest approach (due to user permissions). Even if that’s necessary, it should still be possible to find a suitable solution.

The best option would be to ask the admin before creating containers (creating, duplicating, restoring, migrating, importing) where they should be stored (within /home or elsewhere) and then permanently respect that decision—no exceptions.

Possible Solutions:

1a. Before creating a container, ask which parent directory should be used (e.g., /home , /mnt/ssd1 , /mnt/hdd2 ).
Neth8 would still determine the container name itself (using the existing scheme to check for prior existence). The target drive (path) would be pre-defined or mounted by the admin, and the reliability of the mount could be verified upon restart before creating, restoring, or moving the container.

1b. Before creating a container, ask for the desired container name (within the naming convention, e.g., samba100 ).
If the directory or its contents already exist, offer to empty it and adjust permissions (unless it’s an active container).

1c. At the very least, display the future path (including container name) before creating the container and wait for admin input (if necessary, pause to allow a persistent mount). The admin could then create the correct mount, and Neth8 would adjust permissions.

2. Pin the container path immutably for Neth8 in all variants.
This would allow for deeper custom mounts. Such pinning should only be enabled by the admin.


For My Needs:

For my purposes, it would be almost sufficient if:

  1. Before creating any container, the future name is displayed (and interaction is awaited).
  2. Instead of checking for the existence of the target folder (container name), offer to adjust permissions (or clear the folder) instead of unnecessarily and arbitrarily incrementing the numbering.

This seems so obvious to me (and the latter should be relatively easy to implement) that I hardly dare suggest it to the developers again.

Implementing a polished process for the “typical” Neth8 user—including automatic mount creation and a nice GUI—is, of course, more complex and time-consuming. But let’s wait and see—maybe someone will take pity and implement the simple solutions alongside it?

2 Likes