# Configure PHPSuExec  on FreeBSD



## BSDKernel (Feb 26, 2013)

Currently am running PHP on my FreeBSD server as an apache module and so I have to give folders full permissions for my clients to upload their web pages. But I know that there is a workaround of running php under CGI and enable suexec for php to run as a user owning the web pages directory. Please help me on how to configure this setup as I tried and getting this is the logs  

```
target uid/gid (2497/2498) mismatch with directory (0/0) or program (2497/140733193390530)
```


----------



## BSDKernel (Feb 26, 2013)

If anyone can help me. I will be grateful.


----------



## SirDice (Feb 26, 2013)

Have some patience. Don't expect an answer within 5 minutes of posting your question.


----------



## DutchDaemon (Feb 26, 2013)

Picking the correct forum will only help.


----------



## Carpetsmoker (Mar 4, 2013)

You could try doing what the messages says:



> target uid/gid (2497/2498) mismatch with directory (0/0) or program (2497/140733193390530)



It expect the target directory to be owner by user/group 2497/2498, but it's owned by user/group 0/0 (this is root/wheel).
So try a *chown 2497:2498*. I assume you set some directory in suexec or you use the document root.


----------

