Prerequisites
You'll need the following before continuing:
-
Server DNS name or IP address
-
Share name
Windows 10
On-Demand mount
-
Open the 'Run' menu
-
Press
-
Open it from the Start menu
-
Enter the following command:
Substitute the following
SERVER
- Server’s DNS name or IP address
SHARE-NAME
- The share name you are connecting to\\SERVER\SHARE-NAME
-
Persistent mount
-
Open
This PC
from the start menu -
Click
Map network drive
from theComputer
tab -
Select the drive letter you would like to map the share to
-
In the
Folder
field, enter the following:
Substitute the following
SERVER
- Server’s DNS name or IP address
SHARE-NAME
- The share name you are connecting to
\\SERVER\SHARE-NAME
-
If you're not using your domain account to authenticate against the NAS, then click
Connect using different credentials
and enter your login for the NAS. -
Ensure
Re-connect at sign-in
is ticked -
Click
Finish
-
The drive will now be mounted each time the user logs in
Mac OS X
On-Demand mount
-
Open the 'Finder'
-
In the 'Go' menu, click 'Connect to server'
-
Enter the following:
Substitute the following
SERVER
- Server’s DNS name or IP addressSHARE-NAME
- The share name you are connecting to
smb://SERVER/SHARE-NAME
-
Click 'Connect'
-
You may be asked for your credentials enter your username as follows:
Domain/AD account:YOUR-DOMAIN\username
NAS credentials:SAMBA\username
-
Enter your password
-
Optionally, click 'Remember this password in my keychain'
-
The share will now be mounted
Persistent mount
-
Follow the steps in the 'On-Demand mount'
-
From the 'Apple' menu, select
System Preferences
then selectUsers & Groups
-
Under your user, go to the
Login items
tab -
Drag and drop the network drive icon into the list
You will be prompted for credentials each time you connect to the share unless you select ‘Remember this password in my keychain
’
Linux
Centos & Redhat
On-Demand mount
-
Create a folder to mount the share onto. For example:
mkdir /mnt/share
-
Run the following command in the terminal/command line:
Substitute the following
SERVER
- Server’s DNS name or IP address
SHARE-NAME
- The share name you are connecting to
USERNAME
- Your username
PASSWORD
- Your password
DOMAIN
- If using Active Directory users, this should be your domain, otherwise enterSAMBA
as the domain
mount.cifs \\\\SERVER\\SHARE-NAME /mnt/share -o domain=DOMAIN,user=USERNAME,pass=PASSWORD,vers=3.0,dir_mode=0777,file_mode=0777
Persistent mount
Modifying system files incorrectly can cause the machine to become un-bootable, do this at your own risk.
-
Create a folder to mount the share onto. For example:
mkdir /mnt/share
-
Create a credential file somewhere secure, we'll create a file called
/root/creds.txt
:domain=ExampleDomain username=ExampleUsername password=ExamplePassword
-
Secure the file:
chown root:root /root/creds.txt chmod 400 /root/creds.txt
-
Modify the file system mount file, place the line below at the bottom of the config file:
Substitute the following
SERVER
- Server’s DNS name or IP addressSHARE-NAME
- The share name you are connecting to/etc/fstab
\\SERVER\SHARE-NAME /mnt/share cifs credentials=/root/creds.txt,vers=3.0,dir_mode=0777,file_mode=0777,_netdev,nofail 0 0