简体   繁体   中英

Lost Xdebug.ini file while installing Xdebug

Accidentally i lost xdebug.ini file in /etc/php5/conf.d folder. How to get back that while i am trying to install xdebug using apt-get ,it's giving an note like below.

Not replacing deleted config file /etc/php5/conf.d/xdebug.ini

I searched for this in google, i am able to find only one useful reply. That i can't understand how to do so i am pasting that also here, so please suggest me how to proceed.

I lost my xdebug.ini file on my ubuntu slice. What happened was that I had accidentally installed xdebug via apt-get as well as pecl. I was removing the pecl installation, which also removed the ini file. I then tried reinstalling through apt-get, but i get the message: 

Setting up php5-xdebug (2.0.3-1) ...
Not replacing deleted config file /etc/php5/conf.d/xdebug.ini

Aaaaaarghhhh!! How do I get back my ini file??? anyone have a clue?
rubing January 2009
I just fixed this by purging xdebug using dpkg with the -P flag. And then reinstalling with apt-get. No worries!

Ah geez, it looks the whole file is just a link to the module:

zend_extension=/usr/lib/php5/20060613/xdebug.so

The file that you deleted (/etc/php5/conf.d/xdebug.ini) just contains the following line:

zend_extension=/usr/lib/php5/20060613/xdebug.so

Although the path might be different as that seems for an older PHP version - check which directory names you have under /usr/lib/php5 and use that.

Alternative options are already provided by @tetet.

Maybe 'apt-get install --reinstall' will do the trick for you. Otherwise touch xdebug.ini in /etc/php5/conf.d and try again, touch creates an empty file.

An alternate route is to unpack the downloaded debian package and copy the config file from there: dpkg-deb -x .

Nowdays it's content is more like:

zend_extension=xdebug.so

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM