B737 Undifferentiated or Other Model
Flight Crew Air Transport Pilot (ATP); Flight Crew Multiengine; Flight Crew Instrument
Flight Crew Last 90 Days 218; Flight Crew Total 7448; Flight Crew Type 4535
Aircraft Equipment Problem Critical; Deviation / Discrepancy - Procedural Clearance; Inflight Event / Encounter Weather / Turbulence
Flight Crew Diverted; Flight Crew Inflight Shutdown; Flight Crew Landed in Emergency Condition
Aircraft
FL340 approximately 160 nm east northeast of ZZZ the right engine OIL FILTER BYPASS caution annunciation flashed for 3-5 seconds then remained illuminated.  We advised ATC with clearance to descend as requested to FL200 (FL223 max single engine altitude capability).  Drift down profile initiated while concurrently performing required checklists; balancing fuel as needed as checklist directed engine shutdown.  Declared ZZZ as the nearest suitable divert at point in time. Notified dispatch of intent for ZZZ; as well as coordinating communications with the Purser and making a PA to the passengers.  Obtained ZZZ ATIS which stated winds variable at 6 kts landing Runway XX. Requested Runway XY for additional runway length.  Transitioned from drift down profile to a descent profile when a 3:1 profile attained. As we approached within 15 nm of the field; we were informed that winds were gusting in excess of 20 kts from the south.  We coordinated a runway change to XXL and at approximately 10-12 nm north of the field executed a left 360 degree turn descending to the sector MVA as to scrub altitude due to the much shortened landing distance to Runway XXL.Approach and landing was uneventful as was the taxi evolution to the gate for parking.  Fire crash and rescue followed and informed that there was no threat heat signature emanating from the landing gear/brake assemblies. Normal passenger deplaning ensued.ATC throughout the evolution was perfect in every respect in aiding the successful uneventful outcome.  A discrete frequency was assigned and that was immeasurably valuable.
We were in Cruise and the 'OIL FILTER BYPASS' light illuminated for engine number two. The Captain took the flight controls while I ran the checklist. We ran the checklist which led us to shut down engine number two as the light did not extinguish. We advised ATC and requested a diversion to ZZZ; which was the closest suitable airport.  We drifted down to FL 200 while preparing for the 1 engine approach. The Captain notified the flight attendants to prepare the cabin; he also made a calming PA; and we notified dispatch. ATIS for ZZZ winds were variable at six knots so we requested Runway XXL as it is the longest runway. We were less than 10;000 feet and approximately 20 miles out when the tower reported strong gusting winds from the south so [Runway] XYL was the safest option; but we were too high and had to do a left 360 degree [turn] while we prepared for the new approach.  We flew a normal single engine approach and landed normally. Fire trucks escorted us to the gate as a precaution. Brake temperatures were normal and not excessive. Passengers deplaned in a normal manner. The Captain and I debriefed each other and then the flight attendants.
B737 flight crew reported an engine inflight shutdown in cruise due to an oil filter bypass issue.