ARCHIVED: At IU, what is the instructional web programming environment on Mentor, and how do I use it?

This content has been archived, and is no longer maintained by Indiana University. Resources linked from this page may no longer be available or reliable.
The instructional web programming environment on Mentor will be retired at the end of the fall 2017 semester.

The instructional web programming environment on Mentor is a Unix-based system of services provided for use by advanced classes on web programming and serving data over the web. Mentor hosts individual Apache web servers to allow students to develop and serve web pages or applications. For classes on serving data over the web, these web servers can be loaded with Tomcat modules for student-developed Java applications connected to a Unix-based Oracle database back end.

Requesting accounts on Mentor

Only Indiana University faculty can request Apache/Tomcat accounts on Mentor. To do so, complete the Request Form for Database and Web Accounts for Instruction.

Student accounts are valid for the duration of the course, and automatically expire approximately two weeks after the end of the semester. Faculty accounts do not expire.

If you intend to teach with the Mentor environment, contact UITS well ahead of time, because multiple groups coordinate setup of the environment.

Environment details


  • Hardware: HP DL585-G5 virtual machine
  • Available software:
    This is a partial list; request additional software through your instructor. Required lead time for installation will depend on the nature of the software and other priorities.
    • Red Hat Enterprise Linux OS (virtual machine)
    • Emacs 23.1.1
    • Vim - Vi IMproved 7.4
    • GNU C compiler (gcc) version 4.4.7 20120313
    • Transform
    • perl 5.16.3 with DBD::Oracle-1.23, DBI, Apache::DBI, Apache::DB, Bundle::LWP, CGI, Date::Calc
    • PHP 5.3.26 (cgi) with Oracle
    • Java 1.7.0
    • Ruby version
    • Python version 2.6.6
    • Apache web server 2.2.15 (web programming only) or Apache web server 2.2.15 with mod_php-5.2.11 and mod_jk-1.2.28 (Jakarta Tomcat-Apache connector for web/database programming)
    • Apache Tomcat 7.0.65
    • Oracle InstantClient, including SQL*Plus

The following client tier and database server tier are available for web-database programming:

Client tier

The client tier consists of the IU Bloomington STCs. Available resources include:

  • Web browsers
  • Oracle's SQL*Plus for testing SQL queries before placing them in Java programs

Students can also access Mentor or the Oracle database from their networked personal computers using an SSH client or the Oracle client software, respectively:

Database server tier

The server tier consists of a Linux server, Dbserv, hosting an Oracle 11.2 database named Oed1prd.

General tips on Mentor accounts

  • To access your account, use SSH2 to connect to, using your Mentor username and password (telnet access to Mentor is not available).
  • Direct printing is not available from Mentor. To print a file, open the file in a browser, view the document source, and print.
  • Disk space usage by account is available from the Mentor Instructional Environment Account Data page.

    Data are collected weekly and averaged. Disk space units are in kilobytes.

  • Place .class files in your ~/www/WEB-INF/classes directory; note that the ~ (tilde) stands for your home login directory.
  • Place .jsp, .html, and .pl files in your ~/www directory.
  • To start Apache (and Tomcat), use the following command:
     /usr/local/bin/cmd_apache_tomcat start 
  • To stop Apache (and Tomcat), use the following command:
     /usr/local/bin/cmd_apache_tomcat stop 
  • To shut down and restart Apache (and Tomcat), use the following command:
     /usr/local/bin/cmd_apache_tomcat restart 
  • To access your Apache account pages (without Tomcat) through a browser, go to: 

    To get to your directory index, you can also go to:

    For the above examples, substitute your account name for username and your specific file for filename.

  • To set up a site for Dreamweaver, specify your address as:

    For your host directory, enter:


    Substitute your account name for username.

  • In order to use Transform, you must first install it in your account:
    1. Log in and change to the directory where you will store your forms (e.g., ~/www/forms).
    2. At the prompt, enter tf_install to install Transform. You should install Transform in every directory where you will keep forms.
  • To access your HTML pages and Perl applications through the web, go to:

    Replace yourport with your account's first port number and yourfilename with the name of your file.

  • Apache logs are found in the logs directory off of your home directory (~/logs).

Tips on using Tomcat

  • To run a servlet from a web browser, go to:

    Replace yourport with your account's first port number and yourservlet with the name of your servlet.

  • For information regarding the "class not found" issue for Tomcat, see the Tomcat FAQ.
  • The basic connection string to Oracle database Oed1prd is:
    D.r(new oracle.jdbc.OracleDriver()); Connection conn = DriverManager.getConnection("","username","password");
  • Port numbers are assigned for Tomcat accounts, and you must know your port number to access your servlets and pages over the web. If you lose your port number, you can find it at the Mentor instructional environment account data page.
  • To avoid having to restart Tomcat after modifying a servlet, add reloadable="true" to the context path in your server.xml file.
  • To use JDBC:
    1. Create a directory called lib in ~/www/WEB-INF.
    2. Copy the /ip/share/ojdbc6.jar file to the new lib directory.

Tips on using CGI, PHP, or Perl

  • To run CGI scripts from your account:
    1. Put the script in your www directory or any of its subdirectories.
    2. Name your script with a suffix of either .pl or .cgi.
    3. Set the file permissions to read, write, and execute for the owner only by entering chmod 700 filename. Replace filename with the name of your script.
    4. Test your script from the command line to catch errors. If you have a Tomcat account, you can check your own log files for error messages produced from accessing your script via the web.
  • The option "Global_registers" is turned off for PHP, which may require some changes to your scripts.
  • The "shebang" (#!/usr/local/bin/php) line is required for PHP, because PHP is installed for CGI use.
  • For information about PHP on the IU central servers, see PHP server-side scripting language.
  • To view the HTML pages and Perl applications hosted on your Tomcat account, go to: 

    Substitute your account's first port number for port# and the filename for yourfilename.

Server downtimes

Mentor is offline each Saturday 5-5:30am. The reserved maintenance time (if needed) is Sunday 1-6am. For updates, visit the Mentor Instructional Environment page.

UITS backs up information from Oed1prd to disk and to tape daily with complete backups taken twice a week and incremental backups taken the rest of the week. Since all backups are hot backups, downtime is not necessary. In the event of a system failure, UITS can restore Oed1prd to the point of the last good backup, which is usually from that morning. UITS cannot promise up-to-the-minute recovery of accounts. Further, UITS does not offer recovery of data for individual accounts in cases where data loss is the result of user error. UITS encourages you to maintain copies of all scripts as a sensible measure.

Documentation links

For general information on the various technologies used in the instructional web programming environment on Mentor, see:

Contact information

If you are a student, contact your instructor if you encounter problems with the environment. To help your instructor and UITS isolate the problem, be sure to include specific information about the nature of the problem and include all details that can help diagnose it. Your instructor will contact UITS if the problem involves the server environment.

This is document anix in the Knowledge Base.
Last modified on 2018-01-18 14:00:18.

  • Fill out this form to submit your issue to the UITS Support Center.
  • Please note that you must be affiliated with Indiana University to receive support.
  • All fields are required.

Please provide your IU email address. If you currently have a problem receiving email at your IU account, enter an alternate email address.

  • Fill out this form to submit your comment to the IU Knowledge Base.
  • If you are affiliated with Indiana University and need help with a computing problem, please use the I need help with a computing problem section above, or contact your campus Support Center.

Please provide your IU email address. If you currently have a problem receiving email at your IU account, enter an alternate email address.