More Related Content
Similar to 41a managing services
Similar to 41a managing services (20)
More from mapr-academy (6)
41a managing services
- 2. Managing Services
Agenda
• Review: What are Services?
• Exercise: Managing Services
• The Warden
• Exercise: Stop and Start the Warden
• Service Failover
• Exercise: Failover
• Best Practices
© 2012 MapR Technologies Managing Services 2
- 3. Managing Services
Objectives
At the end of this module you will be able to:
• Identify the different MapR services
• Describe the function that each MapR service provides
• See which services are running on a node
• Describe the purpose of the Warden
• Explain how service failover works
• List the best practices for running MapR services
© 2012 MapR Technologies Managing Services 3
- 5. What Are Services?
Services implement roles
fulfilled by a node
Administrative services:
– ZooKeeper CLDB, JobTracker, NFS,
etc.
Processing services:
– TaskTracker, FileServer, Hbase, etc.
Application services:
– Distinct from scripts or run-at-will
applications like Pig
A daemon called the Warden manages services
© 2012 MapR Technologies Managing Services 5
- 6. Managing Services
Monitoring
JPS/PS
MapR CLI/RESTful API
MCS Dashboard
Starting/stopping
Failover
© 2012 MapR Technologies Managing Services 6
- 7. Exercise:
Managing Services
© 2012 MapR Technologies Managing Services 7
- 8. See What is Running
MCS Dashboard
jps/ps
maprcli dashboard info
© 2012 MapR Technologies Managing Services 8
- 9. Start, Stop, Restart Services
MapR Control System
maprcli node services
-service action (start, stop, restart)
optional
maprcli node services
-action action
-name name
-h to get help
These mechanisms use the warden
© 2012 MapR Technologies Managing Services 9
- 11. The Warden
Knows what should be running
and allocates memory:
warden.conf
/opt/mapr/roles used to
determine services when
configure.sh is run
Manages services and HA for
services
© 2012 MapR Technologies Managing Services 11
- 12. Exercise:
Stop and Start the
Warden
© 2012 MapR Technologies Managing Services 12
- 13. Start/Stop/Restart the Warden
/etc/init.d/mapr-warden stop
/etc/init.d/mapr-warden start
/etc/init.d/mapr-warden restart
© 2012 MapR Technologies Managing Services 13
- 15. Failover
CLDB Warm Standby
Run at will Pig
Followers
ZK
(With a minimum)
Hot spares
NFS
(no minimum)
JT Cold standby
ZooKeeper and NFS are actually more complex
© 2012 MapR Technologies Managing Services 15
- 16. Exercise:
Failover
© 2012 MapR Technologies Managing Services 16
- 17. Failover
Let’s kill a node and see what happens!
© 2012 MapR Technologies Managing Services 17
- 19. Best Practices
Depends on the size of your cluster and load
In general, avoid running compute-intensive services on the same
node
Some suggestions:
– Avoid running ZooKeeper and CLDB together
– If you run TaskTracker on CLDB or ZK nodes, reduce slots
– Avoid running the active JobTracker on the primary CLDB node
– Avoid running the active JobTracker on ZK nodes
© 2012 MapR Technologies Managing Services 19