Two things you can try.
1/ In your main page modify the 'refresh' code
<script type="text/javascript">
function refreshIFrame() {
var x = document.getElementById("graph");
// x.contentWindow.location.reload();
x.src += ' ';
var t = setTimeout(refreshIFrame, 300000);
}
</script>
2/ Add in the graph page header
<meta http-equiv="Cache-Control" content="no-cache, no-store, must-revalidate">
<meta http-equiv="Expires" content="0">