in reply to Is there a better way to approach this?

sub ospf2_split_database {

    my ($dl, $line) = "";

You shouldn't declare those variables here but inside the for loop.

    my @ospf2database = @_;
    my (@router, @network, @external) = ();

    for $line (@ospf2database) {

You should declare $line and $dl here:

    for my $line (@ospf2database) {
        my $dl;

        chomp($line);

Why chomp $line when you are just appending a newline again anyway?

        if ($line =~ /^Router/)  { $dl = 1; }
        if ($line =~ /^Network/) { $dl = 2; }
        if ($line =~ /^Extern/)  { $dl = 5; }
        switch ($dl) {
            case 1 { push(@router, "$line\n");   }
            case 2 { push(@network, "$line\n");  }
            case 5 { push(@external, "$line\n"); }

Do you need two steps?   Can't you just do the push in the if block?   You are testing $line three times although if it matches /^Router/ it will never match /^Network/ or /^Extern/.

if ( $line =~ /^Router/ ) { push @router, "$line\n" } elsif ( $line =~ /^Network/ ) { push @network, "$line\n" } elsif ( $line =~ /^Extern/ ) { push @external, "$line\n" }
        }
    }
    return(\@router,\@network,\@external);
}