You are currently viewing the United Kingdom version of the site.
Would you like to switch to your local site?
15 MIN READ TIME

SAMBA

Using Active Directory with Debian & Samba

  Stuart Burns rolls up his sleeves and takes you through the process of setting up a Linux-based Active Directory infrastructure and how to use it.

Credit: www.samba.org

OUR EXPERT

Stuart Burns is a big Linux advocate and enjoys trying new things in Linux before sharing his findings with the world.

L ike it or not, a lot of authentication uses Active Directory (AD) to manage users and resources. It’s a staple of the Windows world and until recently (Samba 4) there was no way to have a complete AD stack in FOSS to “talk proper AD”. Luckily, with SAMBA version 4.7 and later it’s possible to build an AD controller based completely on Debian and Samba. If you follow AD all the way back it’s just Microsoft’s take on LDAP with some extra secret sauce.

This new capability is a great step forward. However, it’s important to note that while the authentication will work as expected, some items may not work. The message is, “Try this but be aware there may be some areas that present difficulties.” That said, authentication, print servers and SMB file shares should all work if correctly implemented.

The home user among us may be thinking, “This does nothing for me” but even at home, for the techie types AD can be useful. Think of all those usernames and passwords across different systems that are all managed separately. If you could just use one across the entire breadth of your eco-system, wouldn’t that be great? AD makes this possible. One simple daily example is integrating AD management into FreeNAS so that you can log in using a centralised authentication. AD provides this, as well as being able to assign domainbased rights to SMB shares.

A key part of setting up AD is its dependency on DNS. Whenever you set up an AD infrastructure in Windows for the first time it automatically installs a DNS server. Most new installations should select ‘Samba Internal’ for the DNS type. The DNS system comes as part of the AD system, but also provides standard DNS resolution. The walkthrough in this instance is being performed in a test lab. To follow along with this walkthrough the user will need a virtual machine with a static IP address. (For this example, the test AD server IP will be 192.168.1.10 with a netmask of 255.255.255. xxx and a gateway of 192.168.1.1.) The VM should also be able to download the installation packages that will be needed. For this walkthrough Debian 10 is used, but if you’re using Ubuntu it should be very similar.

It’s crucial that the AD domain isn’t a real world one, or it’ll cause problems. For example, chose itburns.lab, which isn’t a real world domain. This is important because it’s not something that can be changed later. It’s vital to lay the groundwork, too. Ensuring accurate time is critical or it can cause problems in Active Directory. VirtualBox VMs (and others) get their time from the host they sit upon, but once other machines are added the time may not be in such accurate sync. For that reason alone, if expanding beyond virtual experimentation, use a time server and make sure all clients receive their time from it.

Unlock this article and much more with
You can enjoy:
Enjoy this edition in full
Instant access to 600+ titles
Thousands of back issues
No contract or commitment
Try for 99p
SUBSCRIBE NOW
30 day trial, then just £9.99 / month. Cancel anytime. New subscribers only.


Learn more
Pocketmags Plus
Pocketmags Plus

This article is from...


View Issues
Linux Format
March 2021
VIEW IN STORE

Other Articles in this Issue


WELCOME
Orchestral Manoeuvres in the Docker
Jonni’s been arguing with me this issue –
REGULARS AT A GLANCE
Is online privacy the hot topic for 2021?
PRIVACY
Linus vs Intel
Linus Torvalds blasts Intel for not supporting ECC memory
Affordable RISC-V PC arrives
BeagleV is a RISC-V computer designed to run Linux
THE END IS NIGH, SO…?
Matt Yonkovit is Percona’s Chief Experience Officer and
SPRING CLEANING
Keith Edmunds is MD of Tiger Computing Ltd,
Apple M1 Macs get Linux support
Apple’s OS 11.2 now supports booting custom kernels
FOSS watch
PineTime takes on the Apple Watch and other wearables
Faster Firefox
Firefox 84 brings HW acceleration to Linux
Distro watch
What’s down the side of the free software sofa?
IT’S GOOD TO SHARE
Alyssa Rosenzweig is a software engineer based at
TIME’S UP FOR OLD KIT
Jon Masters has been involved with Linux for
Kernel Watch
Jon Masters summarises the latest happenings in the Linux kernel, so you don’t have to
Mailserver
Write to us at Linux Format, Future Publishing, Quay House, The Ambury, Bath BA1 1UA or lxf.letters@futurenet.com.
Helpdex
shane_collinge@yahoo.com WRITE TO US Do you have a
Answers
Got a burning question about open source or the kernel? Whatever your level, email it to lxf.answers@futurenet.com
SUBSCRIBE!
EiskaltDC++
FILE-SHARING APPLICATION
TabFS
FILE SYSTEM
TuxPaint
DRAWING APPLICATION
Chipmunk
LOG VIEWER
Darktable
PHOTO EDITOR
EasyLogic Studio
CSS AND SVG EDITOR
Zenith
SYSTEM MONITOR
Tux Vs Yeti
PLATFORMER GAME
Invasion
ARCADE GAME
Qsnapstore
SNAP STORE VIEWER
REVIEWS
AMD Ryzen 5 5600X
As Alan Dexter discovers, this chip may be the runt of the Zen 3 family, but it delivers where it counts most: gaming
Slackel 7.4
Before he couldn’t work with Arch, he couldn’t work with Slackware, which is why Mayank Sharma jumps at everything that mentions the venerable distro
RebornOS 2020.12.28
The constant deluge of Arch-based distros can put anyone to sleep, but this one makes Mayank Sharma wake up from his slumber
Rescuezilla 2.1
With perennial fat fingers, Mayank Sharma has been messing with hard disks long enough to know that good rescue tools are worth their weight in gold
Garuda Linux 210101
Mayank Sharma has enjoyed one Arch-based distribution this month, but will lightning strike twice or has he been taken in by the distro’s tall claims?
Wasteland 3
Management simply hates weirdos and snow, so this is a bad time of year for them and they’re taking it out on Jody Macgregor
Roundup
Game engines
There’s never been a better time to get into game development on Linux. Michael Reed puts five capable engines under the microscope
How free is it?
There are different kinds of free…
Community and support
A game engine is useless without a way of learning how to use it
Programming environment and GUI
A difficult environment can lead to eventual loss of interest
2D workflow and features
Top down, overhead, side on or something else?
3D workflow and features
How easy is it to create a world to move around in?
Extras
Anything that makes it stand out from the rest?
Ease of use
This is relative because some engines are more capable in terms of what they can do
Game engines
The Verdict
Better virtual machines
BETTER VIRTUAL MACHINES
Forget about the draconian confines of reality and immerse yourself (well, your computing) in a virtual world. Jonni Bidwell’s here with a machines-inside-machines extravaganza
A virtual history
Datacentres are full of VMs, but why and how did they get that way?
QEMU, KVM and the other ones
Learn about virtualising the Linux way, with libvir t and Virtual Machine Manager, and jokes about Inception
Orchestrating with Xen
Set up a machine dedicated to hosting VMs with yet another high-powered hypervisor, XCP-ng
INSTALL XCP-NG
1 Launch the installer Fetch the latest ISO
Contain yourself
Containerisation is even more of an ugly word than virtualisation, but it’s a big deal too. A Docker whale-sized big deal, as we’ll discover…
IN-DEPTH
THE LINUX GAMBIT
Jonni Bidwell once again sets a graphics card on fire, this time calculating chess positions…
Pi USER
PASSING ON THE KNOWLEDGE
Thierry Chantier is a French coder and maker.
Pi Foundation boosts support for teachers
Over 300 free curriculum-mapped video lessons now available via the Oak National Academy
Cool HAT dude!
This Pi Smart Fan HAT is stackable and GPIO friendly, too
Raspberry Pi Pico
In a break from the norm Les Pounder tests the latest Pi: a $4 microcontroller featuring the first ‘Pi Silicon’ created by Raspberry Pi
Turn a Pi HAT into a Magic 8-ball project
SENSEHAT
Build a Pi-powered helicopter diorama
Sean Conway uses a helicopter model to demonstrate how lighting, sound and motion can be accomplished using a Raspberry Pi
Connect, configure and use gamepads
GAMING
TUTORIALS
A terminal multiple window manager
You can’t use the mouse or run multiple windows in a text environment… unless you’re Shashank Sharma and know just the right tool for the job
Construct your own mind-maps
Nick Peers reveals how you can easily manage all of your thoughts – from simple ideas to fully formed projects – with this powerful free tool
Next-gen filesystem management
ZFS is a lot more than a filesystem. Neil Bothwick tells all about this advanced volume manager and Swiss Army Knife of filesystems
Run a classic BBC Micro under Ubuntu
Les Pounder reminisces about that one time when he caused a core meltdown in a nuclear reactor, then flew away in a spaceship
Decode signals from weather satellites
Weather satellites transmit signals that you can receive and decode to generate images of the Earth. Mike Bedford shows you how
Dify
IMAGE COMPARISON TOOL
CODING ACADEMY
Coding Arm 64-bit assembly language
Continue writing 64-bit assembly code for the Pi with John Schwartzman, who calls on Linux kernel services and the C run-time library
Write a maze runner game in Python
One way in, and only one way out… video game aficionado Calvin Robinson reveals how to create a vintage maze runner-style game
REGULARS AT GLANCE
On the disc
Discover the highlights from this month’s packed DVD!
GeckoLinux 152
SUPER GECKO MUSCLES
Chat
X
Pocketmags Support