title: Fatal error: Allowed memory size of 419430400 bytes exhausted (tried to allocate 251268854 bytes) in /home/apartmen/php/HTTP/Request.php on line 1012
body: <p>Ok, I know how this question has been asked and all. But, heres the thing.</p>
  
  <ol>
  <li>I'm already using <code>ini_set('memory_limit', '400M');</code></li>
  <li>The file I'm trying to transfer (to Amazon S3) is 245MB</li>
  <li>The error msg is weird, says allowed mem of 400MB exhausted when it was trying to allocate 239MB.. isnt that the other way round?</li>
  </ol>
  
  <p>The script I'm using is a library out there, to communicate with the Amazon S3</p>
  
  <p>Help please!</p>
  
  <p>EDIT<br>
  Ok heres the code, as you can see I'm not doing much, its all about the script I'm using.. That is here: <a href="http://belgo.org/backup_and_restore_to_amazo.html" rel="nofollow">http://belgo.org/backup_and_restore_to_amazo.html</a></p>
  
  <pre><code>ini_set('memory_limit', '400M');
  require 'lib/s3backup.php';
  $bucket = 'thebucketname';
  $bucket_dir = 'apts';
  $local_dir = "/home/apartmen/public_html/transfer/t/tr";
  $s3_backup = new S3_Backup;
  $s3_backup-&gt;upload_dir( $bucket, $bucket_dir, $local_dir );
  </code></pre>