Site Tools


linux:general:mount

Differences

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

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
linux:general:mount [2019/06/06 13:07] lunetikklinux:general:mount [2020/01/09 16:36] (current) lunetikk
Line 1: Line 1:
 ===== Mount networkshares ===== ===== Mount networkshares =====
 +
 +==== Clientpackages to mount shares ====
 +
 +CIFS:\\
 +<code>apt-get install cifs-utils</code>
 +
 +NFS:\\
 +<code>apt-get install nfs-common</code>
  
 ==== Temp. mount ==== ==== Temp. mount ====
Line 47: Line 55:
  
 Insert in "/etc/fstab" Insert in "/etc/fstab"
-<code><server>:/share       /<mountpoint>   nfs     rw,bg,hard,vers=4.0,suid,timeo=600,noatime,rsize=65536,wsize=65536,sec=sys 0</code>+<code><server>:/share /<mountpoint> nfs rw,bg,hard,vers=4.0,suid,timeo=600,noatime,rsize=65536,wsize=65536,sec=sys 0</code>
  
 Execute Execute
 <code>mount -a</code> <code>mount -a</code>
  
-==== Commands ====+===== Versions ===== 
 + 
 +==== CIFS ==== 
 + 
 +^  Version  ^  Description 
 +|  %%vers=3.0%%  |  SMB3 i.e. Windows 8 and up, Windows Server 2012 and up  | 
 +|  %%vers=2.1%%  |  SMB2_10 i.e. Windows 7, Windows Server 2008 R2  | 
 +|  %%vers=2.0%%  |  SMB2_02 i.e. Vista SP1, Windows Server 2008  | 
 +|  %%vers=1.0%%  |  NT1 i.e. Windows 95, NT 4.0  | 
 + 
 +===== Commands =====
  
 ^  Command  ^  Function  ^ ^  Command  ^  Function  ^
-|  showmount -e <nfsserver>  |  show available nfs shares +|  %%showmount -e <nfsserver>%%   show available nfs shares 
-|  mount -t nfs <server>:/<share> /<mountpoint>  |  mount a nfs share  | +|  %%mount -t nfs <server>:/<share> /<mountpoint>%%   mount a nfs share  | 
-|  mount -t cifs //<server>/<share>/ /<mountpoint>  |  mount a cifs share  |+|  %%mount -t cifs //<server>/<share>/ /<mountpoint>%%   mount a cifs share  | 
 + 
 +===== Troubleshooting ===== 
 + 
 +==== Cant mount Windowsshares (CIFS) on Linux ==== 
 + 
 +=== Description === 
 + 
 +Mounting your share leads to the following error 
 + 
 +<code> 
 +mount error(9): Bad file descriptor 
 +</code> 
 + 
 +=== Reason ===  
 + 
 +Microsoft released an Update (January 8, 2019 (Monthly Rollup)) which broke smb2.0 and 2.1 connections.\\ 
 + 
 +The issue affect Windows 7 and Windows Server 2008 (R2). 
 + 
 +[[https://www.theregister.co.uk/2019/01/09/windows_7_network_broken/|https://www.theregister.co.uk/2019/01/09/windows_7_network_broken/]] 
 + 
 +[[https://serverfault.com/questions/948263/kb-4480970-and-or-kb-4480960-breaks-smb2-connections-to-windows-7-shares|https://serverfault.com/questions/948263/kb-4480970-and-or-kb-4480960-breaks-smb2-connections-to-windows-7-shares]] 
 + 
 +=== Fix ===  
 + 
 +Microsoft released a fix to fix their update... m( 
 +<code> 
 +This update resolves the issue where local users who are part of the local “Administrators“ group may not be able to remotely access shares on Windows 7 SP1 and Windows Server 2008 R2 machines after installing the January 8th, 2019 security updates.  
 +This does not affect domain accounts in the local "Administrators" group. 
 +</code> 
 + 
 +Download KB4487345 and install the fix: [[http://www.catalog.update.microsoft.com/Search.aspx?q=KB4487345|KB4487345]] 
 + 
 + 
 +==== CIFS share is mounted but permission is denied ==== 
 + 
 +=== Description === 
 + 
 +Listing the files doesnt work because of missing permission 
 +<code> 
 +ll /<mount> 
 +ls: reading directory /<mount>/: Permission denied 
 +total 0 
 +</code> 
 + 
 +=== Reason ===  
 + 
 +Wrong CIFS version 
 + 
 +=== Fix ===  
 + 
 +Add the correct version (vers=1.0/2.0/2.1/3.0) as an option 
 +<code> 
 +# in /etc/fstab as perm. mount 
 +//<server>/<share> /<mountpoint> cifs credentials=</root/.smbcreds>,iocharset=utf8,sec=ntlm,vers=3.0 0 0 
 + 
 +# temp. mount 
 +mount -t cifs //<server>/<share> /<mountpoint> -o vers=3.0  
 + 
 +</code> 
  
 \\ \\
 \\ \\
 ~~DISCUSSION:closed~~ ~~DISCUSSION:closed~~
linux/general/mount.1559819252.txt.gz · Last modified: 2019/06/06 13:07 by lunetikk