O'Reilly logo

Linux Networking Cookbook by Gregory Boyce

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Configuring Samba as an Active Directory compatible directory service

As of Samba 4.0, Samba has the ability to act as a primary domain controller (PDC) in a manner that is compatible with Active Directory.

How to do it…

Installing on Ubuntu 14.04:

  1. Configure your system with a static IP address and update /etc/hosts to point to that IP address rather than localhost.
  2. Make sure that your time is kept up to date by installing an NTP client:
    sudo apt-get install ntp
    
  3. Pre-emptively disable smbd/nmbd from running automatically:
    sudo bash -c 'echo "manual" > /etc/init/nmbd.override'
    sudo bash –c 'echo "manual" > /etc/init/smbd.override'
    
  4. Install Samba and smbclient:
    sudo apt-get install samba smbclient
    
  5. Remove stock smb.conf:
    sudo rm /etc/samba/smb.conf
    

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required