Skip to content

System Administration🔗

With Modelon Impact installed, it will start automatically on each reboot. The admin script is used to manually stop and start the service.

Stopping and Starting Modelon Impact🔗

Run the following command to stop Modelon Impact:

$ /var/impact/modelonimpact.sh stop

Similarily, to start Modelon Impact again:

$ /var/impact/modelonimpact.sh start

Update the Modelon Impact License🔗

To renew the license, copy the the new license.yaml file into /etc/impact/licenses, then run the following command:

$ /var/impact/modelonimpact.sh license

This will result in a few minutes of service interruption; you may want to plan the operation in advance.

If there is a new license in /etc/impact/licenses, you will be asked if you really want to replace the license. Answer “YES” to this question, and the update will be performed:

$ /var/impact/modelonimpact.sh license
 __  __           _      _               ___                            _   
|  \/  | ___   __| | ___| | ___  _ __   |_ _|_ __ ___  _ __   __ _  ___| |_ 
| |\/| |/ _ \ / _` |/ _ \ |/ _ \| '_ \   | || '_ ` _ \| '_ \ / _` |/ __| __|
| |  | | (_) | (_| |  __/ | (_) | | | |  | || | | | | | |_) | (_| | (__| |_ 
|_|  |_|\___/ \__,_|\___|_|\___/|_| |_| |___|_| |_| |_| .__/ \__,_|\___|\__|
                                                      |_|
               Accurate Simulations. Better Decisions.

Please enter the password for "user" to run with elevated access rights, if asked for it.
[sudo] password for user:

Ubuntu Release: 22.04           RAM Tot / Avail: 15.58 GB / 11.93 GB
Disk size /var: 97G             Load Average: 0.78 0.80 0.82
Avail. space on /var: 54G   K3s cert expiration: 2023-11-29

Modelon Impact is running on: https://modelon-impact.mycompany.com
Keycloak IAM is running on:   https://modelon-impact.mycompany.com/iam/auth/admin

Update Modelon Impact license:

The license is ready to be installed.
NOTE: Modelon Impact will restart and be unavailable for approximately one minute.

Write YES to update the license, or press ENTER to exit: YES
secret "impact-users-license" deleted
secret/impact-users-license created
Stopping Modelon Impact:
[+] Running 2/1
  Container impact-k3s-1  Removed                                                                                                                                                                                                                                                                                      1.4s
 ! Network impact_default  Removed
0.0s
Starting Modelon Impact:
[+] Running 1/1
  Container impact-k3s-1  Started

Renew the TLS Certificate🔗

To renew the certificate, copy the new certificate files, tls.crt and tls.key, into /etc/impact/certs, then run the following command:

$ /var/impact/modelonimpact.sh tls

This will result in a few minutes of service interruption; you may want to plan the operation in advance.

If there is a new valid certificate in /etc/impact/certs, you will be asked if you really want to replace the certificate. Answer “YES” to this question, and the update will be performed:

$ /var/impact/modelonimpact.sh tls
 __  __           _      _               ___                            _   
|  \/  | ___   __| | ___| | ___  _ __   |_ _|_ __ ___  _ __   __ _  ___| |_ 
| |\/| |/ _ \ / _` |/ _ \ |/ _ \| '_ \   | || '_ ` _ \| '_ \ / _` |/ __| __|
| |  | | (_) | (_| |  __/ | (_) | | | |  | || | | | | | |_) | (_| | (__| |_ 
|_|  |_|\___/ \__,_|\___|_|\___/|_| |_| |___|_| |_| |_| .__/ \__,_|\___|\__|
                                                      |_|
               Accurate Simulations. Better Decisions.

Ubuntu Release: 22.04           RAM Tot / Avail: 15.58 GB / 13.26 GB
Disk size /var: 97G             Load Average: 0.47 0.60 0.76
Avail. space on /var: 56G   K3s cert expiration: 2023-11-29

Modelon Impact is running on: https://modelon-impact.mycompany.com
Keycloak IAM is running on:   https://modelon-impact.mycompany.com/iam/auth/admin

Install TLS certificate:
Validating the certificate and key in /etc/impact/certs: OK!

TLS Certificate validity period:
notBefore=Mar 15 00:00:00 2023 GMT
notAfter=Mar 14 23:59:59 2024 GMT

Certificate is ready to be installed.
Write YES to update the certificate, or press ENTER to exit: YES
secret "impact-ssl-certificate" deleted
secret/impact-ssl-certificate created

Renew the K3s Certificate🔗

K3s, that Modelon Impact runs on, creates it own internal certificate which is needed for communicating with the cluster. The certificate is valid for twelve months. If the expiration date is less than ninety days away, a new certificate will be created when you restart Modelon Impact.

The script /var/impact/modelonimpact.sh will show you the expiration date of the certificate, and will give you a reminder to restart Modelon Impact if it expires in less than ninety days.

$ /var/impact/modelonimpact.sh
 __  __           _      _               ___                            _
|  \/  | ___   __| | ___| | ___  _ __   |_ _|_ __ ___  _ __   __ _  ___| |_
| |\/| |/ _ \ / _` |/ _ \ |/ _ \| '_ \   | || '_ ` _ \| '_ \ / _` |/ __| __|
| |  | | (_) | (_| |  __/ | (_) | | | |  | || | | | | | |_) | (_| | (__| |_
|_|  |_|\___/ \__,_|\___|_|\___/|_| |_| |___|_| |_| |_| .__/ \__,_|\___|\__|
                                                      |_|
               Accurate Simulations. Better Decisions.

The K3s certificate expires in less than 90 days. Please restart Modelon Impact to generate a new certificate.

Ubuntu Release: 22.04           RAM Tot / Avail: 15.58 GB / 13.31 GB
Disk size /var: 97G             Load Average: 0.08 0.14 0.11
Avail. space on /var: 62G       K3s cert expiration: 2023-11-29

To restart Modelon Impact, run the commands /var/impact/modelonimpact.sh stop and /var/impact/modelonimpact.sh start. The certificate will then be automatically regenerated.

Note that Modelon Impact will be unavailable for a few minutes, you may want to plan this operation in advance.

Backup Modelon Impact🔗

The backup routine creates a snapshot of the entire Modelon Impact service.

The backup will temporarily pause the Modelon Impact service until the backup is done. You may want to schedule your backup to a period with less activity. You may want to add the backup as a cron-job on your server.

The backup will be written to the folder of your choice, this is configured in /etc/impact/config. The default is /var/impactbackups.

To create a backup, run the following command:

$ /var/impact/modelonimpact.sh backup

Note

Note that the files in /var/impact and /etc/impact are not backed up by this routine. We recommend that you do a normal backup of the Linux OS in addition to the Modelon Impact service. You should backup /var/impact, /etc/impact and /var/impactbackups as a bare minimum.

Restore a Backup🔗

When restoring your system, you will be brought back to that particular point in time. This includes the Modelon Impact version, user database, user data, the license, and the TLS certificate.

Users that have changed their passwords will have the change reverted, this includes the Keycloak administrator user.

To restore a backup, run this command:

$ /var/impact/modelonimpact.sh restore

This will present a list of available backups, sorted by date and time of day. Choose the appropriate backup and follow the instructions to complete the restore. Note that after the restore has completed, your server will need several minutes to restart all components.

If you have new license and certificate files in /etc/impact, run the following commands to update them:

$ /var/impact/modelonimpact.sh license
$ /var/impact/modelonimpact.sh tls

Managing Individual User Disks🔗

While users can save their Modelon Impact workspaces on a code version server, taking an OS backup of the entire server is strongly recommended. As this will safeguard your Modelon Impact backups in another location.

Note also that running /var/impact/modelonimpact.sh backup will not backup the folders /var/impact/ and /etc/impact. An OS backup is required to protect these directories.

All user data can be backed up and restored using the previously described features of modelonimpact.sh. However, using modelonimpact.sh works on the entire Modelon Impact installation, backing up and restoring data for all users in one operation.

There is an alternative procedure to manipulate data for individual users.

To find out the location of your user disk, use the command /var/impact/tools/ls-user-disk.sh <USERNAME>. Inside of the folder output by the command, you will find all your files, including the impact folder that contains all your Modelon Impact related files.

As an example, this shows how to find the impact folder for the user example.user.

$ /var/impact/tools/ls-user-disk.sh example.user
/var/lib/docker/volumes/conf_k3s-data/_data/storage/pvc-57fda079-bd17-4e2c-b11c-e4f4986b25d9_impact_claim-example-2euser

$ sudo ls /var/lib/docker/volumes/conf_k3s-data/_data/storage/pvc-57fda079-bd17-4e2c-b11c-e4f4986b25d9_impact_claim-example-2euser/impact
binary_blobs    custom_functions     default_customizations  ignore.impact  local_projects  released_projects
customizations  generated_resources  libraries               logs           workspaces

The backup archive produced by modelonimpact.sh backup contains, among other data, all user disks. It's possible to unpack the backup file in a temporary location, and copy files from there to your user disk.

Fixing a Corrupt Installation of Modelon Impact🔗

The installation can become corrupt in certain cases. This could happen if the server is not cleanly rebooted, or if there are errors in the configuration file.

In most cases, you can repair a corrupt instance by running the installer again.

If you’d like to recreate the configuration file, run the config command which will let you change the options that are incorrect:

$ /var/impact/modelonimpact.sh config

For the rebuild of your installation, the existing /etc/impact/config will be used. You will be guided through the setup if the config file is missing.

$ /var/impact/modelonimpact.sh install

The installer will detect that you have a running system and ask you to verify that you want to rebuild your instance of Modelon Impact.

Your user data and service configuration will be preserved. You are still advised to have a backup at hand in case you need to do a full disaster recovery.

You already have a running instance of Modelon Impact.
Running the installer will rebuild your instance of Modelon Impact using the options in /etc/impact/config.

Please note that the Modelon Impact service will be unavailable for a few minutes while reconfiguring.
Write YES to run the installer again, or press ENTER to exit: YES

Write “YES” to continue.

Rebuilding the Modelon Impact server will typically take less than five minutes.

The installer ends with this summary:

impact-provisioning-1  | NOTES:
impact-provisioning-1  | =================================
impact-provisioning-1  |  |_ _|  \/  | _ \/_\ / __|_   _|
impact-provisioning-1  |   | || |\/| |  _/ _ \ (__  | |
impact-provisioning-1  |  |___|_|  |_|_|/_/ \_\___| |_|
impact-provisioning-1  |
impact-provisioning-1  | Author: Modelon AB
impact-provisioning-1  | License: Proprietary
impact-provisioning-1  | URL: https://my.server.com
impact-provisioning-1  | =================================
impact-provisioning-1  | Evaluating running pods...
impact-provisioning-1  | Waiting for 1 pods
impact-provisioning-1  | Waiting for 1 pods
impact-provisioning-1  | Waiting for 1 pods
impact-provisioning-1  | Waiting for 1 pods
impact-provisioning-1 exited with code 0

The rebuild was successful if the last line reads “exited with code 0”

It’s possible that a failure is caused by unresponsive docker containers, this is usually solved by running the installer once more.

If it keeps failing, please follow the Disaster Recovery instructions using a backup dating from before the problems started.

Disaster Recovery🔗

If your server is rendered totally unusable, you can use a known good backup for disaster recovery.

You can either:

  • Install Modelon Impact on a different server, or

  • Uninstall Modelon Impact and do a fresh installation on the current server, then

  • Restore a known good backup.

To install Modelon Impact on a different server, just follow the installation instructions in this manual, then restore your system from the backup.

In this case, unless you have the original /etc/modelon/config file at hand, it will be recreated during the installation process.

To uninstall Modelon Impact, run the following command:

$ /var/impact/modelonimpact.sh uninstall

Warning

This will remove your entire Modelon Impact instance. User data and all services. You will need a known good backup in order to get your data back.

Uninstalling Modelon Impact will not remove the files in /etc/impact/. Nor will it remove backups which reside in the backup folder set in the config file.

You can now install Modelon Impact again and restore your backup to get the service up and running, with all configuration settings and user data intact.

Upgrade Modelon Impact🔗

This is the first release of the product, upgrading instructions will come with the next release.

Log Management and Troubleshooting🔗

To collect logs and statistics for troubleshooting, please run the command:

$ /var/impact/modelonimpact.sh analyze

This will collect all necessary information about your Modelon Impact instance, which can be used to assist in solving any issues.

The analysis results can be found in a tar archve /tmp/impact-systemdump-NNNNNNNNN.tar.gz.

Accessing the Modelon Impact Kubernetes Shell🔗

You can access the underlying Kubernetes cluster by running this command:

$ /var/impact/modelonimpact.sh shell

Note that this is usually not required unless you are asked to run certain commands by the Modelon support engineers.

Show Running Docker Pods🔗

The status command to modelonimpact.sh outputs information about the running docker container and all the pods inside of that container. This can be useful for troubleshooting purposes.

$ /var/impact/modelonimpact.sh status
 __  __           _      _               ___                            _
|  \/  | ___   __| | ___| | ___  _ __   |_ _|_ __ ___  _ __   __ _  ___| |_
| |\/| |/ _ \ / _` |/ _ \ |/ _ \| '_ \   | || '_ ` _ \| '_ \ / _` |/ __| __|
| |  | | (_) | (_| |  __/ | (_) | | | |  | || | | | | | |_) | (_| | (__| |_
|_|  |_|\___/ \__,_|\___|_|\___/|_| |_| |___|_| |_| |_| .__/ \__,_|\___|\__|
                                                      |_|
               Accurate Simulations. Better Decisions.

Please enter the password for "impactuser" to run with elevated access rights, if asked for it.

Ubuntu Release: 22.04           RAM Tot / Avail: 15.56 GB / 12.28 GB
Disk size /var: 29G             Load Average: 0.57 0.48 0.41
Avail. space on /var: 26G   K3s cert expiration: 2023-11-29

Modelon Impact is running on: https://modelon-impact.mycompany.com
Keycloak IAM is running on:   https://modelon-impact.mycompany.com/iam/auth/admin

CONTAINER ID   IMAGE                       COMMAND                  CREATED       STATUS       PORTS
                    NAMES
a9676306cbf5   rancher/k3s:v1.24.10-k3s1   "sh -c '/bin/k3s ser…"   2 hours ago   Up 2 hours   0.0.0.0:80->80/tcp, 0.0.0.0:443->443/tcp, 0.0.0.0:6443->6443/tcp, :::6443->6443/tcp   conf-k3s-1

NAMESPACE     NAME                                                   READY   STATUS      RESTARTS   AGE
default       db-postgresql-0                                        1/1     Running     0          5d21h
impact        job-controller-b44488c6c-6bjq8                         1/1     Running     0          5d20h
impact        proxy-844499b5d8-rl2ww                                 1/1     Running     0          5d20h
impact        job-controller-db-migration-p2as4-gnnw6                0/1     Completed   0          5d20h
impact        iam-6b47c56c9d-v695b                                   1/1     Running     0          5d20h
impact        user-scheduler-5c6666999b-k8x5b                        1/1     Running     0          5d20h
impact        impact-iam-provisioning-4f5nc-6bkhr                    0/1     Completed   0          5d20h
impact        user-scheduler-5c6666999b-dm7sn                        1/1     Running     0          5d20h
impact        user-68d69657fb-8t5gk                                  1/1     Running     0          5d20h
impact        continuous-image-puller-8dlmn                          1/1     Running     0          5d20h
impact        license-5458f86448-p89hb                               1/1     Running     0          5d20h
impact        excel-addin-6b6d777f8f-hllks                           1/1     Running     0          5d20h
impact        impact-db-migration-dbgge-kj5lx                        0/1     Completed   0          5d20h
impact        impact-ingress-nginx-controller-5466875fc9-csq9t       1/1     Running     0          5d20h
impact        hub-bcc55cdc7-gwf5v                                    1/1     Running     0          5d20h
kube-system   metrics-server-667586758d-9szxr                        1/1     Running     0          5d21h
kube-system   coredns-7b5bbc6644-2kl7k                               1/1     Running     0          5d21h
kube-system   svclb-impact-ingress-nginx-controller-5bdbaa71-vzxnq   2/2     Running     0          5d20h
kube-system   local-path-provisioner-687d6d7765-8k8kd                1/1     Running     0          5d21h

Uninstall Modelon Impact🔗

Should you need to uninstall Modelon Impact, you can use these commands:

$ /var/impact/modelonimpact.sh uninstall

NOTE: This will also remove all user data stored inside of Modelon Impact. Backup data taken using the modelonimpact.sh script is left untouched. Should you want to remove backups as well, do so using:

$ sudo rm -r /var/impactbackups

This is assuming that you are using the default folder for backups.