[ejabberd] Serving http error 404

six at sixweb.hu six at sixweb.hu
Mon Aug 27 18:55:23 MSK 2012


 

I got your point exactly but I'm afraid you haven't got mine. Please
accept that there _is_ a file called iJab.html at the docroot:


-rw-r--r-- 1 ejabberd ftpuser 1923 2010-06-10 12:04 Changes
drwxr-xr-x
6 ejabberd ftpuser 4096 2010-08-19 14:58 ijab
-rw-r--r-- 1 ejabberd
ftpuser 1851 2012-08-26 21:18 ijab_config.js
-rw-r--r-- 1 ejabberd
ftpuser 1332 2010-03-11 00:48 ijab_i18n_en.js
-rw-r--r-- 1 ejabberd
ftpuser 3485 2010-04-02 17:42 ijab_i18n_zh.js
-rw-r--r-- 1 ejabberd
ftpuser 5757 2010-04-09 15:31 iJab.html 

Again: It was a typo, could we
just move forward, please? Nevertheless,
http://sitename:5280/chat/ijab_i18n_zh.js does not work either. 

No
luck with the URL you suggested. If the docroot is "/var/www-data/ijab"
and the file iJab.html is at the directory "/var/www-data/ijab/" why
should it work? 

You noticed there is a directory "ijab" within the
file list above, actually it's "/var/www-data/ijab/ijab". 

Do you think
I could make the webserver more verbose? Why it does not create access
file, is it because the file is 404? 

Kind regards, 

six 

2012-08-27
16:20 időpontban Daniel Dormont ezt írta: 

> My point was, that there
is no file called iJab.html with _any_ capitalization in that directory.
What directory did you give us the listing for? If it was
/var/www-data/ijab then perhaps the URL should be
http://sitename:5280/chat/ijab/iJab.html [7] because that directory
contains a directory called "ijab". 
> 
> On Mon, Aug 27, 2012 at 4:06
AM, <six at sixweb.hu [8]> wrote:
> 
>> Hello Daniel, 
>> 
>> I tried out
some different scenarios and one of them was to rename the file to test
if the problem was about case sensitivity. It wasn't and I renamed back
the file to the original name since then. I have created the file list
in that unfortunate moment when the file was renamed. I'm sorry for the
misleading file list and I wish it was so easy. :) 
>> 
>> Kind regards,

>> 
>> six 
>> 
>> 2012-08-27 05:07 időpontban Daniel Dormont ezt írta:

>> 
>>> Forgive me for asking the obvious, but the directory listing
you gave below does not include a file called iJab.html. Are you sure
that's the correct URL?
>>> 
>>> On Sun, Aug 26, 2012 at 5:15 PM,
<six at sixweb.hu [4]> wrote: 
>>> 
>>>> Dear List Members, 
>>>> 
>>>> I
use ejabberd 2.1.2 on Ubuntu 10.04 server (erlang 1:13.b.3). XMPP works
fine but I can't make mode_http_fileserver deliver a webpage while
administration interface works fine on port 5280. (I'd like to set up
iJab, finally.) 
>>>> 
>>>> The question is, why am I getting 404 and
how could I debug this? 
>>>> 
>>>> Config snippets: 
>>>> 
>>>> Listen
section: 
>>>> 
>>>> {5280, ejabberd_http, [
>>>>
%%{request_handlers,
>>>> %% [
>>>> %% {["pub", "archive"],
mod_http_fileserver}
>>>> %% ]},
>>>> %%captcha,
>>>>
{request_handlers,
>>>> [
>>>> {["chat"], mod_http_fileserver}
>>>>
]},
>>>> http_bind,
>>>> http_poll,
>>>> web_admin
>>>> ]}
>>>> 
>>>>
Modules section: 
>>>> 
>>>> {mod_http_fileserver, [
>>>> {docroot,
"/var/www-data/ijab"},
>>>> {accesslog,
"/var/log/ejabberd/access.log"}
>>>> ]},
>>>> 
>>>> Then I went to
http://sitename:5280/chat/iJab.html [1] and I expected to get the html
page but unfortunately I got a 404 with every try. 
>>>> 
>>>> I set
loglevel to 5 and I got only this: 
>>>> 
>>>> I(:ejabberd_app:69) :
ejabberd 2.1.2 is started in the node ejabberd at cerebellum 
>>>> 
>>>>
=INFO REPORT==== 2012-08-26 21:44:10 === I(:ejabberd_listener:232) :
(#Port) Accepted connection {{192,168,0,10},42154} ->
{{192,168,0,1},5280} 
>>>> 
>>>> =INFO REPORT==== 2012-08-26 21:44:10
=== D(:ejabberd_http:135) : S: [{["chat"],mod_http_fileserver}, 
>>>>

>>>> {["admin"],ejabberd_web_admin},
>>>>
{["http-bind"],mod_http_bind},
>>>>
{["http-poll"],ejabberd_http_poll}]
>>>> 
>>>> =INFO REPORT====
2012-08-26 21:44:10 === I(:ejabberd_http:137) : started: {gen_tcp,#Port}

>>>> 
>>>> =INFO REPORT==== 2012-08-26 21:44:10 ===
D(:ejabberd_http:254) : (#Port) http query: 'GET' /chat/iJab.html 
>>>>

>>>> =INFO REPORT==== 2012-08-26 21:44:10 === D(:ejabberd_http:322) :
["chat","iJab.html"] matches ["chat"] 
>>>> 
>>>> =INFO REPORT====
2012-08-26 21:44:10 === D(:mod_http_fileserver:294) : Requested
["iJab.html"] 
>>>> 
>>>> The file /var/log/ejabberd/access.log have not
created at all. It seems if fileserver mod did not start at all but
obviously it's not the case since it logs into
/var/log/ejabberd/ejabberd.log. 
>>>> 
>>>> I verified the permission of
the files in question: 
>>>> 
>>>> -rw-r--r-- 1 ejabberd ftpuser 1923
2010-06-10 12:04 Changes
>>>> drwxr-xr-x 6 ejabberd ftpuser 4096
2010-08-19 14:58 ijab
>>>> -rw-r--r-- 1 ejabberd ftpuser 1851 2012-08-26
21:18 ijab_config.js
>>>> -rw-r--r-- 1 ejabberd ftpuser 1332 2010-03-11
00:48 ijab_i18n_en.js
>>>> -rw-r--r-- 1 ejabberd ftpuser 3485 2010-04-02
17:42 ijab_i18n_zh.js
>>>> -rw-r--r-- 1 ejabberd ftpuser 5757 2010-04-09
15:31 index.html 
>>>> 
>>>> The output of ps: 
>>>> 
>>>> ejabberd
17075 0.0 0.0 10712 400 ? S 21:42 0:00
/usr/lib/erlang/erts-5.7.4/bin/epmd -daemon
>>>> ejabberd 17111 0.0 1.2
92116 50532 ? S 21:42 0:01 /usr/lib/erlang/erts-5.7.4/bin/beam -K false
-P 250000 -- -root /usr/lib/erlang -progname erl -- -home
/var/lib/ejabberd -- -sname ejabberd -pa /usr/lib/ejabberd/ebin -s
ejabberd -kernel inetrc "/etc/ejabberd/inetrc" -ejabberd config
"/etc/ejabberd/ejabberd.cfg" log_path "/var/log/ejabberd/ejabberd.log"
-sasl sasl_error_logger {file,"/var/log/ejabberd/erlang.log"} -mnesia
dir "/var/lib/ejabberd" -smp disable -noshell -noshell -noinput
>>>>

>>>> The content of the file /var/log/ejabberd/erlang.log: 
>>>> 
>>>>
=PROGRESS REPORT==== 26-Aug-2012::21:42:16 ===
>>>> application:
ejabberd
>>>> started_at: ejabberd at cerebellum 
>>>> 
>>>> Thanks, 
>>>>

>>>> six 
>>>> 
>>>>
_______________________________________________
>>>> ejabberd mailing
list
>>>> ejabberd at jabber.ru [2]
>>>>
http://lists.jabber.ru/mailman/listinfo/ejabberd [3]
>> 
>>
_______________________________________________
>> ejabberd mailing
list
>> ejabberd at jabber.ru [5]
>>
http://lists.jabber.ru/mailman/listinfo/ejabberd [6]



Links:
------
[1] http://sitename:5280/chat/iJab.html
[2]
mailto:ejabberd at jabber.ru
[3]
http://lists.jabber.ru/mailman/listinfo/ejabberd
[4]
mailto:six at sixweb.hu
[5] mailto:ejabberd at jabber.ru
[6]
http://lists.jabber.ru/mailman/listinfo/ejabberd
[7]
http://sitename:5280/chat/iJab.html
[8] mailto:six at sixweb.hu
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.jabber.ru/pipermail/ejabberd/attachments/20120827/16b53dab/attachment.html>


More information about the ejabberd mailing list