FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » Imported messages » comp.lang.php » Files getting clobbered when I run out of disk space
Show: Today's Messages :: Polls :: Message Navigator
Return to the default flat view Create a new topic Submit Reply
Re: Files getting clobbered when I run out of disk space [message #180107 is a reply to message #180106] Tue, 08 January 2013 01:07 Go to previous messageGo to previous message
Adam Harvey is currently offline  Adam Harvey
Messages: 25
Registered: September 2010
Karma:
Junior Member
On Mon, 07 Jan 2013 15:49:30 -0800, faraz wrote:
> There was some disk space issues with my server. As a result any script
> I had that opened a file for writing would clobber it i.e truncate it to
> zero length . Since there was no space left on device, nothing would be
> written to it.
>
> Are there any workarounds to this?

Honestly, the right answer here is to set up a monitoring system that
will alert you if disk space becomes low — trying to deal with this after
the disk has already filled up is a bad idea, since at that point you've
already lost the ability to write files, logs, database files et cetera.

Trying to do this inline in a PHP script is the wrong tool for the job.

Adam
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: does the php is not popular?i am a phper?
Next Topic: shell script with shell_exec()
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Tue Nov 26 00:06:27 GMT 2024

Total time taken to generate the page: 0.04986 seconds