All exams← All AWS Certified Advanced Networking - Specialty notes

Network Automation and Orchestration: AWS Certified Advanced Networking - Specialty revision notes

Revision notes

## Network Automation and Orchestration

Network automation is crucial for managing complex, dynamic AWS network environments, ensuring consistency, scalability, and security. It shifts network operations from manual tasks to programmatic control, reducing human error and accelerating changes.

Infrastructure as Code (IaC)

Infrastructure as Code (IaC) is fundamental, allowing you to define network resources using declarative configuration files. This ensures idempotency, meaning applying the same configuration multiple times yields the same desired result. It also facilitates version control and collaborative development.

  • AWS CloudFormation: The primary AWS service for IaC. It enables you to model and provision all your AWS infrastructure resources, including VPCs, subnets, route tables, security groups, Transit Gateways, Direct Connect connections, VPNs, AWS Network Firewalls, and Route 53 Resolver endpoints. CloudFormation templates (YAML or JSON) define the desired state.
  • AWS Cloud Development Kit (CDK): An open-source software development framework to define your cloud application resources using familiar programming languages (e.g., Python, TypeScript). CDK synthesizes into CloudFormation templates, offering more programmatic control, abstraction, and reusability for complex network patterns.

Scripting and APIs

Direct programmatic interaction with AWS services is achieved through:

  • AWS Command Line Interface (CLI): For managing AWS services from your terminal, ideal for scripting one-off tasks or integrating into shell scripts.
  • AWS SDKs (e.g., Boto3 for Python): Provide language-specific APIs to interact with AWS services, enabling complex automation scripts and application integrations.

Event-Driven Automation

Event-driven automation allows network changes to react automatically to specific events, enabling real-time remediation or configuration updates.

  • AWS Lambda: A serverless compute service used to run code in response to events.
  • Amazon EventBridge (formerly CloudWatch Events): A serverless event bus that makes it easier to connect applications together using data from your own applications, integrated SaaS applications, and AWS services. EventBridge can trigger Lambda functions based on AWS API calls (e.g., `CreateSecurityGroup`, `ModifyRouteTable`) or scheduled events.

Configuration Management

  • AWS Systems Manager (SSM): Provides capabilities to manage your EC2 instances and other AWS resources. For networking, SSM State Manager can ensure consistent network configurations on instances, and SSM Run Command can execute scripts to modify network settings or troubleshoot issues.

Centralized Network Management

  • AWS Transit Gateway Network Manager: Offers a single dashboard to centrally monitor and manage your global network across AWS Transit Gateways and on-premises networks. It provides visibility into network topology, performance metrics, and events, enabling automated responses to network health changes.

Policy as Code

Network security policies can be defined and managed as code, integrating security directly into the automation pipeline:

  • AWS Network Firewall: Allows you to deploy highly available network security policies (stateless and stateful rules) directly within your VPCs, managed through IaC.
  • Route 53 Resolver DNS Firewall: Enables creating rules to filter outbound DNS queries from your VPCs, preventing communication with malicious domains, also managed as code.

CI/CD for Network Changes

Integrating network infrastructure code into CI/CD pipelines (e.g., AWS CodePipeline, CodeBuild) ensures automated testing, validation, and deployment of network configurations, reducing errors and accelerating changes.

Key facts

Flashcards

What is the primary AWS service for Infrastructure as Code (IaC) to define and provision network resources?
AWS CloudFormation.
tap to reveal
Which two AWS services are commonly combined for event-driven network automation?
AWS Lambda and Amazon EventBridge.
tap to reveal
How can you programmatically interact with AWS network services from a terminal or script?
Using the AWS Command Line Interface (CLI) or AWS SDKs (e.g., Boto3).
tap to reveal
What is the benefit of using IaC for network configurations?
Ensures idempotency, consistency, version control, and faster, error-free deployments.
tap to reveal
Which AWS service provides a centralized dashboard for monitoring and managing global networks built with Transit Gateways?
AWS Transit Gateway Network Manager.
tap to reveal
What does 'policy as code' mean in the context of AWS networking, and name an AWS service that uses it?
Defining network security policies programmatically in code. Examples include AWS Network Firewall and Route 53 Resolver DNS Firewall.
tap to reveal
How can AWS Systems Manager (SSM) assist with network automation on EC2 instances?
SSM State Manager can enforce consistent network configurations, and SSM Run Command can execute scripts for network troubleshooting or changes.
tap to reveal
Practice questions

Network Automation and Orchestration: 5 practice questions

Q1. A company needs to deploy a standardized set of networking resources, including a VPC, subnets, and security groups, to multiple AWS accounts and regions. The solution must be managed from a central administrator account. Which AWS service is designed to automate this process and ensure consistency?
  • A.  AWS Systems Manager Automation
  • B.  AWS CloudFormation StackSets
  • C.  AWS CDK with a custom deployment script
  • D.  AWS Control Tower
Show answer & explanation
✓ Answer: B. AWS CloudFormation StackSets
AWS CloudFormation StackSets extends the functionality of stacks by enabling you to create, update, or delete stacks across multiple accounts and regions with a single operation from a central administrator account.
Q2. A network administrator wants to automatically add a specific tag to any new Elastic Network Interface (ENI) that is created in their VPC. The solution should be event-driven and serverless. Which AWS service is most suitable for this task?
  • A.  AWS Step Functions
  • B.  AWS Lambda
  • C.  AWS Batch
  • D.  An Amazon EC2 instance running a cron job
Show answer & explanation
✓ Answer: B. AWS Lambda
AWS Lambda is a serverless, event-driven compute service that can be triggered by AWS service events, such as an ENI creation event from Amazon EventBridge, to run code and perform actions like tagging.
Q3. A networking team is using AWS CloudFormation to manage their infrastructure. They need to integrate a third-party virtual network appliance whose configuration is managed via a REST API. How can they automate the appliance's configuration as part of the CloudFormation stack lifecycle (Create, Update, Delete)?
  • A.  Use a `DependsOn` attribute to call the API from an EC2 instance after it launches.
  • B.  Embed an AWS CLI script in the `UserData` property of an EC2 instance.
  • C.  Create a CloudFormation custom resource that is backed by an AWS Lambda function.
  • D.  Use an AWS Systems Manager Automation document triggered by a stack deployment event.
Show answer & explanation
✓ Answer: C. Create a CloudFormation custom resource that is backed by an AWS Lambda function.
CloudFormation custom resources allow you to write custom provisioning logic in a Lambda function and have it managed by the CloudFormation stack lifecycle. This is the correct pattern for integrating with unsupported or third-party APIs.
Q4. A company's security policy requires that no security group allows unrestricted inbound access (0.0.0.0/0) on port 22 (SSH). Which AWS service can be used to continuously monitor for this condition and automatically flag non-compliant resources?
  • A.  Amazon Inspector
  • B.  AWS CloudTrail
  • C.  AWS Config
  • D.  Amazon GuardDuty
Show answer & explanation
✓ Answer: C. AWS Config
AWS Config is a service that enables you to assess, audit, and evaluate the configurations of your AWS resources. It provides managed and custom rules to continuously check for compliance against desired configurations.
Q5. A network engineering team uses AWS CodePipeline to automate the deployment of their network infrastructure, which is defined in AWS CloudFormation templates. To minimize risk, they want to review the exact impact of a change before it is applied to their production environment. Which CodePipeline action should they integrate into the pipeline to achieve this?
  • A.  A test action that runs `aws cloudformation validate-template`.
  • B.  A manual approval action that links to the CloudFormation console.
  • C.  An action that creates a CloudFormation change set for the stack.
  • D.  A build action that deploys the stack to a separate test account.
Show answer & explanation
✓ Answer: C. An action that creates a CloudFormation change set for the stack.
Creating a CloudFormation change set allows you to preview the changes CloudFormation will make to your stack. This enables you to see the impact of proposed changes on your running resources before executing them, which is a critical step in a safe CI/CD pipeline.
Test yourself
See the AWS Certified Advanced Networking - Specialty page

More AWS Certified Advanced Networking - Specialty topics