Web Hosting Talk







View Full Version : Local Safe Mode but Global Not


tinyhost
03-27-2004, 08:18 AM
Local Safe Mode but Global Not

Hi there all,

I run a software house, so I host some of the clients, not too public but have about 100 domains hosted in there.

Anyway, I have clients that need their safe mode to be off,
so what I did was to add "php_admin_value safe_mode off" to this section after <module php4> in httpd.include

But sadly, it only works till the plesk overwrites it.

Anyway suggestions that i can keep it permanent?

Thanks

phpdeveloper
03-27-2004, 09:12 AM
Try inserting this into each VirtualHost section, this shouldn't overwritten.

tinyhost
03-27-2004, 10:15 AM
Thank you for your reply.

But sorry to impose but how do you exactly do that?

1.2.3. Steps will be appreciated as I am not really a server admin here, just trying to solve the problem.

Thanks in advance.

phpdeveloper
03-27-2004, 10:18 AM
Well, find the section in httpd.include that starts with:

<VirtualHost>
and ends with
</VirtualHost>

and is related to one of the domains on your server, you will see there a line that says:
ServerName www.domain.com

and insert that line there in your first post, then save and restart apache. This will disable safe mode for that particular domain.

tinyhost
03-27-2004, 10:23 AM
thanks.. but will the plesk rewrite it when I make a new domain or in a couple of days.

What i mean is that will it this safemode method be permanent?

tinyhost
03-27-2004, 10:31 AM
one more sir, should it be <xx.xx.xx.xx:443> or <xx.xx.xx.xx:80>

as what i had done was placing that command in <xx.xx.xx.xx:80>
<IfModule mod_php.4.c>
in between of

php_admin_flag engine on
<--------------------------------> placed here
php_admin_value open_basedir "xxxxxx"

and it didnt last :(

phpdeveloper
03-27-2004, 10:33 AM
should be 80.

tinyhost
03-27-2004, 10:42 AM
sigh..
tried .. failed

I have placed

<VirtualHost xx.xx.xx.xx:80>
Server name xxxxxx
redirectpermanent / http://xxxxxxxx
php_admin_value safe_mode off
</virtualhost>

Please correct me if I am wrong

Checked with phpinfo.php

safe_mode local On Global On

phpdeveloper
03-27-2004, 10:44 AM
Did you restart apache?

tinyhost
03-27-2004, 10:46 AM
yup :(

Anything wrong with this?

<VirtualHost xx.xx.xx.xx:80>
Server name xxxxxx
redirectpermanent / http://xxxxxxxx
php_admin_value safe_mode off
</virtualhost>

Brightadmin
03-29-2004, 02:38 AM
Hi,

Editing "safe mode" options in php.ini may work for global changes.

Regards,

Bright:)

sprintserve
03-29-2004, 06:56 AM
Originally posted by
Hi,

Editing "safe mode" options in php.ini may work for global changes.


when will you learn to read the whole thread and not just spam the board with your posts?

In any case,

Originally posted by
as what i had done was placing that command in <xx.xx.xx.xx:80>
<IfModule mod_php.4.c>
in between of

php_admin_flag engine on
<--------------------------------> placed here
php_admin_value open_basedir "xxxxxx"



Try placing the php_admin_value just before </virtualhost> instead of within the IfModule section and restart Apache .