Script for ethernet port down

I want script for layer2 fiber failover that is if ethernet port ether1 and ether2 both is down than bridge port is enable by finding comment BK1", and if both ether1 and ether 2 is up than bridge port is disable BK1"