The corporate boards of Viacom and CBS agreed to merge in an all-stock deal Tuesday, reuniting the Redstone family’s entertainment holdings after a series of legal battles and corporate intrigues.

The move is intended to enable the blended company valued at about $30 billion to fight off bulked-up competitors and a new threat from digital rivals with well-financed streaming services.

Viacom Chief Executive Bob Bakish is to oversee the new company, which will be called ViacomCBS. The deal would combine such well-known entertainment brands as CBS and Showtime with Viacom’s Paramount television and movie studios, Nickelodeon, Comedy Central and MTV.

CBS also owns the book publisher Simon & Schuster. Current CBS CEO Joe Ianiello is to oversee the former CBS properties under Bakish.  […]