Loading ...
Sorry, an error occurred while loading the content.
 

Re: Setting up webserver - please help!

Expand Messages
  • herriedoc
    If your computer and your NSLU2 are in the samen subnet using one public IP-adress (e.g. like behind a common household NAT-router) and you have IP traffic for
    Message 1 of 5 , Jan 28, 2008
      If your computer and your NSLU2 are in the samen subnet using one public IP-adress (e.g.
      like behind a common household NAT-router) and you have IP traffic for your HTTP-port
      redirected your PC cannot find the adress like any computer outside the local network.

      2 solutions:
      1. check your website out using another connection to the internet to check out network
      setup
      2. modify your hosts-file on your computer (for Windows, I'm not sure what you can do,
      sorry) to be sure if you use the adress you actually get your webserver (nice for
      maintenance purposes)

      --- In nslu2-general@yahoogroups.com, "raspden" <raspden@...> wrote:
      >
      > This has been really helpful. Thanks for your replies. The web server
      > is now up and running. It seems to be going well. I just have one more
      > problem. I wish to use virtual hosts for each of my sites but just
      > cannot get them to work ok. I started with setting up a virtual host
      > file for the phpmyadmin installation. So I added the following to the
      > bottom of the lighttpd.conf file:
      >
      > $HTTP["host"] == "pma.rhazzzz.com" {
      > server.document-root = "/opt/share/www/phpmyadmin"
      > server.errorlog = "/var/log/lighttpd/phpmyadmin/error.log"
      > accesslog.filename = "/var/log/lighttpd/phpmyadmin/access.log"
      > #server.error-handler-404 = "/e404.php"
      > }
      >
      > I then restarted the lighttpd server and navigated to
      > http://pma.rhazzzz.com but the browser could find no page. So I tried
      > adding :8081 to the url and still no joy. I then tried adding the line
      > 'server.port = 8081' to the virtual host and still no joy.
      >
      > I have tried this set up with both 'mod_evhost' and 'mod_simple_vhost'
      > installed but it seems to make no difference.
      >
      > Therefore I'd be most grateful for guidance on this if someone can
      > help me out.
      >
      > Cheers.
      >
      > --- In nslu2-general@yahoogroups.com, Robert Hammond <rob.hammond@>
      > wrote:
      > >
      > > In message <fn7a66+hjv8@>, raspden <raspden@> writes
      > > >Hi there,
      > > >
      > > >I've just got a NSLU2 and have unslung it with the latest firmware.
      > > >I'm just trying to get to grips with setting up applications on it.
      > > >However as my Linux experience is a bit basic I'm finding it tricky.
      > > >
      > > >What I'm trying to do is set up a webserver running PHP and MYSQL. I
      > > >have opted for lightttpd as it's supposed to be resource friendly, and
      > > >I installed this first. I then installed PHP, then MySQL, then finally
      > > >PHPMyAdmin so I could administer databases.
      > > >
      > > You need to also install
      > > php-mysql
      > > and
      > > php-fcgi
      > >
      > > There are some config files that will need changing, the recommended
      > > route for this is to install the openssh optware package and if
      > > connecting with a WinXP machine use WinSCP. WinSCP has a built in
      > Linux
      > > compatible text editor. (Alternatively just use one of the command
      > > line editors such as vi).
      > >
      > > Check out the Wiki page
      > > <http://www.nslu2-linux.org/wiki/HowTo/DeployPHPWebAppUsingFastCGI>
      > >
      > > You will need to add the fastcgi.server configuration to the
      > > lighttpd.conf file.
      > >
      > > I think that the optware version of lighttpd defaults to port 8081
      > >
      > > To access the default web page use http://192.168.1.77:8081
      > >
      > > >But now I'm stuck as to what to do next. I have no idea whether it's
      > > >running ok. I doubt it as I assume I need to configue lighttpd to work
      > > >with PHP and MySQL. But I don't know what needs configuering. I don't
      > > >even know how to restart the lighttpd server. I looked at this
      > > >website: http://gentoo-wiki.com/HOWTO_Lighttpd#Restarting_Lighttpd but
      > > >on the NSLU2 the path /etc/init.d/lighttpd does not exist.
      > > >
      > > The default home page location for all of the Optware web servers is
      > > /opt/share/www. When you first install lighttpd it is configured for
      > > /opt/share/www/lighttpd/ where a web page is located to check that the
      > > web server is running OK. At some stage you will probably need to
      > > change this back to the correct home folder by deleting the trailing
      > > lighttpd/. This is configurable in the above mentioned config file.
      > >
      > > Lighttpd automatically starts under unslung using a script installed at
      > > /opt/etc/init.d/S80lighttpd
      > >
      > > You can stop and start the daemon from a console prompt (you will need
      > > to do this if you change anything in the config file) by typing
      > > /opt/etc/init.d/S80lighttpd stop
      > > /opt/etc/init.d/S80lighttpd start
      > >
      > > >The other thing is I don't know the url to browse to in order to view
      > > >the webserver. I have looked in the lighttpd.conf file but can find no
      > > >trace of such a setting for servername. I'm confident I can get things
      > > >set up easily enough if I can just get the server running, PHP
      > > >installed and then MySQL.
      > > >
      > > >Anyhow I was looking for some sort of guide to help with setting up
      > > >the lighttpd webserver on the NSLU2. Is there one available anywhere
      > > >which could help me out? I've also seen many references that say that
      > > >php-fastcgi needs to be installed. Do I install this alongside PHP or
      > > >instead of?
      > > Yes because lighttpd will not work with just the standard PHP.
      > > >
      > > >Finally maybe someone can advise me on where to put put my websites. I
      > > >have unslung to an 80GB hard drive and it's created two partitions:
      > > >ADMIN 2 and DISK 2. What size are these partitions? How do I find out?
      > > >If the ADMIN partition is small is it better to host my sites on
      > DISK 2?
      > > >
      > > I think that ADMIN 2 and DISK 2 are just Samba share names and not
      > > partitions, all data is stored on the same data partition, size will
      > > be close to 80GB
      > > .
      > > >Many apologies for all the questions but I'm a bit stuck and then
      > > >internet is not being helpful in finding out answers.
      > > >
      > > >Cheers.
      > >
      > > --
      > > Robert Hammond
      > > PGP:0x154144DA
      > >
      >
    Your message has been successfully submitted and would be delivered to recipients shortly.