Princess Cruise Lines Ltd. will plead guilty to seven charges of deliberate pollution of the seas and pay $40 million in penalties, the Justice Department announced Thursday.

The Valencia-based cruise company is a subsidiary of Carnival Corp., headquartered in Miami. As part of the settlement with the Justice Department, ships from eight Carnival companies will be under a court supervised environmental compliance program for five years. The program will involve independent audits and a court appointed monitor.

A whistle-blowing engineer helped investigators determine that Princess’ Caribbean Princess ship illegally dumped oil off the coast of England in 2013. The discharge involved about 4,227 gallons of pollution. At the same time as the discharge, engineers ran clean seawater through the ship’s equipment to create a false record for a legitimate discharge.

The investigation uncovered two other illegal practices on the Caribbean Princess as well as four other Princess ships – Star Princess, Grand Princess, Coral Princess and Golden Princess. One was to open a salt water valve when bilge waste was processed by the oily water separator and content monitor. The purpose was to prevent the monitor from alarming and stopping the discharge into the ocean. The second practice involved discharges of oily bilge water from graywater tanks. This waste was pumped back into the graywater system rather than being processed as oily bilge waste.

The $40 million penalty is “the largest-ever criminal penalty involving deliberate vessel pollution,” according to the Justice Department.