He'll play the neat freak Felix and reunite with his "17 Again" co-star.

CBS' The Odd Couple has found its neat freak.

Thomas Lennon has been tapped to play Felix opposite Matthew Perry's Oscar in the network's multicamera reboot, The Hollywood Reporter has learned.

Friends alum Perry and Joe Keenan (Glee, Frasier) will pen the script for the pilot based on Neil Simon's Broadway play.

PHOTOS: Faces of Pilot Season 2014

Lennon's Felix is described as a maddening neat freak and an uxorious man whose compulsion to live in a precisely ordered, meticulously perfect environment alienates him from everyone in his life. Stunned when Ashley, his wife of 20 years, can no longer stand his persnickety, controlling ways, an emotionally devastated Felix looks to his best friend, Oscar Madison (Perry), for help and support. But Oscar is a born slob, a man who believes that pizza boxes, cigar butts and beer-stained sports pages from 2003 are the height of manly decor. Offered a place to stay by Oscar, Felix feels compelled to repeat the behavior that got him homeless in the first place, and Felix's manic need to clean, cook and control soon shreds every one of Oscar's nerves right down to the bone.

Lennon steps into the role previously played by Tony Randall, Jack Lemmon, Dean Martin and Art Carney on Broadway, TV and the big screen.

The casting reunites Lennon and Perry, who co-starred in the 2009 Zac Efron feature 17 Again in which Lennon played Perry's longtime best friend. The actor, comedian, writer, director and producer also guest-starred in two episodes of Friends, playing Joey's (Matt LeBlanc) hand twin.

STORY: TV Pilots 2014: The Complete Guide

Lennon and writing partner Ben Garant are currently executive producing Comedy Central's Chris Hardwick late-night entry @midnight and prepping multiple feature films, including Naked Gun, Guinea Pigging and Choose Your Own Adventure. The duo also wrote the three Night at the Museum features.

Lennon most recently co-starred on NBC's Sean Saves the World, which was canceled in January. He co-created, produced and starred in Comedy Central's Reno 911 and Sundance's feature Hell Baby.

Perry will also executive produce the CBS Television Studios comedy alongside Timberman-Beverly's Carl Beverly and Sarah Timberman as well as and The Tannenbaum Co.'s Eric and Kim Tannenbaum. Perry's Go On castmember Sarah Baker co-stars.

Lennon is repped by CAA, Principato Young and Jackoway Tyerman.

Email: Lesley.Goldberg@THR.com

Twitter: @Snoodit