English (United Kingdom)
Jms Multi Site, formerly joomla multisite.
Create, share multiple joomla sites in few clicks !
Message
  • EU e-Privacy Directive

    This website uses cookies to manage authentication, navigation, and other functions. By using our website, you agree that we can place these types of cookies on your device.

    View e-Privacy Directive Documents

Welcome, Guest
Please Login or Register.    Lost Password?
Go to bottomPage: 123
TOPIC: hello.php symbolic link error
#1049
hello.php symbolic link error 14 Years, 10 Months ago Karma: 0
Hi Edwin, I am struggling to get symbolic links working. I have WHM and CPanel.

Ran the hello world script and get the error:

Hello world script

Warning: fopen(/home/.../public_html/symlink_file4a3513e4e4b81.txt) [function.fopen]: failed to open stream: Permission denied in /home/.../public_html/hello.php on line 49
hello world script
The current path is "/home/.../public_html"
Error : Unable to create the file /home/.../public_html/symlink_file4a3513e4e4b81.txt
Probably you will need to used the Joomla FTP Layer and the Symbolic Links will be forbidden

I have changed the permissions of the log and tmp folders up to 777 but this did not work.

I have checked the FTP settings in Joomla and these work fine to /public_html

(I installed JMS fine and updated the scripts fine so it is working)

The full path is given to the tmp and log folders eg home/etc

Any ideas? I really wanted to get this up and running quickly as I have a lot of sites to get built!

Any help appreciated.

Will
willhaigh
Fresh Boarder
Posts: 10
graphgraph
User Offline Click here to see the profile of this user
The administrator has disabled public write access.
 
#1050
Re:hello.php symbolic link error 14 Years, 10 Months ago Karma: 54
Some hostin g provider configure their environment to forbid such Symbolic Link usage.

I suppose your apaches is configured to NOT follow Symbolic Links
"Options +FollowSymLinks"

When using the "hello".php", you can check with a SSH connectoin that the file has been successfully created.

If you are runing on your own server, you have to review the apache configuration.
If you are using a hosting provider, contact it supports to check the apaches configuration and know if it accept the creation of Symbolic Links.


"hello.php" try to create a sSymbolic Link to test if it is allowed.
As reported this creation fail.

The "hello.php" is not connected to Joomla or product.
It works in standalone.
edwin2win
Moderator
Posts: 5370
graph
User Offline Click here to see the profile of this user
The administrator has disabled public write access.
 
#1051
Re:hello.php symbolic link error 14 Years, 10 Months ago Karma: 0
My apache server has FollowSymLinks and SymLinksIfOwnerMatch enabled on '/'

Does the latter stop me from using SymLinks with JMS?
willhaigh
Fresh Boarder
Posts: 10
graphgraph
User Offline Click here to see the profile of this user
The administrator has disabled public write access.
 
#1052
Re:hello.php symbolic link error 14 Years, 10 Months ago Karma: 0
I disabled SymLinksIfOwnerMatch
and set file permissions on public_html/tmp and public_html/logs to 777
and I get Unix Symbolic Links: Allowed on the JMS Settings page.

I set logs folder and files to 766 and the files in tmp to 766 and still get the allowed message.

However if I change my tmp folder to 766 I get the error:
Warning: chdir() [function.chdir]: Permission denied (errno 13) in /home/mylocalc/public_html/administrator/components/com_multisites/helpers/helper.php on line 79
Forbidden

the hello.php also gives me the same error even when settings page in JMS is saying Unix Symbolic Links: Allowed.

I dont want to have folders set to 777.

Do you have any more advice I think I am nearly there!

Will
willhaigh
Fresh Boarder
Posts: 10
graphgraph
User Offline Click here to see the profile of this user
The administrator has disabled public write access.
 
#1053
Re:hello.php symbolic link error 14 Years, 10 Months ago Karma: 54
All I can tell you is that you can use the "hello.php" to peform all your test and identify the origin of the Symbolic Link forbidden.

As the "hello.php" works in standalone (don't require anything - joomla is not required), you can use it to test your hosting server configuration.
You can for example try using it in a specific folder that is not related to your current domain or sub-domain.

Personnally, I suggest you to first try setup your hosting server correctly before trying to use the Symbolic Link in JMS.
Once the hosting server will be OK, you could try to setup JMS to use the Symbolic Links.

Just test one parameter (here the hosting server configuration) at a time.

If I understand correctly, when you put chmod 777 the Symbolic Link is OK.
This mean that the files and/or folder has an ower / group that is compatible with the apache user.
You can also try to perform a chown (change owner) to give the appropriate owner of the file. When it will be own or at least in the same group of user, you should have the permission.

This kind of problem may be due to the fact that you transfert( ie. FTP) files and folders with a user that is not compatible with apache. This is the case for example if you use a root user that have more privilege than apache. In this case apaches will not be able to create or modify files/folders created by the root user.
edwin2win
Moderator
Posts: 5370
graph
User Offline Click here to see the profile of this user
Last Edit: 2009/06/14 20:34 By edwin2win.
The administrator has disabled public write access.
 
#1054
Re:hello.php symbolic link error 14 Years, 10 Months ago Karma: 0
Sorry Edwin I think this nearly there.

I got the hello.php to work but only when I set public_html to 777.
So SymLinks do work on my server.
Any thoughts as to why this only works when I set the permission to 777 and how I can resolve?
willhaigh
Fresh Boarder
Posts: 10
graphgraph
User Offline Click here to see the profile of this user
The administrator has disabled public write access.
 
Go to topPage: 123
get the latest posts directly to your desktop
2Win, Multisite(s) are trademarks of Edwin2Win.
Joomla