LiteSpeed Technologies
Download Download     Blog Blog     Wiki Wiki     Forum Forum     Store     Contact Contact    

Go Back   LiteSpeed Support Forums > LiteSpeed Web Server > Install/Configuration > Editing php settings seems impossible

Reply
 
Thread Tools Display Modes
  #1  
Old 09-19-2011, 04:30 PM
tininho tininho is offline
Member
 
Join Date: May 2011
Posts: 17
Default Editing php settings seems impossible

Hi, I have tried everything I can imagine to change the php settings, I mainly want to raise the upload_max_filesize setting to restore my sql back up through phpmyadmin (filesize is bigger than 2M which is the current limit).

my phpinfo shows the following:
Configuration File (php.ini) Path /usr/local/lsws/lsphp5/lib

There is no php.ini in that folder or in any subfolders.

I made a find /usr/local/lsws/ -name 'php.ini' -run and edited all of the php.ini files found. Restarted the server and got absolutely no where (size limit is still 2M).

Can you please point me to a right direction here?
Reply With Quote
  #2  
Old 09-19-2011, 04:42 PM
webizen webizen is offline
LiteSpeed Staff
 
Join Date: Oct 2010
Posts: 2,338
if no php.ini under /usr/local/lsws/lsphp5/lib, default php settings are used no matter which php.ini you change. you should copy the modified php.ini to /usr/local/lsws/lsphp5/lib and restart lsws to make the change effective.
Reply With Quote
  #3  
Old 06-10-2012, 12:25 PM
tininho tininho is offline
Member
 
Join Date: May 2011
Posts: 17
I have problems with the php configuration again, I have edited the /usr/local/lsws/lsphp5/lib/php.ini (also confirmed the path from phpinfo.php) as following (part):

Code:
post_max_size = 100M
max_execution_time = 180
max_input_time = 120
upload_max_filesize = 100M
I restarted and LSWS and afterwards the whole server, I still get this on the phpinfo and PhpMyAdmin confirm the upload limit:

FROM PHPINFO:

Code:
upload_max_filesize	2M	2M
upload_tmp_dir	no value	no value
Screenshot: http://awesomescreenshot.com/0927p49ae

How this happens, why the attribute is not changing?
Reply With Quote
  #4  
Old 06-10-2012, 08:03 PM
NiteWave NiteWave is offline
LiteSpeed Staff
 
Join Date: Sep 2009
Posts: 2,226
check if it's overridden in .htaccess
for example,

php_value upload_max_filesize 2M
Reply With Quote
  #5  
Old 06-11-2012, 12:48 PM
tininho tininho is offline
Member
 
Join Date: May 2011
Posts: 17
I have disabled the ability to change the setting via .htaccess. The php settings remain unchanged, very strange.

I tried to rebuild php, but now I get the following error:
Quote:
fail to save current configuration.

Fail to generate build script, please try to manually fix the error first.
Failed to create manual install script: /usr/local/lsws/phpbuild/buildphp_manual_run.sh
What you think is causing this?
Reply With Quote
  #6  
Old 06-11-2012, 12:55 PM
webizen webizen is offline
LiteSpeed Staff
 
Join Date: Oct 2010
Posts: 2,338
check the ownship/permission of /usr/local/lsws/phpbuild and /usr/local/lsws/phpbuild/buildphp_manual_run.sh. they should be owned by lsadm.
Reply With Quote
  #7  
Old 06-11-2012, 01:26 PM
tininho tininho is offline
Member
 
Join Date: May 2011
Posts: 17
thanks, that helped for php reinstallation. the first problem remains, I cannot get the litespeed to read the custom php.ini file in /usr/local/lsws/lsphp5/lib/php.ini.

None of the settings change, most importantly the upload limit. Bizarre.. Any ideas?

could some other ownership be wrongly set (also strange, but if it helps..).
Reply With Quote
  #8  
Old 06-11-2012, 01:55 PM
webizen webizen is offline
LiteSpeed Staff
 
Join Date: Oct 2010
Posts: 2,338
do following to locate the php.ini in use. If you have not compiled php from admin console, it is likely you use something else.
Quote:
/usr/local/lsws/fcgi-bin/lsphp5 -i | grep "Configuration File"
Reply With Quote
  #9  
Old 06-11-2012, 02:57 PM
tininho tininho is offline
Member
 
Join Date: May 2011
Posts: 17
Here is part of the response (seems that all is not right):

PHP is compiled with Litespeed admin panel, php header and apc checked.

Code:
virtual@virtual273:~$ /usr/local/lsws/fcgi-bin/lsphp5 -i | grep "Configuration File"
PHP:  syntax error, unexpected BOOL_TRUE in /usr/local/lsws/lsphp5/lib/php.ini on line 11
Configuration File (php.ini) Path => /usr/local/lsws/lsphp5/lib
Loaded Configuration File => /usr/local/lsws/lsphp5/lib/php.ini
*** glibc detected *** /usr/local/lsws/fcgi-bin/lsphp5: free(): invalid pointer: 0x00007f8f8dd688b8 ***
======= Backtrace: =========
/lib/x86_64-linux-gnu/libc.so.6(+0x7e626)[0x7f8f8bb3b626]
/usr/local/lsws/fcgi-bin/lsphp5(destroy_zend_class+0x235)[0x73fce5]
/usr/local/lsws/fcgi-bin/lsphp5(zend_hash_clean+0x70)[0x7569a0]
/usr/local/lsws/lsphp5/lib/php/extensions/no-debug-non-zts-20100525/apc.so(apc_interned_strings_shutdown+0x20)[0x7f8f86669040]
/usr/local/lsws/lsphp5/lib/php/extensions/no-debug-non-zts-20100525/apc.so(apc_module_shutdown+0x12a)[0x7f8f8666295a]
/usr/local/lsws/lsphp5/lib/php/extensions/no-debug-non-zts-20100525/apc.so(+0xadff)[0x7f8f86657dff]
/usr/local/lsws/fcgi-bin/lsphp5[0x750113]
/usr/local/lsws/fcgi-bin/lsphp5[0x7552bb]
/usr/local/lsws/fcgi-bin/lsphp5(zend_hash_graceful_reverse_destroy+0x18)[0x756a78]
/usr/local/lsws/fcgi-bin/lsphp5[0x749233]
/usr/local/lsws/fcgi-bin/lsphp5(php_module_shutdown+0x2a)[0x6eb76a]
/usr/local/lsws/fcgi-bin/lsphp5[0x7ec2ed]
/usr/local/lsws/fcgi-bin/lsphp5[0x431126]
/lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xed)[0x7f8f8bade76d]
/usr/local/lsws/fcgi-bin/lsphp5[0x431241]
======= Memory map: ========
00400000-00c8a000 r-xp 00000000 08:02 393690                             /usr/local/lsws/fcgi-bin/lsphp-5.4.0
00e8a000-00e8b000 r--p 0088a000 08:02 393690                             /usr/local/lsws/fcgi-bin/lsphp-5.4.0
00e8b000-00e99000 rw-p 0088b000 08:02 393690                             /usr/local/lsws/fcgi-bin/lsphp-5.4.0
00e99000-00ebc000 rw-p 00000000 00:00 0
02081000-02292000 rw-p 00000000 00:00 0                                  [heap]
7f8f86437000-7f8f8644c000 r-xp 00000000 08:02 1703980                    /lib/x86_64-linux-gnu/libgcc_s.so.1
7f8f8644c000-7f8f8664b000 ---p 00015000 08:02 1703980                    /lib/x86_64-linux-gnu/libgcc_s.so.1
7f8f8664b000-7f8f8664c000 r--p 00014000 08:02 1703980                    /lib/x86_64-linux-gnu/libgcc_s.so.1
7f8f8664c000-7f8f8664d000 rw-p 00015000 08:02 1703980                    /lib/x86_64-linux-gnu/libgcc_s.so.1
7f8f8664d000-7f8f8666f000 r-xp 00000000 08:02 1050379                    /usr/local/lsws/lsphp5/lib/php/extensions/no-debug-non-zts-20100525/apc.so
7f8f8666f000-7f8f8686f000 ---p 00022000 08:02 1050379                    /usr/local/lsws/lsphp5/lib/php/extensions/no-debug-non-zts-20100525/apc.so
7f8f8686f000-7f8f86871000 r--p 00022000 08:02 1050379                    /usr/local/lsws/lsphp5/lib/php/extensions/no-debug-non-zts-20100525/apc.so
7f8f86871000-7f8f86872000 rw-p 00024000 08:02 1050379
Reply With Quote
  #10  
Old 06-11-2012, 04:36 PM
webizen webizen is offline
LiteSpeed Staff
 
Join Date: Oct 2010
Posts: 2,338
pls fix the syntax error in php.ini and comment out 'extension=apc.so' first and see any difference.
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -7. The time now is 04:02 AM.



- Archive - Top
© Copyright 2003-2011 LiteSpeed Technologies, Inc. All rights reserved. Privacy Policy.