Differences

This shows you the differences between the selected revision and the current version of the page.

howto:simple_fun_plug_stepbystep 2008/04/28 12:30 howto:simple_fun_plug_stepbystep 2017/09/06 18:38 current
Line 4: Line 4:
HW: 2 x Samsung 501LJ (500GB) HW: 2 x Samsung 501LJ (500GB)
 +
===== Preparation ===== ===== Preparation =====
  * hook up LAN cable to FRITZbox and power DNS323   * hook up LAN cable to FRITZbox and power DNS323
-  * open firefox and connect to FRITZbox (in my case via http://192.168.178.1/ and password)+  * open firefox and connect to FRITZbox (in my case via http://192.168.178.1/ or http://fritz.box and password) 
 +  * if you don't see the web UI you may have the wrong address. If this has been assigned by a router attached to you LAN the easiest way to find this is using the windows only D-Link set-up utility.
in //System-Netwerkgeraete// I see: in //System-Netwerkgeraete// I see:
Line 27: Line 29:
formats disks formats disks
-  * after restart login ('admin') password ('') shows the setup wizard+  * after restart login ('admin') shows the setup wizard
    Tools - Time     Tools - Time
       
      NTP Server: ntp1.dlink.com       NTP Server: ntp1.dlink.com
-      Time Zone: GNT+1+      Time Zone: GMT+1
      Daylight Saving Time: EU       Daylight Saving Time: EU
       
Line 71: Line 73:
    jens@VENUS:/mnt$                jens@VENUS:/mnt$           
       
 +
  * in firefox use http://192.168.178.26 to reset DNS323   * in firefox use http://192.168.178.26 to reset DNS323
Line 168: Line 171:
    jens@VENUS:/etc$ ssh -l admin 192.168.178.26     jens@VENUS:/etc$ ssh -l admin 192.168.178.26
    admin@192.168.178.26's password:     admin@192.168.178.26's password:
 +   
 +   
 +    BusyBox v1.8.1 (2007-11-20 23:39:08 CET) built-in shell (ash)
 +    Enter 'help' for a list of built-in commands.
 +   
 +    ~ $ exit
 +    Connection to 192.168.178.26 closed.
 +    jens@VENUS:/etc$ 
-BusyBox v1.8.1 (2007-11-20 23:39:08 CET) built-in shell (ash) +===== lighttpd web server install =====
-Enter 'help' for a list of built-in commands.+
-~ $ exit +on DNS323
-Connection to 192.168.178.26 closed. +
-jens@VENUS:/etc$  +
- +    mkdir /mnt/HD_a2/www 
-lighttpd web server install +   mkdir /mnt/HD_a2/www/logs 
---------------------------- +    
- +   vi /mnt/HD_a2/www/index.html  
-mkdir /mnt/HD_a2/www +   <html> 
-mkdir /mnt/HD_a2/www/logs +     <body> 
- +         Hello World from DNS-323 
-vi /mnt/HD_a2/www/index.html +     </body> 
-<html> +   </html>  
- <body> +    
-     Hello World from DNS-323 +   funpkg.sh /mnt/HD_a2/addon/lighttpd-1.4.18.tgz 
- </body> +    
-</html>  +   cd /mnt/HD_a2/fun_plug.d/etc 
- +    
-funpkg.sh /mnt/HD_a2/addon/lighttpd-1.4.18.tgz +   cp /mnt/HD_a2/fun_plug.d/etc/lighttpd.conf-sample /mnt/HD_a2/fun_plug.d/etc/lighttpd.conf 
- +    
-cd /mnt/HD_a2/fun_plug.d/etc +   vi /mnt/HD_a2/fun_plug.d/etc/lighttpd.conf 
- +    
-cp /mnt/HD_a2/fun_plug.d/etc/lighttpd.conf-sample /mnt/HD_a2/fun_plug.d/etc/lighttpd.conf +       server.document-root        = "/mnt/HD_a2/www/" 
- +       server.port                = 3000   
-vi /mnt/HD_a2/fun_plug.d/etc/lighttpd.conf +    
- +    
-   server.document-root        = "/mnt/HD_a2/www/" +   /mnt/HD_a2/fun_plug.d/etc # sh /mnt/HD_a2/fun_plug.d/start/lighttpd.sh start
-   server.port                = 3000   +
- +
- +
-/mnt/HD_a2/fun_plug.d/etc # sh /mnt/HD_a2/fun_plug.d/start/lighttpd.sh start+
to verify status (running is what we expect): to verify status (running is what we expect):
-/mnt/HD_a2/fun_plug.d/etc # sh /mnt/HD_a2/fun_plug.d/start/lighttpd.sh status+''/mnt/HD_a2/fun_plug.d/etc # sh /mnt/HD_a2/fun_plug.d/start/lighttpd.sh status''
if /mnt/HD_a2/fun_plug.d/etc/lighttpd.conf was changed if /mnt/HD_a2/fun_plug.d/etc/lighttpd.conf was changed
-/mnt/HD_a2/fun_plug.d/etc # sh /mnt/HD_a2/fun_plug.d/start/lighttpd.sh restart+''/mnt/HD_a2/fun_plug.d/etc # sh /mnt/HD_a2/fun_plug.d/start/lighttpd.sh restart''
for debug (simulates start with error output): for debug (simulates start with error output):
-/mnt/HD_a2/fun_plug.d/etc # ${SBINDIR}/lighttpd -f ${ETCDIR}/lighttpd.conf +''/mnt/HD_a2/fun_plug.d/etc # ${SBINDIR}/lighttpd -f ${ETCDIR}/lighttpd.conf 
 +''
in firefox: http://192.168.178.26:3000/ in firefox: http://192.168.178.26:3000/
works OK! works OK!
-add php support to lighttpd +===== add php support to lighttpd =====
----------------------------+
-jens@VENUS:/mnt$ sudo cp /home/jens/Download/DNS323NAS_FunPlug_0_3/php-5.2.4.tgz /media/meinefreigabe/mnt/HD_a2/addon+on VENUS
-/mnt/HD_a2/www # funpkg.sh /mnt/HD_a2/addon/php-5.2.4.tgz +    jens@VENUS:/mnt$ sudo cp /home/jens/Download/DNS323NAS_FunPlug_0_3/php-5.2.4.tgz /media/meinefreigabe/mnt/HD_a2/addon
-Unpacking /mnt/HD_a2/addon/php-5.2.4.tgz ... +
-Writing package log /mnt/HD_a2/fun_plug.d/packages/php-5.2.4 ... +
-Installing files to /mnt/HD_a2/fun_plug.d ... +
-Cleaning up +
-/mnt/HD_a2/www #+
-make sure that you can run "php -v" and "php-cgi -v"+on DNS323
-/mnt/HD_a2/www # which php +    /mnt/HD_a2/www # funpkg.sh /mnt/HD_a2/addon/php-5.2.4.tgz 
-/mnt/HD_a2/fun_plug.d/bin/php +   Unpacking /mnt/HD_a2/addon/php-5.2.4.tgz ..
-/mnt/HD_a2/www # php -+   Writing package log /mnt/HD_a2/fun_plug.d/packages/php-5.2.4 ... 
-PHP 5.2.4 (cli) (built: Sep  5 2007 21:33:10) +   Installing files to /mnt/HD_a2/fun_plug.d ... 
-Copyright (c) 1997-2007 The PHP Group +    Cleaning up 
-Zend Engine v2.2.0, Copyright (c) 1998-2007 Zend Technologies +   /mnt/HD_a2/www #
-/mnt/HD_a2/www # php-cgi -v +
-PHP 5.2.4 (cgi-fcgi) (built: Sep  5 2007 21:33:09) +
-Copyright (c) 1997-2007 The PHP Group +
-Zend Engine v2.2.0, Copyright (c) 1998-2007 Zend Technologies +
-/mnt/HD_a2/www #+
-/mnt/HD_a2/fun_plug.d/etc # vi lighttpd.conf +make sure that you can run "php -v" and "php-cgi -v"
-/mnt/HD_a2/fun_plug.d/etc # diff lighttpd.conf lighttpd.conf-sample +    /mnt/HD_a2/www # which php 
---- lighttpd.conf      Sat Apr 26 16:38:25 2008 +    /mnt/HD_a2/fun_plug.d/bin/php 
-+++ lighttpd.conf-sample        Tue Nov 20 23:43:53 2007 +    /mnt/HD_a2/www # php -v 
-@@ -21,7 +21,7 @@ +    PHP 5.2.4 (cli) (built: Sep  5 2007 21:33:10) 
- #                              "mod_auth", +    Copyright (c) 1997-2007 The PHP Group 
- #                              "mod_status", +   Zend Engine v2.2.0, Copyright (c) 1998-2007 Zend Technologies 
- #                              "mod_setenv", +    /mnt/HD_a2/www # php-cgi -v 
--                               "mod_fastcgi", +   PHP 5.2.4 (cgi-fcgi) (built: Sep  5 2007 21:33:09) 
-+#                               "mod_fastcgi", +   Copyright (c) 1997-2007 The PHP Group 
- #                              "mod_proxy", +   Zend Engine v2.2.0, Copyright (c) 1998-2007 Zend Technologies 
- #                              "mod_simple_vhost", +   /mnt/HD_a2/www #
- #                              "mod_evhost", +
-@@ -37,7 +37,7 @@+
- ## a static document-root, for virtual-hosting take look at the +adjust configuraton
- ## server.virtual-* options +
--server.document-root        = "/mnt/HD_a2/www/" +
-+server.document-root        = "/mnt/HD_a2/www/pages/"+
- server.upload-dirs = ( "/mnt/HD_a2/tmp" ) +    /mnt/HD_a2/fun_plug.d/etc # vi lighttpd.conf  
- +    /mnt/HD_a2/fun_plug.d/etc # diff lighttpd.conf lighttpd.conf-sample 
-@@ -50,11 +50,11 @@ +    --- lighttpd.conf      Sat Apr 26 16:38:25 2008 
- +    +++ lighttpd.conf-sample        Tue Nov 20 23:43:53 2007 
- ## php support +    @@ -21,7 +21,7 @@ 
- ## uncomment the following lines and the mod_fastcgi module above +    #                              "mod_auth", 
--fastcgi.server = ( ".php" => (( +    #                              "mod_status", 
--    "bin-path"  => "/mnt/HD_a2/fun_plug.d/bin/php-cgi", +    #                              "mod_setenv", 
--    "socket"    => "/tmp/php-cgi.socket", +    -                              "mod_fastcgi", 
--    "max-procs" => 2 +    +#                              "mod_fastcgi", 
--))) +    #                              "mod_proxy", 
-+#fastcgi.server = ( ".php" => (( +    #                              "mod_simple_vhost", 
-+#    "bin-path"  => "/mnt/HD_a2/fun_plug.d/bin/php-cgi", +    #                              "mod_evhost", 
-+#    "socket"    => "/tmp/php-cgi.socket", +    @@ -37,7 +37,7 @@ 
-+#    "max-procs" => 2 +     
-+#))) +    ## a static document-root, for virtual-hosting take look at the 
- +    ## server.virtual-* options 
- +    -server.document-root        = "/mnt/HD_a2/www/" 
- ## set the event-handler (read the performance section in the manual) +    +server.document-root        = "/mnt/HD_a2/www/pages/" 
-@@ -146,7 +146,7 @@ +     
- ######### Options that are good to be but not neccesary to be changed ####### +    server.upload-dirs = ( "/mnt/HD_a2/tmp" ) 
- +    
- ## bind to port (default: 80) +   @@ -50,11 +50,11 @@ 
--server.port                = 3000 +    
-+server.port                = 8080 +     ## php support 
- +     ## uncomment the following lines and the mod_fastcgi module above 
- ## bind to localhost (default: all interfaces) +   -fastcgi.server = ( ".php" => (( 
- #server.bind                = "grisu.home.kneschke.de" +   -    "bin-path"  => "/mnt/HD_a2/fun_plug.d/bin/php-cgi", 
-@@ -184,10 +184,10 @@ +   -    "socket"    => "/tmp/php-cgi.socket", 
- dir-listing.show-readme    = "enable"+   -    "max-procs" => 2 
 +   -))) 
 +   +#fastcgi.server = ( ".php" => (( 
 +   +#    "bin-path"  => "/mnt/HD_a2/fun_plug.d/bin/php-cgi", 
 +   +#    "socket"    => "/tmp/php-cgi.socket", 
 +   +#    "max-procs" => 2 
 +   +#))) 
 +    
 +    
 +     ## set the event-handler (read the performance section in the manual) 
 +   @@ -146,7 +146,7 @@ 
 +     ######### Options that are good to be but not neccesary to be changed ####### 
 +    
 +     ## bind to port (default: 80) 
 +   -server.port                = 3000 
 +   +server.port                = 8080 
 +    
 +     ## bind to localhost (default: all interfaces) 
 +     #server.bind                = "grisu.home.kneschke.de" 
 +   @@ -184,10 +184,10 @@ 
 +     dir-listing.show-readme    = "enable" 
 +     
 +    ## enable debugging 
 +    -debug.log-request-header  = "enable" 
 +    -debug.log-response-header  = "enable" 
 +    -debug.log-request-handling = "enable" 
 +    -debug.log-file-not-found  = "enable" 
 +    +#debug.log-request-header  = "enable" 
 +    +#debug.log-response-header  = "enable" 
 +    +#debug.log-request-handling = "enable" 
 +    +#debug.log-file-not-found  = "enable" 
 +     
 +    ### only root can use these options  
 +    # 
 +    /mnt/HD_a2/fun_plug.d/etc # 
- ## enable debugging 
--debug.log-request-header  = "enable" 
--debug.log-response-header  = "enable" 
--debug.log-request-handling = "enable" 
--debug.log-file-not-found  = "enable" 
-+#debug.log-request-header  = "enable" 
-+#debug.log-response-header  = "enable" 
-+#debug.log-request-handling = "enable" 
-+#debug.log-file-not-found  = "enable" 
- ### only root can use these options +restart lighttpd
-+
-/mnt/HD_a2/fun_plug.d/etc #  +
 +    /mnt/HD_a2/fun_plug.d/etc # sh /mnt/HD_a2/fun_plug.d/start/lighttpd.sh restart
 +    Starting lighttpd...
 +    /mnt/HD_a2/fun_plug.d/etc # sh /mnt/HD_a2/fun_plug.d/start/lighttpd.sh status
 +    running
 +    /mnt/HD_a2/fun_plug.d/etc #
-/mnt/HD_a2/fun_plug.d/etc # sh /mnt/HD_a2/fun_plug.d/start/lighttpd.sh restart +running is good.\\ 
-Starting lighttpd... +Create a simple php
-/mnt/HD_a2/fun_plug.d/etc # sh /mnt/HD_a2/fun_plug.d/start/lighttpd.sh status +
-running +
-/mnt/HD_a2/fun_plug.d/etc #+
-/mnt/HD_a2/www # more hello.php +    /mnt/HD_a2/www # more hello.php 
-<html> +   <html> 
- <head> +     <head> 
-   <title>PHP-Test</title> +       <title>PHP-Test</title> 
-   </head> +       </head> 
-     <body> +         <body> 
-     <?php echo '<p>Hallo Welt</p>'; ?> +         <?php echo '<p>Hallo Welt</p>'; ?> 
-       </body> +           </body> 
-       </html> +           </html> 
-/mnt/HD_a2/www #+   /mnt/HD_a2/www #
in firefox: http://192.168.178.26:3000/hello.php in firefox: http://192.168.178.26:3000/hello.php
-/mnt/HD_a2/www # vi info.php +    /mnt/HD_a2/www # vi info.php 
-/mnt/HD_a2/www # more info.php +   /mnt/HD_a2/www # more info.php 
-<?PHP +   <?PHP 
-phpinfo (); +   phpinfo (); 
-?> +   ?> 
-/mnt/HD_a2/www # +   /mnt/HD_a2/www #
in firefox: http://192.168.178.26:3000/info.php in firefox: http://192.168.178.26:3000/info.php
OK - works! OK - works!

Navigation

Personal Tools