View Full Version : Edit php.ini?
tm2000
08-03-2005, 05:05 AM
Need some input... Need to change php.ini to allow larger uploads... Currently: upload_max_filesize 2M
Q1: Can I do that?
Q2: How and are there any downsides to mnaking it larger (other then using more disk space)
Thanks!
1. you can use pico.
First do:
whereis php
and it will tell you the dir for the php.ini file then do:
Before we edit the file, let's make a backup.
cp /path/to/php.ini /path/to/php.ini.bak (replace path/to with actual dir)
now let's edit it
pico /path/to/php.ini (replace path/to with the actual dir)
Then hit CTRL + W (at the same time) and type in upload_max_filesize. Once you do that it should take you to the place where you can edit it and just change the number there.
Then hit CTRL +X (at the same time) and then hit enter and type 'y' then enter.
then do service httpd restart.
2. I wouldn't really know, should be okay
tm2000
08-03-2005, 09:18 AM
FANTASTIC!!! Thank you so much for the step by step and the details... New to VPS from shared... so all new stuff for me... GREAT!
FANTASTIC!!! Thank you so much for the step by step and the details... New to VPS from shared... so all new stuff for me... GREAT!
No problem :-).
If your uncomfortable editting in SSH, you can always transfer your files off your server then edit them in notepad. Use WINSCP
http://winscp.net/eng/index.php
http://img.photobucket.com/albums/v86/pztup/Untitled-3.jpg
PvUtrix
08-03-2005, 02:49 PM
there are a few copies of php.ini on the VPS, to know which one is actually being used make a info.php file with just one function phpinfo(). There you will see which one is used next to "Configuration File (php.ini) Path" mine is /usr/local/Zend/etc/php.ini for instance
also "whereis php.ini" does not show the one used for me, I prefer "locate php.ini"
The best way to find php.ini in used to use this command.
root@gnu [~]# php -i | grep php.ini
Configuration File (php.ini) Path => /usr/local/Zend/etc/php.ini
ozgreg
08-16-2005, 06:20 PM
or locate php.ini :-)
vBulletin® v3.8.4, Copyright ©2000-2010, Jelsoft Enterprises Ltd.