For simplified step-by-step installation notes, see
If you do not have Java SE (Standard Edition) Development Kit 17 or later already installed, you will need to download and install it from Java SE Downloads first. For instance, you can use Oracle’s Java SE Development Kit 21 or Adoptium Temurin JDK 21. Java 21 is suggested, rather than the latest version, due to its long-term support (LTS).
-Djava.security.manager=allow to be set.
UniTime 4.8 or earlier: Download Apache Tomcat 9
web-tomcat10/UniTime.war in the distribution).UniTime 4.9 or later: Download Apache Tomcat 10 or later
Install Apache Tomcat
Download MySQL from MySQL Downloads
serverTimezone parameter in the connection string (see MySQL Time Zone Support for more details).Install MySQL
Install MySQL JDBC driver
MariaDB works, but it is currently not supported. If you are using MariaDB, please note that:
connection.driver_class=org.mariadb.jdbc.Driver
dialect=org.hibernate.dialect.MariaDBDialect
connection.url=jdbc:mariadb://localhost:3306/timetable?useSSL=false&useUnicode=true&characterEncoding=utf-8&allowPublicKeyRetrieval=true
Download the latest UniTime 4.8 distribution from UniTime Downloads
Unzip the archive
tar -xvzf unitime-4.8_bld100.tar.gz
Install timetable database
doc/mysql folder of the distributionschema.sql contains the database schema, file woebegon-data.sql contains test data (Woebegon College Test Suite, see Online Demo for more details).
mysql command-line tool
schema.sql, you need to populate the database either using woebegon-data.sql or blank-data.sql filewoebegon-data are used, you will be able to login into the application using the same credentials as described on our online demo pageblank-data are used, there is only administrator account created. Both username and password are admin.
mysql -uroot -p -f <schema.sql
mysql -uroot -p <woebegon-data.sql
Deploy UniTime application
web/UniTime.war to Tomcat/webapps, where Tomcat is the folder where Tomcat is installed.
export JAVA_OPTS="${JAVA_OPTS} -Djava.awt.headless=true"
export JAVA_OPTS="${JAVA_OPTS} -Xmx2048m"
Start Tomcat
Tomcat/logs/catalina.out
Tip: If you have installed Tomcat on a Linux-based machine from a package (e.g., by running apt-get install tomcat9), you will need to make sure that there is a data folder available within the tomcat directory and that Tomcat has enough permissions to write files in there. This can be accomplished with something like:
mkdir /var/lib/tomcat9/data
chown tomcat9 /var/lib/tomcat9/data
/etc/default/tomcat9 file in this case.Tip: If you are using Tomcat 10 on Ubuntu/Debian, you may need to create a file /etc/systemd/system/tomcat10.service.d/override.conf containing the following lines:
[Service]
ReadWritePaths=/var/lib/tomcat10/data
/usr/lib/systemd/system/tomcat10.service.d/override.conf, depending on the location of the tomcat10.service file.Please note that UniTime 4.8 requires Java 17 or later. Java 8 and 11 are no longer supported.
To upgrade an existing UniTime installation, only the new UniTime.war file should be placed in the Tomcat/webapps folder instead of the existing one. All the necessary changes to the database are done automatically during the first deployment. The safest way to do so is as follows:
Tomcat/webapps, remove UniTime folder and replace the existing UniTime.war with the new oneTomcat/work folder.If you are using remove solver servers, the appropriate JARs need to be updated as well.
Some HQL reports may need to be updated due to the Hibernate upgrade, in particular:
table = id no longer works (e.g., Session = %SESSION% must be changed to Session.uniqueId = %SESSION%)is true needs to be changed to x = true= null or != null needs to be changed to is null or is not nullBIT_AND needs to be changed to BITANDInstructionalOffering.coordinators needs to be changed to InstructionalOffering.offeringCoordinatorsAssignment.classId needs to be changed to Assignment.clazz.uniqueIdCourseOffering.isControl = 1 needs to be changed to CourseOffering.isControl = truemod(x, n) may need to be changed to mod(cast(x as int), n)(x - y) by minutesysdate - :days (where :days is an integer) may need to be changed to adddate(sysdate, - :days) (Oracle)decode(...) returning an integer may need to be changed to cast(decode(...) as int) (Oracle)Scheduling Subparts: Limit and Course Name are no longer pre-computed, in the reports
ss.limit with (select sum(c.expectedCapacity) from Class_ c where c.schedulingSubpart = s)ss.courseName with (select co.subjectAreaAbbv || ' ' || co.courseNbr from CourseOffering co where co.isControl = true and co.instructionalOffering = ss.instrOfferingConfig.instructionalOffering)Instructional Offering: Limit and Demand are no longer pre-computed, in the reports
io.limit with (select sum(ioc.limit) from InstrOfferingConfig ioc where ioc.instructionalOffering = io)io.demand with (select sum(co.demand + (case when cox is null then 0 else cox.demand end)) from CourseOffering co left outer join co.demandOffering cox where co.instructionalOffering = io)Some Scripts may need to be updated due to the Hibernate upgrade, e.g,
Query.setLong, setString, setDate, etc., needs to be changed to setParameterQueueIn/QueueOut.setXml/getXML now takes a string (use setDocument/getDocument for XML access)See UniTime 4.8 release notes for other changes.
UniTime 4.9 is still being developed. For production installations, please use UniTime 4.8 for now.
Please note that UniTime 4.9 requires Java 17 or later. Apache Tomcat 10.1 or later is also needed (earlier installations are typically running Tomcat 8 or 9).
To upgrade an existing UniTime installation, only the new UniTime.war file should be placed in the Tomcat/webapps folder instead of the existing one. All the necessary changes to the database are done automatically during the first deployment. The safest way to do so is as follows:
Tomcat/webapps, remove UniTime folder and replace the existing UniTime.war with the new oneTomcat/work folder.If you are using remove solver servers, the appropriate JARs need to be updated as well.
See UniTime 4.9 release notes for other changes.
There are a lot of properties that are defined in file application.properties that is located in timetable.jar, which is located in UniTime.war at WEB-INF/lib. These properties can be changed in one of the following ways:
custom.properties and located in UniTime.war at WEB-INF/classes.tmtbl.custom.properties pointing to it.Tomcat/conf/catalina.propertiesexport JAVA_OPTS="${JAVA_OPTS} -Dtmtbl.title=Timetabling Demo"
export JAVA_OPTS="${JAVA_OPTS} -Dtmtbl.custom.properties=/etc/default/unitime.properties
Tip: Name the custom properties file Tomcat/conf/unitime.properties and put all the properties you need in there. For UniTime to use the file, add the following line to Tomcat/conf/catalina.properties
tmtbl.custom.properties=${catalina.base}/conf/unitime.properties
If the same property is defined on multiple places, the first one from the following order will be taken:
-Dproperty=value, or defined in Tomcat/conf/catalina.properties)custom.properties (UniTime.war/WEB-INF/classes/custom.properties or as defined by tmtbl.custom.properties system property)application.properties (UniTime.war/WEB-INF/lib/timetable.jar/application.properties)The database connection can be changed using custom properties. However, please note that these properties cannot be defined using the UniTime application (Administration / Defaults / Configuration menu item) since the database connection needs to be configured before the database can be accessed. For instance, custom.properties file can contain the following:
# MySQL Configuration Example
connection.url=jdbc:mysql://localhost:3306/timetable?serverTimezone=Europe/Prague
connection.username=timetable
connection.password=unitime
connection.driver_class=com.mysql.jdbc.Driver
dialect=org.hibernate.dialect.MySQLDialect
tmtbl.uniqueid.generator=org.hibernate.id.TableHiLoGenerator
default_schema=timetable
By default, all timetabling problems are solved within the application (using the same Java Virtual Machine); however, especially for bigger institutions, it might be desired to solve the timetabling problems by one or more separate solver servers.
All the necessary libraries are in the solver folder of the distribution except the JDBC driver. For MySQL 8.x download mysql-connector-java-8.0.33.jar, or for Oracle download ojdbc8.jar. If a different version of the driver is downloaded, rename it to mysql-connector-java.jar or ojdbc8.jar.
Place the JDBC driver in the solver directory (same location as the timetable.jar), for instance:
curl https://repo1.maven.org/maven2/com/mysql/mysql-connector-j/8.0.33/mysql-connector-j-8.0.33.jar --output solver/mysql-connector-java.jar
To run a remote solver, do:
java -Xmx2g -Dtmtbl.custom.properties=custom.properties -jar solver/timetable.jar
File custom.properties should contain all the custom parameters needed for starting up the server (e.g., database connection properties, if different from the defaults). It is usually the same as the one used on the Tomcat, except the jgroups.tcp.address property (see below). The load is automatically and seamlessly balanced between the remote solvers. The remote solver server also automatically reconnects itself when the web server is restarted. When the remote solver is shut down, all active timetabling instances are backed up and restored when the solver server is started again. The following properties need to be set in the custom.properties file. Please note that all these properties need to be set on the Tomcat side as well.
jgroups.tcp.address=127.0.0.1
IP address of the machine that is using this configuration file. This property should be different on each machine; the remaining properties are usually the same for all the UniTime instances (Tomcats as well as remote solver servers). If the property is set to 127.0.0.1 or localhost, the server will not be able to accept remote connections – use only if all the instances are running on the same machine!
unitime.solver.cluster=true
This property enables the Solver cluster. This cluster is used for RPCs between the Tomcat(s) and the remote solver server(s). Communication between UniTime instances is done using JGroups.
unitime.solver.port=7800
Default communication port for the Solver cluster. If the given port is taken (e.g., there are running multiple remote solver server(s) on the same machine), the next one available will be used instead.
unitime.solver.initial_hosts=127.0.0.1[7800]
By default, TCP ping discovery is used to form a cluster. The above parameter defines a comma-separated list of machines (and their communication ports) on which a UniTime instance may be running. It does not necessarily need to have all the possible IP addresses; usually, it is set to the IP addresses of the Tomcat server(s) running UniTime.
unitime.solver.jgroups.config=solver-jgroups-tcp.xml
An alternative JGroups configuration file can be provided with this property. The default configuration file is available here.
With UniTime 4.0, it is possible to run multiple instances of UniTime on a cluster of Tomcats and/or remote solver servers. Besides the Solver cluster and Enrollment cluster, it is also possible to form a Hibernate cluster that is used to replicate Hibernate L2 cache. The following properties can be used to configure the Hibernate cluster.
unitime.hibernate.cluster=true
This property enables the Hibernate cluster. This cluster is used for replication of Hibernate second level cache between multiple UniTime instances.
unitime.hibernate.port=7833
Default communication port for the Hibernate cluster. If the given port is taken (e.g., there are running multiple remote solver server(s) on the same machine), the next one available will be used instead.
unitime.hibernate.initial_hosts=127.0.0.1[7833]
By default, TCP ping discovery is used to form a cluster. The above parameter defines a comma-separated list of machines (and their communication ports) on which a UniTime instance may be running. It does not necessarily need to have all the possible IP addresses; usually, it is set to the IP addresses of the Tomcat server(s) running UniTime.
unitime.hibernate.jgroups.config=hibernate-jgroups-tcp.xml
An alternative JGroups configuration file can be provided with this property. The default configuration file is available here.
Please note that Hibernate cluster is only needed when there are two or more Tomcats running UniTime. Remote solver servers have the L2 cache disabled and hence no need to connect to the Hibernate cluster.
Here are some notes about using Oracle Database
The following custom properties need to be set (connection URL, username, and password may vary)
# Oracle Configuration Example
connection.url=jdbc:oracle:thin:@localhost:1521:xe
connection.username=timetable
connection.password=unitime
connection.driver_class=oracle.jdbc.driver.OracleDriver
dialect=org.hibernate.dialect.OracleDialect
tmtbl.uniqueid.generator=org.hibernate.id.SequenceGenerator
If the schema is different from timetable, the default_schema property needs to be changed as well
default_schema=timetable
File ojdbc8.jar (or later) needs to be copied either to Tomcat/lib or to Tomcat/webapps/UniTime/WEB-INF/lib. This file can be downloaded, e.g., from Oracle JDBC Drivers
Oracle installation scripts are located in doc/oracle folder of the distribution
imp tool and the woebegon.dat from the GitHub.
imp timetable/###### file=woebegon.dat full=y
User timetable needs to be created first, e.g., using sqlplus
sqlplus system
create user timetable identified by ######; grant dba to timetable; exit
Here are some notes about using PostgreSQL, for more details, please see the Migrating to PostgreSQL document.
Install PostgreSQL 12.0 or later from https://www.postgresql.org/download (using the default port 5432, and a custom password)
Create timetable user and timetable database, using the same name and credentials as the default UniTime database:
createuser --interactive --pwprompt -U postgres
Enter name of role to add: timetable
Enter password for new role: unitime
Enter it again: unitime
Shall the new role be a superuser? (y/n) n
Shall the new role be allowed to create databases? (y/n) y
Shall the new role be allowed to create more new roles? (y/n) n
Password: <password provided during install>
createdb timetable -U timetable -O timetable
Password: unitime
Populate the timetable database, using this timetable.sql file (Documentation/Database/PostgreSQL/timetable.sql in https://github.com/UniTime/unitime)
psql -U timetable <timetable.sql
Download JDBC Driver from https://jdbc.postgresql.org/download.html and place it to Tomcat/lib (e.g., postgresql-42.2.8.jar)
Change UniTime connection properties. The following custom properties need to be set (connection URL, username, password may vary)
# PostgreSQL Configuration Example
connection.url=jdbc:postgresql://localhost:5432/timetable
connection.driver_class=org.postgresql.Driver
dialect=org.hibernate.dialect.PostgreSQLDialect
connection.username=timetable
connection.password=unitime
default_schema=timetable
hibernate.dbcp.validationQuery=select 1
hibernate.globally_quoted_identifiers=true
Start UniTime, and check the logs for any errors.
Once UniTime is installed and works fine, the following steps should be done in order to make your UniTime instance more secure. This is especially important when the instance is accessible publicly.
Please note that UniTime comes with a few accounts pre-installed (just an admin user when blank-data.sql was used; more users when woebegon-data.sql was used). At start, we recommend changing their default passwords and/or removing the users you do not need. This can be done on the Administration > Other > Users page.
All the pre-installed accounts can be safely deleted once you at least a system administrator account is created. This requires creating a new users (containing username, external ID, and password) and creating a new manager with the matching external ID and System Administrator role using the Administration > Academic Sessions > Timetable Managers page.
Please note that Users can be emptied out, or only contain one or two backup users, if some authentication via LDAP, CAS, or OAuth2 is configured. With an external authentication enabled, the Users page is typically only used to create API users if they need to be able to authenticate using Basic authentication or an API key.
UniTime uses an encoding algorithm for export URLs (such as the calendar URL that the users can subscribe to in ther Calendar applications, authorizing the user to get the requested information) and API Tokens (see API manual). To secure this, you will need to change the endoding secret in the unitime.encode.secret application property.
# Configuration: encoder secret, please change the value in the custom properties!
unitime.encode.secret=FIXME
Optionally, you can also change the encoding algorithm. For legacy reasons, the PBKDF2WithHmacSHA1 algorithm is used by default. Change to PBKDF2WithHmacSHA512 for more secure encoding. This will also require setting the cipher initialization vector. You may also adjust the other related parameters listed below.
# Configuration: encoder secret algorithm, set to PBKDF2WithHmacSHA512 for more secure encoding
unitime.encode.algorithm=PBKDF2WithHmacSHA512
# Configuration: encoder secret algorithm iteration count, set it to 100000 for more secure encoding
unitime.encode.iterationCount=100000
# Configuration: encoder secret algorithm key length
unitime.encode.keyLength=128
# Configuration: encoder secret cipher transformation, set to AES/CBC/PKCS5Padding for more secure encoding
unitime.encode.cipher=AES/CBC/PKCS5Padding
# Configuration: encoder secret cipher initialization vector, set to a secret text when AES/CBC/PKCS5Padding is being used
unitime.encode.cipher.iv=FIXME
All these parameters can be set in the custom properites file (see Custom Properties). They do not show and cannot be set on the Application Configuration page.
If the UniTime instance has a public address, you can configure the HTTPS access with a valid certificate. Let’s Encrypt is likely the easiest choice, with plenty of tutorials available online.
Please check out the Administration Manual for the UniTime initial setup, creation of your first academic session, etc.
| Back to UniTime Online Documentation | © UniTime 2026 | Content available under GNU Free Documentation License 1.3 |