DSM-G600, DNS-3xx and NSA-220 Hack Forum

Unfortunately no one can be told what fun_plug is - you have to see it for yourself.

You are not logged in.

Announcement

#1 2007-05-26 05:06:07

DNS-323 Talker
Member
Registered: 2007-05-21
Posts: 245

lighttpd...I'm sure I'm missing something obvious...

I'm trying to get lighttpd working on my DNS-323 so I can host some simple photo pages to share with my family via http.

I've set up fun_plug (the most recent version) and have telnet working, which includes lighttpd.  I'm a complete linux newbie, and am stumbling along doing a lot of reading/searching the forum and various web sites, but can't figure out why lighttpd won't work.

I have:

- enabled lighttpd to run
- modified the lighttpd.conf file to set the port to 8080 (that's the only change I've made to the sample conf file that comes with fun_plug
- set up port forwarding on my router to forward port 8080 to the DNS-323 intenal IP (192.168....)
- created a very simple web page (index.htm) with just one line of text.  I placed it in the "www/pages" directory that the lighttpd.conf file references (/mnt/HD_a2/www/pages/). 

I've tried to access the web page and been unable to...I get a page cannot be displayed error.  I use the following for the url:

http://<my external IP>:8080/index.htm

I've tried running lighttpd.sh manually (command line via telnet - ./lighttpd.sh) to confirm that it's really running.  When I do that I get the message: Can't bind to port: 8080 address already in use.  I assume that's because port 8080 is bound the first time lighttpd runs at restart.  That sound reasonable, or do I need to change to another port?  Is there another command that I can issue to confirm that lighttpd is really bound to port 8080?  I used ps to confirm it is a running process (results -  1136 root     /mnt/HD_a2/fun_plug.d/bin/lighttpd -f /mnt/HD_a2/fun_plug.d/etc/).


Any thoughts on what I'm doing wrong, or haven't done that I need to?

Thanks!

Last edited by DNS-323 Talker (2007-05-26 05:09:27)


DNS-323 w/two Seagate 500 GB RAID1
Fonz's Fun_Plug- Don't DNS-323 without it!

Offline

 

#2 2007-05-26 05:19:55

DNS-323 Talker
Member
Registered: 2007-05-21
Posts: 245

Re: lighttpd...I'm sure I'm missing something obvious...

hmmm...I changed the port in the conf file and my router to 3000, and now it works.  If anyone knows why I couldn't use 8080 I'd be very interested in that information.


DNS-323 w/two Seagate 500 GB RAID1
Fonz's Fun_Plug- Don't DNS-323 without it!

Offline

 

#3 2007-05-26 13:28:01

fonz
Member / Developer
From: Berlin
Registered: 2007-02-06
Posts: 1716
Website

Re: lighttpd...I'm sure I'm missing something obvious...

I don't know of anything that uses 8080. My funplug stuff definetly does not. Try the following commands to find out what's going on:

netstat -tln    - to see what ports are in use
killall lighttpd - to stop lighttpd, then recheck netstat. port 8080 should have disappeared

after restarting lighttpd.sh with port 8080 in the config, it should work...

Offline

 

#4 2007-05-26 19:14:07

DNS-323 Talker
Member
Registered: 2007-05-21
Posts: 245

Re: lighttpd...I'm sure I'm missing something obvious...

Here's netstat -tln results with the killall and recheck netstat.  The only port that clears is 3000, as you would expect.   So that looks OK. 

netstat -tln wrote:

/mnt/HD_a2 # netstat -tln
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address           Foreign Address         State
tcp        0      0 0.0.0.0:515             0.0.0.0:*               LISTEN
tcp        0      0 0.0.0.0:63878           0.0.0.0:*               LISTEN
tcp        0      0 0.0.0.0:3689            0.0.0.0:*               LISTEN
tcp        0      0 0.0.0.0:139             0.0.0.0:*               LISTEN
tcp        0      0 0.0.0.0:80              0.0.0.0:*               LISTEN
tcp        0      0 0.0.0.0:21              0.0.0.0:*               LISTEN
tcp        0      0 0.0.0.0:22              0.0.0.0:*               LISTEN
tcp        0      0 0.0.0.0:23              0.0.0.0:*               LISTEN
tcp        0      0 0.0.0.0:3000            0.0.0.0:*               LISTEN
tcp        0      0 0.0.0.0:443             0.0.0.0:*               LISTEN
/mnt/HD_a2 #
/mnt/HD_a2 # killall lighttpd
/mnt/HD_a2 # netstat -tln
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address           Foreign Address         State
tcp        0      0 0.0.0.0:515             0.0.0.0:*               LISTEN
tcp        0      0 0.0.0.0:63878           0.0.0.0:*               LISTEN
tcp        0      0 0.0.0.0:3689            0.0.0.0:*               LISTEN
tcp        0      0 0.0.0.0:139             0.0.0.0:*               LISTEN
tcp        0      0 0.0.0.0:80              0.0.0.0:*               LISTEN
tcp        0      0 0.0.0.0:21              0.0.0.0:*               LISTEN
tcp        0      0 0.0.0.0:22              0.0.0.0:*               LISTEN
tcp        0      0 0.0.0.0:23              0.0.0.0:*               LISTEN
tcp        0      0 0.0.0.0:443             0.0.0.0:*               LISTEN


DNS-323 w/two Seagate 500 GB RAID1
Fonz's Fun_Plug- Don't DNS-323 without it!

Offline

 

#5 2007-05-26 19:20:28

fonz
Member / Developer
From: Berlin
Registered: 2007-02-06
Posts: 1716
Website

Re: lighttpd...I'm sure I'm missing something obvious...

so lighttpd should start fine with port 8080. anyway, 8080 is an arbitray port number i've chosen. there's nothing wrong with port 3000 or any other port.

Offline

 

#6 2007-05-26 19:24:14

DNS-323 Talker
Member
Registered: 2007-05-21
Posts: 245

Re: lighttpd...I'm sure I'm missing something obvious...

And when I set the conf file to port 8080, 8080 shows up in the netstat -tln list...I'll haev to keep checking, seems like some problem w/my router forwarding port 8080 possibly...


DNS-323 w/two Seagate 500 GB RAID1
Fonz's Fun_Plug- Don't DNS-323 without it!

Offline

 

#7 2007-05-26 19:29:49

DNS-323 Talker
Member
Registered: 2007-05-21
Posts: 245

Re: lighttpd...I'm sure I'm missing something obvious...

Thanks, fonz....I think I'll likely just leave it at 3000...it works, right?  smile


DNS-323 w/two Seagate 500 GB RAID1
Fonz's Fun_Plug- Don't DNS-323 without it!

Offline

 

#8 2007-05-26 20:41:18

mykroft
Member
Registered: 2007-05-12
Posts: 83

Re: lighttpd...I'm sure I'm missing something obvious...

DNS-323 Talker wrote:

hmmm...I changed the port in the conf file and my router to 3000, and now it works.  If anyone knows why I couldn't use 8080 I'd be very interested in that information.

Most routers use 8080 for remote admin of the router so that port is reserved.  I use 8081 on mine.....

Myk

Offline

 

#9 2007-05-27 01:29:58

DNS-323 Talker
Member
Registered: 2007-05-21
Posts: 245

Re: lighttpd...I'm sure I'm missing something obvious...

mykroft wrote:

DNS-323 Talker wrote:

hmmm...I changed the port in the conf file and my router to 3000, and now it works.  If anyone knows why I couldn't use 8080 I'd be very interested in that information.

Most routers use 8080 for remote admin of the router so that port is reserved.  I use 8081 on mine.....

Myk

Thanks...that's good to know.  I'll give 8081 a shot at some point just for fun.


DNS-323 w/two Seagate 500 GB RAID1
Fonz's Fun_Plug- Don't DNS-323 without it!

Offline

 

Board footer

Powered by PunBB
© Copyright 2002–2010 PunBB