Book Image

Cisco ACI Cookbook

By : Stuart Fordham
Book Image

Cisco ACI Cookbook

By: Stuart Fordham

Overview of this book

Cisco Application Centric Infrastructure (ACI) is a tough architecture that automates IT tasks and accelerates data-center application deployments. This book focuses on practical recipes to help you quickly build, manage, and customize hybrid environment for your organization using Cisco ACI. You will begin by understanding the Cisco ACI architecture and its major components. You will then configure Cisco ACI policies and tenants. Next you will connect to hypervisors and other third-party devices. Moving on, you will configure routing to external networks and within ACI tenants and also learn to secure ACI through RBAC. Furthermore, you will understand how to set up quality of service and network programming with REST, XML, Python and so on. Finally you will learn to monitor and troubleshoot ACI in the event of any issues that arise. By the end of the book, you will gain have mastered automating your IT tasks and accelerating the deployment of your applications.
Table of Contents (17 chapters)
Title Page
Credits
About the Author
About the Reviewers
www.PacktPub.com
Customer Feedback
Preface

Authenticating through REST and XML


Without authenticating to the APIC first, we will not be able to run any subsequent commands.

How to do it...

  1. Set the URL to https://192.168.1.205/api/aaaLogin.xml (obviously changing the IP address to the one of your APIC controller).
  2. Enter the following on line 1:
     <aaaUser name="admin" pwd="admin123" />

 

 

  1. Press Send.

How it works...

The Postman application sends the raw XML to the aaaLogin.xml URL. In the results pane, we should see some XML returned and should have, on the left-hand side, a status code of 200 (meaning everything worked fine). The XML code should look like this:

<?xml version="1.0" encoding="UTF-8"?>
<imdata totalCount="1">
 <aaaLogin token="8HoO9sU0o39ygQinBsHcrBD61hhXdr+JNiXaiETpZUz+5t+5C2ijW8JbTOCc/53dZP0M9O4ByrbtNWknUwj0fkppYXPVEjPyGlkfP8JDOGV9THxEi28Dpcf0eDOBNlRNHlPAnsvXJ1B1cM+aT+xk3ADfR4D9koFNT0VRTENzSux5uwKzjvScbRY1AIIN+Dor" siteFingerprint="ROT0QumJdEhJzyqM" refreshTimeoutSeconds="600" maximumLifetimeSeconds...