Jump to content

[SOLVED] problem VPS creates /img/tmp files with owner & group=apache


Recommended Posts

Hi,

 

My VPS is giving me some problems. I hope someone here has encountered the same issue and found a solution to it.

 

I am able to create a product. However when I tried to upload an image for the product using the [image] link on the left of the product screen this appeared "An error occurred when copying the image" and the process stopped.

 

I did some checks and realised that a temporary file has been created in /img/tmp and the owner and group rights is "apache: apache" instead of "user:psacln". It also creates some other sub-folders and files in img/p with the same file ownership.

 

for the img/p - I can CHOWN and CHGRP when they come along. But for the img/tmp even if I did it, the product image would not be uploaded as a new tmp file is created with the "apache;apache" ownership. Seems like I am got going to make it.

 

I tried to search this forum but was unable to dig out any past post. Sorry, if this have been solved.

Link to comment
Share on other sites

Hi Vekia,

 

I am given all rights to manage the "container". There is a Plesk 9.5.4 Control Panel and it comes with Virtuozzo for me to SSH in. I also know there is CentOS in it. Using these tools I may be alright except that I am not a Unix person and I just don't know how to tell the VPS not to use 'apache:apache".

 

Any guide from you will be appreciated.

Link to comment
Share on other sites

1) Hi El Patron,

 

I visited this page [http://www.mewsoft.com/download/fcgitest.zip] to get a script to run the VPS and the result is "internal error" meaning, according to the author - I do not have a FASTCGI module. I hope the script is written correctly.

 

 

2) Hi Vekia,

 

On my VPS, I discovered these information:

/etc/apache2/envvars ===> /apache2 folder not present

/etc/sysconfig/httpd ===> /httpd file contains remarks only

/etc/rc.conf ==> this file not present

 

Regards.

Link to comment
Share on other sites

Hi Vekia,

 

I got this from PHPinfo:

 

System: Linux 2.6.18-028stab095.1 #1 SMP Mon Oct 24 20:15:15 MSD 2011 i686

Server API: Apache 2.0 Handler

Apache Version: Apache/2.2.3 (CentOS)

Apache API Version: 20051115

Server Root: /etc/httpd

X-Powered-By: PHP/5.3.3

PHP API: 20090626

Virtual Directory Support: disabled

Configuration File (php.ini) Path: /etc

Link to comment
Share on other sites

<p>Hi Vekia,</p>

<p> </p>

<p>I found this inside the file! I should be close now, right? :D</p>

<p> </p>

<pre>

# User/Group: The name (or #number) of the user/group to run httpd as.

# . On SCO (ODT 3) use "User nouser" and "Group nogroup".

# . On HPUX you may not be able to use shared memory as nobody, and the

# suggested workaround is to create a user www and use that user.

# NOTE that some kernels refuse to setgid(Group) or semctl(IPC_SET)

# when the value of (unsigned)Group is above 60000;

# don't use Group #-1 on these systems!

#

User apache

Group apache</pre>

<pre>

</pre>

 

Link to comment
Share on other sites

Hi Vekia,

 

I am so grateful to you, and also El Patron for responding.

 

Hmm. I am using "germs" for owner. Because I am doing this at the top-level, do you think it will propagate "germs:psacln" to all other domains residing in this VPS? I am going to log in another domain name for a store for my [spam-filter]'s flower online (once she is ready).

Link to comment
Share on other sites

Hi El Patron,

 

Based on the valuable tips given "apache module, try fastcgi" - I did a research on their uses and this led me to the VPS' Web Hosting Setup (Plesk Panel 9.5.4.) for the particular domain name. At the PHP Support field, it is stated as run as Apache Module and there is another field ["PHP 'Safe mode' on ]. I disabled this 'Safe mode' field and the product images can be uploaded without further issue.

 

Thank you once again to Vekia and El Patron for spending your time on this. Really appreciated.

 

Germs :D

Edited by germs (see edit history)
  • Like 1
Link to comment
Share on other sites

  • 8 months later...

Hi El Patron,

 

Based on the valuable tips given "apache module, try fastcgi" - I did a research on their uses and this led me to the VPS' Web Hosting Setup (Plesk Panel 9.5.4.) for the particular domain name. At the PHP Support field, it is stated as run as Apache Module and there is another field ["PHP 'Safe mode' on ]. I disabled this 'Safe mode' field and the product images can be uploaded without further issue.

 

Thank you once again to Vekia and El Patron for spending your time on this. Really appreciated.

 

Germs :D

I'm experiencing exactly the same problem. Where do you set "PHP safe mode" to off?

 

Edit: found it in php.ini. It's already off but my problem still exist......

Edited by vansrv7 (see edit history)
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...