DMXzone File System Connector Support Product Page
Under investigation
How to fix Apache server 500 error?
Reported 11 Jun 2016 20:07:58
1
has this problem
11 Jun 2016 20:07:58 Jack McNeely posted:
I went through the steps in the tutorial for listing the files in a directory, and the File System Connector did its thing and completed all the steps (yay!). The resulting code is in a file called filelist.php. But when I load that in a browser, the place where the files should be listed is blank.The extension generated dmxConnect/api/Files/Videos.php, the name I told it to use for the data set because the folder that I am trying to list contains a bunch of video files.
The php error log and the Apache error log do not show any errors. The Apache access.log shows a generic 500 error code when it tries to load dmxConnect/api/Files/Videos.php.
The Videos.php file loads dmxConnectLib/dmxConnect.php, which attempts to load dmxConnect/config.php, which does not exist. That seems to be no big deal, but I can't figure out why Apache is barfing on Videos.php.
The directory where the videos reside is outside Apache's normal document root, on a different drive configured as a virtual directory in Apache's httpd.conf file. There aren't any .htacess files anywhere that would alter the configuration. To get Dreamweaver to be able to see the aliased directory, I set it up as a new site, empty except for the video files, and Dreamweaver is happy with that.
The httpd.conf directives look like this:
<IfModule alias_module>
Alias /MyVideos "S:/MyVideos"
</IfModule alias_module>
<Directory "S:/MyVideos">
Options Indexes Includes
AllowOverride AuthConfig Indexes
IndexOptions FancyIndexing FoldersFirst IgnoreCase SuppressDescription NameWidth=*
Order allow,deny
Allow from all
</Directory>
This is on Apache 2.2 running php 5.4.45, but I get the same results on a different machine running Apache 2.4. The Videos directory is not set as a ScriptAlias directory, if that matters.
In dmxConnectLib/dmxConnect.php, I tried setting $CONFIG_DEBUG to TRUE, but that did not produce any additional error messages on the filelist.php page or in the logs. Does anyone know what I am doing wrong?
Replies
Replied 13 Jun 2016 07:05:55
13 Jun 2016 07:05:55 Teodor Kuduschiev replied:
Hi Jack,
Please check the following tutorial: www.dmxzone.com/go/32354/debugging-problems-in-dmxzone-server-connect/ it explains how to debug the 500 server errors.
Please check the following tutorial: www.dmxzone.com/go/32354/debugging-problems-in-dmxzone-server-connect/ it explains how to debug the 500 server errors.
Replied 15 Jun 2016 16:00:25
15 Jun 2016 16:00:25 Jack McNeely replied:
The debugging console trick shows that the server is complaining about an invalid path coming from line 61 of dmxConnectLib\lib\core\Path.php:
file:"S:\MyVideos\dmxConnectLib\lib\core\Path.php"
line: 61
message:"Invalid Path! S:\MyVideos\Videos\Buffy.The.Vampire.Slayer"
That path does exists. Could this be Apache or php whining about the backslash vs. forward slash for path separators?
The complete debug message displayed in the Firefox developer tools panel is:
JSON
code: 0
file:"S:\MyVideos\dmxConnectLib\lib\core\Path.php"
line: 61
message:"Invalid Path! S:\MyVideos\Videos\Buffy.The.Vampire.Slayer"
trace:"#0 S:\MyVideos\dmxConnectLib\lib\core\FileSystem.php(188): lib\core\Path::toSiteUrl('S:\MyVideos\Vide...')
#1 S:\MyVideos\dmxConnectLib\modules\fs.php(288): lib\core\FileSystem::stat('S:\MyVideos\Vide...')
#2 S:\MyVideos\dmxConnectLib\modules\fs.php(273): modules\fs->stat(Object(stdClass))
#3 S:\MyVideos\dmxConnectLib\lib\App.php(159): modules\fs->dir(Object(stdClass), 'videos')
#4 S:\MyVideos\dmxConnectLib\lib\App.php(98): lib\App->execSteps(Object(stdClass))
#5 S:\MyVideos\dmxConnectLib\lib\App.php(71): lib\App->exec(Object(stdClass))
#6 S:\MyVideos\dmxConnect\api\Files\Videos.php(73): lib\App->define('{? "meta": {? ...')
#7 {main}"
file:"S:\MyVideos\dmxConnectLib\lib\core\Path.php"
line: 61
message:"Invalid Path! S:\MyVideos\Videos\Buffy.The.Vampire.Slayer"
That path does exists. Could this be Apache or php whining about the backslash vs. forward slash for path separators?
The complete debug message displayed in the Firefox developer tools panel is:
JSON
code: 0
file:"S:\MyVideos\dmxConnectLib\lib\core\Path.php"
line: 61
message:"Invalid Path! S:\MyVideos\Videos\Buffy.The.Vampire.Slayer"
trace:"#0 S:\MyVideos\dmxConnectLib\lib\core\FileSystem.php(188): lib\core\Path::toSiteUrl('S:\MyVideos\Vide...')
#1 S:\MyVideos\dmxConnectLib\modules\fs.php(288): lib\core\FileSystem::stat('S:\MyVideos\Vide...')
#2 S:\MyVideos\dmxConnectLib\modules\fs.php(273): modules\fs->stat(Object(stdClass))
#3 S:\MyVideos\dmxConnectLib\lib\App.php(159): modules\fs->dir(Object(stdClass), 'videos')
#4 S:\MyVideos\dmxConnectLib\lib\App.php(98): lib\App->execSteps(Object(stdClass))
#5 S:\MyVideos\dmxConnectLib\lib\App.php(71): lib\App->exec(Object(stdClass))
#6 S:\MyVideos\dmxConnect\api\Files\Videos.php(73): lib\App->define('{? "meta": {? ...')
#7 {main}"
Replied 15 Jun 2016 18:35:47
15 Jun 2016 18:35:47 Teodor Kuduschiev replied:
Can you tell me what the path should be? Also if possible please provide a link to your page.
Replied 20 Jun 2016 20:03:43
20 Jun 2016 20:03:43 Jack McNeely replied:
The path should be exactly what the error message says it cannot find, S:\MyVideos\Videos\Buffy.The.Vampire.Slayer, although that would be rendered in a browser as localhost/MyVideos/Videos/Buffy.The.Vampire.Slayer/
I can't provide a link to the page on my Windows machine, because that is firewalled off from the Internet. But I did create another page and upload it to a FreeBSD machine, and, tah-dah, the magic works on the Unix box but not on my Windows machines. If you want to see the code for the new page, it is at www.mcneely.org/dmxtest/filelist.php. I don't know whether that will tell you anything useful, because that one works. But it doesn't work on my Windows machine, and the error is the same, namely, the debugging says the path is invalid. It is not a permissions issue on my Windows machine. If I point a browser directly at the folder in question, Apache displays its usual list of the files.
The new page just provides a list of images that I used in making two other test pages to show how newer versions of dmxSuperzed.js break the animation magic in dmxAnimate. Those pages are at www.mcneely.org/dmxtest/supersized/index.html if you want to see them.
I can't provide a link to the page on my Windows machine, because that is firewalled off from the Internet. But I did create another page and upload it to a FreeBSD machine, and, tah-dah, the magic works on the Unix box but not on my Windows machines. If you want to see the code for the new page, it is at www.mcneely.org/dmxtest/filelist.php. I don't know whether that will tell you anything useful, because that one works. But it doesn't work on my Windows machine, and the error is the same, namely, the debugging says the path is invalid. It is not a permissions issue on my Windows machine. If I point a browser directly at the folder in question, Apache displays its usual list of the files.
The new page just provides a list of images that I used in making two other test pages to show how newer versions of dmxSuperzed.js break the animation magic in dmxAnimate. Those pages are at www.mcneely.org/dmxtest/supersized/index.html if you want to see them.
Replied 27 Jun 2016 11:48:06
27 Jun 2016 11:48:06 Teodor Kuduschiev replied:
Hello Jack,
It is difficult to debug this, without an access to your machine. There are no issues with Windows servers, also our own showcase server is windows based. Most probably there is some configuration issue, but we can only guess what this might be.
It is difficult to debug this, without an access to your machine. There are no issues with Windows servers, also our own showcase server is windows based. Most probably there is some configuration issue, but we can only guess what this might be.
Replied 27 Jun 2016 21:54:45
27 Jun 2016 21:54:45 Jack McNeely replied:
Please check your
email. I sent a link on Wednesday, June 22, for how to get to my Windows machine.
Replied 28 Jun 2016 07:12:18
28 Jun 2016 07:12:18 Teodor Kuduschiev replied:
Please re-send the email as i cannot seem to find one from you in my inbox.
Replied 28 Jun 2016 20:18:13
28 Jun 2016 20:18:13 Jack McNeely replied:
Done. I also sent a copy to
Since you have it working on Windows, I know that the problem is 100 percent on my end. Any time a DMXZone extension doesn't work as expected, I always know that the problem is always on my end.