SlideShare uma empresa Scribd logo
1 de 27
Orchestrating Clusters
with Ironfan and Chef
    Robert J. Berger - CTO Runa, Inc.
          rberger@runa.com
Hassles of Big Data Stack
      Deployments
• Lots of Moving Parts
 •   Hadoop/HBase just one sub-system
 •   Heterogeneous Tech
 •   Monitoring & Metrics Everywhere
 •   Details obscure the big picture
• Need repeatability & variations on themes
The Forest for the Trees
Forest
Dash        App
                     Monitor
board      Servers




Elastic              Hadoop
           AMQP
Search                M/R




Session
           HBase     MySQL
 Store
MySQL




                                                                                       Slave
                                                                 Slave               Slave
                                                               Slave             Master
                   GDash
                Statsd
               Sensu                                    Slave
          Logstash                                     Slave
         Ganglia                                   Slave
                        Monitoring




        Graphite                                  Slave
        Web                                     Slave                                                           Regionsrvr
                                               Slave                                                      Regionsrvr
                                           Slave
                                                          Hadoop
                                                           M/R




                                          Slave                                                  Regionsrvr
Trees




                                      Sec Master
                                                                                               Regionsrvr
                                      Master
                                                                                             Regionsrvr
                                                                                          Regionsrvr
               Clj App                                                                  Regionsrvr
              Clj App
                                                                                       Regionsrvr
          Clj App
                                                                                     Regionsrvr
                        App Servers




          Web
                                           Rabbit                                Regionsrvr
         Web
                                          Rabbit        AMQP                    Regionsrvr
        ELB
                                                                               HB Master




                                                                                                HBase
                                                                             HB Master
                                                                            ZooKeeper
                                                                          ZooKeeper
                                                                         ZooKeeper
                                           ES Server
                                          ES Server
          Rails App                     ES Server




                                                       Search
                                                       Elastic
                          Dashboard
         Rails App                     ES Server
         Web
                                                                                     Redis
                                                                                 Redis




                                                                                               Session
                                                                                                Store
                                                                                Redis
Leaves
Dashboard                        App Servers                                   Monitoring
 Nginx         MySQL Client       Elastic Load Balancer MySQL Client              Nginx             Ganglia Server
 Reverse Proxy Upstart Config      Nginx                 Upstart Config             Reverse Proxy     Ganglia Web
 Unicorn       Logstash Client    Reverse Proxy         Logstash Client           Java              Statsd Server
 Rails                            Swarmiji                                        Leiningen         Graphite Server
 Dashboard App                    Java                                            Jark              Grpahite Web
 Java                             Leiningen                                       Postfix            Python
 Postfix                           Jark                                            Cron jobs         Logstash
 Cron jobs                        Clojure Apps                                    Sensu Server      MySQL Client
 Sensu client                     HBase Client                                    Sensu Web         Upstart Config
 Sensu plugins                    Postfix                                          Sensu Client      Logstash Client
                                  Cron jobs                                       Sensu Plugins
                                  Sensu client
                                  Sensu plugins

Elastic Search                   AMQP                                     Hadoop M/R
 Elastic Search Server            RabbitMQ                                 Namenode
 Java                             RabbitMQ Plugins                         Secondary Namenode
 Cron jobs                        Cluster Config                            Tasktracker
 Sensu client                     Erlang                                   Jobtrackers
 Sensu plugins                    Cron jobs                                Bootstrap Namenmode
 Upstart Config                    Sensu client                             Java
                                  Sensu plugins                            JMX
                                  Upstart Config                            Cron jobs
                                                                           Sensu client
                                                                           Sensu plugins
                                                                           Ganglia Client
                                                                           Upstart Config

Session Store                    HBase                                             MySQL
Redis                             Namenode            Zookeeper                     MySQL Master
Cron jobs                         Secondary Namenode HBase Master                   MySQL Slaves
Sensu client                      Tasktracker         Regionserver                  Cluster Setup
Sensu plugins                     Jobtrackers                                       Cron jobs
Upstart Config                     Datanodes                                         Sensu client
                                  Bootstrap Namenmode                               Sensu plugins
                                  Java                                              Upstart Config
                                  JMX
                                  Cron jobs
                                  Sensu client
                                  Sensu plugins
                                  Ganglia Client
                                  Upstart Config
Molecules
<configuration>
  <property>
    <name>hbase.rootdir</name>
    <value>hdfs://ip-10-19-65-58.ec2.internal:8020/hadoop/hbase</value>
    <description>The directory shared by region servers.
    Should be fully-qualified to include the filesystem to use.
    E.g: hdfs://NAMENODE_SERVER:PORT/HBASE_ROOTDIR
    </description>
  </property>
  <property>
    <name>hbase.cluster.distributed</name>
    <value>true</value>
    <description>The mode the cluster will be in. Possible values are
      false: standalone and pseudo-distributed setups with managed Zookeeper
      true: fully-distributed with unmanaged Zookeeper Quorum (see hbase-env.sh)
    </description>
  </property>
  <property>
    <name>hbase.zookeeper.quorum</name>
    <value>master.example.com,region0.example.com,region1.example.com</value>
    <description>Comma separated list of servers in the ZooKeeper Quorum.
    For example, "host1.mydomain.com,host2.mydomain.com,host3.mydomain.com".
    By default this is set to localhost for local and pseudo-distributed modes
    of operation. For a fully-distributed setup, this should be set to a full
    list of ZooKeeper quorum servers. If HBASE_MANAGES_ZK is set in hbase-env.sh
    this is the list of servers which we will start/stop ZooKeeper on.
    </description>
  </property>
Config Management:
   Leaves & Molecules

• Chef, Puppet, Cfengine
• Much better than shell scripts or cli jocks
• Infrastructure as code
• Still No Forest Perspective
Ironfan: Forest, Trees,
    Leaves and Molecules
•   Open Source Project from Infochimps
•   Builds on top of Chef
•   Cluster Description in Single File
    • Your System Diagram Come to Life
•   Components announce capabilities
    • Service Discovery automates interconnects
•   Knife (CLI) extension controls cluster and
    component life-cycles
Basic Chef
Community + Own                   Chef Server
  Cookbooks           Search                     Auth &
                                                 ACLs



                      Nodes          Roles /
                                    Cookbooks   Data Bags
                     Attributes




                                                                   N




                                                                   N




                                                                   N



                  Chef Knife:
        Upload Cookboks to Chef Server                             N


              Launch Instances /
              Bootstrap Servers

                                                            VMs and/or Servers
                                                            Running Chef-Client
            Chef Development Host
Chef + Ironfan
Community + Own                   Chef Server
  Cookbooks           Search                     Auth &
                                                 ACLs



                      Nodes          Roles /
                                    Cookbooks   Data Bags
                     Attributes




                                                                   N




                                                                   N




                                                                   N



         Chef Knife + Ironfan Gem:
         Launch / Bootstrap / Manage                               N


         Whole Clusters, All Facets or
             Specific Instances

                                                            VMs and/or Servers
                                                            Running Chef-Client
           Chef Development Host
Ironfan Pantry +
                    Chef + Ironfan
Community + Own                    Chef Server
    Cookbooks          Search /
                       Search                     Auth &
                      Discovery                   ACLs


                       Nodes
                       Nodes
                      Attributes      Roles /
                                     Cookbooks   Data Bags
                      Attributes
                      Discovery



                                                                    N




                                                                    N




                                                                    N



           Chef Knife + Ironfan Gem:
          Launch / Bootstrap / Manage                               N


          Whole Clusters, All Facets or
              Specific Instances

                                                             VMs and/or Servers
                                                             Running Chef-Client
             Chef Development Host
Ironfan Components
• Ironfan Gem:
  •   Knife Plugins to orchestrate clusters
  •   Logic to sync Chef Server & Cloud[s]
• Silverware: Coordinate Discovery of Services
• Ironfan-Homebase: Ironfan tuned Chef-Repo
• Ironfan-Pantry: Cookbooks tuned for
  Clusters
• Ironfan-CI: Testing of Ironfan clusters and
  Cookbooks
Cluster Config: Forest View
                  ClusterChef.cluster 'base0-cluster0' do
    Global          setup_role_implications
                    cloud :ec2 do
Cloud & Cluster       region              'us-east-1'

    Configs            availability_zones ['us-east-1b']
                      backing             'ebs'
                      image_name          'natty'
                      security_group(cluster_root) do
                        authorize_port_range(22)
                      end
                    end

                    role                 "base_role"
                    role                 "chef_client"
                    role                 "base0-cluster0"
                    role                 "production"
                    role                 "runastack"
                    role                 "ebs_volumes_attach"                Roles & Recipes
                    role                 "ebs_volumes_mount"
                                                                             are the “Leaves”
   Facets are       facet 'master' do
  the “Trees”         instances           1
                      cloud.image_id      'ami-93c31afa'
                      cloud.flavor        "cc1.4xlarge"

                      role                "big_package"
                      role                "hadoop_master"
                      role                "hbase_master"
                      recipe              "cluster_chef::cluster_webfront"
                      recipe              "hbase::utils"
                      recipe              "route53::runa"
                      role                "monitored_client"
                    end
Global Cloud & Recipe Confgs
         ClusterChef.cluster 'base0-cluster0' do
           setup_role_implications                     Cluster Name
           cloud :ec2 do
Cloud        region              'us-east-1'
Configs       availability_zones ['us-east-1b']
             backing             'ebs'                   Configure
             image_name          'natty'                  Security
             security_group(cluster_root) do               Group
               authorize_port_range(22)
             end
           end

Shared     role                 "base_role"
 Roles     role                 "chef_client"
           role                 "base0-cluster0"
           role                 "production"
           role                 "runastack"
           role                 "ebs_volumes_attach"
           role                 "ebs_volumes_mount"
Facet Name
             Facets add Specifics
             facet 'master' do
                                                                      Number of
 Cloud         instances           1                                   Copies
Overrides      cloud.image_id      'ami-93c31afa'
               cloud.flavor        "cc1.4xlarge"

               role                "hadoop_master"                      Facet
               role                "hbase_master"                      Roles &
               recipe              "cluster_chef::cluster_webfront"
               recipe              "hbase::utils"                      Recipes
               recipe              "route53::runa"
               role                "monitored_client"
Facet Name   end
                                                                      Number of
 Cloud
             facet 'regionserver' do
               instances           7
                                                                       Copies
Overrides      cloud.image_id      'ami-93c31afa'
               cloud.flavor        "cc1.4xlarge"

               role                "hadoop_slave"
               role                "hbase_regionserver"                 Facet
Make one       recipe              "hbase::utils"
                                                                       Roles &
instance       recipe              "route53::runa"
               role                "monitored_client"                  Recipes
 special       server 0 do
                 role   "zookeeper_server"
               end
             end
Facets Composed of
     Components
• Components are Services
  • Nginx, MySQL server, Zookeeper, HBMaster,
    Namenode, etc.
• Chef Cookbooks manage components
• Ironfan Silverware for service discovery
  • Auto-Connects components together
Silverware:
        Service Discovery
•   Announcements enable Service Discovery
•   Implemented using Chef Node Attributes
    •   DSL for Chef Attributes
•   Components announce Services & Amenities
    •   Enables zero-conf for things like Logging, Ports,
        Dashboard sources, etc.
•   Announcements effectively define a component's
    Contract or API
Silverware Service Discovery
• Recipe that creates a service , announces it
announce(:hadoop, :namenode)


• Recipe that requires a service , discovers it
hbase_config = Mash.new({
  :namenode_fqdn   => discover(:hadoop, :namenode ).private_hostname),
  :jobtracker_addr => discover(:hadoop, :jobtracker).private_ip),
  :zookeeper_addrs =>
discover_all(:zookeeper, :server).map(&:private_ip).sort,
  :ganglia         => discover(:ganglia, :server),
  :ganglia_addr    => discover(:ganglia, :server).private_hostname),
  :private_ip      => private_ip_of(node)
  })
Silverware:
 Announce Capabilities
• Goes beyond basic component discovery
• Capabilities
 • Serve webpages, execute script, send
    metrics, answer queries
• Aspects
 • Ports, daemons, logs, files, dashboards
Aspects enable Zeroconf
       Amenities
•   A log aspect would enable the following amenities
    •   logrotated    to manage its logs
    •   flume   to archive logs to a location
•   A port aspect would enable
    • Configuration of firewall
    • Monitoring of port uptime & latency
    • Remote checks that firewalled ports do NOT respond
Knife Cluster:
 Lifecycle Management
• A Plugin for Opscode Chef Knife
• Deployment & Lifecycle Operations:
  • launch, bootstrap, kill, start, stop
• Access and Chef Operations
  • ssh, kick, proxy
• Utilities
  • show, sync
Knife Launch Cluster,
       Facet or Instance[s]
• Launch cluster launchcluster
  knife
         all the nodes in a
                            base0-master0

• Launchcluster launch base0-master0 facet 0
  knife
         just a single instance of a single
                                            master

• Launchclusterinstances base0-master0 regionserver
  knife
         all the
                 launch
                         of a facet
Stop/Start Cluster, Facet
        or Instance[s]
• Stop whole cluster base0-master0
  knife cluster stop

• Stop a cluster stop base0-master0 master 0
  knife
         single instance of a single facet

• Stop allcluster stop abase0-master0 regionserver
  knife
           instances of facet
Same Knife Command to
   Launch Vagrant[s]

• Can use the same cluster configurations
  and knife command to launch Vagrants
  knife cluster vagrant up base0-master0

• Still Experimental
Ironfan-CI
• Jenkins based Continuous Integration of
  Clusters
• Still Experimental
• Uses Discovery to automate baseline test
  creation
• Leverages Vagrant to create clean test
  environments
References
•   Basic Chef Stuff:
    http://wiki.opscode.com/display/chef/Home

•   Ironfan Screencast:
    http://vimeo.com/37279372
•   Ironfan Wiki for the most complete info :
    https://github.com/infochimps-labs/ironfan/wiki

•   The Forest for the Trees Photo - Ame Otoko
    http://www.flickr.com/photos/ameotoko/5383225925/

Mais conteúdo relacionado

Semelhante a Orchestrating HBase Cluster Deployment with Ironfan and Chef

At Scale With Style (Erlang User Conference 2012)
At Scale With Style (Erlang User Conference 2012)At Scale With Style (Erlang User Conference 2012)
At Scale With Style (Erlang User Conference 2012)Wooga
 
Ruby and Rails for womens
Ruby and Rails for womensRuby and Rails for womens
Ruby and Rails for womenss4nx
 
HA Clustering of PostgreSQL(replication)@2012.9.29 PG Study.
HA Clustering of PostgreSQL(replication)@2012.9.29 PG Study.HA Clustering of PostgreSQL(replication)@2012.9.29 PG Study.
HA Clustering of PostgreSQL(replication)@2012.9.29 PG Study.Takatoshi Matsuo
 
Hadoop Conference Japan 2011 Fall
Hadoop Conference Japan 2011 FallHadoop Conference Japan 2011 Fall
Hadoop Conference Japan 2011 FallRyu Kobayashi
 
ARC301 Intro to Chaos Monkey & the Simian Army - AWS re: Invent 2012
ARC301 Intro to Chaos Monkey & the Simian Army - AWS re: Invent 2012ARC301 Intro to Chaos Monkey & the Simian Army - AWS re: Invent 2012
ARC301 Intro to Chaos Monkey & the Simian Army - AWS re: Invent 2012Amazon Web Services
 
Developer's Most Frequent Hadoop Headaches & How to Address Them__HadoopSumm...
Developer's Most Frequent Hadoop Headaches &  How to Address Them__HadoopSumm...Developer's Most Frequent Hadoop Headaches &  How to Address Them__HadoopSumm...
Developer's Most Frequent Hadoop Headaches & How to Address Them__HadoopSumm...Yahoo Developer Network
 
09 - Fábio Akita - Além do rails
09 - Fábio Akita - Além do rails09 - Fábio Akita - Além do rails
09 - Fábio Akita - Além do railsDNAD
 
.NET Architects Day - DNAD 2011
.NET Architects Day - DNAD 2011.NET Architects Day - DNAD 2011
.NET Architects Day - DNAD 2011Fabio Akita
 
UTHOC2 - Under The Hood of Oracle Clusterware 2.0 - Grid Infrastructure by Al...
UTHOC2 - Under The Hood of Oracle Clusterware 2.0 - Grid Infrastructure by Al...UTHOC2 - Under The Hood of Oracle Clusterware 2.0 - Grid Infrastructure by Al...
UTHOC2 - Under The Hood of Oracle Clusterware 2.0 - Grid Infrastructure by Al...Alex Gorbachev
 
Session 49 Practical Semantic Sticky Note
Session 49 Practical Semantic Sticky NoteSession 49 Practical Semantic Sticky Note
Session 49 Practical Semantic Sticky NoteISSGC Summer School
 
Use Cases and Integration Scenarios with SAP Adaptive Computing Virtualization
Use Cases and Integration Scenarios with SAP Adaptive Computing VirtualizationUse Cases and Integration Scenarios with SAP Adaptive Computing Virtualization
Use Cases and Integration Scenarios with SAP Adaptive Computing VirtualizationGunther_01
 
Realtime Apache Hadoop at Facebook
Realtime Apache Hadoop at FacebookRealtime Apache Hadoop at Facebook
Realtime Apache Hadoop at Facebookparallellabs
 
Ram chinta hug-20120922-v1
Ram chinta hug-20120922-v1Ram chinta hug-20120922-v1
Ram chinta hug-20120922-v1Ram Chinta
 
Hummingbird - Open Source for Small Satellites - GSAW 2012
Hummingbird - Open Source for Small Satellites - GSAW 2012Hummingbird - Open Source for Small Satellites - GSAW 2012
Hummingbird - Open Source for Small Satellites - GSAW 2012Logica_hummingbird
 
Session 49 - Semantic metadata management practical
Session 49 - Semantic metadata management practical Session 49 - Semantic metadata management practical
Session 49 - Semantic metadata management practical ISSGC Summer School
 
Rails Metal, Rack, and Sinatra
Rails Metal, Rack, and SinatraRails Metal, Rack, and Sinatra
Rails Metal, Rack, and SinatraAdam Wiggins
 

Semelhante a Orchestrating HBase Cluster Deployment with Ironfan and Chef (20)

At Scale With Style (Erlang User Conference 2012)
At Scale With Style (Erlang User Conference 2012)At Scale With Style (Erlang User Conference 2012)
At Scale With Style (Erlang User Conference 2012)
 
At Scale With Style
At Scale With StyleAt Scale With Style
At Scale With Style
 
Ruby and Rails for womens
Ruby and Rails for womensRuby and Rails for womens
Ruby and Rails for womens
 
HA Clustering of PostgreSQL(replication)@2012.9.29 PG Study.
HA Clustering of PostgreSQL(replication)@2012.9.29 PG Study.HA Clustering of PostgreSQL(replication)@2012.9.29 PG Study.
HA Clustering of PostgreSQL(replication)@2012.9.29 PG Study.
 
Hadoop Conference Japan 2011 Fall
Hadoop Conference Japan 2011 FallHadoop Conference Japan 2011 Fall
Hadoop Conference Japan 2011 Fall
 
ARC301 Intro to Chaos Monkey & the Simian Army - AWS re: Invent 2012
ARC301 Intro to Chaos Monkey & the Simian Army - AWS re: Invent 2012ARC301 Intro to Chaos Monkey & the Simian Army - AWS re: Invent 2012
ARC301 Intro to Chaos Monkey & the Simian Army - AWS re: Invent 2012
 
Ruby on rails
Ruby on railsRuby on rails
Ruby on rails
 
20070329 Tech Study
20070329 Tech Study 20070329 Tech Study
20070329 Tech Study
 
XS Japan 2008 Services English
XS Japan 2008 Services EnglishXS Japan 2008 Services English
XS Japan 2008 Services English
 
Developer's Most Frequent Hadoop Headaches & How to Address Them__HadoopSumm...
Developer's Most Frequent Hadoop Headaches &  How to Address Them__HadoopSumm...Developer's Most Frequent Hadoop Headaches &  How to Address Them__HadoopSumm...
Developer's Most Frequent Hadoop Headaches & How to Address Them__HadoopSumm...
 
09 - Fábio Akita - Além do rails
09 - Fábio Akita - Além do rails09 - Fábio Akita - Além do rails
09 - Fábio Akita - Além do rails
 
.NET Architects Day - DNAD 2011
.NET Architects Day - DNAD 2011.NET Architects Day - DNAD 2011
.NET Architects Day - DNAD 2011
 
UTHOC2 - Under The Hood of Oracle Clusterware 2.0 - Grid Infrastructure by Al...
UTHOC2 - Under The Hood of Oracle Clusterware 2.0 - Grid Infrastructure by Al...UTHOC2 - Under The Hood of Oracle Clusterware 2.0 - Grid Infrastructure by Al...
UTHOC2 - Under The Hood of Oracle Clusterware 2.0 - Grid Infrastructure by Al...
 
Session 49 Practical Semantic Sticky Note
Session 49 Practical Semantic Sticky NoteSession 49 Practical Semantic Sticky Note
Session 49 Practical Semantic Sticky Note
 
Use Cases and Integration Scenarios with SAP Adaptive Computing Virtualization
Use Cases and Integration Scenarios with SAP Adaptive Computing VirtualizationUse Cases and Integration Scenarios with SAP Adaptive Computing Virtualization
Use Cases and Integration Scenarios with SAP Adaptive Computing Virtualization
 
Realtime Apache Hadoop at Facebook
Realtime Apache Hadoop at FacebookRealtime Apache Hadoop at Facebook
Realtime Apache Hadoop at Facebook
 
Ram chinta hug-20120922-v1
Ram chinta hug-20120922-v1Ram chinta hug-20120922-v1
Ram chinta hug-20120922-v1
 
Hummingbird - Open Source for Small Satellites - GSAW 2012
Hummingbird - Open Source for Small Satellites - GSAW 2012Hummingbird - Open Source for Small Satellites - GSAW 2012
Hummingbird - Open Source for Small Satellites - GSAW 2012
 
Session 49 - Semantic metadata management practical
Session 49 - Semantic metadata management practical Session 49 - Semantic metadata management practical
Session 49 - Semantic metadata management practical
 
Rails Metal, Rack, and Sinatra
Rails Metal, Rack, and SinatraRails Metal, Rack, and Sinatra
Rails Metal, Rack, and Sinatra
 

Mais de Robert Berger

Scaling Runa Inc Big Data e-commerce service with AWS
Scaling Runa Inc Big Data e-commerce service with AWSScaling Runa Inc Big Data e-commerce service with AWS
Scaling Runa Inc Big Data e-commerce service with AWSRobert Berger
 
Personal Object Technology
Personal Object TechnologyPersonal Object Technology
Personal Object TechnologyRobert Berger
 
Facilitating Distributed Last Mile Broadband Access Providers
Facilitating Distributed Last Mile Broadband Access ProvidersFacilitating Distributed Last Mile Broadband Access Providers
Facilitating Distributed Last Mile Broadband Access ProvidersRobert Berger
 
The Linux Probability Wave
The Linux Probability WaveThe Linux Probability Wave
The Linux Probability WaveRobert Berger
 
802.11: Ethernet Marches On
802.11: Ethernet Marches On802.11: Ethernet Marches On
802.11: Ethernet Marches OnRobert Berger
 
Wireless commonsense fontsfixed
Wireless commonsense fontsfixedWireless commonsense fontsfixed
Wireless commonsense fontsfixedRobert Berger
 
Deploying infrastructure with Opscode Chef
Deploying infrastructure with Opscode ChefDeploying infrastructure with Opscode Chef
Deploying infrastructure with Opscode ChefRobert Berger
 
Chef 0.8, Knife and Amazon EC2
Chef 0.8, Knife and Amazon EC2Chef 0.8, Knife and Amazon EC2
Chef 0.8, Knife and Amazon EC2Robert Berger
 

Mais de Robert Berger (9)

Scaling Runa Inc Big Data e-commerce service with AWS
Scaling Runa Inc Big Data e-commerce service with AWSScaling Runa Inc Big Data e-commerce service with AWS
Scaling Runa Inc Big Data e-commerce service with AWS
 
Personal Object Technology
Personal Object TechnologyPersonal Object Technology
Personal Object Technology
 
Facilitating Distributed Last Mile Broadband Access Providers
Facilitating Distributed Last Mile Broadband Access ProvidersFacilitating Distributed Last Mile Broadband Access Providers
Facilitating Distributed Last Mile Broadband Access Providers
 
The Linux Probability Wave
The Linux Probability WaveThe Linux Probability Wave
The Linux Probability Wave
 
802.11: Ethernet Marches On
802.11: Ethernet Marches On802.11: Ethernet Marches On
802.11: Ethernet Marches On
 
Open spectrum
Open spectrumOpen spectrum
Open spectrum
 
Wireless commonsense fontsfixed
Wireless commonsense fontsfixedWireless commonsense fontsfixed
Wireless commonsense fontsfixed
 
Deploying infrastructure with Opscode Chef
Deploying infrastructure with Opscode ChefDeploying infrastructure with Opscode Chef
Deploying infrastructure with Opscode Chef
 
Chef 0.8, Knife and Amazon EC2
Chef 0.8, Knife and Amazon EC2Chef 0.8, Knife and Amazon EC2
Chef 0.8, Knife and Amazon EC2
 

Último

DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsSergiu Bodiu
 
Digital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptxDigital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptxLoriGlavin3
 
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxA Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxLoriGlavin3
 
TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024Lonnie McRorey
 
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...Wes McKinney
 
Take control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteTake control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteDianaGray10
 
A Framework for Development in the AI Age
A Framework for Development in the AI AgeA Framework for Development in the AI Age
A Framework for Development in the AI AgeCprime
 
Decarbonising Buildings: Making a net-zero built environment a reality
Decarbonising Buildings: Making a net-zero built environment a realityDecarbonising Buildings: Making a net-zero built environment a reality
Decarbonising Buildings: Making a net-zero built environment a realityIES VE
 
Connecting the Dots for Information Discovery.pdf
Connecting the Dots for Information Discovery.pdfConnecting the Dots for Information Discovery.pdf
Connecting the Dots for Information Discovery.pdfNeo4j
 
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc
 
Generative AI for Technical Writer or Information Developers
Generative AI for Technical Writer or Information DevelopersGenerative AI for Technical Writer or Information Developers
Generative AI for Technical Writer or Information DevelopersRaghuram Pandurangan
 
The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsPixlogix Infotech
 
2024 April Patch Tuesday
2024 April Patch Tuesday2024 April Patch Tuesday
2024 April Patch TuesdayIvanti
 
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptxUse of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptxLoriGlavin3
 
Assure Ecommerce and Retail Operations Uptime with ThousandEyes
Assure Ecommerce and Retail Operations Uptime with ThousandEyesAssure Ecommerce and Retail Operations Uptime with ThousandEyes
Assure Ecommerce and Retail Operations Uptime with ThousandEyesThousandEyes
 
From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .Alan Dix
 
How to write a Business Continuity Plan
How to write a Business Continuity PlanHow to write a Business Continuity Plan
How to write a Business Continuity PlanDatabarracks
 
Manual 508 Accessibility Compliance Audit
Manual 508 Accessibility Compliance AuditManual 508 Accessibility Compliance Audit
Manual 508 Accessibility Compliance AuditSkynet Technologies
 
How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.Curtis Poe
 
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptxPasskey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptxLoriGlavin3
 

Último (20)

DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platforms
 
Digital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptxDigital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptx
 
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxA Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
 
TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024
 
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
 
Take control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteTake control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test Suite
 
A Framework for Development in the AI Age
A Framework for Development in the AI AgeA Framework for Development in the AI Age
A Framework for Development in the AI Age
 
Decarbonising Buildings: Making a net-zero built environment a reality
Decarbonising Buildings: Making a net-zero built environment a realityDecarbonising Buildings: Making a net-zero built environment a reality
Decarbonising Buildings: Making a net-zero built environment a reality
 
Connecting the Dots for Information Discovery.pdf
Connecting the Dots for Information Discovery.pdfConnecting the Dots for Information Discovery.pdf
Connecting the Dots for Information Discovery.pdf
 
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
 
Generative AI for Technical Writer or Information Developers
Generative AI for Technical Writer or Information DevelopersGenerative AI for Technical Writer or Information Developers
Generative AI for Technical Writer or Information Developers
 
The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and Cons
 
2024 April Patch Tuesday
2024 April Patch Tuesday2024 April Patch Tuesday
2024 April Patch Tuesday
 
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptxUse of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
 
Assure Ecommerce and Retail Operations Uptime with ThousandEyes
Assure Ecommerce and Retail Operations Uptime with ThousandEyesAssure Ecommerce and Retail Operations Uptime with ThousandEyes
Assure Ecommerce and Retail Operations Uptime with ThousandEyes
 
From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .
 
How to write a Business Continuity Plan
How to write a Business Continuity PlanHow to write a Business Continuity Plan
How to write a Business Continuity Plan
 
Manual 508 Accessibility Compliance Audit
Manual 508 Accessibility Compliance AuditManual 508 Accessibility Compliance Audit
Manual 508 Accessibility Compliance Audit
 
How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.
 
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptxPasskey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptx
 

Orchestrating HBase Cluster Deployment with Ironfan and Chef

  • 1. Orchestrating Clusters with Ironfan and Chef Robert J. Berger - CTO Runa, Inc. rberger@runa.com
  • 2. Hassles of Big Data Stack Deployments • Lots of Moving Parts • Hadoop/HBase just one sub-system • Heterogeneous Tech • Monitoring & Metrics Everywhere • Details obscure the big picture • Need repeatability & variations on themes
  • 3. The Forest for the Trees
  • 4. Forest Dash App Monitor board Servers Elastic Hadoop AMQP Search M/R Session HBase MySQL Store
  • 5. MySQL Slave Slave Slave Slave Master GDash Statsd Sensu Slave Logstash Slave Ganglia Slave Monitoring Graphite Slave Web Slave Regionsrvr Slave Regionsrvr Slave Hadoop M/R Slave Regionsrvr Trees Sec Master Regionsrvr Master Regionsrvr Regionsrvr Clj App Regionsrvr Clj App Regionsrvr Clj App Regionsrvr App Servers Web Rabbit Regionsrvr Web Rabbit AMQP Regionsrvr ELB HB Master HBase HB Master ZooKeeper ZooKeeper ZooKeeper ES Server ES Server Rails App ES Server Search Elastic Dashboard Rails App ES Server Web Redis Redis Session Store Redis
  • 6. Leaves Dashboard App Servers Monitoring Nginx MySQL Client Elastic Load Balancer MySQL Client Nginx Ganglia Server Reverse Proxy Upstart Config Nginx Upstart Config Reverse Proxy Ganglia Web Unicorn Logstash Client Reverse Proxy Logstash Client Java Statsd Server Rails Swarmiji Leiningen Graphite Server Dashboard App Java Jark Grpahite Web Java Leiningen Postfix Python Postfix Jark Cron jobs Logstash Cron jobs Clojure Apps Sensu Server MySQL Client Sensu client HBase Client Sensu Web Upstart Config Sensu plugins Postfix Sensu Client Logstash Client Cron jobs Sensu Plugins Sensu client Sensu plugins Elastic Search AMQP Hadoop M/R Elastic Search Server RabbitMQ Namenode Java RabbitMQ Plugins Secondary Namenode Cron jobs Cluster Config Tasktracker Sensu client Erlang Jobtrackers Sensu plugins Cron jobs Bootstrap Namenmode Upstart Config Sensu client Java Sensu plugins JMX Upstart Config Cron jobs Sensu client Sensu plugins Ganglia Client Upstart Config Session Store HBase MySQL Redis Namenode Zookeeper MySQL Master Cron jobs Secondary Namenode HBase Master MySQL Slaves Sensu client Tasktracker Regionserver Cluster Setup Sensu plugins Jobtrackers Cron jobs Upstart Config Datanodes Sensu client Bootstrap Namenmode Sensu plugins Java Upstart Config JMX Cron jobs Sensu client Sensu plugins Ganglia Client Upstart Config
  • 7. Molecules <configuration> <property> <name>hbase.rootdir</name> <value>hdfs://ip-10-19-65-58.ec2.internal:8020/hadoop/hbase</value> <description>The directory shared by region servers. Should be fully-qualified to include the filesystem to use. E.g: hdfs://NAMENODE_SERVER:PORT/HBASE_ROOTDIR </description> </property> <property> <name>hbase.cluster.distributed</name> <value>true</value> <description>The mode the cluster will be in. Possible values are false: standalone and pseudo-distributed setups with managed Zookeeper true: fully-distributed with unmanaged Zookeeper Quorum (see hbase-env.sh) </description> </property> <property> <name>hbase.zookeeper.quorum</name> <value>master.example.com,region0.example.com,region1.example.com</value> <description>Comma separated list of servers in the ZooKeeper Quorum. For example, "host1.mydomain.com,host2.mydomain.com,host3.mydomain.com". By default this is set to localhost for local and pseudo-distributed modes of operation. For a fully-distributed setup, this should be set to a full list of ZooKeeper quorum servers. If HBASE_MANAGES_ZK is set in hbase-env.sh this is the list of servers which we will start/stop ZooKeeper on. </description> </property>
  • 8. Config Management: Leaves & Molecules • Chef, Puppet, Cfengine • Much better than shell scripts or cli jocks • Infrastructure as code • Still No Forest Perspective
  • 9. Ironfan: Forest, Trees, Leaves and Molecules • Open Source Project from Infochimps • Builds on top of Chef • Cluster Description in Single File • Your System Diagram Come to Life • Components announce capabilities • Service Discovery automates interconnects • Knife (CLI) extension controls cluster and component life-cycles
  • 10. Basic Chef Community + Own Chef Server Cookbooks Search Auth & ACLs Nodes Roles / Cookbooks Data Bags Attributes N N N Chef Knife: Upload Cookboks to Chef Server N Launch Instances / Bootstrap Servers VMs and/or Servers Running Chef-Client Chef Development Host
  • 11. Chef + Ironfan Community + Own Chef Server Cookbooks Search Auth & ACLs Nodes Roles / Cookbooks Data Bags Attributes N N N Chef Knife + Ironfan Gem: Launch / Bootstrap / Manage N Whole Clusters, All Facets or Specific Instances VMs and/or Servers Running Chef-Client Chef Development Host
  • 12. Ironfan Pantry + Chef + Ironfan Community + Own Chef Server Cookbooks Search / Search Auth & Discovery ACLs Nodes Nodes Attributes Roles / Cookbooks Data Bags Attributes Discovery N N N Chef Knife + Ironfan Gem: Launch / Bootstrap / Manage N Whole Clusters, All Facets or Specific Instances VMs and/or Servers Running Chef-Client Chef Development Host
  • 13. Ironfan Components • Ironfan Gem: • Knife Plugins to orchestrate clusters • Logic to sync Chef Server & Cloud[s] • Silverware: Coordinate Discovery of Services • Ironfan-Homebase: Ironfan tuned Chef-Repo • Ironfan-Pantry: Cookbooks tuned for Clusters • Ironfan-CI: Testing of Ironfan clusters and Cookbooks
  • 14. Cluster Config: Forest View ClusterChef.cluster 'base0-cluster0' do Global setup_role_implications cloud :ec2 do Cloud & Cluster region 'us-east-1' Configs availability_zones ['us-east-1b'] backing 'ebs' image_name 'natty' security_group(cluster_root) do authorize_port_range(22) end end role "base_role" role "chef_client" role "base0-cluster0" role "production" role "runastack" role "ebs_volumes_attach" Roles & Recipes role "ebs_volumes_mount" are the “Leaves” Facets are facet 'master' do the “Trees” instances 1 cloud.image_id 'ami-93c31afa' cloud.flavor "cc1.4xlarge" role "big_package" role "hadoop_master" role "hbase_master" recipe "cluster_chef::cluster_webfront" recipe "hbase::utils" recipe "route53::runa" role "monitored_client" end
  • 15. Global Cloud & Recipe Confgs ClusterChef.cluster 'base0-cluster0' do setup_role_implications Cluster Name cloud :ec2 do Cloud region 'us-east-1' Configs availability_zones ['us-east-1b'] backing 'ebs' Configure image_name 'natty' Security security_group(cluster_root) do Group authorize_port_range(22) end end Shared role "base_role" Roles role "chef_client" role "base0-cluster0" role "production" role "runastack" role "ebs_volumes_attach" role "ebs_volumes_mount"
  • 16. Facet Name Facets add Specifics facet 'master' do Number of Cloud instances 1 Copies Overrides cloud.image_id 'ami-93c31afa' cloud.flavor "cc1.4xlarge" role "hadoop_master" Facet role "hbase_master" Roles & recipe "cluster_chef::cluster_webfront" recipe "hbase::utils" Recipes recipe "route53::runa" role "monitored_client" Facet Name end Number of Cloud facet 'regionserver' do instances 7 Copies Overrides cloud.image_id 'ami-93c31afa' cloud.flavor "cc1.4xlarge" role "hadoop_slave" role "hbase_regionserver" Facet Make one recipe "hbase::utils" Roles & instance recipe "route53::runa" role "monitored_client" Recipes special server 0 do role "zookeeper_server" end end
  • 17. Facets Composed of Components • Components are Services • Nginx, MySQL server, Zookeeper, HBMaster, Namenode, etc. • Chef Cookbooks manage components • Ironfan Silverware for service discovery • Auto-Connects components together
  • 18. Silverware: Service Discovery • Announcements enable Service Discovery • Implemented using Chef Node Attributes • DSL for Chef Attributes • Components announce Services & Amenities • Enables zero-conf for things like Logging, Ports, Dashboard sources, etc. • Announcements effectively define a component's Contract or API
  • 19. Silverware Service Discovery • Recipe that creates a service , announces it announce(:hadoop, :namenode) • Recipe that requires a service , discovers it hbase_config = Mash.new({ :namenode_fqdn => discover(:hadoop, :namenode ).private_hostname), :jobtracker_addr => discover(:hadoop, :jobtracker).private_ip), :zookeeper_addrs => discover_all(:zookeeper, :server).map(&:private_ip).sort, :ganglia => discover(:ganglia, :server), :ganglia_addr => discover(:ganglia, :server).private_hostname), :private_ip => private_ip_of(node) })
  • 20. Silverware: Announce Capabilities • Goes beyond basic component discovery • Capabilities • Serve webpages, execute script, send metrics, answer queries • Aspects • Ports, daemons, logs, files, dashboards
  • 21. Aspects enable Zeroconf Amenities • A log aspect would enable the following amenities • logrotated to manage its logs • flume to archive logs to a location • A port aspect would enable • Configuration of firewall • Monitoring of port uptime & latency • Remote checks that firewalled ports do NOT respond
  • 22. Knife Cluster: Lifecycle Management • A Plugin for Opscode Chef Knife • Deployment & Lifecycle Operations: • launch, bootstrap, kill, start, stop • Access and Chef Operations • ssh, kick, proxy • Utilities • show, sync
  • 23. Knife Launch Cluster, Facet or Instance[s] • Launch cluster launchcluster knife all the nodes in a base0-master0 • Launchcluster launch base0-master0 facet 0 knife just a single instance of a single master • Launchclusterinstances base0-master0 regionserver knife all the launch of a facet
  • 24. Stop/Start Cluster, Facet or Instance[s] • Stop whole cluster base0-master0 knife cluster stop • Stop a cluster stop base0-master0 master 0 knife single instance of a single facet • Stop allcluster stop abase0-master0 regionserver knife instances of facet
  • 25. Same Knife Command to Launch Vagrant[s] • Can use the same cluster configurations and knife command to launch Vagrants knife cluster vagrant up base0-master0 • Still Experimental
  • 26. Ironfan-CI • Jenkins based Continuous Integration of Clusters • Still Experimental • Uses Discovery to automate baseline test creation • Leverages Vagrant to create clean test environments
  • 27. References • Basic Chef Stuff: http://wiki.opscode.com/display/chef/Home • Ironfan Screencast: http://vimeo.com/37279372 • Ironfan Wiki for the most complete info : https://github.com/infochimps-labs/ironfan/wiki • The Forest for the Trees Photo - Ame Otoko http://www.flickr.com/photos/ameotoko/5383225925/

Notas do Editor

  1. \n
  2. \n
  3. \n
  4. \n
  5. \n
  6. \n
  7. \n
  8. \n
  9. \n
  10. \n
  11. \n
  12. \n
  13. \n
  14. \n
  15. \n
  16. \n
  17. \n
  18. \n
  19. \n
  20. \n
  21. \n
  22. \n
  23. \n
  24. \n
  25. \n
  26. \n
  27. \n
  28. \n
  29. \n
  30. \n