Course Outline
Module 1: Introduction and MongoDB Architecture (4h)
Curriculum:
- Historical context and the MongoDB ecosystem.
- Typical application scenarios, along with their advantages and limitations.
- Core architectural components: instances, processes, and configuration layers.
Practical Application:
- Interactive exploration via Mongo Shell and CLI connections.
- Creation of a sample database and collection.
Module 2: Installation and Initial Configuration (6h)
Curriculum:
- Hardware and resource prerequisites.
- Deployment procedures on Linux (deb/rpm), Windows, and macOS.
- Configuration via YAML files (mongod.conf): managing dataDir, logDir, bindIp, and port settings.
- Startup parameters and systemd/service management protocols.
Practical Application:
- Provisioning instances on local VMs or Docker containers.
- Tuning configurations for both development and production contexts.
- Validating secure remote connectivity protocols.
Module 3: Data Modeling and Basic Operations (5h)
Curriculum:
- Understanding BSON documents, collections, and database structures.
- Modeling strategies: embedding versus referencing; data design patterns.
- Foundations of basic indexing (introduced previously).
- Executing operations via Mongo Shell and scripting examples using native drivers.
Practical Application:
- Modeling a specific use case, such as an inventory or billing system.
- Implementing standard CRUD operations.
- Applying schema validation using JSON Schema within MongoDB.
Module 4: Indexes and Performance (4h)
Curriculum:
- Types of indexes: simple, compound, multikey, text, and geospatial.
- Utilizing explain() to analyze query metrics.
- Evaluating the impact of indexes on write performance and memory usage.
Practical Application:
- Populating collections with test data.
- Testing query performance with and without indexes; interpreting explain() outputs.
- Optimizing index strategies based on observed access patterns.
Module 5: Security (5h)
Curriculum:
- Authentication mechanisms: SCRAM, and introductory LDAP/Kerberos integration.
- Defining user accounts and custom roles.
- Implementing TLS/SSL encryption between clients and servers.
- Configuring at-rest encryption keys.
- Setting up basic audit logging.
Practical Application:
- Creating user accounts with least-privilege access.
- Configuring TLS on local instances.
- Testing unauthorized access attempts and reviewing generated audit logs.
Module 6: Replication and High Availability (6h)
Curriculum:
- Core replication concepts: Primary nodes, Secondary nodes, and oplogs.
- Replica set configuration: initiation, membership management, and arbitration.
- Monitoring cluster status and election processes.
- Maintenance tasks: adding or removing members and reassigning priorities.
Practical Application:
- Deploying a three-node replica set (locally or on VMs).
- Simulating a primary node failure to observe failover behavior.
- Rebuilding secondary nodes and recovering replica states.
Module 7: Sharding and Horizontal Scalability (6h)
Curriculum:
- Sharding fundamentals: shard keys, config servers, and mongos routers.
- Shard key selection strategies and associated risks.
- Deploying config servers, shards, and mongos instances.
- Managing rebalancing and chunk migration.
Practical Application:
- Configuring a basic sharded cluster.
- Inserting large datasets to observe data distribution.
- Exploring shard key modification and understanding its limitations.
Module 8: Backup, Restore, and Disaster Recovery (4h)
Curriculum:
- Utilizing native tools: mongodump/mongorestore and filesystem snapshots.
- Executing backups across replica sets and sharded clusters.
- Basic backup management using Cloud Manager or Ops Manager.
- Disaster Recovery (DR) planning: defining RTO and RPO.
Practical Application:
- Performing backup and restore cycles on a test database.
- Simulating system failures and recovering from backups.
- Designing a DR plan for a hypothetical scenario.
Module 9: Monitoring and Alerts (4h)
Curriculum:
- Monitoring tools: mongostat, mongotop, and Cloud Manager/Atlas Monitoring.
- Integration concepts with Prometheus and Grafana.
- Tracking key metrics: CPU, memory, I/O, oplog size, and latencies.
- Configuring alerts: defining thresholds and notification routes.
Practical Application:
- Deploying local or container-based monitoring agents.
- Setting up basic dashboards with sample metrics.
- Simulating load scenarios to observe alert triggers.
Module 10: Maintenance, Upgrades, and Best Practices (4h)
Curriculum:
- Upgrade strategies for both replica sets and sharded clusters.
- Data cleanup, compaction, and integrity checks.
- Reviewing logs and conducting regular security audits.
- Automating routine tasks using scripts, cronjobs, Ansible, or Terraform.
- Establishing data retention and archiving policies.
Practical Application:
- Simulating minor and major upgrades in a controlled environment.
- Developing automation scripts for backup and monitoring workflows.
- Creating a periodic maintenance checklist.
Summary and Next Steps
Requirements
- A solid grasp of fundamental database concepts and data structures.
- Proficiency with Linux command-line operations.
- Foundational knowledge of networking and system administration.
Target Audience
- Database administrators and system engineers responsible for MongoDB environments.
- DevOps and infrastructure teams tasked with deploying and sustaining MongoDB stacks.
- Developers looking to deepen their understanding of MongoDB internals and deployment best practices.
Testimonials (2)
The pace of talking and explanation.
Marko Skokovic - PWO by Lottomatica Serbia
Course - MongoDB for Administrators
Sir Jose is cool and explains every detail of the commands. We appreciate the time he takes to share his knowledge with us, and it truly shows that he is an expert in this field.