SlideShare a Scribd company logo
GlusterFS Translators
Almost Live Tutorial
Jeff Darcy
August 28, 2012
Session Overview
● Build a “negative lookup” caching translator
● add functionality
● hook things together
● build
● configure
● debug
● Almost live - see each step as code is written,
built, and run
The Problem
Dir A

file 4
Dir B
file 1

Dir C

file 3
Dir D
file 2
● First process misses in A/B/C
● Second process has no “memory” of misses,
searches from the beginning again
● Idea: cache the misses, return immediately
On the Shoulders of Giants
++++
Minor Changes 1
Back for Seconds
Minor Changes 2
Boiler Plate
init
fini
Header File
Updating the Cache (negatives)
Updating the Cache (positives)
Checking the Cache
Final Pieces (create and mkdir)
Time to Build
Almost There
Original Volfile
Modified Volfile
Running in a Debugger
Setting First Breakpoint
First Failed Lookup
Cache Kicks In
How Well Does It Work?
● Simulate PHP workload
● 1000 files spread across 10 directories
● 80% of requests to 10% of files
● test time for 10000 searches
● Numbers for comparison only
● debug build
● wimpy test machines (GigE)
Getting a Baseline
Are You Ready?
Interlude: glupy
● Write translators in Python
● Uses extending/embedding, ctypes module
● Brand new project
● weekend hacking, mid-August 2012
● still implementing 70+ operation types
● Article coming soon in $major_publication
Python Lookup Function
Python Callback Function
Python Setup
Yet Another Volfile
Scripting Languages Aren't So Slow
Conclusion
● Even simple translators can produce big
effects
● Writing translators isn't that hard
● Writing glupy translators will be even
easier
● What would you like GlusterFS to do
today?
Resources
http://hekafs.org/index.php/2011/11/translator-101-class-1-setting-the-stage/
http://hekafs.org/index.php/2011/11/translator-101-lesson-2-init-fini-and-private-
context/
http://hekafs.org/index.php/2011/11/translator-101-lesson-3-this-time-for-real/
http://hekafs.org/index.php/2011/11/translator-101-lesson-4-debugging-a-
translator/
https://github.com/jdarcy/negative-lookup
https://github.com/jdarcy/glupy
http://www.gluster.org/

More Related Content

ODP
Kkeithley ufonfs-gluster summit
ODP
Gluster intro-tdose
ODP
Scale out backups-with_bareos_and_gluster
ODP
Developing apps and_integrating_with_gluster_fs_-_libgfapi
ODP
Lcna tutorial-2012
ODP
Gluster d thread_synchronization_using_urcu_lca2016
PDF
State of the_gluster_-_lceu
PDF
OSBConf 2015 | Scale out backups with bareos and gluster by niels de vos
Kkeithley ufonfs-gluster summit
Gluster intro-tdose
Scale out backups-with_bareos_and_gluster
Developing apps and_integrating_with_gluster_fs_-_libgfapi
Lcna tutorial-2012
Gluster d thread_synchronization_using_urcu_lca2016
State of the_gluster_-_lceu
OSBConf 2015 | Scale out backups with bareos and gluster by niels de vos

What's hot (20)

PDF
Gluster d2
ODP
Accessing gluster ufo_-_eco_willson
ODP
Sdc challenges-2012
PDF
Sdc 2012-challenges
ODP
GlusterFS Containers
ODP
Join the super_colony_-_feb2013
ODP
Dedupe nmamit
PDF
Gluster intro-tdose
ODP
20160130 Gluster-roadmap
ODP
Tiering barcelona
PDF
Gluster fs current_features_and_roadmap
ODP
YDAL Barcelona
PDF
Disperse xlator ramon_datalab
ODP
Lisa 2015-gluster fs-introduction
PDF
Hands On Gluster with Jeff Darcy
PDF
Integrating gluster fs,_qemu_and_ovirt-vijay_bellur-linuxcon_eu_2013
PDF
Challenges with Gluster and Persistent Memory with Dan Lambright
ODP
Gluster technical overview
PDF
20160401 guster-roadmap
ODP
Gdeploy 2.0
Gluster d2
Accessing gluster ufo_-_eco_willson
Sdc challenges-2012
Sdc 2012-challenges
GlusterFS Containers
Join the super_colony_-_feb2013
Dedupe nmamit
Gluster intro-tdose
20160130 Gluster-roadmap
Tiering barcelona
Gluster fs current_features_and_roadmap
YDAL Barcelona
Disperse xlator ramon_datalab
Lisa 2015-gluster fs-introduction
Hands On Gluster with Jeff Darcy
Integrating gluster fs,_qemu_and_ovirt-vijay_bellur-linuxcon_eu_2013
Challenges with Gluster and Persistent Memory with Dan Lambright
Gluster technical overview
20160401 guster-roadmap
Gdeploy 2.0
Ad

Viewers also liked (14)

ODP
Leases and-caching final
ODP
20160401 Gluster-roadmap
PDF
On demand file-caching_-_gustavo_brand
PDF
Gluster wireshark niels_de_vos
ODP
Bug triage in_gluster
PDF
Debugging with-wireshark-niels-de-vos
PDF
Qemu gluster fs
ODP
Gsummit apis-2013
ODP
Integrating gluster fs,_qemu_and_ovirt-vijay_bellur-linuxcon_eu_2013
ODP
Introduction to Open Source
ODP
Gluster fs hadoop_fifth-elephant
ODP
Introduction to highly_availablenfs_server_on_scale-out_storage_systems_based...
PDF
Gluster for sysadmins
ODP
Responsibilities of gluster_maintainers
Leases and-caching final
20160401 Gluster-roadmap
On demand file-caching_-_gustavo_brand
Gluster wireshark niels_de_vos
Bug triage in_gluster
Debugging with-wireshark-niels-de-vos
Qemu gluster fs
Gsummit apis-2013
Integrating gluster fs,_qemu_and_ovirt-vijay_bellur-linuxcon_eu_2013
Introduction to Open Source
Gluster fs hadoop_fifth-elephant
Introduction to highly_availablenfs_server_on_scale-out_storage_systems_based...
Gluster for sysadmins
Responsibilities of gluster_maintainers
Ad

More from Gluster.org (20)

PDF
Automating Gluster @ Facebook - Shreyas Siravara
PDF
nfusr: a new userspace NFS client based on libnfs - Shreyas Siravara
PDF
Facebook’s upstream approach to GlusterFS - David Hasson
PDF
Throttling Traffic at Facebook Scale
PDF
GlusterFS w/ Tiered XFS
PDF
Gluster Metrics: why they are crucial for running stable deployments of all s...
PDF
Up and Running with Glusto & Glusto-Tests in 5 Minutes (or less)
PDF
Data Reduction for Gluster with VDO
PDF
Releases: What are contributors responsible for
PDF
RIO Distribution: Reconstructing the onion - Shyamsundar Ranganathan
PDF
Gluster and Kubernetes
PDF
Native Clients, more the merrier with GFProxy!
PDF
Gluster: a SWOT Analysis
PDF
GlusterD-2.0: What's Happening? - Kaushal Madappa
PDF
Scalability and Performance of CNS 3.6
PDF
What Makes Us Fail
PDF
Gluster as Native Storage for Containers - past, present and future
PDF
Heketi Functionality into Glusterd2
PDF
Architecture of the High Availability Solution for Ganesha and Samba with Kal...
PDF
Gluster Containerized Storage for Cloud Applications
Automating Gluster @ Facebook - Shreyas Siravara
nfusr: a new userspace NFS client based on libnfs - Shreyas Siravara
Facebook’s upstream approach to GlusterFS - David Hasson
Throttling Traffic at Facebook Scale
GlusterFS w/ Tiered XFS
Gluster Metrics: why they are crucial for running stable deployments of all s...
Up and Running with Glusto & Glusto-Tests in 5 Minutes (or less)
Data Reduction for Gluster with VDO
Releases: What are contributors responsible for
RIO Distribution: Reconstructing the onion - Shyamsundar Ranganathan
Gluster and Kubernetes
Native Clients, more the merrier with GFProxy!
Gluster: a SWOT Analysis
GlusterD-2.0: What's Happening? - Kaushal Madappa
Scalability and Performance of CNS 3.6
What Makes Us Fail
Gluster as Native Storage for Containers - past, present and future
Heketi Functionality into Glusterd2
Architecture of the High Availability Solution for Ganesha and Samba with Kal...
Gluster Containerized Storage for Cloud Applications

Recently uploaded (20)

PDF
CIFDAQ's Market Insight: SEC Turns Pro Crypto
PDF
Encapsulation_ Review paper, used for researhc scholars
PDF
Unlocking AI with Model Context Protocol (MCP)
PDF
NewMind AI Monthly Chronicles - July 2025
PPTX
A Presentation on Artificial Intelligence
PDF
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
PPTX
Cloud computing and distributed systems.
PDF
Encapsulation theory and applications.pdf
PPTX
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
PDF
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
PDF
Agricultural_Statistics_at_a_Glance_2022_0.pdf
PPTX
Digital-Transformation-Roadmap-for-Companies.pptx
PDF
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
PDF
Advanced methodologies resolving dimensionality complications for autism neur...
PDF
The Rise and Fall of 3GPP – Time for a Sabbatical?
PPTX
Big Data Technologies - Introduction.pptx
PPTX
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
PDF
Mobile App Security Testing_ A Comprehensive Guide.pdf
PDF
Per capita expenditure prediction using model stacking based on satellite ima...
PDF
Shreyas Phanse Resume: Experienced Backend Engineer | Java • Spring Boot • Ka...
CIFDAQ's Market Insight: SEC Turns Pro Crypto
Encapsulation_ Review paper, used for researhc scholars
Unlocking AI with Model Context Protocol (MCP)
NewMind AI Monthly Chronicles - July 2025
A Presentation on Artificial Intelligence
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
Cloud computing and distributed systems.
Encapsulation theory and applications.pdf
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
Agricultural_Statistics_at_a_Glance_2022_0.pdf
Digital-Transformation-Roadmap-for-Companies.pptx
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
Advanced methodologies resolving dimensionality complications for autism neur...
The Rise and Fall of 3GPP – Time for a Sabbatical?
Big Data Technologies - Introduction.pptx
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
Mobile App Security Testing_ A Comprehensive Guide.pdf
Per capita expenditure prediction using model stacking based on satellite ima...
Shreyas Phanse Resume: Experienced Backend Engineer | Java • Spring Boot • Ka...

Lcna example-2012