30
Leveraging RFC 4533 to build a heterogeneous LDAP server replication system Emmanuel Lécharny [email protected] Leveraging RFC 4533 to build a heterogeneous replication system

Leveraging RFC 4533 to build a heterogeneous replication ... · Leveraging RFC 4533 to build a heterogeneous LDAP server replication system History X.500 is the root Caching Shadowing

  • Upload
    others

  • View
    2

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Leveraging RFC 4533 to build a heterogeneous replication ... · Leveraging RFC 4533 to build a heterogeneous LDAP server replication system History X.500 is the root Caching Shadowing

Leveraging RFC 4533 to build a heterogeneous LDAP server replication system

Emmanuel Lé[email protected]

Leveraging RFC 4533 to builda heterogeneous replication system

Page 2: Leveraging RFC 4533 to build a heterogeneous replication ... · Leveraging RFC 4533 to build a heterogeneous LDAP server replication system History X.500 is the root Caching Shadowing

Leveraging RFC 4533 to build a heterogeneous LDAP server replication system

Speaker's Qualification

Emmanuel Lécharny

Apache Software Foundation memberFormer chairman of the Apache

Directory ProjectPMC of the Apache Directory ProjectPMC of the MINA ProjectWorks at IKTEK, a small company

based on Identity Managment andOpen Source technologies

Page 3: Leveraging RFC 4533 to build a heterogeneous replication ... · Leveraging RFC 4533 to build a heterogeneous LDAP server replication system History X.500 is the root Caching Shadowing

Leveraging RFC 4533 to build a heterogeneous LDAP server replication system

Agenda

IntrodutionA bit of historyRFC 4533, what's in the box ?Using it in a heteregoneous environmentWhat for ?RoadmapFuture stepsLinksQ/A

Page 4: Leveraging RFC 4533 to build a heterogeneous replication ... · Leveraging RFC 4533 to build a heterogeneous LDAP server replication system History X.500 is the root Caching Shadowing

Leveraging RFC 4533 to build a heterogeneous LDAP server replication system

I Introduction

Introduction

Page 5: Leveraging RFC 4533 to build a heterogeneous replication ... · Leveraging RFC 4533 to build a heterogeneous LDAP server replication system History X.500 is the root Caching Shadowing

Leveraging RFC 4533 to build a heterogeneous LDAP server replication system

I introduction

Replication :Critical to any production LDAP serverHas to be reliableHas to be fastno exit optionnot a standard until RFC 4533 was writtenThis RFC opens many doors

It's not just about replication...

Page 6: Leveraging RFC 4533 to build a heterogeneous replication ... · Leveraging RFC 4533 to build a heterogeneous LDAP server replication system History X.500 is the root Caching Shadowing

Leveraging RFC 4533 to build a heterogeneous LDAP server replication system

II History

A bit of history

Page 7: Leveraging RFC 4533 to build a heterogeneous replication ... · Leveraging RFC 4533 to build a heterogeneous LDAP server replication system History X.500 is the root Caching Shadowing

Leveraging RFC 4533 to build a heterogeneous LDAP server replication system

History

X.500 is the rootCachingShadowing

Replication is not a part of LDAP specificationsMany published drafts since 1997A few RFCs since 2002

RFC 3384RFC 4530/4533

LDUP working group 'failed' to produce a RFC

Page 8: Leveraging RFC 4533 to build a heterogeneous replication ... · Leveraging RFC 4533 to build a heterogeneous LDAP server replication system History X.500 is the root Caching Shadowing

Leveraging RFC 4533 to build a heterogeneous LDAP server replication system

History

February 2004, Kurt Zeilenga's draft :LDAP Multi-master Replication Considered Harmful

Many servers have already implemented a LDUP likereplication system, but each system is vendor specific.

OpenLDAP has implemented two different system : slurpd (now obsoleted) and Syncrepl

Still looking for a common base to build an interoperablereplication system...

Page 9: Leveraging RFC 4533 to build a heterogeneous replication ... · Leveraging RFC 4533 to build a heterogeneous LDAP server replication system History X.500 is the root Caching Shadowing

Leveraging RFC 4533 to build a heterogeneous LDAP server replication system

III What's in the box ?

RFC 4533, what's in the BOX ?

Page 10: Leveraging RFC 4533 to build a heterogeneous replication ... · Leveraging RFC 4533 to build a heterogeneous LDAP server replication system History X.500 is the root Caching Shadowing

Leveraging RFC 4533 to build a heterogeneous LDAP server replication system

What's in the box ?

“... and I think syncreplis the best thing since copulation.”

(seen on the OpenLDAP mailing list, 18/9/2009)

Probably a bit emphatic !

Page 11: Leveraging RFC 4533 to build a heterogeneous replication ... · Leveraging RFC 4533 to build a heterogeneous LDAP server replication system History X.500 is the root Caching Shadowing

Leveraging RFC 4533 to build a heterogeneous LDAP server replication system

What's in the box ?

A standardA protocol Fixes some existing replication issues

Failure to ensure a reasonable level of convergence

Failure to detect that convergence cannot be achieved (without reload);

Require pre-arranged synchronization agreements

Require the server to maintain histories of past changes to DIT contentand/or meta information

Require the server to maintain synchronization state on a per-client basis

Overly chatty protocols.

Page 12: Leveraging RFC 4533 to build a heterogeneous replication ... · Leveraging RFC 4533 to build a heterogeneous LDAP server replication system History X.500 is the root Caching Shadowing

Leveraging RFC 4533 to build a heterogeneous LDAP server replication system

What's in the box ?

Implemented so far by OpenLDAPReplaces the defunct LDUP groupIs currently being implemented in Apache Directory

Server

Page 13: Leveraging RFC 4533 to build a heterogeneous replication ... · Leveraging RFC 4533 to build a heterogeneous LDAP server replication system History X.500 is the root Caching Shadowing

Leveraging RFC 4533 to build a heterogeneous LDAP server replication system

IV Implementation details

Replication in aheterogeneous environment

Page 14: Leveraging RFC 4533 to build a heterogeneous replication ... · Leveraging RFC 4533 to build a heterogeneous LDAP server replication system History X.500 is the root Caching Shadowing

Leveraging RFC 4533 to build a heterogeneous LDAP server replication system

Implementation details

It does not need a specific protocol : LDAP isenough

As soon as a server implements the producer partof the protocol, it can replicate itself with anotherconsumer

Implementing a consumer makes your server aworking 'slave'

To have the producer and consumer is not enough :you have to implement a conflict resolutionsystem

Page 15: Leveraging RFC 4533 to build a heterogeneous replication ... · Leveraging RFC 4533 to build a heterogeneous LDAP server replication system History X.500 is the root Caching Shadowing

Leveraging RFC 4533 to build a heterogeneous LDAP server replication system

Consumer

The consumer is the easiest part to implementNeeds a client APIImplement the controlsImplement the protocol handlingInject the modifications into the server

Done in ADS, as a proof of conceptCan be implemented as a standalone component

Page 16: Leveraging RFC 4533 to build a heterogeneous replication ... · Leveraging RFC 4533 to build a heterogeneous LDAP server replication system History X.500 is the root Caching Shadowing

Leveraging RFC 4533 to build a heterogeneous LDAP server replication system

Producer

The producer is more complexImplement the controlsImplement the protocol handlingSupport for persistent searchSupport for pollingHave to keep a local state (with a journal)

Not yet done in ADSCan also be a standalone component, a kind of

replication proxy.

Page 17: Leveraging RFC 4533 to build a heterogeneous replication ... · Leveraging RFC 4533 to build a heterogeneous LDAP server replication system History X.500 is the root Caching Shadowing

Leveraging RFC 4533 to build a heterogeneous LDAP server replication system

Conflict resolution

The most complex partEasy only in Master-Slave situationWhen in multi-master, conflicts are likely to happen

Need synchronized servers (NTP)Based on entryCSNThe better the precision, the better the resolutionLast writer wins

This is a deterministic system, it does not need ahuman being to resolve conflicts

Page 18: Leveraging RFC 4533 to build a heterogeneous replication ... · Leveraging RFC 4533 to build a heterogeneous LDAP server replication system History X.500 is the root Caching Shadowing

Leveraging RFC 4533 to build a heterogeneous LDAP server replication system

V What for ?

What for ?

Page 19: Leveraging RFC 4533 to build a heterogeneous replication ... · Leveraging RFC 4533 to build a heterogeneous LDAP server replication system History X.500 is the root Caching Shadowing

Leveraging RFC 4533 to build a heterogeneous LDAP server replication system

What for ?

Implementing a standardRFC 4533 is a de facto standard : it guarantees our users

that they can switch from one server to another one ifneeded

Maybe not the best solution ever, but what else ?In OSS world, interoperability mattersAllows a cross replication between openLDAP and

Apache Directory Server

Page 20: Leveraging RFC 4533 to build a heterogeneous replication ... · Leveraging RFC 4533 to build a heterogeneous LDAP server replication system History X.500 is the root Caching Shadowing

Leveraging RFC 4533 to build a heterogeneous LDAP server replication system

What for ?

You can't ignore the installed serversOpenLDAP is already installed in many placesApache Directory Server serves a different set of needs

and a heterogeneous cluster is ideal for providing thefeatures you need based on the differing strengthsoffered by various servers

By implementing this RFC, we are offering more than justLDAP, but we also guarantee the users' assets

Some applications are not critical but need moreextensible servers to work : we see that as anopportunity beside OpenLDAP

Page 21: Leveraging RFC 4533 to build a heterogeneous replication ... · Leveraging RFC 4533 to build a heterogeneous LDAP server replication system History X.500 is the root Caching Shadowing

Leveraging RFC 4533 to build a heterogeneous LDAP server replication system

What for ?

Apache DS offers extended functionalitiesWe have implemented Stored Procedures and TriggersThis can be leveraged in a global system where the

central storage is OpenLDAP and ADS is used as an e-provisionning solution

Apache Directory Server can be embedded, andreplicated with an external server

Can also be a solution for remote applications, when notconnected

Page 22: Leveraging RFC 4533 to build a heterogeneous replication ... · Leveraging RFC 4533 to build a heterogeneous LDAP server replication system History X.500 is the root Caching Shadowing

Leveraging RFC 4533 to build a heterogeneous LDAP server replication system

What for ?

Other benefitsIn companies where many different LDAP servers are

installed, cross replication can helpDedicated system using replication

AuditingBackups

The protocol itself can be implemented without thebackend : as an API

Page 23: Leveraging RFC 4533 to build a heterogeneous replication ... · Leveraging RFC 4533 to build a heterogeneous LDAP server replication system History X.500 is the root Caching Shadowing

Leveraging RFC 4533 to build a heterogeneous LDAP server replication system

VI Roadmap

Roadmapfor

Apache DS

Page 24: Leveraging RFC 4533 to build a heterogeneous replication ... · Leveraging RFC 4533 to build a heterogeneous LDAP server replication system History X.500 is the root Caching Shadowing

Leveraging RFC 4533 to build a heterogeneous LDAP server replication system

Roadmap for ADS

Apache Directory Server implementation statusRemove Mitosis code from the serverInclude support for entryUUID and entryCSNImplement a journal to efficiently implement synrecplDefine a client-API being able to communicate using

LDAP protocol with a remote serverImplement the needed controls (SyncRequest, SyncInfo,

SyncDone, SyncState)

Page 25: Leveraging RFC 4533 to build a heterogeneous replication ... · Leveraging RFC 4533 to build a heterogeneous LDAP server replication system History X.500 is the root Caching Shadowing

Leveraging RFC 4533 to build a heterogeneous LDAP server replication system

Roadmap for ADS

Apache Directory Server implementation status :Implement the consumer partWrite a proof of concept, with ADS being a consumer and

OpenLDAP as producerImplement the producer partImplement the conflict resolution systemDefine and implement integration tests

Page 26: Leveraging RFC 4533 to build a heterogeneous replication ... · Leveraging RFC 4533 to build a heterogeneous LDAP server replication system History X.500 is the root Caching Shadowing

Leveraging RFC 4533 to build a heterogeneous LDAP server replication system

DEMO

DEMO ...

Page 27: Leveraging RFC 4533 to build a heterogeneous replication ... · Leveraging RFC 4533 to build a heterogeneous LDAP server replication system History X.500 is the root Caching Shadowing

Leveraging RFC 4533 to build a heterogeneous LDAP server replication system

VI Future

Future steps

Page 28: Leveraging RFC 4533 to build a heterogeneous replication ... · Leveraging RFC 4533 to build a heterogeneous LDAP server replication system History X.500 is the root Caching Shadowing

Leveraging RFC 4533 to build a heterogeneous LDAP server replication system

Future

Delta-SyncreplSyncrepl on other servers too ?Schema replicationTooling

Page 29: Leveraging RFC 4533 to build a heterogeneous replication ... · Leveraging RFC 4533 to build a heterogeneous LDAP server replication system History X.500 is the root Caching Shadowing

Leveraging RFC 4533 to build a heterogeneous LDAP server replication system

VII Links

Websitehttp://directory.apache.org

Downloadhttp://directory.apache.org/apacheds/1.5/downloads.html

Mailing listsDevelopment list: [email protected] list: [email protected]

Issue trackinghttp://issues.apache.org/jira/browse/DIRSERVER

Page 30: Leveraging RFC 4533 to build a heterogeneous replication ... · Leveraging RFC 4533 to build a heterogeneous LDAP server replication system History X.500 is the root Caching Shadowing

Leveraging RFC 4533 to build a heterogeneous LDAP server replication system

Questions & Answers

Questions

&Answers