Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
storage:smb [2017/01/12 15:55]
eServices Greece
storage:smb [2018/01/09 12:28] (current)
eServices Greece
Line 19: Line 19:
   * Click on **Connect using different credentials**   * Click on **Connect using different credentials**
   * Click on **Finish**   * Click on **Finish**
-{{ :storage:mapnetworkdrive.jpg?direct&200 |}}+
 Windows will ask you for your credentials (Username and Password) and after you enter them correctly it will open your cloud storage in File Explorer. Windows will ask you for your credentials (Username and Password) and after you enter them correctly it will open your cloud storage in File Explorer.
 +<WRAP group>
 +<WRAP half column>
 +{{ :storage:fileexplorer-menu-computer.jpg?direct&300 |File Explorer - Computer Menu}}
 +{{ :storage:mapnetworkdrive.jpg?direct&300 |Map Network Drive}}
 +</WRAP>
 +<WRAP half column>
 +{{ :storage:mapnetworkdrivecredentials.jpg?direct&300 |Credentials}}
 +</WRAP>
 +</WRAP>
  
 +==== Disconnect Network Drive ====
 +In order to disconnect your network drive:
 +  * Open a **File Explorer**
 +  * Find the Network Drive in the list and right click on it
 +  * Click on **Disconnect**
 +{{ :storage:mapnetworkdrive-disconnect.jpg?direct&300 |Disconnect Network Drive}}
  
 +===== Command Line =====
 +In a console that has administrative permissions:
  
 +==== Mount as Network Drive ====
 +<sxh>net use q: \\mystorage.cs.esgr.in\backup</sxh>
 +This will mount the cloud storage on Drive Letter Q:
  
-==== Command Line ==== +==== Mount under UNC Path ==== 
-In a console that has administrative permissions: +<sxh>mklink /D C:\%userprofile%\MyStorageFolder \\mystorage.cs.esgr.in\backup</sxh>
-  * mklink /D C:\%userprofile%\MyStorageFolder \\mystorage.cs.esgr.in\backup+
 This will mount the cloud storage in a folder called //MyStorageFolder// inside your user profile. This will mount the cloud storage in a folder called //MyStorageFolder// inside your user profile.
 +
 +===== Linux =====
 +
 +==== Required Packages ====
 +<sxh bash>
 +yum install samba-client samba-common cifs-utils
 +</sxh>
 +
 +==== fstab ====
 +We will assume your user in the system is **myuser** \\
 +Add an entry in your fstab like this:
 +<sxh>//mystorage.cs.esgr.in/backup /home/myuser/mystorage cifs user=user1234,pass=WMacuuvnnxaKuiwBTrn2,iocharset=utf8 0 0</sxh>
 +
 +=== Protecting the Username & Password ===
 +In order to avoid the leaking of username & password you can do the following:
 +
 +Create the file ~/.smbcredentials:
 +<sxh>touch ~/.smbcredentials</sxh>
 +
 +Add the following inside the smbcredentials file:
 +<sxh>username=user1234
 +password=WMacuuvnnxaKuiwBTrn2</sxh>
 +
 +Change the permissions of the file to be readable only from your id:
 +<sxh>chmod 600 ~/.smbcredentials</sxh>
 +
 +Change the fstab entry to be like this:
 +<sxh>//mystorage.cs.esgr.in/backup /home/myuser/mystorage cifs credentials=/home/myuser/.smbcredentials,iocharset=utf8 0 0</sxh>