With SAMBA/CIFS, you can mount your Storage Box into the local file system of a client device (e.g. your local computer). After everything is setup, you can access your Storage Box data via the local file system of your own device.
Before you follow this how-to guide, open the overview of your Storage Box in Hetzner Console to check if SMB support is enabled. If not, select the action "Change settings" and enable SMB support. After you activate SMB, it can take a few minutes before you can access your Storage Box via WebDAV.
General information:
- Connections using SAMBA may not be automatically encrypted. However, some Windows versions use encryption by default.
- If you use a FritzBox Router from AVM, you need to deactivate the NetBIOS filter for Samba/CIFS to work. Please check the AVM knowledge base for more information. (FritzBox documentation)
-
Prepare the access details
To mount the Storage Box into the local file system, you have to provide the address that points at the directory of your user. Provide the domain in the following format:
-
Main user
The share name is
backup
u#####.your-storagebox.de/backup
-
Sub account
The share name is your username
u#####-sub#.your-storagebox.de/u#####-sub#
-
-
Mount the Storage Box
The next steps are different depending on the operating system of your device. Click on one of the options below to view the respective steps.
-
Install CIFS
If CIFS is not installed yet, install it now. In Debian-based distributions, the command is provided via the package
cifs-utils
:apt-get install cifs-utils
Additionally, add the following line in
/etc/rc.local
:modprobe cifs echo 0 > /proc/fs/cifs/OplockEnabled
-
Create a mount point
You can mount the Storage Box on any directory. However, you should mount your Storage Box on an empty directory. If you mount your Storage Box on a directory with data, it is not possible to access this data until the Storage Box is unmounted again. To avoid issues like this, you can just create a new direcotry, for example in
/mnt
:mkdir /mnt/my-storage-box
-
Manually mount the Storage Box directory
For this session, you will have to mount the file system manually. If you add the file system and its mount point to the
fstab
file, the system will automatically mount your file system at every reboot. This step is optional and will be explained below.Use this command to mount the file system of the Storage Box on the new directory:
Replace
<username>
,password
, the address, and/mnt/my-storage-box
with your own information.mount.cifs -o seal,user=<username>,pass=<password> //<username>.your-storagebox.de /mnt/my-storage-box
To encrypt a SAMBA connection, you need the
seal
option. Note that this feature is only available in newer Linux versions (e.g. starting with Ubuntu 18.04). -
Test access
Navigate to the directory on which you just mounted the Storage Box. The directory should now contain all data of your Storage Box.
-
Add an entry in
fstab
The
fstab
file contains file systems and all related mounting options. All file systems that are listed in/etc/fstab
are automatically mounted at a reboot.Edit
/etc/fstab
and add the following line:Replace the address and
/mnt/my-storage-box
with your own information.//<username>.your-storagebox.de/backup /mnt/my-storage-box cifs iocharset=utf8,rw,seal,credentials=/etc/backup-credentials.txt,uid=<Systemkonto>,gid=<Systemgruppe>,file_mode=0660,dir_mode=0770 0 0
To encrypt a SAMBA connection, you need the
seal
option. Note that this feature is only available in newer Linux versions (e.g. starting with Ubuntu 18.04). -
Add an entry in
/etc/backup-credentials.txt
To automatically mount the Storage Box directory at reboot, the system needs your access details to the Storage Box. Add this line in
/etc/backup-credentials.txt
:Replace
<username>
and<password>
with your own information.username=<username> password=<password>
The file should have the following permissions:
chmod 0660 /etc/backup-credentials.txt
-
Create a mount point
You can mount the Storage Box on any directory. However, you should mount your Storage Box on an empty directory. If you mount your Storage Box on a directory with data, it is not possible to access this data until the Storage Box is unmounted again. To avoid issues like this, you can just create a new direcotry, for example in
/mnt
:mkdir /mnt/my-storage-box
-
Add an entry in
fstab
The
fstab
file contains file systems and all related mounting options. All file systems that are listed in/etc/fstab
are automatically mounted at a reboot.Edit
/etc/fstab
and add the following line:Replace
<username>
andbackup
with your own username and share name.//<username>/backup /mnt/my-storage-box smbfs rw,-N,-I=<username>.your-storagebox.de,-U=<username> 0 0
-
Add an entry in
/etc/nsmb.conf
To automatically mount the Storage Box directory at reboot, the system needs your access details to the Storage Box. Add this line in
/etc/nsmb.conf
:Replace
<username>
and<password>
with your own information.[<username>] charsets=UTF8:UTF8 [<username>:<password>] password=$$crypt-string
Create the crypt-string with
smbutil crypt
. -
Open the Windows Explorer
In the Windows Explorer, navigate to "Map network drive":
-
Windows 10: On the left, click on This PC. And then at the top, click on Computer and then on Map network drive.
-
Windows 11: On the left, click on This PC. And then at the top, click on the three dots and then on Map network drive.
-
-
Connect the network drive
A new window should have popped up.
-
Select a network drive letter of your choice.
-
Enter your Storage Box address as folder, for example:
Replace
<username>
andbackup
with your own username and share name.\\<username>.your-storagebox.de\backup
-
Check the option "Reconnect at login", if you want to automatically establish a connection upon starting the system.
-
Click on Finish.
-
-
Provide login credentials
When you are asked for login information, you should enter the username and password you used for your Storage Box. Or as an alternative, you can save the login information in Windows.
-
Access data
The setup of your Storage Box as a network drive should now be finished and you should be able to find it as a separate drive under This PC (Windows 10/11).
Linux
FreeBSD
Windows
In Windows, you can connect your Storage Box as a network drive with its own drive letter.
-
Known Issues
-
Error with files larger than 4 GB
If there are errors when copying files that are 4 GB or larger, then it can help to deactivate caching. To do so, you need to mount the Storage Box with the extra parameter
-o cache=none
.
-
You should now be able to access your Storage Box data via the local file system on your device.