hosted by liquidweb


Go Back   Web Hosting Talk : Web Hosting Main Forums : Hosting Software and Control Panels : Create a symlink between different users that targets to PHP
Reply

Hosting Software and Control Panels Software used in the web hosting industry. Topics include control panels, add-on software, setup scripts, etc.
Forum Jump

Create a symlink between different users that targets to PHP

Reply Post New Thread In Hosting Software and Control Panels Subscription
 
Send news tip View All Posts Thread Tools Search this Thread Display Modes
  #1  
Old 07-05-2009, 09:20 AM
dglite dglite is offline
New Member
 
Join Date: Sep 2008
Posts: 4
Talking

Create a symlink between different users that targets to PHP


Hi, I’ve been working on a project for weeks and I can not solve this, hope you can give me an idea. I am working on a dedicated server, and I need to create some symlinks between different accounts and users...
Both accounts are on the same partition of the server (home) and I have root access and SSH access for everything.
If I create a symlink to a directory of another account and on that directory there is any HTML file (e.g. Index.html), that symlink works great and it shows the content on that file.
HOWEVER if the symlink targets to a directory in which there is a PHP file (e.g. Index.php) or any script programmed in PHP (e.g. Joomla) it does not work and gives...
“Internal Server Error” + Additionally, a 404 Not Found error was encountered...

When I go to Cpanel the “error log” says...

[Sun Jul 05 09:15] [error] [client zz] File does not exist: /home/zzz/public_html/500.shtml
[Sun Jul 05 09:15] [error] [client zz] SoftException in Application.cpp:367: Mismatch between target UID (123) and UID (123) of file "/home/zzz/public_html/my-dir/my-symlink/index.php"

However, If go to SSH and edit server owner of the symlink, so both symlink and target file has the same owner (chown user:user directory_name) the problem is the same, but on the “error log” the UID Mismatch disappear and I only find...
File does not exist: /home/zzz/public_html/500.shtml

I’ve also tried modifying suexec by changing... “domain.com” for “domain-com” on the server alias, and does not work.

Here I give you more info about server file structure...

serveralias generation path...
/var/cpanel/userdata/USER/DOMAIN

suexec location...
/usr/local/apache/sbin/suexec

Server Information

System Linux
Apache Version 2.2.11 (Unix)
PERL Version 5.8.8
PHP Version 5.2.8

So the question is... HOW can I create a symlink between different users on the same dedicated server partition, that target to PHP scripts or how can I allow the server to execute PHP scripts through symlinks of different accounts?

Any help would be much appreciated, tks in advance!

Reply With Quote


Sponsored Links
  #2  
Old 07-05-2009, 09:58 AM
HivelocityDD HivelocityDD is offline
WHT Addict
 
Join Date: Apr 2009
Location: localhost
Posts: 174
I think the issue is because you have installed suexec.

Have you tried full permission to the directories of the symbolic link. Also make sure the permission is there for the apache daemon most probably nobody

I would also suggest you check for openbase_dir settings in your php.ini disable it if it is there.

__________________
Dedicated Servers - sales@hivelocity.net - 1-888-869-HOST(4678)
Award winning Managed Hosting - Dedicated Server Hosting
Managed Dedicated Servers. Reseller Discounts. 24/7 Impressive Tech Support.

Reply With Quote
  #3  
Old 07-05-2009, 02:49 PM
dglite dglite is offline
New Member
 
Join Date: Sep 2008
Posts: 4
Talking How to uninstall suexec or edit openbase_dir?

Hi: first of all thanks for your fast reply and for your interest in helping us, that´s excellent.

I just would like to know this:

- If I have to unsinstall suexec, how can I do it? Or where can I find a step by step guide?

- how do I give full permission to the directories if always symbolic link chmod is 777?

- how do I disable openbase_dir on my php.ini?

I want to thank you again for your time, is great to find webmasters helping others, see u...

Reply With Quote
Sponsored Links
  #4  
Old 07-06-2009, 08:33 AM
==○○MR LAWZ○○== ==○○MR LAWZ○○== is offline
Newbie
 
Join Date: Oct 2008
Location: India
Posts: 21
Which os are you using ?

Reply With Quote
  #5  
Old 07-06-2009, 12:50 PM
dglite dglite is offline
New Member
 
Join Date: Sep 2008
Posts: 4
Talking I´ve tried lots of things...

Hi: in reply to your question, this is the system information...

Processor #1 Name: Intel(R) Pentium(R) 4 CPU 3.00GHz
System Information
Linux 2.6.18-92.el5 #1 SMP 2008 i686 i686 i386 GNU/Linux
sda: Write Protect is off
Apache Version 2.2.11 (Unix)
PERL Version 5.8.8
Path a PERL /usr/bin/perl
PHP Version 5.2.8

I went to WHM >> Security >> Security Center >> PHP Open Basedir Tweak >> and disable Open Basedir for both domains... But the problem is still the same.

I´ve also modified the saname of suexec so it will not be considered... But the problem is still the same.

I´ve changed the user owner of both files and directories, to unify them... But the problem is still the same.

Is there any way to have 2 domains and 1 user owner on WHM, or any other ay to solve this? Sincerely... Dglite

Reply With Quote
  #6  
Old 07-06-2009, 06:57 PM
dglite dglite is offline
New Member
 
Join Date: Sep 2008
Posts: 4
Talking Finally solved it...

Hi: I would like to thank you all for your help, it was just great. I was able to solve it. In the end I did not have to use symlinks, but your instructions helped me a lot to understand the situation and were very usefull, I really appreciate that!!!


Reply With Quote
Reply

Similar Threads
Thread Thread Starter Forum Replies Last Post
cpanel - having users create their own emails MPDon Hosting Software and Control Panels 0 10-16-2007 04:30 AM
RaQ 550 - Unable to create users. dradrian Dedicated Server 1 07-30-2006 05:40 AM
anyone know of any script that allows users to signup and create their own website .. d3nnis Programming Discussion 19 12-04-2003 10:43 AM
how to create virtual users in webmin? rlynch Hosting Security and Technology 4 03-08-2003 09:09 PM
program for users to create a website online genevaroth Hosting Software and Control Panels 5 05-31-2002 11:52 PM

Related posts from TheWhir.com
Title Type Date Posted
CM4all Offers Ecommerce Store Widget Ecwid to Partners Web Hosting News 2013-02-06 10:47:29
NetDNA Launches Integrated CDN for Developers to Optimize Web Application Performance Web Hosting News 2012-11-19 15:30:18
Web Host Gandi Emphasizes User Customization with Interface Updates Web Hosting News 2012-10-23 16:14:19
Security Provider HostingArmor Releases Server Scanning cPanel Plugin Web Hosting News 2011-07-25 19:33:26
Hosting Provider Web.com Launches Mobile Website Service Web Hosting News 2011-06-20 17:50:17


Tags
apache, different users, php, server alias, symlink

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes
Postbit Selector

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 Off
HTML code is Off

Forum Jump
Login:
Log in with your username and password
Username:
Password:



Forgot Password?
Advertisement:
Web Hosting News:



 

X

Welcome to WebHostingTalk.com

Create your username to jump into the discussion!

WebHostingTalk.com is the largest, most influentual web hosting community on the Internet. Join us by filling in the form below.


(4 digit year)

Already a member?