Web.Developer Server Suite v3.01 Professional Edition User Guide
If you can see this from http://localhost/docs/suite-guide/, it means that the installation of the Apache web server software on this system was successful. The Apache Manual has been included with this distribution. [Note that this Guide will assume that the Web.Developer Server Suite has been installed under drive 'C:'.]
Suite ComponentsCore
Professional Components
Web Applications
Server InformationBasic InformationBy default, Apache Server is bound to IP '0.0.0.0' [all available interfaces/IPs on the system], port 80 [http] and 443 [ssl], with DocumentRoot and Virtual Hosts accessible to the public. By default, MySQL Server is bound to IP '127.0.0.1' [loopback, also know as 'localhost'], port 3306 [mysql], and is only accessible via user 'root' from the local system.
URL 'http://localhost/' is the start of folder 'C:\www\vhosts\localhost\_\'. Apache Configuration FilesApache HTTP Server configuration files are located under folder 'C:\www\Apache22\conf\'...
Apache LogsGlobal Access log records ALL Server URL requests, segmented internally by VH field -- 'C:/www/Apache22/logs/access_global.log' Dynamic/Mass VHs Access log records ALL Dynamic VH URL requests, segmented internally by VH field -- 'C:/www/Apache22/logs/access_mass.log' Dynamic/Mass VHs Error log records ALL Dynamic VH reportable errors, segmented internally by VH field -- 'C:/www/Apache22/logs/error_mass.log' Access logs of static VHs record URL requests by VH block / specific log file, segmented internally by VH field -- 'C:/www/Apache22/logs/<VH>/access.log' Error logs of static VHs record all reportable errors, per VH -- 'C:/www/Apache22/logs/<VH>/error.log' Status Information
PHP
All Virtual Host directories that fall under the path of "/www/vhosts/*/", have PHP enabled via Apache configuration file C:\www\Apache22\conf\extra\suite-global\suite-php5.conf MySQL
MySQL has one user account enabled...
CGI
localhost has a ScriptAlias of URL 'cgi-bin' with a path of C:\www\vhosts\localhost\_cgi-bin\. By default, all files under this directory will be treated as cgi scripts. All dynamic Virtual Hosts have a ScriptAlias of URL 'cgi-bin' with paths of C:\www\vhosts\_dynamic\*\_cgi-bin\. By default, all files under these directories will be treated as cgi scripts. No assumptions are made for static Virtual Hosts. Individual configurations are made per Virtual Host. Scripts will be executed by their 'shebang' line. The shebang line is the first line of the script, denoted by '#!' (without ''), and contains the path to the interpreter of that particular script. For a perl script this will be... #!C:/www/perl/bin/perl.exe
Virtual Hosts
The Apache configuration file 'C:\www\Apache22\conf\extra\httpd-vhosts.conf' loads and configures the Suite's Virtual Hosts. It contains the configuration for localhost and the dynamic Virtual Hosts container. Static Virtual Host configurations are included in from folder C:\www\Apache22\conf\extra\vhosts\_static\. There are 3 types of Virtual Host setups. The main Virtual Host 'localhost' setup, static Virtual Hosts, and dynamic Virtual Hosts.
There are 4 initial Virtual Hosts set up. The main Virtual Host 'localhost', two static Virtual Hosts 'simplehost.com' and 'smarthost.com', and a dynamic Virtual Host 'example.com'.
All Virtual Hosts under C:\www\vhosts\_dynamic\ can be created and manipulated at will without any configuration. Sub-domains are created as C:\www\vhosts\_dynamic\<domain.tld>\<subdomain> Note that if you are running Virtual Hosts only locally [the domain names are fictitious / are not registered / do not resolve to an IP address], make sure to edit the Windows HOSTS file [C:\WINDOWS\system32\drivers\etc\hosts] to resolve all given domain names and aliases to IP address 127.0.0.1... 127.0.0.1 localhost 127.0.0.1 simplehost.com 127.0.0.1 www.simplehost.com 127.0.0.1 smarthost.com 127.0.0.1 www.smarthost.com 127.0.0.1 blog.smarthost.com 127.0.0.1 wiki.smarthost.com 127.0.0.1 forums.smarthost.com 127.0.0.1 example.com 127.0.0.1 www.example.com 127.0.0.1 blog.example.com 127.0.0.1 wiki.example.com 127.0.0.1 forums.example.com Virtual Host Structurelocalhost:
dynamic Virtual Hosts:
static Virtual Hosts: No assumptions are made for static Virtual Hosts. It is recommended to follow the general convention as outlined for localhost and dynamic Virtual Hosts. Each Virtual Host has additional global URLs:
Directory Structure of a Typical Dynamic Virtual Host:
Creating New Dynamic Virtual HostsNo Apache configuration is required. You may create more domains at will by simply...
You may create more sub-domains at will by simply 1) creating a new sub-domain folder under the domain directory and 2) resolving the new sub-domain via the Windows HOSTS file [C:\WINDOWS\system32\drivers\etc\hosts] or DNS Server. The mass setup/configuration for all the dynamic Virtual Hosts is located within configuration file C:\www\Apache22\conf\extra\httpd-vhosts.conf Creating New Static Virtual Hosts[This only applies to creating new static Virtual Hosts / domains. Sub-domains for existing smart-static VHs are created dynamically.] domain.tld.conf
DocumentRoot Structure
Logs
Edit awstats.new-domain.conf, update lines:
OtherCreate folder \www\Apache22\conf\extra\vhosts\_static\new-domain\ to contain any additional configurations for this Virtual Host. Update Windows HOSTS file [C:\WINDOWS\system32\drivers\etc\hosts] to resolve new-domain and all sub-domains to IP 127.0.0.1 Restart Apache. Web ApplicationsAll Web Applications are initially bound locally [127.0.0.1 -- via a global .htaccess file located under \www\vhosts\localhost\], and are not fully installed. Each application's installation script(s) have pre-set default values for our configuration/setup. In most cases, user must only input an e-mail address and select a user-name with a password.
* Note that while all other Web Applications can be installed from the above URLs, Drupal must be installed from http://localhost/drupal/install.php. Suite SecurityApacheBy default, Apache is bound to IP 0.0.0.0 [all interfaces], meaning that anyone can potentially view your Webroot/DocumentRoot by accessing your public [internet] or private [intranet] IP address. If you would like to keep your Web-Server private and/or for local use only... Allow access to Apache only from IP 127.0.0.1 [loopback]Under C:/www/Apache22/conf/httpd.conf, change 'Listen 80' to 'Listen 127.0.0.1:80' Under C:/www/Apache22/conf/extra/httpd-ssl.conf, change 'Listen 443' to 'Listen 127.0.0.1:443' To only allow LAN access, you can bind Apache to the LAN IP of the system. Virtual HostsNote that an .htaccess file under C:\www\vhosts\localhost restricts access to IP 127.0.0.1 for this Virtual Host. To open access to the outside world, edit file and change: order deny,allow deny from all allow from 127.0.0.1 ...to... order allow,deny allow from all MySQLBy default, MySQL is bound to IP 127.0.0.1 [loopback], meaning that only the local system has direct access to MySQL. MySQL user 'root' and other database specific users are only allowed access to MySQL when the login is performed from the same system that MySQL is running on; 'root' is the only general MySQL user setup initially. phpMyAdmin is set up for a multi-user (untrusted) environment. A control user ('pma@localhost') is used to check the login user's permissions. Initially, the client can only log into phpMyAdmin under the 'root' MySQL account. MySQL Internal Users
Do not use the above users in any way. They are only used by their respective applications internally. Change the default MySQL user 'root' passwordOpen the command prompt and change to the C:\www\mysql5\bin directory... mysqladmin -u root -prootwdp password new-password-here Note that 'password' is a literal string -- do not substitute in anything. Private DirectoryChange the initial password 'passadmin' for user 'admin'; the user protecting the C:\www\vhosts\example.com\private directory... Open the command prompt and change to the C:\www\vhosts\example.com\private directory... htpasswd .htpasswd admin URLs and HandlesSecuredThe following directories and handles are secured from outside access. Apache will only serve the following to the local system. http://localhost/server-statushttp://localhost/server-info ["Access to all" can be granted via a one line change under the VirtualHost's DocumentRoot .htaccess file.]
http://localhost/joomlahttp://localhost/drupal http://localhost/wordpress http://localhost/mediawiki http://localhost/phpbb3 UnrestrictedThe following directories and handles are unrestricted. Note that these URL are implicitly unrestricted; the default .htaccess file blocks all access to localhost from any IP other than 127.0.0.1... http://localhost/phpmyadmin/ http://localhost/stats/ http://localhost/docs/ access is unrestricted. http://localhost/cgi-bin/ access is unrestricted. http://localhost/phpinfo.php access is unrestricted. NotesURLs are case sensitive, type as they are displayed.Extra ExamplesAfter you are comfortable with PHP and CGI, you might want to delete... CGI example file C:\www\vhosts\localhost\cgi-bin\printenv.pl PHP example file C:\www\vhosts\localhost\phpinfo.php Controlling Apache[Note that Apache has already been installed as a Service, and started. The following is for reference only.]
[You can also use the Web.Developer 'Controller' to stop/start the Apache Service.]
Service Management WindowOpen the Service Management Window... Start » Run... » services.exe <Enter> Locate Service Name 'Apache2' Functions provided: Service 'stop'/'start', Startup type [on system boot] 'manual'/'automatic' Command LineEnter the command-line... Start » Run... » cmd.exe <Enter> Change to the Apache directory... cd /d C:\www\Apache22\bin Start Apache2 Service [one of two ways]httpd -k start NET START Apache2.2 Stop Apache2 Service [one of two ways]httpd -k stop NET STOP Apache2.2 Install Apache2 as a Service [only do one of the following -- either standard or ssl-enabled; NOT BOTH][Note that this will start Apache2 automatically from now on, but not this first time]
standard [port 80] Apachehttpd -k install ssl-enabled [port 80,443] Apachehttpd -D SSL -k install Uninstall the Apache2 Servicehttpd -k uninstall Controlling MySQLUser/PasswordMySQL has only one general account enabled...
Note that mysql access to user 'root' will only be granted from localhost [the system Apache is installed on]. Controlling MySQL[Note that MySQL has already been installed as a Service, and started. The following is for reference only.]
[You can also use the Web.Developer 'Controller' to stop/start the MySQL Service.]
Enter the Windows command-line shell... Start » Run... » cmd.exe <Enter> Change to the MySQL directory... cd /d C:\www\mysql5\bin Start MySQL ServiceNET START MySQL Stop MySQL ServiceNET STOP MySQL Install MySQL Servicemysqld-nt --install Uninstall the MySQL Servicemysqld-nt --remove Using MySQL ShellMySQL can be accessed interactively either from phpMyAdmin or from the command line. Enter the Windows command-line shell... Start » Run... » cmd.exe <Enter> Change to the MySQL directory... cd /d C:\www\mysql5\bin Get status informationmysqladmin -u root -p status Get variables informationmysqladmin -u root -p variables Access MySQL Shellmysql -u root -p Display Databasesshow DATABASES; Select Databaseuse <db_name>; Display Tables of Selected Databaseshow TABLES; Describe Table of Selected Databasedescribe <table_name>; Display MySQL User informationselect user,host,password from mysql.user; Exit MySQL Shellquit; Using phpMyAdmin
phpMyAdmin is set up globally, for all Virtual Hosts, via URL /phpmyadmin/. phpMyAdmin provides access to MySQL via any of the MySQL users. Only one initial MySQL user 'root' is set up.
Note that suite-phpmyadmin.conf is configured to allow the URL '/phpmyadmin' to be accessed from all. Using Private Directory
One initial user is configured to access the private directory...
The users allowed access to this directory are managed via the 'htpasswd.exe' program included with Apache. The 'htpasswd' program creates a file [in our case '.htpasswd'] which stores the user/password combination. This file is read by Apache to manage access rights for this directory. Delete user 'admin'... C:\www\vhosts\localhost\_private> htpasswd -Dm .htpasswd admin
Create user 'admin' with password 'passadmin'... C:\www\vhosts\localhost\_private> htpasswd -mb .htpasswd admin passadmin
Using AWStats
AWstats is set up globally, for all Virtual Hosts, via URL /stats/. AWStats configurations file for localhost will read Apache's access log file C:/www/Apache22/logs/localhost/access.log Note that Apache's suite-awstats.conf is configured to allow the URL '/stats/' to be accessed from all. Notes for InstallationMake sure that any previous Apache, IIS, and/or MySQL Services are stopped and removed/uninstalled from Services ('Services Menu' -- Start » Run... » services.msc <Enter>). While you can stop Services under this menu, you will still need to open the command-shell and run the appropriate Apache, IIS, and MySQL Service uninstall commands -- before you install this package. If you are upgrading our package, you will need to uninstall the older version first. Never overwrite the 'www' directory as some files are READ-ONLY and will not be overwritten. If you have an older version of our package, or have had previous installs of PHP and/or MySQL, always make sure to remove any php.ini and my.ini files you might have under your %SystemRoot% (Win2000 -> C:\WINNT, WinXP -> C:\Windows) directory. Also make sure you do not have a my.cnf file present under C:\. If you have ActiveState Perl installed, uninstall it or make sure that C:\www\perl\bin is located first (relative to ActiveState Perl) in the system PATH variable. Always REBOOT YOUR SYSTEM after installation, as path and environmental changes must propagate throughout your system. Some programs, firewalls, and anti-virus software have been known to block Apache and MySQL from binding to their appropriate interfaces. Either re-configure your firewall and/or anti-virus software, or disable that software. If your system is running behind a router, make sure to forward the appropriate Apache and MySQL ports (80 and 3306 respectively) if you want your local network, or even the Internet, to see those Services. Installing Apache under Windows XP requires for Windows XP Service Pack 1 to be present. Additionally, for Windows XP users, it is recommended to disable the QoS ("Quality of Service") Service. Note that Windows XP Service Pack 2 (SP2) installs a native Firewall on the user's system. Configure it to pass and allow binding to ports 80 (http) and 3306 (mysql). Change the SSL certificates provided with this package, as everyone with this package initially has the same keys... mod_aspdotnet
PREREQUISITES -- REQUIREMENTS FOR mod_aspdotnetmod_aspdotnet requires the .NET Framework v1.1 to be installed on the user's system. [All versions of .NET Framework can be installed side-by-side on the user's system]
GACmod_aspdotnet must be registered in the Global Assembly Cache... Install Apache.Web.dll into the GACOpen two folder views (Windows Explorer)...
Drag-and-drop file 'Apache.Web.dll' from 1st window into the second. Register ASP.NET...Enter the command shell (cmd.exe), change to your .NET runtime directory [v1.1: C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322], and execute... aspnet_regiis -ir Apache configurationCopy file C:\www\Apache22\conf\extra\other\suite-mod_aspdotnet.conf into C:\www\Apache22\conf\extra\suite-global\ Edit C:\www\Apache22\conf\extra\suite-global\suite-mod_aspdotnet.conf NOTICE two instances of 'C:/WINDOWS/' (default, for Windows XP+) OR 'C:/WINNT/' (for Windows 2000) -- change to your %SystemRoot% directory. Save changes and restart Apache for configuration changes to take effect... NET STOP Apache2.2 NET START Apache2.2 Apache should now be able to load mod_aspdotnet and automatically proxy to the ASP.NET engine. Test mod_aspdotnetThe following WILL NOT WORK unless user has met prerequisites... Enter URL http://localhost/asp/helloworld1.aspx Enter URL http://localhost/asp/helloworld2.aspx TomcatBy default, Tomcat Server is bound to IP '0.0.0.0' [all available interfaces/IPs on the system], port 8080 [http] and 8009 [ajp], with DocumentRoot accessible to the public.
PREREQUISITES -- REQUIREMENTS FOR TomcatInstall Java JRETomcat6 requires the Java Runtime Environment [JRE] 5/1.5+ [The JDK is not necessary]. Download JRE 5 (or newer) from http://www.java.com/en/download/manual.jsp Install to the default directory, C:\Program Files\Java\, forming C:\Program Files\Java\jre-version Set Environmental VariablesTomcat requires Environmental Variables... JRE_HOME=C:\Program Files\Java\jre-version-path CATALINA_HOME=C:\www\Tomcat6 Set variables under Start » Settings » Control Panel » System » Advanced » Environment Variables » System variables » New... Restart system for the environmental variables to fully propagate. httpd.confOur Suite is already configured to use mod_proxy_ajp, for localhost [C:\www\Apache22\conf\extra\vhosts\localhost\suite-mod_proxy_ajp.conf], using the provided Tomcat examples [C:\www\Tomcat6\webapps\examples] Additional sample configurations using mod_jk and mod_proxy_http are provided under C:\www\Apache22\conf\extra\Tomcat6 Tomcat and Connectors (modules) should now be able to run... Install and Start TomcatInstall Tomcat as a Service \www\Tomcat6\bin> service.bat install [The Tomcat6 Service will be installed as 'manual' startup -- manual startup will be required after every reboot]
Start Tomcat6 Service NET START Tomcat6 Test TomcatNative serverThe following WILL NOT WORK unless user has met prerequisites... Enter URL http://localhost:8080/ Enter URL http://localhost:8080/manager/status
Apache connectorThe following WILL NOT WORK unless user has met prerequisites... Both Apache and Tomcat have to be running for this to work. Enter URL http://localhost/examples/ This will server Java pages via Apache. Stop and Uninstall TomcatStop Tomcat6 Service... NET STOP Tomcat6 Uninstall Tomcat as a Service... service.bat uninstall Reference Manuals and Documentation![]() |