5

How to set up Samba in Ubuntu/Linux, and access it in Mac OS and Windows

 3 years ago
source link: https://adrianmejia.com/how-to-set-up-samba-in-ubuntu-linux-and-access-it-in-mac-os-and-windows/
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.

How to set up Samba in Ubuntu/Linux, and access it in Mac OS and Windows

Last updated July 12th 2011

215.9k

8 Comments

How to set up Samba in Ubuntu/Linux, and access it in Mac OS and Windows

Samba allows to share files and printers with other computers remotely, regardless their operating system (linux, windows, Mac, ...). This guide show how to intall and configure the Samba service in a Ubuntu machine and access it through windows and mac.

Setting up the Samba File Server on Ubuntu/Linux:

  1. Open the terminal
  2. Install samba with the following command:   sudo apt-get install samba smbfs
  3. Configure samba typing: vi /etc/samba/smb.conf
  4. Set your workgroup (if necesary). Go down in the file, until you see :
    # Change this to the workgroup/NT-domain name your Samba server will part of
       workgroup = WORKGROUP
  5. Set your share folders. Do something like this (change your path and comments)
    # Adrian's share
    [MyShare]
      comment = YOUR COMMENTS
      path = /your-share-folder
      read only = no
      guest ok = yes
    
  6. Restart samba. type: /etc/init.d/smbd restart
  7. Create the share folder: sudo mkdir /your-share-folder
  8. Set the permissions: sudo chmod 0777 /your-share-folder
  9. you are all set in ubuntu
Accessing Samba Server Files from:
Mac OS
  1. Open finder
  2. Menu Go -> Connect to server (command-k)
  3. In the "Server Address" textbox, type: smb://<your-ip-address-to-ubuntu>
  4. Connect
  5. Select guest and OK
  6. Your all set, you'll be able to see /<your-share-folder> from here.
Windows
  1. Start button -> Run
  2. Type: \\<your-ip-address-to-ubuntu>\<your-share-folder>
  3. All set
If you need to enable the samba ports in your firewall these are the ports:
port type    port no
udp        137
udp        138
tcp        139
tcp        445

About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK