Top Banner
Storage Developer Conference 2009 © 2009 Kai Blin. All rights reserved. Samba ARMed and Ready Running an Active Directory DC on 2 Watts
31

Samba ARMed and Ready - SNIA · Samba ARMed and Ready. Running an Active Directory DC on 2 Watts. ... No license costs ... Samba4 DNS server ISC ...

Dec 26, 2018

Download

Documents

trinhhanh
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: Samba ARMed and Ready - SNIA · Samba ARMed and Ready. Running an Active Directory DC on 2 Watts. ... No license costs ... Samba4 DNS server ISC ...

Storage Developer Conference 2009 © 2009 Kai Blin. All rights reserved.

Samba ARMed and Ready

Running an Active Directory DC on 2 Watts

Page 2: Samba ARMed and Ready - SNIA · Samba ARMed and Ready. Running an Active Directory DC on 2 Watts. ... No license costs ... Samba4 DNS server ISC ...

Storage Developer Conference 2009 © 2009 Kai Blin. All rights reserved.2

Overview

IntroductionHardware

Beagle BoardAlternatives

SoftwareUbuntu LinuxSamba

Performance

2

Page 3: Samba ARMed and Ready - SNIA · Samba ARMed and Ready. Running an Active Directory DC on 2 Watts. ... No license costs ... Samba4 DNS server ISC ...

Storage Developer Conference 2009 © 2009 Kai Blin. All rights reserved.3

About Myself

Computational biology grad studentProtein design

Wine Developer since 2005AuthenticationNetworking

Samba Team member since 2007ID mapping / winbindEmbedded Samba

3

Page 4: Samba ARMed and Ready - SNIA · Samba ARMed and Ready. Running an Active Directory DC on 2 Watts. ... No license costs ... Samba4 DNS server ISC ...

Storage Developer Conference 2009 © 2009 Kai Blin. All rights reserved.4

ARM Architecture

32bit RISC architectureLow-power, low-costWidely used in consumer electronics

Smartphones/PDAsHandheld gaming consolesRouters / NAS boxes

Page 5: Samba ARMed and Ready - SNIA · Samba ARMed and Ready. Running an Active Directory DC on 2 Watts. ... No license costs ... Samba4 DNS server ISC ...

Storage Developer Conference 2009 © 2009 Kai Blin. All rights reserved.5

Why Bother?

Low power consumptionKeeps the power bill down

Fan-less and QuietOffice or home use

Low unit costActive Directory server for < €150/$200No license costs

Mobile

5

Page 6: Samba ARMed and Ready - SNIA · Samba ARMed and Ready. Running an Active Directory DC on 2 Watts. ... No license costs ... Samba4 DNS server ISC ...

Storage Developer Conference 2009 © 2009 Kai Blin. All rights reserved.6

Hardware

6

Page 7: Samba ARMed and Ready - SNIA · Samba ARMed and Ready. Running an Active Directory DC on 2 Watts. ... No license costs ... Samba4 DNS server ISC ...

Storage Developer Conference 2009 © 2009 Kai Blin. All rights reserved.7

Hardware Used

Beagle BoardPowered USB hubUSB ethernet controller

7

Page 8: Samba ARMed and Ready - SNIA · Samba ARMed and Ready. Running an Active Directory DC on 2 Watts. ... No license costs ... Samba4 DNS server ISC ...

Storage Developer Conference 2009 © 2009 Kai Blin. All rights reserved.8

Beagle Board

Budget-friendlyEasy to useAlways-onGreen ITLight-weightExtensible via USB

8

Page 9: Samba ARMed and Ready - SNIA · Samba ARMed and Ready. Running an Active Directory DC on 2 Watts. ... No license costs ... Samba4 DNS server ISC ...

Storage Developer Conference 2009 © 2009 Kai Blin. All rights reserved.9

Beagle Board

8cm x 8cm (3”x3”)128/256 MB RAM500 mA / 5 VSD/MMC/SDIO slotSerial portNo ethernet

9

Page 10: Samba ARMed and Ready - SNIA · Samba ARMed and Ready. Running an Active Directory DC on 2 Watts. ... No license costs ... Samba4 DNS server ISC ...

Storage Developer Conference 2009 © 2009 Kai Blin. All rights reserved.10

Beagle Peripherals

Powered USB hubSupplies power to Beagle boardProvides additional USB ports

USB Ethernet controllerUSB2.0 interface (480 Mbit/s)Provides 10/100 Mbit/s EthernetFast enough for SOHO use

10

Page 11: Samba ARMed and Ready - SNIA · Samba ARMed and Ready. Running an Active Directory DC on 2 Watts. ... No license costs ... Samba4 DNS server ISC ...

Storage Developer Conference 2009 © 2009 Kai Blin. All rights reserved.11

Alternatives

Sheeva PlugFaster processor, 512 MB RAMGigabit ethernet onboard3 A / 5 V

Gumstix OveroSimilar to Beagle BoardExpansion card provides WiFi250 mA / 4 V

11

Page 12: Samba ARMed and Ready - SNIA · Samba ARMed and Ready. Running an Active Directory DC on 2 Watts. ... No license costs ... Samba4 DNS server ISC ...

Storage Developer Conference 2009 © 2009 Kai Blin. All rights reserved.12

Software

12

Page 13: Samba ARMed and Ready - SNIA · Samba ARMed and Ready. Running an Active Directory DC on 2 Watts. ... No license costs ... Samba4 DNS server ISC ...

Storage Developer Conference 2009 © 2009 Kai Blin. All rights reserved.13

Software Used

LinuxUbuntu 9.04 “Jaunty Jackalope”

SambaSamba4

DNS serverISC Bind

13

Page 14: Samba ARMed and Ready - SNIA · Samba ARMed and Ready. Running an Active Directory DC on 2 Watts. ... No license costs ... Samba4 DNS server ISC ...

Storage Developer Conference 2009 © 2009 Kai Blin. All rights reserved.14

Ubuntu “Jaunty Jackalope”

General Linux distributionThousands of software packagesWide range of applications

Supports ARM out of the boxNo need to compile packages yourself

No official Beagleboard kernel (yet)Community kernels available

Page 15: Samba ARMed and Ready - SNIA · Samba ARMed and Ready. Running an Active Directory DC on 2 Watts. ... No license costs ... Samba4 DNS server ISC ...

Storage Developer Conference 2009 © 2009 Kai Blin. All rights reserved.15

Ubuntu Setup

Bootstrap on PCrootstock script sets up root filesystemPartition and format SD cardCopy kernel and filesystem to SD card

Boot beagleConfigure networkingUpdate system

15

rootstock: https://launchpad.net/project-rootstock

Page 16: Samba ARMed and Ready - SNIA · Samba ARMed and Ready. Running an Active Directory DC on 2 Watts. ... No license costs ... Samba4 DNS server ISC ...

Storage Developer Conference 2009 © 2009 Kai Blin. All rights reserved.16

Alternative Distributions

ÅngströmSpecial embedded distributionDesigned for handhelds and NAS boxesRecommended by Texas Instruments

AndroidSpecial embedded distributionDesigned for mobile phones

And many others...

16

Page 17: Samba ARMed and Ready - SNIA · Samba ARMed and Ready. Running an Active Directory DC on 2 Watts. ... No license costs ... Samba4 DNS server ISC ...

Storage Developer Conference 2009 © 2009 Kai Blin. All rights reserved.17

Samba

Opening Windows to a wider world for 17 yearsSMB/CIFS/SMB2 file servicesCurrent: 3.4.1, released 2009-09-01Providing NT4-style domain controllerMember server in Active Directory domains

Page 18: Samba ARMed and Ready - SNIA · Samba ARMed and Ready. Running an Active Directory DC on 2 Watts. ... No license costs ... Samba4 DNS server ISC ...

Storage Developer Conference 2009 © 2009 Kai Blin. All rights reserved.18

Samba4

Active Directory Domain Controller supportAlpha 8 released June 19th 2009Active Directory components usableFile / print services need work

18

Page 19: Samba ARMed and Ready - SNIA · Samba ARMed and Ready. Running an Active Directory DC on 2 Watts. ... No license costs ... Samba4 DNS server ISC ...

Storage Developer Conference 2009 © 2009 Kai Blin. All rights reserved.19

Samba4 Setup

Compile sources (tarball, git)Call ./setup/provision

Sets up databasesCreates related config files

Set up DNSZone file created by provision

19

Page 20: Samba ARMed and Ready - SNIA · Samba ARMed and Ready. Running an Active Directory DC on 2 Watts. ... No license costs ... Samba4 DNS server ISC ...

Storage Developer Conference 2009 © 2009 Kai Blin. All rights reserved.20

DNS

Different per distributionUbuntu: Copy over files to /etc/bind/

Problem: bind memory usageAlternatives

dnsmasqOwn implementation

Page 21: Samba ARMed and Ready - SNIA · Samba ARMed and Ready. Running an Active Directory DC on 2 Watts. ... No license costs ... Samba4 DNS server ISC ...

Storage Developer Conference 2009 © 2009 Kai Blin. All rights reserved.21

Samba4 Demo

Join Win2k3 memberJoin Samba 3 memberCreate user via MMCEnumerate users on Samba 3 member

21

Page 22: Samba ARMed and Ready - SNIA · Samba ARMed and Ready. Running an Active Directory DC on 2 Watts. ... No license costs ... Samba4 DNS server ISC ...

Storage Developer Conference 2009 © 2009 Kai Blin. All rights reserved.22

Samba “Franky”

Samba 3: File / print servicesTried and trueGrown code

Samba 4: AD domain controllerClean designFocus on new technology

Combine to get production-ready AD DC“Best of”Code name: Franky

22

Page 23: Samba ARMed and Ready - SNIA · Samba ARMed and Ready. Running an Active Directory DC on 2 Watts. ... No license costs ... Samba4 DNS server ISC ...

Storage Developer Conference 2009 © 2009 Kai Blin. All rights reserved.23

Samba “Franky” Setup

Grab sources from git://git.samba.org/samba.gitCompile Samba 3 with --enable-developer=yes

Merged Samba 3 / Samba 4 buildpdb_ads glue code

Provision Samba 4 as describedAs domain controller“server services = ldap, cldap, kdc”

23

Page 24: Samba ARMed and Ready - SNIA · Samba ARMed and Ready. Running an Active Directory DC on 2 Watts. ... No license costs ... Samba4 DNS server ISC ...

Storage Developer Conference 2009 © 2009 Kai Blin. All rights reserved.24

Smba “Franky” Setup (cont.)

Set up Samba 3Different smb.conf file!As domain controller“passdb backend = pdb_ads”

Setup DNS as described

24

Page 25: Samba ARMed and Ready - SNIA · Samba ARMed and Ready. Running an Active Directory DC on 2 Watts. ... No license costs ... Samba4 DNS server ISC ...

Storage Developer Conference 2009 © 2009 Kai Blin. All rights reserved.25

Performance Data

25

Page 26: Samba ARMed and Ready - SNIA · Samba ARMed and Ready. Running an Active Directory DC on 2 Watts. ... No license costs ... Samba4 DNS server ISC ...

Storage Developer Conference 2009 © 2009 Kai Blin. All rights reserved.26

Power Consumption

26

System Idle (W) Load (W)

AMD Athlon64 3000+ 75 105

Intel Core2 Quad 109 180

Mac Mini G4 20 40

ThinkPad R52 27 50

Beagleboard 4 7

ShevaPlug 6 9

Page 27: Samba ARMed and Ready - SNIA · Samba ARMed and Ready. Running an Active Directory DC on 2 Watts. ... No license costs ... Samba4 DNS server ISC ...

Storage Developer Conference 2009 © 2009 Kai Blin. All rights reserved.27

Test (in ~ cycles per minute)

Win2003 Server(Virtual Machine)

Samba4(Virtual Machine)

Samba4(Beagleboard)

kinit - kdestroy 510 1430 100

join - leave 70 90 10

User add - delete 90 110 12

Group add - del 90 160 22

LDAP search indexed 70 120 40

LDAP search wildcard 200 340 100

LDAP searchnot indexed 220 360 100

Benchmark Data

27

Page 28: Samba ARMed and Ready - SNIA · Samba ARMed and Ready. Running an Active Directory DC on 2 Watts. ... No license costs ... Samba4 DNS server ISC ...

Storage Developer Conference 2009 © 2009 Kai Blin. All rights reserved.28

Conclusions

Suitable for small setupsSlow operations not done often

Affordable Active Directory setupSome optimization might help

Page 29: Samba ARMed and Ready - SNIA · Samba ARMed and Ready. Running an Active Directory DC on 2 Watts. ... No license costs ... Samba4 DNS server ISC ...

Storage Developer Conference 2009 © 2009 Kai Blin. All rights reserved.29

Possible Use Cases

“Mobile Workgroup” serversHome office set-top boxCouple with OpenChange for email applianceReplicating DC for branch offices...

Page 30: Samba ARMed and Ready - SNIA · Samba ARMed and Ready. Running an Active Directory DC on 2 Watts. ... No license costs ... Samba4 DNS server ISC ...

Storage Developer Conference 2009 © 2009 Kai Blin. All rights reserved.30

Future Work

Optimize for resource savingFacilitate DNS setupWeb configuration frontend

Page 31: Samba ARMed and Ready - SNIA · Samba ARMed and Ready. Running an Active Directory DC on 2 Watts. ... No license costs ... Samba4 DNS server ISC ...

Storage Developer Conference 2009 © 2009 Kai Blin. All rights reserved.31

Thank You

31

Samba Team blog http://news.samba.org/developers/

Kai's tech blog http://kblin.blogspot.com/

Kai's Beagle page http://kblin.org/projects/home_server

Samba Embedded wiki page http://wiki.samba.org/index.php/Samba_Embedded