OJS OCS OMP OHS

You are viewing the PKP Support Forum | PKP Home Wiki



OJS, PHP 5.3.6 and Blank Pages

Are you responsible for making OJS work -- installing, upgrading, migrating or troubleshooting? Do you think you've found a bug? Post in this forum.

Moderators: jmacgreg, btbell, michael, bdgregg, barbarah, asmecher

Forum rules
What to do if you have a technical problem with OJS:

1. Search the forum. You can do this from the Advanced Search Page or from our Google Custom Search, which will search the entire PKP site. If you are encountering an error, we especially recommend searching the forum for said error.

2. Check the FAQ to see if your question or error has already been resolved.

3. Post a question, but please, only after trying the above two solutions. If it's a workflow or usability question you should probably post to the OJS Editorial Support and Discussion subforum; if you have a development question, try the OJS Development subforum.

Re: OJS, PHP 5.3.6 and Blank Pages

Postby atoz » Mon Mar 18, 2013 4:26 pm

ramon wrote:Hello atoz,
When you are logged in the server, your user has to be the owner of the files so you can edit them.
However, Apache is running as a different user and that user needs permission on your folders.
You can run chown -Rf www-data:youruser to OJS folder (this will run recursively!) so that Apache has permission and your group also has permission.
You could also try playing with permissions (adding the apache user only on certain folders), but usually that takes a lot of work and may later cause you further issues.


Hi Ramon,
I really thank you for your help. I have another 3 questions:

Just to be clear, If I choose the second option (playing with permissions); Are you suggesting I have to run chown -Rf www-data:myuser individually to the common writable folders? (cache, public, t_compile, _db, t_config ....) ? And than, set the permissions again to 755?

Is there a problem (or more than one) on my server setup that is producing this behaviour? Is it possible to fix?

The last one, finally, 777 is not a good and safety option to any folder, isn`t it?

Thank you again!
atoz
 
Posts: 4
Joined: Sun Mar 17, 2013 9:04 pm

Re: OJS, PHP 5.3.6 and Blank Pages

Postby ramon » Tue Mar 19, 2013 7:56 am

Hello atoz,

I personally wouldn't recommend fiddling with folder permissions unless you know what you're doing AND know how your server is setup.
Sometimes you create a Web Server group (www-data), not just the web server user, and add other users to it so that you can make their web folders run with their permissions, to make it easier to edit and not need them to be root or allow them to run chmod or chown commands, for example. These types of situations are highly specialized and tend NOT to be the case with paid hosting. This is more likely to happen in an institution with it's own private network.

First, I would figure out who is the web server user (ps -ef | grep apache, this command is everywhere in this forum!).
Then, chown -Rf the ojs folder to that web user.
Then, set chmod -Rf 644 to ojs folder.
Then, set 755 to public, plugins, locale, cache and any other folder that requires writing by the web server.
Depending on the configuration, 644 may not work and you'll have to settle with 755 or even 775... which is already not too safe.

NEVER use 777 in a production environment.

Also, you should check that the submissions folder is outside of the web public folder and that it has writing permissions, it's included in the PHP paths, etc...

The group in the chown command will only be effective or have any effect if the group exists.
Otherwise, it won't matter much.
The last number is for any other user in the server, which should be 4 or 5 at the most. These types of users don't really need to do anything other than, maybe, execute files... that's it...

_______________________________
Ramón Martins Sodoma da Fonseca
Analista em C&T
Coordenação de Tecnologias de Informação
Instituto Brasileiro de Informação em Ciência e Tecnologia - IBICT
Ministério da Ciência e Tecnologia - MCT
ramon
 
Posts: 931
Joined: Wed Oct 15, 2003 6:15 am
Location: Brasí­lia/DF - Brasil

Re: OJS, PHP 5.3.6 and Blank Pages

Postby atoz » Sun Mar 24, 2013 10:30 am

Ramon,
Thank you for the help, I'll try your suggestions!
atoz
 
Posts: 4
Joined: Sun Mar 17, 2013 9:04 pm

Re: OJS, PHP 5.3.6 and Blank Pages

Postby ubaiddev » Mon Apr 08, 2013 1:40 am

Hello all I am having same problem, My website was running fine. but last time my hosting server provider upgrade there hosting. now my website is showing blank page.
I follow the instructions to find out the error. I got this :
Fatal error: Cannot redeclare class Locale in /home/synergy/public_html/demo/jms/classes/i18n/Locale.inc.php on line 26

can anyone tell me what should I do?

Thanks
ubaiddev
 
Posts: 27
Joined: Mon Apr 08, 2013 1:35 am

Re: OJS, PHP 5.3.6 and Blank Pages

Postby ramon » Mon Apr 08, 2013 7:22 am

Hello ubaiddev

You're most probably running into a class conflict between your OJS and PHP versions.
You should upgrade to the latest OJS version to fix this, as you probably have more trouble trying to rename all the class calls yourself.

_______________________________
Ramón Martins Sodoma da Fonseca
Analista em C&T
Coordenação de Tecnologias de Informação
Instituto Brasileiro de Informação em Ciência e Tecnologia - IBICT
Ministério da Ciência e Tecnologia - MCT
ramon
 
Posts: 931
Joined: Wed Oct 15, 2003 6:15 am
Location: Brasí­lia/DF - Brasil

Previous

Return to OJS Technical Support

Who is online

Users browsing this forum: Google [Bot] and 2 guests