for my $line ( qx|df| ) { my ( $disk, $usage ) = (split /\s+/, $line)[0,4]; print "$disk $usage\n"; }