By wat on Wednesday, 12 February 2014
Posted in Technical Issues
Replies 46
Likes 0
Views 723
Votes 0
I think it still not completed because user avatar and photo did not migrated.
Hello wat,

I have ran the migration for you and it seems to work fine and it did not stall at 20%. Not too sure how to reproduce this issue but the user's are migrated already
·
Wednesday, 12 February 2014 21:48
·
0 Likes
·
0 Votes
·
0 Comments
·
Do I need to migrate again because photo still not show?
wat
·
Wednesday, 12 February 2014 22:02
·
0 Likes
·
0 Votes
·
0 Comments
·
Hm yeah, it looks like there's an issue with the photo avatar migration. I am checking on this.
·
Wednesday, 12 February 2014 22:07
·
0 Likes
·
0 Votes
·
0 Comments
·
Hello wat,

After running some tests, it looks like there are some permission issues on the folders. Hence, the avatar migration actually failed to generate those avatars. Can you please let me know if it is correct that you are running Joomla on FTP Layer?
·
Wednesday, 12 February 2014 22:40
·
0 Likes
·
0 Votes
·
0 Comments
·
I don't know that my joomla running on FTP layer or not. Is it the folder permission? What's the folder I need to writable? I can do it for you because you can not change it via ftp.
wat
·
Wednesday, 12 February 2014 22:46
·
0 Likes
·
0 Votes
·
0 Comments
·
Hello wat,

The php script needs access to the /media/com_easysocial/ folder
·
Thursday, 13 February 2014 00:47
·
0 Likes
·
0 Votes
·
0 Comments
·
already changed /media/com_easysocial/ to 777
wat
·
Thursday, 13 February 2014 09:52
·
0 Likes
·
0 Votes
·
0 Comments
·
I try to complete the migration but it's show this error.
wat
·
Thursday, 13 February 2014 16:57
·
0 Likes
·
0 Votes
·
0 Comments
·
Hello wat,

I think there's still a problem because the php script cannot write contents on the newly created folder. For example, take a look at this folder in /media/com_easysocial/testing/ . This folder was created using Joomla and it by default has a umask of 755 . However, I cannot seem to create a file on that particular folder due to permission errors

Can you check this with your hosting provider? I do think that the ownership of the files and folders as the user "ftp" is really wrong though.
·
Thursday, 13 February 2014 22:47
·
0 Likes
·
0 Votes
·
0 Comments
·
What do I need to check with my hosting provider? I don't know what do I need to ask with them. I have a account to login to the server. Do you need it?
wat
·
Thursday, 13 February 2014 23:00
·
0 Likes
·
0 Votes
·
0 Comments
·
Hello wat,

Ask them to check on the global "umask" and if it is correct for the file and folder ownership to belong to the user "ftp" ?
·
Friday, 14 February 2014 02:37
·
0 Likes
·
0 Votes
·
0 Comments
·
Hi Mark, they said they've just changed all the folder to 755 because of the hacker problem in this server last two day. They ask which folder we need to change to 777, then they will change for you?
wat
·
Friday, 14 February 2014 13:24
·
0 Likes
·
0 Votes
·
0 Comments
·
I see testing folder which you create and it's show lilt this. I've already click recursively.
wat
·
Friday, 14 February 2014 15:35
·
0 Likes
·
0 Votes
·
0 Comments
·
Hello wat,

It should never be 777 ! 777 is like opening doors to hackers and say "Come and hack me please". What you need to sort out is the write access. I am not sure if you understand the issue here about the "test" folder.

1. I write a test script, to create a folder in /tmp/testing/
2. In that test script, I try to create a file in /tmp/testing/ and it failed.

Why 2# failed is because when it creates the folder /tmp/testing/ , it does not have the proper ownership.

This is the second test that I ran on the site, to create a file called "hello.txt" in the document root so you can see the error message



Warning: file_put_contents(/home/acnethai/domains/acnethai.com/public_html/hello.txt) [function.file-put-contents]: failed to open stream: Permission denied in /home/acnethai/domains/acnethai.com/public_html/libraries/joomla/filesystem/file.php on line 421


Again, DO NOT EVER SET TO 777! It's too dangerous to do that. To fix this, we need to address the real issue, which is the ownership of the file and folders
·
Saturday, 15 February 2014 01:35
·
0 Likes
·
0 Votes
·
0 Comments
·
Thanks for your advice. What do I need to help you solve this problem please tell me? As I told you before this post that I have the account to login to my server if you need it.
wat
·
Saturday, 15 February 2014 10:42
·
0 Likes
·
0 Votes
·
0 Comments
·
Hello wat,

What your hosting provider need to do right now is to sort out the ownership of the file and folder (I still believe that the files and folder should not be owned by the user "ftp") . The ownership of the file and folders should be owned by the webserver user.

Do you have root access to the server? If you have the root access, I can help you to check the server and reset all the permissions and fix it once and for all for you.

P/S: I noticed that there are some folders on the site with 777 permissions by other 3rd party extensions. You must not set it to 777 like I said earlier. Setting 777 is suicidal
·
Saturday, 15 February 2014 12:13
·
0 Likes
·
0 Votes
·
0 Comments
·
Here is my root access account to the server.
wat
·
Saturday, 15 February 2014 12:32
·
0 Likes
·
0 Votes
·
0 Comments
·
For the folder which chmod777, I think some of extension requirement need these folder to chmod777. So I don't know can I turn all of these folder to 755?
wat
·
Saturday, 15 February 2014 12:37
·
0 Likes
·
0 Votes
·
0 Comments
·
Hello wat,

Thanks! I have fixed the permissions for you and the problem is because you should use the FTP user "acnethai" instead fo tu111 . I checked your server configuration and it looks like suPHP is installed so Apache is being emulated as running as "acnethai", so the files and folder owner should be acnethai. This way, you do not need 777 anywhere. Everything should be 755.

Okay, before I proceed can I confirm the following:

1. Can I reinstall EasySocial and wipe out the existing data in EasySocial and then re-migrate everything again?

2. Can I reset everything to be 755?

3. I have also changed the password for the user acnethai to the same password as tu111 .
·
Saturday, 15 February 2014 14:35
·
0 Likes
·
0 Votes
·
0 Comments
·
1. Can I reinstall EasySocial and wipe out the existing data in EasySocial and then re-migrate everything again?

ok

2. Can I reset everything to be 755?

ok

3. I have also changed the password for the user acnethai to the same password as tu111 .

Do you mean ftp password? I send ftp of acnethai account for you in this field.
wat
·
Saturday, 15 February 2014 15:33
·
0 Likes
·
0 Votes
·
0 Comments
·
For the permission, I can set all of these folder to be 755?
wat
·
Saturday, 15 February 2014 15:36
·
0 Likes
·
0 Votes
·
0 Comments
·
Hello wat,

I am sorry for the delay of this reply, I have been debugging your site / server for almost 10 hours now Okay, you can actually disregard those messages you see in the "System Info" in your Joomla back end because, if they are going through the Joomla's API which is JFile and JFolder, they should be safe with suExec.

The reason why you are seeing those directories as "not writable" is because Joomla is using is_writable method in PHP to check if those folders are writable but because is_writable is a php function, it is returning false because php scripts are running as the user "apache".

To really solve your permission issues, on the server there's 2 choice:

1. This is more ideal and everything should be 755 NOT 777. However, php scripts on the site need to explicitly use JFile and JFolder from Joomla and not rely on built-in php functions to store files. I am not too sure which extension should fail but if you hit errors, you should notify the developer.

2. This is a much quicker way around, is to have every file / folders to be owned by apache / apache and do not use suExec. This way, existing scripts will most likely work fine but I am not sure about Directadmin though.

By the way, I have also migrated the items over to EasySocial now
·
Sunday, 16 February 2014 03:34
·
0 Likes
·
0 Votes
·
0 Comments
·
I don't know how can I say about your service. It's really great. I see one problem that occur with raxo_module which pull the image from the content which I selected to show at the module. But now it did not show as the image which I attach. Do you have the idea with this problem?
wat
·
Sunday, 16 February 2014 09:25
·
0 Likes
·
0 Votes
·
0 Comments
·
Hello wat,

I am really sorry for the delay of this reply as it is a weekend for us here. Hm, I am not too sure what Raxo module is doing there but perhaps you can try checking this with them? If they are relying on the php's function to "write" or "read" data, their script will fail. They must utilize Joomla's filesystem library because only Joomla's filesystem library goes through the FTP Layer (If your Joomla is installed / configured with FTP)
·
Sunday, 16 February 2014 20:30
·
0 Likes
·
0 Votes
·
0 Comments
·
Ok Mark, I will ask them for this problem. Really thanks for your great support again.
wat
·
Sunday, 16 February 2014 20:59
·
0 Likes
·
0 Votes
·
0 Comments
·
You are most welcome wat Let me know how this goes.
·
Sunday, 16 February 2014 21:37
·
0 Likes
·
0 Votes
·
0 Comments
·
Hello Mark, they suggest me to do with this step but has no luck. Image still not show and they don't know what's the problem because it has shown before.

1. Use the most recent module version.
We keep improving our product, please track the updates.


2. Enable images in the module administration panel
Also set width and height for both TOP and usual items (e.g. 200*160 and 120*80).
The module generates thumbnails from images in your articles. Make sure that the selected articles have images.


3. Check thumbnail library (tb.php) workability.
Open in browser http://yoursitename/modules/mod_raxo_al ... ols/tb.php
You see “no image specified”. That means everything is ok! (Skip the rest of this step and go to step 4).

If you see: "500 Internal Server Error or "Permission denied" or "Could not create the index.html file" and similar error messages, that means that the problem is in your hosting settings.

Open your FTP client and make sure that:
a) the file tb.php has permissions 644;
b) From our experience we can say that in similar situations most probably it's permission problem, and it's very important who is the OWNER of this file. The owner must be the same as for other Joomla files.
c) sometimes the following helps: copy tb.php to your computer, delete this file on the server and then copy this file from your computer back to the server.

If you don't know how to change this, please contact your hoster on this issue.


4. Make sure that the thumbnail cache folder is writable.
Make sure that the folder yoursite/images/raxo_thumbs/ is created and has status "writable".
It depends on your hosting but most often folder permissions must be 755 (sometimes 777).
wat
·
Tuesday, 18 February 2014 11:27
·
0 Likes
·
0 Votes
·
0 Comments
·
Let them know that they cannot use imagejpeg / imagepng to generate files. In other words, the following will fail on a suexec setup and PHP is not running on CGI mode.


imagejpeg($canvas, $tempfile, $quality);
imagepng($canvas, $tempfile, floor($quality * 0.09));


They need to use the API that Joomla provides, JFile::write to store files because JFile::write will go through the FTP layer when necessary.
·
Tuesday, 18 February 2014 12:47
·
0 Likes
·
0 Votes
·
0 Comments
·
Thanks Mark I will tell them and think I will create image manually.
wat
·
Tuesday, 18 February 2014 13:56
·
0 Likes
·
0 Votes
·
0 Comments
·
You are most welcome
·
Tuesday, 18 February 2014 18:18
·
0 Likes
·
0 Votes
·
0 Comments
·
Hello Mark, now how can I know what's the extension I can use? I've just taken front page slide show module out of my site because it can not use. I notice that both of the extensions are not in JED list but how can I consider to use the extension outside JED?

Sorry for have question again.
wat
·
Wednesday, 19 February 2014 14:32
·
0 Likes
·
0 Votes
·
0 Comments
·
Hello wat,

Hm, what do you mean by you "can use"? Every extensions is use-able on the site If it fails because of file generation, you should ask them to fix it because they are actually relying on the native php function to perform file operations rather than utilizing Joomla's FTP layer.
·
Wednesday, 19 February 2014 14:59
·
0 Likes
·
0 Votes
·
0 Comments
·
thank you.
wat
·
Wednesday, 19 February 2014 17:29
·
0 Likes
·
0 Votes
·
0 Comments
·
You are most welcome
·
Wednesday, 19 February 2014 20:55
·
0 Likes
·
0 Votes
·
0 Comments
·
Here is raxo module developer said.

imagejpeg and imagepng are standard PHP function to work with images. It's first time we hear that some hosting cannot support that. If it's really true, you won't be able to create thumbnails and work with images not only in our module, but at all.

Also, we pull your attention to Joomla Technical Requirements:
http://www.joomla.org/about-joomla/technical-requirements.html
Recommended PHP Version 5.4 +

Your hosting use a very old PHP version 5.2.17.
So contact your hoster to change PHP to a newer version.

I cannot give some more advice because FTP access you provided doesn't work.
And I see that you still haven't solved the permission issue.
wat
·
Thursday, 20 February 2014 10:16
·
0 Likes
·
0 Votes
·
0 Comments
·
Hello wat,

Perhaps it's best that you contact your hosting provider to upgrade PHP to the latest version so that it satisfies their requirements. Let me simplify this problem for you:

1. Your PHP is not configured as CGI module.
2. Your webserver has suexec installed and loaded and everything needs to be owned by the user account acnethai
3. When you save a file using imagejpeg( $resource , $filename ); , the user that is used will be the webserver user. In this case, the user is apache.
4. The solution? Use Joomla's file layer to store files because Joomla has FTP layer stores files as the FTP user.
·
Thursday, 20 February 2014 18:22
·
0 Likes
·
0 Votes
·
0 Comments
·
Thanks again Mark for your suggestion. Can you suggest who can update php and config the server for me? I'm thinking to change new host or find someone to config my server because my site's admin is not familiar with joomla.
wat
·
Thursday, 20 February 2014 21:57
·
0 Likes
·
0 Votes
·
0 Comments
·
Hello wat,

The problem is you are running on directadmin I am not sure if your hosting provider added suexec on purpose or is it a default build of directadmin. You should request your host to simplify your life. First, disable suexec and just use apache user to handle everything

Another alternative is to run PHP as a CGI module as I believe this could solve issues.
·
Thursday, 20 February 2014 22:21
·
0 Likes
·
0 Votes
·
0 Comments
·
I think they cannot because I talk with them to please upgrade php to newer version since last year but still 5.2 now that why I would like to find someone to re-config this server or change to new host.
wat
·
Thursday, 20 February 2014 22:39
·
0 Likes
·
0 Votes
·
0 Comments
·
Hm, that's sad to hear Where is the server hosted now?
·
Thursday, 20 February 2014 23:35
·
0 Likes
·
0 Votes
·
0 Comments
·
Yes, it's really sad. I'm hosted in Thailand. http://www.pinkkeyhost.com/pub/modules/mypages/
wat
·
Friday, 21 February 2014 05:25
·
0 Likes
·
0 Votes
·
0 Comments
·
Hello wat,

Their website looks bad :x Try looking for a better host in Thailand? :P
·
Friday, 21 February 2014 11:12
·
0 Likes
·
0 Votes
·
0 Comments
·
I don't how can I find the host to suit with joomla or can you suggest anyone for me to config our server. Now I use dedicated server that I can do everything with my server.
wat
·
Friday, 21 February 2014 11:25
·
0 Likes
·
0 Votes
·
0 Comments
·
Hello wat,

I am not sure if there are any hosts in Thailand as I am not familiar with the hosting environment there. You should try googling them?
·
Friday, 21 February 2014 11:30
·
0 Likes
·
0 Votes
·
0 Comments
·
Hi Mark, can I ask you a little that I've just changed permission at my server to apache via command chown apache:apache R * and can install component via joomla installation. Is this change to use apache user but I see at the permission page that it's chmod 777 every folder and cannot change permission? Do I need to do anything next?

Sorry for disturbing you and thanks for your answer.
wat
·
Saturday, 22 February 2014 18:47
·
0 Likes
·
0 Votes
·
0 Comments
·
Hello wat,

If you change everything to (user)apache and (group)apache , you will face problems because your apache configuration seems like configured to use suexec. Suexec is an apache module that simulates apache to run as your shell user. In this case, apache is running under the user of acnethai . I am not sure what other complications it may cause but if everything is owned by apache, then probably you need to disable the FTP layer in Joomla.
·
Saturday, 22 February 2014 19:22
·
0 Likes
·
0 Votes
·
0 Comments
·
View Full Post