Getting size of whole file:
PHP Code: 
$ch curl_init();
curl_setopt($chCURLOPT_URL"http://www.dsa.da/urfile.rar");
curl_setopt($chCURLOPT_NOBODY1);
curl_setopt($chCURLOPT_RETURNTRANSFER0);
curl_setopt($chCURLOPT_FOLLOWLOCATION1);
curl_exec($ch);
$info curl_getinfo($ch);
$maxSize $info['download_content_length']; 
$info is an arrays. print_r it so you can check what it contains.

Upadaing every 5 sec i did in JS, its just ajax request of file:
PHP Code: 
echo filesize("urfile.rar"
That ajax request update value of html5 tag:
Code: 
<progress max="<?php echo $maxSize ?>" value=""></progress>
I didnt post my whole scripts because its part of something bigger. Anyway hope it help