File Layout of Web Stack Components
This section discusses the file layout of Web Stack components.
Note - The easy user interface provided from the Launch menu for rapid and easy-to-learn
web application development is intended for development purposes. It is not recommended to
run mission critical web sites without customizing and tuning of the components for
performance, scalability, and security. When you have developed a working application, it is
recommended to transfer the data from the database and PHP files from your
development machine to a production-quality installation that has been carefully tuned to your mission
critical needs.
You can access these components from the Launch menu of the Solaris platform.
From the Launch menu, select All Applications > Developer Tools > Web Stack
Admin.
Alternatively, the web stack tools can be accessed from the installation path described
in the following sections.
Apache 2 HTTPd Server Files
The following list describes the file structure for Apache Web Server:
Note - The string [version] should be expanded to "MAJOR.MINOR". For example, /usr/apache2/2.2/*.
- /etc/apache2/[version]/httpd.conf
Contains server configuration files. A newly-installed server contains a default httpd.conf file. This is the main configuration file.
- /etc/apache2/[version]/conf.d
Contains additional server configuration files.
By default, server will load all the .conf files placed under this directory. It also has 2 additional .load configuration files-modules-32.load and modules-64.load which contain LoadModule directives for loading the 32 and 64-bit bundled apache modules respectively. All the .conf files in this directory are included by the following line in httpd.conf:
Include /etc/apache2/2.2/conf.d/*.conf. You can add the additional configuration here.
- /etc/apache2/[version]/envvars
Contains the environment settings that the server uses at startup.
When the /usr is mounted as read-only, you will not be able to modify the envvars file present in the following path /usr/apache2/[version]/envvars. To modify the environment settings you need to edit the envvars file present in the following path /etc/apache2/[version]/envvars.
- /etc/apache2/[version]/magic
Magic data for mod_mime_magic Apache module as documented in the
/usr/apache2/2.2/manual/mod/mod_mime_magic.html file. Editing this file is not recommended.
- /etc/apache2/[version]/mime.types
Default MIME types file. This file sets the default list of mappings from filename extensions to content types, changing this file is not recommended. Use the AddType directive instead.
- /etc/apache2/[version]/original/
Contents under this directory are delivered as-is from the apache distribution and these files are not meant to be read by the server.
- /etc/apache2/[version]/sample-conf.d
Contains sample .conf files. These are not included in the main configuration file. To use the sample file, copy the file to conf.d directory and modify as per the need.
- /usr/apache2/[version]/bin
Contains the 32-bit httpd (Pre-fork MPM) and httpd.worker (Worker MPM) executables as well as other utility programs.
- /usr/apache2/[version]/bin/[isainfo]
Contains the 64-bit httpd (Prefork MPM) and httpd.worker (Worker MPM) executables as well as other utility programs.
- /usr/apache2/[version]/manual
Contains the Apache manual in HTML format.
- /usr/apache2/[version]/include
Contains the Apache header files, which are needed for building various optional server extensions with apxs(8).
- /usr/apache2/[version]/libexec
Contains 32-bit loadable modules (DSOs) supplied with the server.
- /usr/apache2/[version]/libexec/[isainfo]
Contains 64-bit loadable modules (DSOs) supplied with the server.
- /usr/apache2/[version]/man
Contains man pages for the server, utility programs, and mod_perl.
Add this directory to your MANPATH to read the Apache man pages.
- /usr/apache2/[version]/lib
Contains the 32-bit apache2 core libraries.
- /usr/apache2/[version]/lib/[isainfo]
Contains the 64-bit Apache 2 core libraries.
- /usr/apache2/[version]/lib/perl
Contains the 32-bit modules and library files used by the mod_perl extension to Apache.
- /var/apache2/[version]/cgi-bin
Default location for the CGI scripts.
This can be changed by altering the httpd.conf file and restarting the server.
- /var/apache2/[version]/htdocs
Default document root.
This can be changed by altering the httpd.conf file and restarting the server.
- /var/apache2/[version]/icons
Icons used by the server.
This should not be changed.
- /var/apache2/[version]/libexec
Place holder for 32-bit user apache modules.
Any 32-bit modules which are added using apxs(8) are copied into this directory.
- /var/apache2/[version]/libexec/[isainfo]
Place holder for 64-bit user Apache 2 modules.
Any 64-bit modules which are added using apxs(8) are copied into this directory.
- /var/apache2/[version]/logs
Contains server log files.
The formats, names, and locations of the files in this directory can be altered by various configuration directives in the httpd.conf file.
- /var/apache2/[version]/proxy
Directory used to cache pages if the caching feature of mod_proxy is enabled in the httpd.conf file.
The location of the cache can also be changed by changing the proxy configuration in the httpd.conf file.
Modules mod_fcgid, mod_jk,mod_security, and mod_dtrace are integrated to Apache 2. For more
information about these modules, see http://fastcgi.coremail.cn/doc.htm, http://tomcat.apache.org/connectors-doc/generic_howto/quick.html, http://www.modsecurity.org/documentation/index.html, and http://prefetch.net/projects/apache_modtrace/mod_dtrace.c
MySQL Database Files
The MySQL 5.0.45 software for Solaris is installed into a number of subdirectories
of /usr/mysql/5.0. Symbolic links are created from all directories under /usr/mysql/5.0 to /usr/mysql
directories so that latest version of MySQL can also be accessed from /usr/mysql.
- /usr/mysql/5.0/bin
Contains the binaries and scripts.
- /usr/mysql/5.0/lib
Contains the libraries for the client API.
- /usr/mysql/5.0/include
Contains the header files for the client API.
- /usr/mysql/5.0/man/man1
Manual pages for client programs.
- /usr/mysql/5.0/man/man8
Manual pages for server programs.
- /usr/mysql/5.0/share
Shared data: locale, time zone
- /usr/mysql/5.0/docs
Contains HTML documentation.
- /usr/mysql/5.0/mysql-test
Contains MySQL test programs.
- /usr/mysql/5.0/sql-bench
SQL benchmark test
- /usr/mysql/5.0/share/mysql
Contains internationalization (I18N) files, sample configuration files, and utility scripts.
- /var/mysql/5.0/data
Default database data directory.
- /etc/mysql/5.0
Contains the MySQL configuration file.
- /usr/mysql/5.0/bin/mysql
Client executable.
- /usr/mysql/5.0/bin/mysqld
Server executable.
PHP 5.2.4 Files
The following list describes the file structure for PHP:
- /usr/php5/5.2.4/bin
Contains the PHP configuration executables.
- /usr/php5/5.2.4/lib
Contains PHP library files.
- /usr/php5/5.2.4/modules
Contains PHP modules for PHP extensions.
- /usr/apache2/2.2/libexec
Contains the PHP module for Apache 2 (32-bit) prefork MPM and the module name is mod_php5.so. This module is delivered as part of SUNWapch22m-php5 package.
- /usr/php5/5.2.4
Contains the default configuration file (php.ini).
- /usr/php5/5.2.4/conf.d
Contains extension specific INI files for each PHP extension . Here, you can enable or disable various extensions that are integrated with the package.
Note - The PHP extensions like APC, DTrace, XDebug, suhosin, andtcpwrap are disabled by default. To
enable these extensions, you need to uncomment the respective line (extensions=<module-name>.so) in the
conf.d file.
PostgreSQL Database Files
The following list describes the file structure for the PostgreSQL database:
- /usr/postgres/8.2/bin
Contains the PostgreSQL executables.
- /usr/postgres/8.2/etc
Contains a sample database.
- /usr/postgres/8.2/jdbc
Contains the JDBC drivers for PostgreSQL.
- /usr/postgres/8.2/lib
Contains library files for OpenSolaris.
- /usr/postgres/8.2/man
Contains the man pages for the commands.
Ruby Files
The following list describes the file structure for Ruby:
- /var/ruby/1.8/gem_home
Contains the Rubygems repository. Configure the GEM_HOME environment variable to point to /var/ruby/1.8/gem_home to use this installation of Rubygems.
- /usr/ruby/1.8/bin
Contains the Ruby executable as well as other utility programs, and Rubygems programs. These programs are linked from /usr/bin. For example: /usr/ruby/1.8/bin/ruby is linked from /usr/bin/ruby1.8, and may be linked from /usr/bin/ruby if 1.8 is the latest version of Ruby installed on this system.
Squid Files
The following list describes the file structure for Squid:
- /usr/squid/bin
Contains the executable for the Squid client and to run the cache.
- /usr/squid/libexec
Contains the libraries.
- /etc/squid/squid.conf
The main configuration file. Modify this file for Squid to work.