Moxa V2416-T-XPE [31/88] Saving web pages to a usb storage device

Moxa V2416-W7E [31/88] Saving web pages to a usb storage device
V2416 Linux User's Manual Managing Communications
3-7
1. Mount the root file system with write permission.
MOXA:~# mount -o remount,rw
2. Type
# vi/etc/apache2/sites-enabled/000-default to edit the configuration file. Comment out
the following lines:
#ScriptAlias /cgi-bin/ /var/www/apache2-default/cgi-bin/
#<Directory “/var/www/apache2 default/cgi-bin/”>
# AllowOverride None
# Options ExecCGI -MultiViews +SymLinksIfOwnerMatch
# #Order allow,deny
# Order deny,allow
# Allow from all
#</Directory>
MOXA:/etc# vi /etc/apache2/sites-available/default
#ScriptAlias /cgi-bin/ /var/www/apache2-default/cgi-bin/
#<Directory “/var/www/apache2 default/cgi-bin/”>
# AllowOverride None
# Options ExecCGI -MultiViews +SymLinksIFOwnerMatch
# #Order allow,deny
# Order deny,allow
# Allow from all
#</Directory>
3. After you finish writing or modifying the code, remember to execute umount /to change the root
directory back to Read-only mode.
MOXA:~# umount /
4. Re-start the apache server.
MOXA:~# /etc/init.d/apache2 restart
ATTENTION
When you develop your own CGI application, make sure your CGI file is executable.
Saving Web Pages to a USB Storage Device
Some applications may have web pages that take up a lot of storage space. This section describes how to save
web pages to the USB mass storage device, and then configure the Apache web servers DocumentRoot to
open these pages. The files used in this example can be downloaded from Moxas website.
1. Prepare the web pages and then save the pages to the USB storage device. Click on the following link to
download the web page test suite: http://www.w3.org/MarkUp/Test/HTML401.zip.
2. Uncompress the zip file to your desktop PC, and then use FTP to transfer it to the V2416-LX’s
/media/usb0 directory.
3. Mount the root file system with write permission.
MOXA:~# mount -o remount,rw /dev/hda1 /
4. Type # vi/etc/apache2/sites-enabled/000-default to edit the configuration file.
MOXA:/etc# vi /etc/apache2/sites-enabled/000-default

Содержание

Похожие устройства

Скачать