SlideShare ist ein Scribd-Unternehmen logo
1 von 27
Downloaden Sie, um offline zu lesen
7 Ways To Optimize Hudson/Jenkins
for Production Installation
Kohsuke Kawaguchi
Creator of the Hudson project




                  ©2011 Cloud Bees, Inc. All Rights Reserved
About CloudBees
Our	
  Mission	
       Become	
  the	
  leading	
  Java™	
  Pla3orm	
  as	
  a	
  Service	
  (PaaS)	
  

Why	
  	
  We’re	
     CloudBees	
  services	
  the	
  complete	
  lifecycle	
  of	
  Cloud	
  
Different	
             applica>on	
  development	
  and	
  deployment.	
  
                       No	
  Servers.	
  No	
  Virtual	
  Machines.	
  No	
  IT.	
  

Strategy	
             §  DEV@cloud	
  –	
  Cloud	
  Services	
  for	
  Developers	
  

                       §  RUN@cloud	
  –	
  Fric@onless	
  run@me	
  PaaS	
  for	
  Java	
  apps	
  




                                       ©2011 Cloud Bees, Inc. All Rights                                  2
                                                 Reserved
Continuous Integration - Hudson
Nectar	
  –	
  On-­‐Premise	
  Enterprise	
  Hudson	
  
•  Support	
  from	
  the	
  Hudson	
  experts.	
                              Hudson Adoption, by
•  VMware	
  scale	
  your	
  Hudson	
  environment.	
                               Builds
                                                                         25,000	
  
•  Enterprise	
  Features	
  extend	
  Hudson	
  for	
  large	
  
   environments.	
  
                                                                         20,000	
  
•  Integrate	
  with	
  the	
  Cloud	
  integra@on	
  with	
  
   DEV@Cloud	
  and	
  RUN@Cloud	
  coming	
  
                                                                         15,000	
  
	
  
Benefits	
  of	
  DEV@cloud	
  Hudson	
  Service:	
  
                                                                         10,000	
  
•  Scale	
  your	
  Hudson	
  environment	
  with	
  the	
  
   power	
  of	
  the	
  Cloud	
  
                                                                          5,000	
  
•  Ease	
  your	
  Hudson	
  management	
  overhead	
  
•  Speed	
  your	
  Hudson	
  builds	
  
                                                                                0	
  
•  Save	
  money	
  with	
  on-­‐demand	
  Hudson	
  
   Service.	
  
                                                                                         Source: Hudson Labs
	
  



                                              ©2011 Cloud Bees, Inc. All Rights                                3
                                                        Reserved
Idea Behind This Webinar
•  7 relatively easy techniques you can
   apply today
•  It helps to spend some time setting it up
   “right”
  –  Even if Hudson is easy enough to deploy
  –  Especially for serious production use
•  It’s not too late even if you are already
   running Hudson

                ©2011	
  CloudBees,	
  Inc.	
  AInc. All Reserved	
  
                 ©2011 CloudBees, ll	
  Rights	
   Rights               4
                                Reserved 	
  
#1: Backup
•  Better late than never
•  Useful for
  –  Disaster recovery
  –  Accidental configuration changes




                ©2011	
  CloudBees,	
  Inc.	
  All	
  Rights	
  Reserved	
     5
                                         	
  
#1: Backup Planning
•  Everything is under $HUDSON_HOME
  –  Check system config to see where it is
  –  No need to backup slaves
•  Live vs offline
  –  Live backup is OK
  –  Configuration writes are atomic




                 ©2011	
  CloudBees,	
  Inc.	
  All	
  Rights	
  Reserved	
     6
                                          	
  
#1: Subsetting backup
•    /war    (exploded war)
•    /cache (downloaded tools)
•    /tools (extracted tools)
•    /jobs/*
     –  builds (build records)
     –  builds/*/archive (archived artifacts)
     –  workspace



                   ©2011	
  CloudBees,	
  Inc.	
  All	
  Rights	
  Reserved	
     7
                                            	
  
#1: More on backup
•  File system-level snapshot for maximum
   consistency
  –  LVM
  –  Other storage-level snapshots
     •  Don’t forget fsfreeze
  –  ZFS, if you are on Solaris
     •  Incremental, too


•  Nectar can help you

                   ©2011	
  CloudBees,	
  Inc.	
  All	
  Rights	
  Reserved	
     8
                                            	
  
#1: Testing restore
•  Just copy it somewhere and “java -jar
   hudson.war --httpPort=9999”
  –  HUDSON_HOME is relocateable




               ©2011	
  CloudBees,	
  Inc.	
  All	
  Rights	
  Reserved	
     9
                                        	
  
#2: Disk
•  Prepare for disk usage growth
  –  Especially when you start to host jobs from
     people who aren’t close to you
  –  Make sure you can throw more disks at the
     problem later


•  No need to waste money on 15000rpm
   SCSI disks
  –  But bigger disk is nice


                 ©2011	
  CloudBees,	
  Inc.	
  All	
  Rights	
  Reserved	
     10
                                          	
  
#2: Expandable volume
•  “Spanned volume” on Windows
•  LVM on Linux
  –  This needs the most upfront planning
•  ZFS
  –  Shame there’s no viable free Solaris flavor
  –  $HUDSON_HOME should be its own FS


•  If it’s too late, symlink is your friend

                 ©2011	
  CloudBees,	
  Inc.	
  All	
  Rights	
  Reserved	
     11
                                          	
  
#3: Native packages
•  Comes in .deb/.rpm
  –  Much easier to install/upgrade
  –  Reproducible
  –  init script & daemon user
•  Configuration in
  –  /etc/default/hudson
  –  /etc/sysconfig/hudson
•  Windows --- work in progress
•  Existing $HUDSON_HOME can be
   migrated


                 ©2011	
  CloudBees,	
  Inc.	
  All	
  Rights	
  Reserved	
     12
                                          	
  
#4: Distributed builds
•  You will grow beyond a single system
  –  Load is not the only factor
     •  Better isolation between builds
     •  Diversity in the test/build platform
  –  Cheaper to scale horizontally


•  Let Hudson use multiple computers



                   ©2011	
  CloudBees,	
  Inc.	
  All	
  Rights	
  Reserved	
     13
                                            	
  
Demo
#4: Slave reconnectivity
•  Let master launch slaves (if you can)
  –  Via SSH or DCOM
  –  Easier to keep the cluster up & running
  –  It’s amazing how easily a computer gets sick
•  Set up SSH public key authentication
  –  Login to systems without typing password
  –  Must-have! Inexcusable!
  –  Only takes 5 minutes or so to set up


                ©2011	
  CloudBees,	
  Inc.	
  All	
  Rights	
  Reserved	
     15
                                         	
  
#5: Labels
•  Treat build machines like livestock, not
   like pets
  –  Don’t tie builds to specific build machine
  –  Build machines should be interchangeable
•  Labels, instead of names
  –  Tag slaves by their capabilities/environments
  –  Jobs can be tied to boolean expression of
     labels
•  Better resource utilization, manageability

                ©2011	
  CloudBees,	
  Inc.	
  All	
  Rights	
  Reserved	
     16
                                         	
  
Demo
#6: Invest in good URL
•  If your users can’t see Hudson, much of
   the benefit is lost
  –  Make the URL easier to remember


        hVp://sca14-­‐3530.sca.cloudbees.com:8080/hudson/	
  


        hVp://hudson.cloudbees.com/	
  




                   ©2011	
  CloudBees,	
  Inc.	
  All	
  Rights	
  Reserved	
     18
                                            	
  
#6: Use service name
•  Get the host alias, instead of using
   primary machine name
  –  If your IT isn’t helping, use dynamic DNS
  –  This also makes your service relocatable




                ©2011	
  CloudBees,	
  Inc.	
  All	
  Rights	
  Reserved	
     19
                                         	
  
#6: Share port 80 with other apps
•  Apache reverse proxy
  –  Let you run Hudson in non-root, too

    browser	
                                            Apache	
                Hudson	
  



•  For Windows
  –  IIS7+URL Rewrite+Application Request
     Routing



                  ©2011	
  CloudBees,	
  Inc.	
  All	
  Rights	
  Reserved	
                  20
                                           	
  
#6: No “/hudson”
•  Use virtual host to distinguish multiple
   apps, not context path

                                                                                             Hudson	
  


    browser	
                                                   Apache	
  /	
  IIS	
  


                  hVp://hudson.cloudbees.com/	
                                              Redmine	
  
                  hVp://redmine.cloudbees.com/	
  




                              ©2011	
  CloudBees,	
  Inc.	
  All	
  Rights	
  Reserved	
                   21
                                                       	
  
#7: Keeping build records under control
•  Discard old build records if you can
  –  Helps start-up time, memory usage
  –  Often feasible, for example CI builds
•  Setting is per-project basis




•  The point is to avoid unbounded
   consumption. Don’t go overboard
                ©2011	
  CloudBees,	
  Inc.	
  All	
  Rights	
  Reserved	
     22
                                         	
  
Demo
Conclusion
•  7 tips
   –  Backup
   –  Disk planning
   –  Native packages
   –  Distributed builds
   –  Labels
   –  Reverse proxy
   –  Discard build records


                 ©2011	
  CloudBees,	
  Inc.	
  All	
  Rights	
  Reserved	
     24
                                          	
  
CloudBees Resources
•  CloudBees
   –  http://www.cloudbees.com/
•  Nectar
   –  http://nectar.cloudbees.com/
•  Try Dev@Cloud
   –  https://grandcentral.cloudbees.com/account/signup
•  Register for news from CloudBees
   –  http://www.cloudbees.com/company.cb
•  CloudBees on YouTube: new videos soon
   –  http://www.youtube.com/user/CloudBeesTV




                            ©2011	
  CloudBees,	
  Inc.	
  All	
  Rights	
  Reserved	
     25
                                                     	
  
Coming Soon: 1 Day Hudson Training
•  Instructor-led
•  More comprehensive, all-round
•  London, New York, and Tokyo

•  To receive updates:
  –  http://www.cloudbees.com/company.cb




               ©2011	
  CloudBees,	
  Inc.	
  All	
  Rights	
  Reserved	
     26
                                        	
  
Q&A




      ©2011 CloudBees, Inc. All Rights
                Reserved

Weitere ähnliche Inhalte

Was ist angesagt?

Automated Deployment Pipeline using Jenkins, Puppet, Mcollective and AWS
Automated Deployment Pipeline using Jenkins, Puppet, Mcollective and AWSAutomated Deployment Pipeline using Jenkins, Puppet, Mcollective and AWS
Automated Deployment Pipeline using Jenkins, Puppet, Mcollective and AWS
Bamdad Dashtban
 
Using Containers for Building and Testing: Docker, Kubernetes and Mesos. FOSD...
Using Containers for Building and Testing: Docker, Kubernetes and Mesos. FOSD...Using Containers for Building and Testing: Docker, Kubernetes and Mesos. FOSD...
Using Containers for Building and Testing: Docker, Kubernetes and Mesos. FOSD...
Carlos Sanchez
 
SF DevOps: Introducing Vagrant
SF DevOps: Introducing VagrantSF DevOps: Introducing Vagrant
SF DevOps: Introducing Vagrant
Mitchell Hashimoto
 
Docker, a new LINUX container technology based light weight virtualization
Docker, a new LINUX container technology based light weight virtualizationDocker, a new LINUX container technology based light weight virtualization
Docker, a new LINUX container technology based light weight virtualization
Suresh Balla
 

Was ist angesagt? (20)

What's New in Docker 1.12 by Nishant Totla for Docker SF Meetup 08.03.16
What's New in Docker 1.12 by Nishant Totla for Docker SF Meetup 08.03.16 What's New in Docker 1.12 by Nishant Totla for Docker SF Meetup 08.03.16
What's New in Docker 1.12 by Nishant Totla for Docker SF Meetup 08.03.16
 
Solving Real World Production Problems with Docker
Solving Real World Production Problems with DockerSolving Real World Production Problems with Docker
Solving Real World Production Problems with Docker
 
Java Developer Intro to Environment Management with Vagrant, Puppet, and Dock...
Java Developer Intro to Environment Management with Vagrant, Puppet, and Dock...Java Developer Intro to Environment Management with Vagrant, Puppet, and Dock...
Java Developer Intro to Environment Management with Vagrant, Puppet, and Dock...
 
Automated Deployment Pipeline using Jenkins, Puppet, Mcollective and AWS
Automated Deployment Pipeline using Jenkins, Puppet, Mcollective and AWSAutomated Deployment Pipeline using Jenkins, Puppet, Mcollective and AWS
Automated Deployment Pipeline using Jenkins, Puppet, Mcollective and AWS
 
Docker Ecosystem on Azure
Docker Ecosystem on AzureDocker Ecosystem on Azure
Docker Ecosystem on Azure
 
Using Containers for Building and Testing: Docker, Kubernetes and Mesos. FOSD...
Using Containers for Building and Testing: Docker, Kubernetes and Mesos. FOSD...Using Containers for Building and Testing: Docker, Kubernetes and Mesos. FOSD...
Using Containers for Building and Testing: Docker, Kubernetes and Mesos. FOSD...
 
Puppet and Vagrant in development
Puppet and Vagrant in developmentPuppet and Vagrant in development
Puppet and Vagrant in development
 
SF DevOps: Introducing Vagrant
SF DevOps: Introducing VagrantSF DevOps: Introducing Vagrant
SF DevOps: Introducing Vagrant
 
Immutable infrastructure with Docker and containers (GlueCon 2015)
Immutable infrastructure with Docker and containers (GlueCon 2015)Immutable infrastructure with Docker and containers (GlueCon 2015)
Immutable infrastructure with Docker and containers (GlueCon 2015)
 
Docker introduction
Docker introductionDocker introduction
Docker introduction
 
Introduction to docker
Introduction to dockerIntroduction to docker
Introduction to docker
 
Introduction to Docker and all things containers, Docker Meetup at RelateIQ
Introduction to Docker and all things containers, Docker Meetup at RelateIQIntroduction to Docker and all things containers, Docker Meetup at RelateIQ
Introduction to Docker and all things containers, Docker Meetup at RelateIQ
 
Bare-metal, Docker Containers, and Virtualization: The Growing Choices for Cl...
Bare-metal, Docker Containers, and Virtualization: The Growing Choices for Cl...Bare-metal, Docker Containers, and Virtualization: The Growing Choices for Cl...
Bare-metal, Docker Containers, and Virtualization: The Growing Choices for Cl...
 
The Lies We Tell Our Code (#seascale 2015 04-22)
The Lies We Tell Our Code (#seascale 2015 04-22)The Lies We Tell Our Code (#seascale 2015 04-22)
The Lies We Tell Our Code (#seascale 2015 04-22)
 
Docker Tips And Tricks at the Docker Beijing Meetup
Docker Tips And Tricks at the Docker Beijing MeetupDocker Tips And Tricks at the Docker Beijing Meetup
Docker Tips And Tricks at the Docker Beijing Meetup
 
Docker for developers
Docker for developersDocker for developers
Docker for developers
 
Introduction to docker
Introduction to dockerIntroduction to docker
Introduction to docker
 
Testing Distributed Micro Services. Agile Testing Days 2017
Testing Distributed Micro Services. Agile Testing Days 2017Testing Distributed Micro Services. Agile Testing Days 2017
Testing Distributed Micro Services. Agile Testing Days 2017
 
Docker, a new LINUX container technology based light weight virtualization
Docker, a new LINUX container technology based light weight virtualizationDocker, a new LINUX container technology based light weight virtualization
Docker, a new LINUX container technology based light weight virtualization
 
Microservices: How loose is loosely coupled?
Microservices: How loose is loosely coupled?Microservices: How loose is loosely coupled?
Microservices: How loose is loosely coupled?
 

Ähnlich wie 7 Ways to Optimize Hudson in Production

Hadoop in the Clouds, Virtualization and Virtual Machines
Hadoop in the Clouds, Virtualization and Virtual MachinesHadoop in the Clouds, Virtualization and Virtual Machines
Hadoop in the Clouds, Virtualization and Virtual Machines
DataWorks Summit
 
Hadoop Operations – Past, Present, and Future
Hadoop Operations – Past, Present, and FutureHadoop Operations – Past, Present, and Future
Hadoop Operations – Past, Present, and Future
DataWorks Summit
 

Ähnlich wie 7 Ways to Optimize Hudson in Production (20)

Securing jenkins
Securing jenkinsSecuring jenkins
Securing jenkins
 
Cloud for agile_sw_projects-final
Cloud for agile_sw_projects-finalCloud for agile_sw_projects-final
Cloud for agile_sw_projects-final
 
Webinar: Productionizing Hadoop: Lessons Learned - 20101208
Webinar: Productionizing Hadoop: Lessons Learned - 20101208Webinar: Productionizing Hadoop: Lessons Learned - 20101208
Webinar: Productionizing Hadoop: Lessons Learned - 20101208
 
Make a Move to the Azure Cloud with SoftNAS
Make a Move to the Azure Cloud with SoftNASMake a Move to the Azure Cloud with SoftNAS
Make a Move to the Azure Cloud with SoftNAS
 
Hadoop in the Clouds, Virtualization and Virtual Machines
Hadoop in the Clouds, Virtualization and Virtual MachinesHadoop in the Clouds, Virtualization and Virtual Machines
Hadoop in the Clouds, Virtualization and Virtual Machines
 
The Kubernetes WebLogic revival (part 1)
The Kubernetes WebLogic revival (part 1)The Kubernetes WebLogic revival (part 1)
The Kubernetes WebLogic revival (part 1)
 
20191201 kubernetes managed weblogic revival - part 1
20191201 kubernetes managed weblogic revival - part 120191201 kubernetes managed weblogic revival - part 1
20191201 kubernetes managed weblogic revival - part 1
 
Getting the Most Out of Your Data in the Cloud with Cloudbreak
Getting the Most Out of Your Data in the Cloud with CloudbreakGetting the Most Out of Your Data in the Cloud with Cloudbreak
Getting the Most Out of Your Data in the Cloud with Cloudbreak
 
Infoblox Cloud Solutions - Cisco Mid-Atlantic User Group
Infoblox Cloud Solutions - Cisco Mid-Atlantic User GroupInfoblox Cloud Solutions - Cisco Mid-Atlantic User Group
Infoblox Cloud Solutions - Cisco Mid-Atlantic User Group
 
Hadoop Operations – Past, Present, and Future
Hadoop Operations – Past, Present, and FutureHadoop Operations – Past, Present, and Future
Hadoop Operations – Past, Present, and Future
 
Mesosphere and the Enterprise: Run Your Applications on Apache Mesos - Steve ...
Mesosphere and the Enterprise: Run Your Applications on Apache Mesos - Steve ...Mesosphere and the Enterprise: Run Your Applications on Apache Mesos - Steve ...
Mesosphere and the Enterprise: Run Your Applications on Apache Mesos - Steve ...
 
Postgres Plus Cloud Database
Postgres Plus Cloud DatabasePostgres Plus Cloud Database
Postgres Plus Cloud Database
 
Structor - Automated Building of Virtual Hadoop Clusters
Structor - Automated Building of Virtual Hadoop ClustersStructor - Automated Building of Virtual Hadoop Clusters
Structor - Automated Building of Virtual Hadoop Clusters
 
Hadoop Operations
Hadoop OperationsHadoop Operations
Hadoop Operations
 
Managing ScaleIO as Software on Mesos - David vonThenen - Dell EMC World 2017
Managing ScaleIO as Software on Mesos - David vonThenen - Dell EMC World 2017Managing ScaleIO as Software on Mesos - David vonThenen - Dell EMC World 2017
Managing ScaleIO as Software on Mesos - David vonThenen - Dell EMC World 2017
 
Flume and HBase
Flume and HBase Flume and HBase
Flume and HBase
 
Hadoop Everywhere & Cloudbreak
Hadoop Everywhere & CloudbreakHadoop Everywhere & Cloudbreak
Hadoop Everywhere & Cloudbreak
 
Hortonworks Technical Workshop: HDP everywhere - cloud considerations using...
Hortonworks Technical Workshop:   HDP everywhere - cloud considerations using...Hortonworks Technical Workshop:   HDP everywhere - cloud considerations using...
Hortonworks Technical Workshop: HDP everywhere - cloud considerations using...
 
Postgres & Red Hat Cluster Suite
Postgres & Red Hat Cluster SuitePostgres & Red Hat Cluster Suite
Postgres & Red Hat Cluster Suite
 
Google does containers: Hello Kubernetes - Steve Wong and Vladimir Vivien - D...
Google does containers: Hello Kubernetes - Steve Wong and Vladimir Vivien - D...Google does containers: Hello Kubernetes - Steve Wong and Vladimir Vivien - D...
Google does containers: Hello Kubernetes - Steve Wong and Vladimir Vivien - D...
 

Mehr von CloudBees

Mehr von CloudBees (20)

JUC Europe 2015: Scaling Your Jenkins Master with Docker
JUC Europe 2015: Scaling Your Jenkins Master with DockerJUC Europe 2015: Scaling Your Jenkins Master with Docker
JUC Europe 2015: Scaling Your Jenkins Master with Docker
 
JUC Europe 2015: Plugin Development with Gradle and Groovy
JUC Europe 2015: Plugin Development with Gradle and GroovyJUC Europe 2015: Plugin Development with Gradle and Groovy
JUC Europe 2015: Plugin Development with Gradle and Groovy
 
JUC Europe 2015: Multi-Node Environment as a Jenkins Slave (Compound-Slave)
JUC Europe 2015: Multi-Node Environment as a Jenkins Slave (Compound-Slave)JUC Europe 2015: Multi-Node Environment as a Jenkins Slave (Compound-Slave)
JUC Europe 2015: Multi-Node Environment as a Jenkins Slave (Compound-Slave)
 
JUC Europe 2015: The Famous Cows of Cambridge: A Non-Standard Use Case for Je...
JUC Europe 2015: The Famous Cows of Cambridge: A Non-Standard Use Case for Je...JUC Europe 2015: The Famous Cows of Cambridge: A Non-Standard Use Case for Je...
JUC Europe 2015: The Famous Cows of Cambridge: A Non-Standard Use Case for Je...
 
JUC Europe 2015: Jenkins Made Easy
JUC Europe 2015: Jenkins Made EasyJUC Europe 2015: Jenkins Made Easy
JUC Europe 2015: Jenkins Made Easy
 
JUC Europe 2015: Scaling of Jenkins Pipeline Creation and Maintenance
JUC Europe 2015: Scaling of Jenkins Pipeline Creation and MaintenanceJUC Europe 2015: Scaling of Jenkins Pipeline Creation and Maintenance
JUC Europe 2015: Scaling of Jenkins Pipeline Creation and Maintenance
 
JUC Europe 2015: From Virtual Machines to Containers: Achieving Continuous In...
JUC Europe 2015: From Virtual Machines to Containers: Achieving Continuous In...JUC Europe 2015: From Virtual Machines to Containers: Achieving Continuous In...
JUC Europe 2015: From Virtual Machines to Containers: Achieving Continuous In...
 
JUC Europe 2015: Hey! What Did We Just Release?
JUC Europe 2015: Hey! What Did We Just Release?JUC Europe 2015: Hey! What Did We Just Release?
JUC Europe 2015: Hey! What Did We Just Release?
 
JUC Europe 2015: Orchestrating Your Pipelines with Jenkins, Python and the Je...
JUC Europe 2015: Orchestrating Your Pipelines with Jenkins, Python and the Je...JUC Europe 2015: Orchestrating Your Pipelines with Jenkins, Python and the Je...
JUC Europe 2015: Orchestrating Your Pipelines with Jenkins, Python and the Je...
 
JUC Europe 2015: Jenkins Pipeline for Continuous Delivery of Big Data Projects
JUC Europe 2015: Jenkins Pipeline for Continuous Delivery of Big Data ProjectsJUC Europe 2015: Jenkins Pipeline for Continuous Delivery of Big Data Projects
JUC Europe 2015: Jenkins Pipeline for Continuous Delivery of Big Data Projects
 
JUC Europe 2015: Jenkins-Based Continuous Integration for Heterogeneous Hardw...
JUC Europe 2015: Jenkins-Based Continuous Integration for Heterogeneous Hardw...JUC Europe 2015: Jenkins-Based Continuous Integration for Heterogeneous Hardw...
JUC Europe 2015: Jenkins-Based Continuous Integration for Heterogeneous Hardw...
 
JUC Europe 2015: Optimizing Your CI: Lessons Learned from a Successful Jenkin...
JUC Europe 2015: Optimizing Your CI: Lessons Learned from a Successful Jenkin...JUC Europe 2015: Optimizing Your CI: Lessons Learned from a Successful Jenkin...
JUC Europe 2015: Optimizing Your CI: Lessons Learned from a Successful Jenkin...
 
JUC Europe 2015: Enabling Continuous Delivery for Major Retailers
JUC Europe 2015: Enabling Continuous Delivery for Major RetailersJUC Europe 2015: Enabling Continuous Delivery for Major Retailers
JUC Europe 2015: Enabling Continuous Delivery for Major Retailers
 
JUC Europe 2015: Bringing CD at Cloud-Scale with Jenkins, Docker and "Tiger"
JUC Europe 2015: Bringing CD at Cloud-Scale with Jenkins, Docker and "Tiger"JUC Europe 2015: Bringing CD at Cloud-Scale with Jenkins, Docker and "Tiger"
JUC Europe 2015: Bringing CD at Cloud-Scale with Jenkins, Docker and "Tiger"
 
JUC Europe 2015: Making Strides towards Enterprise-Scale DevOps...with Jenkin...
JUC Europe 2015: Making Strides towards Enterprise-Scale DevOps...with Jenkin...JUC Europe 2015: Making Strides towards Enterprise-Scale DevOps...with Jenkin...
JUC Europe 2015: Making Strides towards Enterprise-Scale DevOps...with Jenkin...
 
JUC Europe 2015: Evolving the Jenkins UI
JUC Europe 2015: Evolving the Jenkins UIJUC Europe 2015: Evolving the Jenkins UI
JUC Europe 2015: Evolving the Jenkins UI
 
JUC Europe 2015: Using Infrastructure Nodes Wisely With Jenkins and Apache Mesos
JUC Europe 2015: Using Infrastructure Nodes Wisely With Jenkins and Apache MesosJUC Europe 2015: Using Infrastructure Nodes Wisely With Jenkins and Apache Mesos
JUC Europe 2015: Using Infrastructure Nodes Wisely With Jenkins and Apache Mesos
 
JUC Europe 2015: How to Optimize Automated Testing with Everyone's Favorite B...
JUC Europe 2015: How to Optimize Automated Testing with Everyone's Favorite B...JUC Europe 2015: How to Optimize Automated Testing with Everyone's Favorite B...
JUC Europe 2015: How to Optimize Automated Testing with Everyone's Favorite B...
 
JUC 2015 - Keynote Address and Opening Remarks by Kohsuke Kawaguchi, Founder,...
JUC 2015 - Keynote Address and Opening Remarks by Kohsuke Kawaguchi, Founder,...JUC 2015 - Keynote Address and Opening Remarks by Kohsuke Kawaguchi, Founder,...
JUC 2015 - Keynote Address and Opening Remarks by Kohsuke Kawaguchi, Founder,...
 
JUC Europe 2015: Continuous Integration and Distribution in the Cloud with DE...
JUC Europe 2015: Continuous Integration and Distribution in the Cloud with DE...JUC Europe 2015: Continuous Integration and Distribution in the Cloud with DE...
JUC Europe 2015: Continuous Integration and Distribution in the Cloud with DE...
 

Kürzlich hochgeladen

IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
Enterprise Knowledge
 

Kürzlich hochgeladen (20)

How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
Evaluating the top large language models.pdf
Evaluating the top large language models.pdfEvaluating the top large language models.pdf
Evaluating the top large language models.pdf
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 

7 Ways to Optimize Hudson in Production

  • 1. 7 Ways To Optimize Hudson/Jenkins for Production Installation Kohsuke Kawaguchi Creator of the Hudson project ©2011 Cloud Bees, Inc. All Rights Reserved
  • 2. About CloudBees Our  Mission   Become  the  leading  Java™  Pla3orm  as  a  Service  (PaaS)   Why    We’re   CloudBees  services  the  complete  lifecycle  of  Cloud   Different   applica>on  development  and  deployment.   No  Servers.  No  Virtual  Machines.  No  IT.   Strategy   §  DEV@cloud  –  Cloud  Services  for  Developers   §  RUN@cloud  –  Fric@onless  run@me  PaaS  for  Java  apps   ©2011 Cloud Bees, Inc. All Rights 2 Reserved
  • 3. Continuous Integration - Hudson Nectar  –  On-­‐Premise  Enterprise  Hudson   •  Support  from  the  Hudson  experts.   Hudson Adoption, by •  VMware  scale  your  Hudson  environment.   Builds 25,000   •  Enterprise  Features  extend  Hudson  for  large   environments.   20,000   •  Integrate  with  the  Cloud  integra@on  with   DEV@Cloud  and  RUN@Cloud  coming   15,000     Benefits  of  DEV@cloud  Hudson  Service:   10,000   •  Scale  your  Hudson  environment  with  the   power  of  the  Cloud   5,000   •  Ease  your  Hudson  management  overhead   •  Speed  your  Hudson  builds   0   •  Save  money  with  on-­‐demand  Hudson   Service.   Source: Hudson Labs   ©2011 Cloud Bees, Inc. All Rights 3 Reserved
  • 4. Idea Behind This Webinar •  7 relatively easy techniques you can apply today •  It helps to spend some time setting it up “right” –  Even if Hudson is easy enough to deploy –  Especially for serious production use •  It’s not too late even if you are already running Hudson ©2011  CloudBees,  Inc.  AInc. All Reserved   ©2011 CloudBees, ll  Rights   Rights 4 Reserved  
  • 5. #1: Backup •  Better late than never •  Useful for –  Disaster recovery –  Accidental configuration changes ©2011  CloudBees,  Inc.  All  Rights  Reserved   5  
  • 6. #1: Backup Planning •  Everything is under $HUDSON_HOME –  Check system config to see where it is –  No need to backup slaves •  Live vs offline –  Live backup is OK –  Configuration writes are atomic ©2011  CloudBees,  Inc.  All  Rights  Reserved   6  
  • 7. #1: Subsetting backup •  /war (exploded war) •  /cache (downloaded tools) •  /tools (extracted tools) •  /jobs/* –  builds (build records) –  builds/*/archive (archived artifacts) –  workspace ©2011  CloudBees,  Inc.  All  Rights  Reserved   7  
  • 8. #1: More on backup •  File system-level snapshot for maximum consistency –  LVM –  Other storage-level snapshots •  Don’t forget fsfreeze –  ZFS, if you are on Solaris •  Incremental, too •  Nectar can help you ©2011  CloudBees,  Inc.  All  Rights  Reserved   8  
  • 9. #1: Testing restore •  Just copy it somewhere and “java -jar hudson.war --httpPort=9999” –  HUDSON_HOME is relocateable ©2011  CloudBees,  Inc.  All  Rights  Reserved   9  
  • 10. #2: Disk •  Prepare for disk usage growth –  Especially when you start to host jobs from people who aren’t close to you –  Make sure you can throw more disks at the problem later •  No need to waste money on 15000rpm SCSI disks –  But bigger disk is nice ©2011  CloudBees,  Inc.  All  Rights  Reserved   10  
  • 11. #2: Expandable volume •  “Spanned volume” on Windows •  LVM on Linux –  This needs the most upfront planning •  ZFS –  Shame there’s no viable free Solaris flavor –  $HUDSON_HOME should be its own FS •  If it’s too late, symlink is your friend ©2011  CloudBees,  Inc.  All  Rights  Reserved   11  
  • 12. #3: Native packages •  Comes in .deb/.rpm –  Much easier to install/upgrade –  Reproducible –  init script & daemon user •  Configuration in –  /etc/default/hudson –  /etc/sysconfig/hudson •  Windows --- work in progress •  Existing $HUDSON_HOME can be migrated ©2011  CloudBees,  Inc.  All  Rights  Reserved   12  
  • 13. #4: Distributed builds •  You will grow beyond a single system –  Load is not the only factor •  Better isolation between builds •  Diversity in the test/build platform –  Cheaper to scale horizontally •  Let Hudson use multiple computers ©2011  CloudBees,  Inc.  All  Rights  Reserved   13  
  • 14. Demo
  • 15. #4: Slave reconnectivity •  Let master launch slaves (if you can) –  Via SSH or DCOM –  Easier to keep the cluster up & running –  It’s amazing how easily a computer gets sick •  Set up SSH public key authentication –  Login to systems without typing password –  Must-have! Inexcusable! –  Only takes 5 minutes or so to set up ©2011  CloudBees,  Inc.  All  Rights  Reserved   15  
  • 16. #5: Labels •  Treat build machines like livestock, not like pets –  Don’t tie builds to specific build machine –  Build machines should be interchangeable •  Labels, instead of names –  Tag slaves by their capabilities/environments –  Jobs can be tied to boolean expression of labels •  Better resource utilization, manageability ©2011  CloudBees,  Inc.  All  Rights  Reserved   16  
  • 17. Demo
  • 18. #6: Invest in good URL •  If your users can’t see Hudson, much of the benefit is lost –  Make the URL easier to remember hVp://sca14-­‐3530.sca.cloudbees.com:8080/hudson/   hVp://hudson.cloudbees.com/   ©2011  CloudBees,  Inc.  All  Rights  Reserved   18  
  • 19. #6: Use service name •  Get the host alias, instead of using primary machine name –  If your IT isn’t helping, use dynamic DNS –  This also makes your service relocatable ©2011  CloudBees,  Inc.  All  Rights  Reserved   19  
  • 20. #6: Share port 80 with other apps •  Apache reverse proxy –  Let you run Hudson in non-root, too browser   Apache   Hudson   •  For Windows –  IIS7+URL Rewrite+Application Request Routing ©2011  CloudBees,  Inc.  All  Rights  Reserved   20  
  • 21. #6: No “/hudson” •  Use virtual host to distinguish multiple apps, not context path Hudson   browser   Apache  /  IIS   hVp://hudson.cloudbees.com/   Redmine   hVp://redmine.cloudbees.com/   ©2011  CloudBees,  Inc.  All  Rights  Reserved   21  
  • 22. #7: Keeping build records under control •  Discard old build records if you can –  Helps start-up time, memory usage –  Often feasible, for example CI builds •  Setting is per-project basis •  The point is to avoid unbounded consumption. Don’t go overboard ©2011  CloudBees,  Inc.  All  Rights  Reserved   22  
  • 23. Demo
  • 24. Conclusion •  7 tips –  Backup –  Disk planning –  Native packages –  Distributed builds –  Labels –  Reverse proxy –  Discard build records ©2011  CloudBees,  Inc.  All  Rights  Reserved   24  
  • 25. CloudBees Resources •  CloudBees –  http://www.cloudbees.com/ •  Nectar –  http://nectar.cloudbees.com/ •  Try Dev@Cloud –  https://grandcentral.cloudbees.com/account/signup •  Register for news from CloudBees –  http://www.cloudbees.com/company.cb •  CloudBees on YouTube: new videos soon –  http://www.youtube.com/user/CloudBeesTV ©2011  CloudBees,  Inc.  All  Rights  Reserved   25  
  • 26. Coming Soon: 1 Day Hudson Training •  Instructor-led •  More comprehensive, all-round •  London, New York, and Tokyo •  To receive updates: –  http://www.cloudbees.com/company.cb ©2011  CloudBees,  Inc.  All  Rights  Reserved   26  
  • 27. Q&A ©2011 CloudBees, Inc. All Rights Reserved