I usually handle this (say, to run tests on servers):
Create an __DIE__ handler for the Perl process. This ensures that the process completes normally and that Devel :: Cover terminates the DB population.
Send SIGINT to the process of starting a new DIE handler.
run the cover program in the cover_db directory after the process is dead.
source share