Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Blank screen #3569

Closed
sona1111 opened this issue Jun 1, 2013 · 8 comments
Closed

Blank screen #3569

sona1111 opened this issue Jun 1, 2013 · 8 comments

Comments

@sona1111
Copy link

sona1111 commented Jun 1, 2013

Hello I have been happily hosting owncloud for myself about 6 months now without any issue. Very recently, not sure exactly when, two problems popped up. The first one I noticed on my laptop running ubuntu and owncloud client the memory useage was 1.5gb and had constant disk useage. (from swap I would guess) I thought it abnormal and I had a few videos which were a little large I thought might be causing problems (though they had been there for a while without much issue) When I tried to log into the web interface I was greeted with a completely blank screen - no error, nothing in view source either.

I tried upgrading packages changing to the newest owncloud version, restarting apache and mysql services, still same issue.

Server is ubuntu server 11.10

I see this a few times in the apache log:

[Sun May 19 22:13:12 2013] [error] [client 69.142.90.54] PHP Warning: include(): Filename cannot be empty in /home/jms/owncloud/lib/template.php on line 408
[Sun May 19 22:13:12 2013] [error] [client 69.142.90.54] PHP Warning: include(): Failed opening '' for inclusion (include_path='/home/jms/owncloud/lib:/home/jms/owncloud/config:/home/jms/owncloud/3rdparty:/home/jms/owncloud/apps:/home/jms/owncloud/lib:.:/usr/share/php:/usr/share/pear:/home/jms/owncloud') in /home/jms/owncloud/lib/template.php on line 408

and these errors in the owncloud log:

{"app":"PHP","message":"include(): Filename cannot be empty at /home/jms/owncloud/lib/template.php#441","level":2,"time":1369107865}
{"app":"PHP","message":"include(): Failed opening '' for inclusion (include_path='/home/jms/owncloud/lib:/home/jms/owncloud/config:/home/$
{"app":"PHP","message":"include(): Filename cannot be empty at /home/jms/owncloud/lib/template.php#441","level":2,"time":1369107875}
{"app":"PHP","message":"include(): Failed opening '' for inclusion (include_path='/home/jms/owncloud/lib:/home/jms/owncloud/config:/home/$
{"app":"PHP","message":"include(): Filename cannot be empty at /home/jms/owncloud/lib/template.php#441","level":2,"time":1369202278}
{"app":"PHP","message":"include(): Failed opening '' for inclusion (include_path='/home/jms/owncloud/lib:/home/jms/owncloud/config:/home/$
{"app":"PHP","message":"include(): Filename cannot be empty at /home/jms/owncloud/lib/template.php#441","level":2,"time":1369271931}
{"app":"PHP","message":"include(): Failed opening '' for inclusion (include_path='/home/jms/owncloud/lib:/home/jms/owncloud/config:/home/$

@DeepDiver1975
Copy link
Member

@sona1111 which version are you running now?

@ghost
Copy link

ghost commented Jun 1, 2013

Some additional reports in the forums about this:

https://forum.owncloud.org/viewtopic.php?f=23&t=11352

For the high RAM usage see here: owncloud/client#591

@sona1111
Copy link
Author

sona1111 commented Jun 1, 2013

I have tried both version 4 and version 5. I started having the problem while using version 4.

I also tried deleting the database and creating it again without luck.

@RustyDust
Copy link

I ran into the same problem today and after some hours of debugging I came up with a fix that works for me. The problem at least in my case was in /lib/template.php where the fetchTemplate function wasn't able to find/get the correct template 'layout.guest.php'. Here's the patch I use for fixing this on 5.0.7:

--- a/lib/template.php  2013-06-06 17:55:51.000000000 +0200
+++ b/lib/template.php  2013-06-30 17:21:39.000000000 +0200
@@ -291,6 +291,11 @@
                                // Check if the template is overwritten by the selected theme
                                if ($this->checkPathForTemplate(OC::$SERVERROOT."/themes/$theme/apps/$app/templates/", $
name, $fext)) {
                                }elseif ($this->checkPathForTemplate(OC_App::getAppPath($app)."/templates/", $name, $fex
t)) {
+                               }elseif ($this->checkPathForTemplate(OC::$SERVERROOT."/$app/templates/", $name, $fext)) 
{
+                               }else{
+                                       echo('template not found: template:'.$name.' formfactor:'.$fext
+                                                       .' webroot:'.OC::$WEBROOT.' serverroot:'.OC::$SERVERROOT);
+                                       die();
                                }
                        }else{
                                // Check if the template is overwritten by the selected theme

I'm not sure whether the first elseif is correct at all or whether it should be replaced by my new elseif line. To better be safe than sorry I let it stay ;) I also added an error exit in case no template is found. Again, I'm not sure whether this was intended but without it the function would just exit in case $app contained something but no template could be found - which I don't think is what it should be doing.

I wasn't able to find out why the function couldn't find a template in the first place for in another installation that works just fine without the patch ownCloud will always pick the other branch of the outer if-then-else condition, namely the one where $app is empty. What exactly triggers the difference in behavior I don't know. Tried with different versions of PHP, used 5.3 as well as 5.4 - on the failing system it would always use the "wrong" and now fixed branch.

Anyway, it works for me, you can give it a spin at your own risk. Always remember: you break it, you own the pieces.

@VicDeo
Copy link
Member

VicDeo commented Jun 30, 2013

@RustyDust there is a great possibility you hit a bug fixed by #3770

@sona1111
Copy link
Author

@RustyDust, thank you so much! that code did the trick and I am back up.

@RustyDust
Copy link

@VicDeo You're probably right. Unfortunately I can't use the git checkout from master at the moment for the particular setup I'm working on. Also, even if the getTheme() fix also fixes the bug I encountered I still find it strange that the outer if-branch will let things pass through even if it wasn't able to find a template.

@karlitschek
Copy link
Contributor

should be fixed with #3770

@lock lock bot locked as resolved and limited conversation to collaborators Aug 21, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants