Для съема ститистики на оборудовании Juniper из коробки по flow к сожалению ничего, что либо удовлетворяющее по точности, к сожалению не предоставляется. Немого подумав был выбран съем статистики по счетчикам интерфейсов. Скрипт написан мной на perl.

#cat juniper.pl
#!/usr/bin/perl
use Expect;
use IO::Stty;
use DBI;
require ("mysql.inc");
$username="dumper";
$password="SecReT";
$ip="10.1.1.1";
$dbh=DBI->connect($data_source,$dbuser,$dbpass) || die "connecting: $DBI::errstr";
$exp = Expect->spawn("telnet $ip");
$exp->expect(5,[ 'ogin: $' => sub {$exp->send("$username\n");exp_continue; }]);
$exp->expect (5, [ 'ssword:$' => sub { $exp->send("$password\n");exp_continue; }]);
$exp->log_file("filename", "w");
$exp->send("sh int terse| no-more \n");
$exp->send("exit\n");
$exp->soft_close();
@file=`cat filename |grep ge|grep inet |sed -e 's/---(more.*)---//'`;
$i=0;
foreach $str (@file)
{
($a,$b,$c)=split (' ',$str);
$int[$i]=$a;
$_=$a;
print "$_\n";
tr /\//_/;
$int_names[$i]=$_;
$i++;
}
$j=0;
$time=time();
$df=`mkdir $time`;

foreach $int (@int)
{
$file="stat-$int_names[$j].log";
$exp = Expect->spawn("telnet $ip");
$exp->expect(5,[ 'ogin: $' => sub {$exp->send("$username\n");exp_continue; }]);
$exp->expect (1, [ 'ssword:$' => sub { $exp->send("$password\n");exp_continue; }]);
$exp->log_file("$time/$file.log", "w");
$exp->send("sh int stat $int detail | no-more | match bytes\n");
$exp->send("clear interfaces statistics $int \n");
$exp->send("exit\n");
$exp->soft_close();
$j++;
@stat=`cat $time/$file.log |grep -e 'bytes :'|head -n 2`;

foreach $st (@stat)
{
($desc1,$desc2,$d,$data)=split(" ",$st);
if ($desc1 eq "Input") {$input=$data};
if ($desc1 eq "Output") {$output=$data};
}

print "time= $time\n";
print "IP= $ip\n";
print "IFace = $int\n";
print "Input= $input bytes\n";
print "Output= $output bytes\n";
$dbh->do("insert into stat_main (time, device_IP,iface,input,output) value ($time,inet_aton('$ip'),'$int','$input','$output')");
}
$dbh->disconnect;

#cat mysql.inc
#Доступ к базе данных
$dbuser="root";
$dbpass="bdpassword";
$db_name="stat";
$tb_ip="ip";
$tb_vlan="vlans";
$tb_user="owner";
$data_source="DBI:mysql:stat:localhost";


Дампа базы не прилагаю так как он вполне виден из скрита
Написано было за полчаса по просьбе айпитехов.
Сырцы с интерфейсов сохряняются в виде файлов на всякий случай.