Manual:IP/SMB: Difference between revisions

From MikroTik Wiki
Jump to navigation Jump to search
m (→‎Example: spacings and bullets)
Line 131: Line 131:
Now check for results:
Now check for results:


Check general service settings:
*Check general service settings:
 
 
  /ip smb print
  /ip smb print


Line 142: Line 144:
     interfaces: all
     interfaces: all


SMB user settings:
*SMB user settings:


  /ip smb users print
  /ip smb users print
Line 153: Line 155:
  1    mtuser      mtpasswd      no
  1    mtuser      mtpasswd      no


And finally SMB shares settings:
*And finally SMB shares settings:


  /ip smb shares print
  /ip smb shares print
Line 159: Line 161:


[admin@MikroTik] /ip smb> shares print  
[admin@MikroTik] /ip smb> shares print  
Flags: X - disabled, I - inactive, * - default  
Flags: X - disabled, I - inactive, * - default  
  #    NAME                  DIRECTORY        MAX-SESSIONS
  #    NAME                  DIRECTORY        MAX-SESSIONS
  0  * ;;; default share
  0  * ;;; default share

Revision as of 08:24, 23 January 2012

Summary

Sub-menu: /ip smb


SMB server provides windows sharing access to configured folders of the router.

Server settings

Property Description
enabled (yes | no; Default: no) If SMB service is enabled
domain (string; Default: MSHOME) Name of windows workgroup
allow-guests (yes | no; Default: yes) If SMB guest user is allowed to access created shares
interface (string; Default: all) list of interfaces that SMB service is available on.

Share settings

Sub-menu: /ip smb share


To set up SMB share users have to specify what folders can be accessed by the router. If folder does not exist it will be created automatically for use by created share.


Property Description
disabled (yes | no; Default: no) If SMB share is accessible to any configured SBM user
max-sessions (number; Default: 10) How many SMB simultaneous connections are allowed to shared folder
name (string; Default: ) Name of the SMB share
directory (string; Default: ) What folder should be assigned to the SMB share. If left empty value of name argument will be used from the root folder.

User setup

Sub-menu: /ip smb share


Set up users that can access SMB shares of the router.


Property Description
disabled (yes | no; Default: no) If SMB service is enabled
name (string; Default: ) login name of the SMB service user
password (string; Default: ) password for SMB user to connect to SMB service
read-only (yes | no; Default: yes) Sets if user has only read-only rights when accessing shares or full access.

Example

To make some RouterOS folder available through SMB service follow these steps:

  • create user:
/ip smb user add read-only=no name=mtuser password=mtpasswd 
  • add shared folder
/ip smb share add name=backup
  • enable SMB service
/ip smb set enabled=yes

Now check for results:

  • Check general service settings:


/ip smb print


[admin@MikroTik] /ip smb> print 
      enabled: yes
       domain: MSHOME
      comment: MikrotikSMB
 allow-guests: yes
   interfaces: all
  • SMB user settings:
/ip smb users print


[admin@MikroTik] /ip smb> users print 
Flags: * - default, X - disabled 
#    NAME         PASSWORD      READ-ONLY
0 *  guest                      yes 
1    mtuser       mtpasswd      no
  • And finally SMB shares settings:
/ip smb shares print


[admin@MikroTik] /ip smb> shares print

Flags: X - disabled, I - inactive, * - default 
#    NAME                   DIRECTORY        MAX-SESSIONS
0  * ;;; default share
     pub                   /pub              10
1    backup                /backup           10

Now additional configuration changes can be done, like disabling default user and share etc.