26

I'm running some php file every 2 minutes via Windows Task Scheduler, but time-to-time I get notification about low space on my drive D:.

After check I found that in XAMPP tmp folder located on D:\XAMPP\tmp are lot of files with names similar to: cachegrind.out.1381478803-D__xampp_htdocs_Real_Estate_App_index_php and size of each file is more than 144 MB.

These files have content:

==== NEW PROFILING FILE ==============================================
version: 1
creator: xdebug 2.2.3
cmd: D:\xampp\htdocs\Real Estate App\index.php
part: 1
positions: line

events: Time

fl=php:internal
fn=php::header
3 0

fl=php:internal
fn=php::define
45 0

...

I understand that this is caused because of xdebug, but how to stop this process I don't know. Mybe someone had same problem? Any ideas?

zur4ik
  • 6,072
  • 9
  • 52
  • 78

2 Answers2

50

You have xdebug profiling enabled. If this is enabled xdebug will write runtime information about the scripts into systems temp folder (by default). Disable it in your php.ini (or in the xdebug.ini, depends on where did you set it)

xdebug.profiler_enable=Off

and restart the web server

hek2mgl
  • 152,036
  • 28
  • 249
  • 266
  • 3
    I found [XDebug] category in my php.ini file with option: `xdebug.profiler_enable = 1`. I switched value to 0 and looks like my problem is solved. Thanks a lot! – zur4ik Oct 11 '13 at 08:22
  • 4
    you are welcome. you can delete the existing cachegrind files as well – hek2mgl Oct 11 '13 at 08:23
  • can we delete those files in tmp folder it is really taking lot of space ?? @hek2mgl – Hitesh Feb 26 '14 at 04:25
  • @hek2mgl : xdebug.profiler_enable = 0 | is zero in my php.ini but still i see tmp folder oversized, what are other things which might have caused this ? – Hitesh Feb 26 '14 at 04:57
  • @hitesh have you restarted the webserver? – hek2mgl Feb 26 '14 at 07:53
  • @hek2mgl no i didnt change the value, In php.ini the value was zero initially...since i didnt change it, i dont need to restart the browser, I wanted to know what are other things which might cause this issue other than xdebug – Hitesh Feb 26 '14 at 09:58
  • @hitesh There are a 1000s of reasons possible. You need to check which files are in /tmp and who is creating that files. – hek2mgl Feb 26 '14 at 10:30
  • @hek2mgl : I have files of size 160 mb just now created when i started using my drupal site of name cachegrind.out.1393565671-H__xampp_htdocs_gemkt_trunk_index_php ..... htdocs/gemkt/trunk/index.php these are folders...|| and there are lot of files getting created here of almost same size – Hitesh Feb 28 '14 at 05:48
  • Thank you, Ive just deleted 860GB of cachegrind.out files from my PC. its only a 920GB HDD. I wont be turning xdebug.profiler_enable back ON any time soon, unless there is a way of disabling the cache only ? – TarranJones Feb 10 '16 at 17:53
7

Yes found out that turning xdebug.profiler to off does part of the trick

xdebug.profiler_enable= 0

Then also turn off also eAccelerator which precomplies codes

; The directory that is used for disk cache. eAccelerator stores precompiled ; code, session data, content and user entries here. The same data can be ; stored in shared memory also (for more quick access).

eaccelerator.enable="0"

Then stop apache

Delete the files in the tmp dir

Resart apache does the trick

Pascal
  • 2,377
  • 3
  • 25
  • 40