Installation of Dymola on Linux Ubuntu 64 bit

This page describes how to install Dymola on Linux Ubuntu 64-bit and adjust the colors of the tool tips. The installation was done for Ubuntu 14.04, but most steps should also apply to other versions.

Installation from rpm files

Dymola for Linux is distributed as a zip file that contains rpm files. To install these files on Ubuntu, replace the first line with the actual Dymola version and run the following commands:

# Unzip the file, for example if there is a file ${DYMVER}-linux.tar.gz, type
unzip Dymola_2021x.AM_CAT_Dymola.Linux64.1-1.zip
# Change to the directory that contains the .rpm files, such as
cd dymola-2021x/AM_CAT_Dymola.Linux64/1/linux_x86_64
# Unpack the rpm files
for ff in `ls *.rpm`; do (sudo rpm2cpio $ff | cpio -i --make-directories); done
DYMVER=dymola-2021x-x86_64
sudo chmod -R o-w opt/${DYMVER}
sudo mv opt/${DYMVER} /opt/${DYMVER}

# Dymola is now installed in /opt/$DYMVER
# We will now make it executable with a simple dymola command
sudo ln -s /opt/${DYMVER}/bin/dymola.sh /usr/local/bin/dymola

# Now move the man page to the right location (create the folder first if you get an error)
sudo mv usr/local/man/man1/dymola.1 /usr/local/share/man/man1/dymola.1

# Dymola does not ship all libraries needed on Ubuntu 18.04
# We typically copy these two files from a previous installation
# (LBL cannot distribute these files, if you don't have them, ask your Dymola provider.)
sudo cp /opt/dymola-2021x-x86_64/bin/lib64/libevent-2.0.so.5  /opt/${DYMVER}/bin/lib64/
sudo cp /opt/dymola-2021x-x86_64/bin/lib64/libxcb-xinput.so.0 /opt/${DYMVER}/bin/lib64/

Now dymola will start dymola and man dymola should show a man page.

Use of Modelica Standard Library 3.2.3

Recent versions of Dymola do not distribute the Modelica Standard Library 3.2.3. To use the Modelica Standard Library 3.2.3, you can install it from github using

wget https://github.com/modelica/ModelicaStandardLibrary/releases/download/v3.2.3%2Bbuild.4/ModelicaStandardLibrary_v3.2.3.zip
unzip ModelicaStandardLibrary_v3.2.3.zip
sudo mv Modelica\ 3.2.3 /opt/${DYMVER}/Modelica/Library

Ubuntu 16.04

The Dymola 2017 license file looks for a network interface name eth0, but this was renamed to ens33 in Ubuntu 16.04. It can be changed back to eth0 as described here or here. In our case, creating the file below and rebooting worked:

$ cat /etc/udev/rules.d/70-persistent-net.rules
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{dev_id}=="0x0", ATTR{type}=="1", KERNEL=="eth0", NAME="eth0"

The 64 bit dymola version in bin64/dymola requires the following packages to be installed:

sudo apt-get install libqt5x11extras5 libqt5script5

as can be tested by running ldd bin64/dymola | grep "not found".

Ubuntu 14.04

32 bit support

You may need to install rpm2cpio to unpack the Dymola rpms, and libc6-dev-i386 and g++-multilib to compile models. You can do so by running

sudo apt-get install rpm2cpio libc6-dev-i386 g++-multilib

If the compilation fails and dslog.txt contains the line

/usr/bin/ld: cannot find -lstdc++

then try to add the following to the dymola/bin/lib directory:

sudo apt-get install lib32stdc++6
sudo ln -s /usr/lib32/libstdc++.so.6 /opt/dymola/bin/lib/libstdc++.so