SlideShare a Scribd company logo
CUSTOMIZING NETWORK LINK
AGGREGATION USING PYTHON
SCRIPTS IN OMNISWITCH
APPLICATION NOTE
Customizing network link aggregation using Python scripts in OmniSwitch
ALCATEL-LUCENT ENTERPRISE
2
INTRODUCTION
Today’s enterprise networks provide mission-critical resources for employees, customers
and business partners. Networks must be flexible, and the network operations staff must
be able to trust that network issues are resolved quickly to minimize business impact.
Alcatel-Lucent OmniSwitch® products can respond to network events quickly using the
Event Manager of the Alcatel-Lucent Operating System (AOS) and its embedded Python®
scripting feature.
Specific network events can trigger Python scripts to provide fast, real-time, software-
defined responses tailored to the requirements of the enterprise. For example, the
customers can set up different responses for link failures depending on the location and
type of a link.
This application note demonstrates a combination of OmniSwitch features, including the
AOS Event Manager and Python scripting, to provide a software-defined response failure
of individual links in a link aggregation group. The software-defined result is customized
to match the customer’s network policy needs, following the industry-standard link
aggregation protocols. Another note describes how the AOS Event Manager and Python
scripting can be used to extend policy-based routing.
SOFTWARE-DEFINED RESPONSE TO A PARTIAL
FAILURE OF A LINK AGGREGATION GROUP
Enterprise networks frequently use multiple link aggregation groups to provide higher
bandwidth and increased network resiliency. The AOS Event Manager and Python
scripting can provide software-defined responses when a link failure occurs.
LAG A
AOS Python
scripting
provides
software-
defined
response to
link failure
OS A
Enterprise
network
OS B
LAG B
Customizing network link aggregation using Python scripts in OmniSwitch
ALCATEL-LUCENT ENTERPRISE
3
The Enterprise network shown above uses two OmniSwitch units, OS A and OS B,
and two link aggregation groups, LAG A and LAG B, to provide redundant access to a
major router. There are four ports in each LAG identified as ports A1 through A4 and B1
through B4.
In this example, the customer has designed the network so that either LAG can provide
sufficient bandwidth for all traffic and only one LAG is active at any time. The customer
policy is to consider a LAG failed when half of the links in that LAG have failed.
The customer is concerned about partial failures where several links in a LAG fail, but
at least one link remains operational. In that case, the traffic capacity is significantly
reduced, but industry-standard link aggregation protocols do not automatically consider
the LAG as failed.
The following solution implements a custom policy using the AOS Event Manager and
Python scripting, along with AOS Web Services RESTful remote command execution.
The OmniSwitch Event Manager executes a custom Python script in OS A whenever a
link fails. The Python script checks the number of remaining links in the LAG A group
against a pre-defined limit and disables the entire LAG if the number of remaining links
falls below the limit. The second LAG is then enabled remotely by OS A on OS B using
the AOS RESTful API. All traffic then flows through the LAG B. This avoids operating the
network with a partially-failed LAG and meets the goals set by the customer policy.
EXAMPLE
This example demonstrates the AOS Event Manager and Python scripting.
The Event Manager is configured with event-action commands that execute the script
linkagg_script.py when the snmp linkDown trap occurs.
! Trap Manager:
snmp-trap absorption disable
event-action trap linkDown script /flash/python/linkagg_script.py
AOS passes the trap type and other parameters to the script when a linkDown trap
occurs. The script then checks the parameters trap and data[ifIndex] to determine
what happened.
enterprise.alcatel-lucent.com Alcatel-Lucent and the Alcatel-Lucent Enterprise logo are trademarks of Alcatel-Lucent. To view
Alcatel-Lucent Enterprise trademarks visit: enterprise.alcatel-lucent.com/trademarks. All other trademarks are the property of their
respective owners. The information presented is subject to change without notice. Alcatel-Lucent Enterprise assumes no responsibility
for inaccuracies contained herein. Copyright © 2015 Alcatel-Lucent Enterprise. All Rights Reserved. 201502170004EN (March)
Pseudocode for linkagg_script.py
If (SNMP trap is linkDown)
	 If (the port is a member of LAG 1)
		 Set value = the number of operational ports remaining in LAG 1
			 If (number of remaining ports is below the customer’s threshold)
				Execute local AOS command to Disable LAG 1 on OmniSwitch A
				Execute remote AOS command to Enable LAG 2 on OmniSwitch B
				Send email message to network manager’s phone
			Else
				Log the port failed and the number of remaining ports
	Else
		 linkDown event is not on a member of LAG 1. Ignore it.
CONCLUSION
The AOS Event Manager and Python scripting provide a fast, flexible, software-defined
response to network events. The response supports and enforces network policies defined
by the networking staff. Responses can include enabling or disabling links or changing
network priorities. It can also include gathering information to document the failure and
notifying network staff by e-mail.
REFERENCES
See “OmniSwitch AOS XXX Switch Management Guide”, chapter “Web Services, CLI
Scripting, and OpenFlow”. The document is located at http://enterprise.alcatel-lucent.
com/UserGuides. This application note applies to AOS release 7.3.4 or later.

More Related Content

Recently uploaded

快速办理(新加坡SMU毕业证书)新加坡管理大学毕业证文凭证书一模一样
快速办理(新加坡SMU毕业证书)新加坡管理大学毕业证文凭证书一模一样快速办理(新加坡SMU毕业证书)新加坡管理大学毕业证文凭证书一模一样
快速办理(新加坡SMU毕业证书)新加坡管理大学毕业证文凭证书一模一样
3a0sd7z3
 
manuaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaal
manuaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaalmanuaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaal
manuaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaal
wolfsoftcompanyco
 
留学挂科(UofM毕业证)明尼苏达大学毕业证成绩单复刻办理
留学挂科(UofM毕业证)明尼苏达大学毕业证成绩单复刻办理留学挂科(UofM毕业证)明尼苏达大学毕业证成绩单复刻办理
留学挂科(UofM毕业证)明尼苏达大学毕业证成绩单复刻办理
uehowe
 
存档可查的(USC毕业证)南加利福尼亚大学毕业证成绩单制做办理
存档可查的(USC毕业证)南加利福尼亚大学毕业证成绩单制做办理存档可查的(USC毕业证)南加利福尼亚大学毕业证成绩单制做办理
存档可查的(USC毕业证)南加利福尼亚大学毕业证成绩单制做办理
fovkoyb
 
怎么办理(umiami毕业证书)美国迈阿密大学毕业证文凭证书实拍图原版一模一样
怎么办理(umiami毕业证书)美国迈阿密大学毕业证文凭证书实拍图原版一模一样怎么办理(umiami毕业证书)美国迈阿密大学毕业证文凭证书实拍图原版一模一样
怎么办理(umiami毕业证书)美国迈阿密大学毕业证文凭证书实拍图原版一模一样
rtunex8r
 
办理毕业证(NYU毕业证)纽约大学毕业证成绩单官方原版办理
办理毕业证(NYU毕业证)纽约大学毕业证成绩单官方原版办理办理毕业证(NYU毕业证)纽约大学毕业证成绩单官方原版办理
办理毕业证(NYU毕业证)纽约大学毕业证成绩单官方原版办理
uehowe
 
快速办理(Vic毕业证书)惠灵顿维多利亚大学毕业证完成信一模一样
快速办理(Vic毕业证书)惠灵顿维多利亚大学毕业证完成信一模一样快速办理(Vic毕业证书)惠灵顿维多利亚大学毕业证完成信一模一样
快速办理(Vic毕业证书)惠灵顿维多利亚大学毕业证完成信一模一样
3a0sd7z3
 
Discover the benefits of outsourcing SEO to India
Discover the benefits of outsourcing SEO to IndiaDiscover the benefits of outsourcing SEO to India
Discover the benefits of outsourcing SEO to India
davidjhones387
 
HijackLoader Evolution: Interactive Process Hollowing
HijackLoader Evolution: Interactive Process HollowingHijackLoader Evolution: Interactive Process Hollowing
HijackLoader Evolution: Interactive Process Hollowing
Donato Onofri
 
办理毕业证(UPenn毕业证)宾夕法尼亚大学毕业证成绩单快速办理
办理毕业证(UPenn毕业证)宾夕法尼亚大学毕业证成绩单快速办理办理毕业证(UPenn毕业证)宾夕法尼亚大学毕业证成绩单快速办理
办理毕业证(UPenn毕业证)宾夕法尼亚大学毕业证成绩单快速办理
uehowe
 
Ready to Unlock the Power of Blockchain!
Ready to Unlock the Power of Blockchain!Ready to Unlock the Power of Blockchain!
Ready to Unlock the Power of Blockchain!
Toptal Tech
 
成绩单ps(UST毕业证)圣托马斯大学毕业证成绩单快速办理
成绩单ps(UST毕业证)圣托马斯大学毕业证成绩单快速办理成绩单ps(UST毕业证)圣托马斯大学毕业证成绩单快速办理
成绩单ps(UST毕业证)圣托马斯大学毕业证成绩单快速办理
ysasp1
 
办理新西兰奥克兰大学毕业证学位证书范本原版一模一样
办理新西兰奥克兰大学毕业证学位证书范本原版一模一样办理新西兰奥克兰大学毕业证学位证书范本原版一模一样
办理新西兰奥克兰大学毕业证学位证书范本原版一模一样
xjq03c34
 
一比一原版(USYD毕业证)悉尼大学毕业证如何办理
一比一原版(USYD毕业证)悉尼大学毕业证如何办理一比一原版(USYD毕业证)悉尼大学毕业证如何办理
一比一原版(USYD毕业证)悉尼大学毕业证如何办理
k4ncd0z
 
Bengaluru Dreamin' 24 - Personal Branding
Bengaluru Dreamin' 24 - Personal BrandingBengaluru Dreamin' 24 - Personal Branding
Bengaluru Dreamin' 24 - Personal Branding
Tarandeep Singh
 
Should Repositories Participate in the Fediverse?
Should Repositories Participate in the Fediverse?Should Repositories Participate in the Fediverse?
Should Repositories Participate in the Fediverse?
Paul Walk
 

Recently uploaded (16)

快速办理(新加坡SMU毕业证书)新加坡管理大学毕业证文凭证书一模一样
快速办理(新加坡SMU毕业证书)新加坡管理大学毕业证文凭证书一模一样快速办理(新加坡SMU毕业证书)新加坡管理大学毕业证文凭证书一模一样
快速办理(新加坡SMU毕业证书)新加坡管理大学毕业证文凭证书一模一样
 
manuaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaal
manuaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaalmanuaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaal
manuaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaal
 
留学挂科(UofM毕业证)明尼苏达大学毕业证成绩单复刻办理
留学挂科(UofM毕业证)明尼苏达大学毕业证成绩单复刻办理留学挂科(UofM毕业证)明尼苏达大学毕业证成绩单复刻办理
留学挂科(UofM毕业证)明尼苏达大学毕业证成绩单复刻办理
 
存档可查的(USC毕业证)南加利福尼亚大学毕业证成绩单制做办理
存档可查的(USC毕业证)南加利福尼亚大学毕业证成绩单制做办理存档可查的(USC毕业证)南加利福尼亚大学毕业证成绩单制做办理
存档可查的(USC毕业证)南加利福尼亚大学毕业证成绩单制做办理
 
怎么办理(umiami毕业证书)美国迈阿密大学毕业证文凭证书实拍图原版一模一样
怎么办理(umiami毕业证书)美国迈阿密大学毕业证文凭证书实拍图原版一模一样怎么办理(umiami毕业证书)美国迈阿密大学毕业证文凭证书实拍图原版一模一样
怎么办理(umiami毕业证书)美国迈阿密大学毕业证文凭证书实拍图原版一模一样
 
办理毕业证(NYU毕业证)纽约大学毕业证成绩单官方原版办理
办理毕业证(NYU毕业证)纽约大学毕业证成绩单官方原版办理办理毕业证(NYU毕业证)纽约大学毕业证成绩单官方原版办理
办理毕业证(NYU毕业证)纽约大学毕业证成绩单官方原版办理
 
快速办理(Vic毕业证书)惠灵顿维多利亚大学毕业证完成信一模一样
快速办理(Vic毕业证书)惠灵顿维多利亚大学毕业证完成信一模一样快速办理(Vic毕业证书)惠灵顿维多利亚大学毕业证完成信一模一样
快速办理(Vic毕业证书)惠灵顿维多利亚大学毕业证完成信一模一样
 
Discover the benefits of outsourcing SEO to India
Discover the benefits of outsourcing SEO to IndiaDiscover the benefits of outsourcing SEO to India
Discover the benefits of outsourcing SEO to India
 
HijackLoader Evolution: Interactive Process Hollowing
HijackLoader Evolution: Interactive Process HollowingHijackLoader Evolution: Interactive Process Hollowing
HijackLoader Evolution: Interactive Process Hollowing
 
办理毕业证(UPenn毕业证)宾夕法尼亚大学毕业证成绩单快速办理
办理毕业证(UPenn毕业证)宾夕法尼亚大学毕业证成绩单快速办理办理毕业证(UPenn毕业证)宾夕法尼亚大学毕业证成绩单快速办理
办理毕业证(UPenn毕业证)宾夕法尼亚大学毕业证成绩单快速办理
 
Ready to Unlock the Power of Blockchain!
Ready to Unlock the Power of Blockchain!Ready to Unlock the Power of Blockchain!
Ready to Unlock the Power of Blockchain!
 
成绩单ps(UST毕业证)圣托马斯大学毕业证成绩单快速办理
成绩单ps(UST毕业证)圣托马斯大学毕业证成绩单快速办理成绩单ps(UST毕业证)圣托马斯大学毕业证成绩单快速办理
成绩单ps(UST毕业证)圣托马斯大学毕业证成绩单快速办理
 
办理新西兰奥克兰大学毕业证学位证书范本原版一模一样
办理新西兰奥克兰大学毕业证学位证书范本原版一模一样办理新西兰奥克兰大学毕业证学位证书范本原版一模一样
办理新西兰奥克兰大学毕业证学位证书范本原版一模一样
 
一比一原版(USYD毕业证)悉尼大学毕业证如何办理
一比一原版(USYD毕业证)悉尼大学毕业证如何办理一比一原版(USYD毕业证)悉尼大学毕业证如何办理
一比一原版(USYD毕业证)悉尼大学毕业证如何办理
 
Bengaluru Dreamin' 24 - Personal Branding
Bengaluru Dreamin' 24 - Personal BrandingBengaluru Dreamin' 24 - Personal Branding
Bengaluru Dreamin' 24 - Personal Branding
 
Should Repositories Participate in the Fediverse?
Should Repositories Participate in the Fediverse?Should Repositories Participate in the Fediverse?
Should Repositories Participate in the Fediverse?
 

Featured

2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot
Marius Sescu
 
Everything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPTEverything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPT
Expeed Software
 
Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsProduct Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage Engineerings
Pixeldarts
 
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
ThinkNow
 
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfAI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
marketingartwork
 
Skeleton Culture Code
Skeleton Culture CodeSkeleton Culture Code
Skeleton Culture Code
Skeleton Technologies
 
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024
Neil Kimberley
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
contently
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
Albert Qian
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
Kurio // The Social Media Age(ncy)
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
Search Engine Journal
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
SpeakerHub
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next
Tessa Mero
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Lily Ray
 
How to have difficult conversations
How to have difficult conversations How to have difficult conversations
How to have difficult conversations
Rajiv Jayarajah, MAppComm, ACC
 
Introduction to Data Science
Introduction to Data ScienceIntroduction to Data Science
Introduction to Data Science
Christy Abraham Joy
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best Practices
Vit Horky
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project management
MindGenius
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
RachelPearson36
 

Featured (20)

2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot
 
Everything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPTEverything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPT
 
Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsProduct Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage Engineerings
 
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
 
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfAI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
 
Skeleton Culture Code
Skeleton Culture CodeSkeleton Culture Code
Skeleton Culture Code
 
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
 
How to have difficult conversations
How to have difficult conversations How to have difficult conversations
How to have difficult conversations
 
Introduction to Data Science
Introduction to Data ScienceIntroduction to Data Science
Introduction to Data Science
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best Practices
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project management
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
 

How to use Python to automate a response if members of a Link-Aggregation failed

  • 1. CUSTOMIZING NETWORK LINK AGGREGATION USING PYTHON SCRIPTS IN OMNISWITCH APPLICATION NOTE
  • 2. Customizing network link aggregation using Python scripts in OmniSwitch ALCATEL-LUCENT ENTERPRISE 2 INTRODUCTION Today’s enterprise networks provide mission-critical resources for employees, customers and business partners. Networks must be flexible, and the network operations staff must be able to trust that network issues are resolved quickly to minimize business impact. Alcatel-Lucent OmniSwitch® products can respond to network events quickly using the Event Manager of the Alcatel-Lucent Operating System (AOS) and its embedded Python® scripting feature. Specific network events can trigger Python scripts to provide fast, real-time, software- defined responses tailored to the requirements of the enterprise. For example, the customers can set up different responses for link failures depending on the location and type of a link. This application note demonstrates a combination of OmniSwitch features, including the AOS Event Manager and Python scripting, to provide a software-defined response failure of individual links in a link aggregation group. The software-defined result is customized to match the customer’s network policy needs, following the industry-standard link aggregation protocols. Another note describes how the AOS Event Manager and Python scripting can be used to extend policy-based routing. SOFTWARE-DEFINED RESPONSE TO A PARTIAL FAILURE OF A LINK AGGREGATION GROUP Enterprise networks frequently use multiple link aggregation groups to provide higher bandwidth and increased network resiliency. The AOS Event Manager and Python scripting can provide software-defined responses when a link failure occurs. LAG A AOS Python scripting provides software- defined response to link failure OS A Enterprise network OS B LAG B
  • 3. Customizing network link aggregation using Python scripts in OmniSwitch ALCATEL-LUCENT ENTERPRISE 3 The Enterprise network shown above uses two OmniSwitch units, OS A and OS B, and two link aggregation groups, LAG A and LAG B, to provide redundant access to a major router. There are four ports in each LAG identified as ports A1 through A4 and B1 through B4. In this example, the customer has designed the network so that either LAG can provide sufficient bandwidth for all traffic and only one LAG is active at any time. The customer policy is to consider a LAG failed when half of the links in that LAG have failed. The customer is concerned about partial failures where several links in a LAG fail, but at least one link remains operational. In that case, the traffic capacity is significantly reduced, but industry-standard link aggregation protocols do not automatically consider the LAG as failed. The following solution implements a custom policy using the AOS Event Manager and Python scripting, along with AOS Web Services RESTful remote command execution. The OmniSwitch Event Manager executes a custom Python script in OS A whenever a link fails. The Python script checks the number of remaining links in the LAG A group against a pre-defined limit and disables the entire LAG if the number of remaining links falls below the limit. The second LAG is then enabled remotely by OS A on OS B using the AOS RESTful API. All traffic then flows through the LAG B. This avoids operating the network with a partially-failed LAG and meets the goals set by the customer policy. EXAMPLE This example demonstrates the AOS Event Manager and Python scripting. The Event Manager is configured with event-action commands that execute the script linkagg_script.py when the snmp linkDown trap occurs. ! Trap Manager: snmp-trap absorption disable event-action trap linkDown script /flash/python/linkagg_script.py AOS passes the trap type and other parameters to the script when a linkDown trap occurs. The script then checks the parameters trap and data[ifIndex] to determine what happened.
  • 4. enterprise.alcatel-lucent.com Alcatel-Lucent and the Alcatel-Lucent Enterprise logo are trademarks of Alcatel-Lucent. To view Alcatel-Lucent Enterprise trademarks visit: enterprise.alcatel-lucent.com/trademarks. All other trademarks are the property of their respective owners. The information presented is subject to change without notice. Alcatel-Lucent Enterprise assumes no responsibility for inaccuracies contained herein. Copyright © 2015 Alcatel-Lucent Enterprise. All Rights Reserved. 201502170004EN (March) Pseudocode for linkagg_script.py If (SNMP trap is linkDown) If (the port is a member of LAG 1) Set value = the number of operational ports remaining in LAG 1 If (number of remaining ports is below the customer’s threshold) Execute local AOS command to Disable LAG 1 on OmniSwitch A Execute remote AOS command to Enable LAG 2 on OmniSwitch B Send email message to network manager’s phone Else Log the port failed and the number of remaining ports Else linkDown event is not on a member of LAG 1. Ignore it. CONCLUSION The AOS Event Manager and Python scripting provide a fast, flexible, software-defined response to network events. The response supports and enforces network policies defined by the networking staff. Responses can include enabling or disabling links or changing network priorities. It can also include gathering information to document the failure and notifying network staff by e-mail. REFERENCES See “OmniSwitch AOS XXX Switch Management Guide”, chapter “Web Services, CLI Scripting, and OpenFlow”. The document is located at http://enterprise.alcatel-lucent. com/UserGuides. This application note applies to AOS release 7.3.4 or later.