IDM Command Line Parameters

IDM is packed in a Java JAR file, a universal package that can be run on any system capable of running Java Version 8. or the open-source edition OpenJDK which now prevealed over the oracle distribution after the license change.

This page explains the IDM command line options. Even though there are preconfigured distribution packages available under Installation, you may want to run multiple instances at the same time, which requires manual control.

Starting IDM

With java8 installed and in path:

java -jar idm.jar

On Windows and MAC, you can also double click on the idm.jar file.

By default, the application starts with GUI as a Desktop application and opens the following ports:

  • HTTP Web RESTful API (web & python access): TCP/IP port 33000

  • IDM Services (Pro Version): TCP/IP port 33003

These ports are closed for external access by default, however, a web javascript or other running processes can silently connect to it. You may want to setup an admin or user password.

The ports can be changed in GUI or directly in the idm.conf. To allow access to the RESTful services you need to open the port in your firewall.

  • Linux:

  • Windows: on the first attempt to access the 9001 port externally, the user is asked to allow/disallow access

  • MAC: ..

For interfacing an USB device you may need to manually grant rights or provide a proper driver, do see USB Device Drivers Setup page.

Stopping IDM

IDM syncs run-time data information every 600 seconds, upon device disconnection and on exit. To ensure data integrity, stop IDM by:

  • either sending it SIGINT, so under Linux: kill <process pid>

  • by pressing CTRL+C if running in command line mode when invoked directly,

  • or simply by closing the GUI when running the Desktop version.

In case the data integrity is lost:

  • the IDM configuration file idm.conf may be restored from bak file, see Configuration

  • corrupted recordings of the file are backuped under records/ and new records are created. The utility to recover the old data and merge it with new data is still pending.

Command Line options

Starting Options

--daemon                                start program in command line mode without GUI
--systray                               enable system tray
--run=<command>                         run a command or script at startup. example: --run=$openSerialPort(demo)
--working-dir=<directory>               set working directory
--disable-bluetooth                     disable bluetooth support
--api-disable-records                   disable message recording by default. It can still be enabled manually for each device
--version                               print program version
--license                               print license acknowledgements
--help                                  print this help contents

IDM is started as a GUI Desktop application by default. With the switch –daemon, GUI will not be initialized, suitable to run as a daemon (background service). For example: to start a Linux/IDM and put it into the background, use the nohup helper utility:

$ nohup java -jar idm.jar --daemon &

Note

IDM options are provided at the end, after the -jar idm.jar.

Alternatively, for development purposes, you may wish to start the application as GUI but would like to minimize it to a system tray to appear as a daemon. Use the –systray option.

IDM offers a set of so-called terminal commands, which are used to make actions, typically opening or closing ports. One such command can be provided via the command line using the –run option. Note that the ports also offer auto opening/closing features.

The –working-dir changes the base directory, which affects the default location for the config file, optional web file serving folder and storage for device recordings, stored under records/ sub-directory.

On some systems (Windows) with specific device drivers (Virtual COMs), a Bluetooth search may be long and unnecessary. In such cases it can be turned off temporarily from the command line via the –disable-bluetooth option or directly in the idm.conf. The Bluetooth configuration can also be managed from GUI under Settings.

The –api-disable-records is a master switch to disable recording regardless of the idm.conf. It is useful for testing purposes, not to splash records in a valid record storage without altering the idm.conf.

IDM as a Java application can be supplemented with numerous Java options to limit/set the memory space. For example, to reserve and limit memory consumption of a background daemon to 128 MB:

$ nohup java -Xms128m -Xmx128m -jar idm.jar --daemon &

Note

Java options are provided before the -jar idm.jar.

Configuration

--config=<filename>                     set custom configuration file
--config-<module>.<parameter>=<value>   set custom configuration parameter
--config-autorecovery                   try to restore configuration from backup file
--localhost-admin                       set localhost http access to admin mode automatically

By default, IDM searches for the idm.conf configuration file in the current folder. System wide (daemon) installations need to provide a system specific config file (option –config), which can also provide predefined presets for some hardware. The –config-<module>.<parameter> overrides the settings from the idm.conf.

The –config-autorecovery option will restore a damaged idm.conf from idm.conf.bak if present and retry upon restart for another time. If both files are damaged, IDM exists.

It may be convenient to avoid typing passwords in deployments where only a system administrator has local access. With the option –localhost-admin it may be easier to do a local configuration via python and to simplify scripting.

System Logging and Debugging

--severity=<minlevel>                   minimum logging level: Off, Trace, Debug, API, Info (default), Warning, Error to be reported.
--log4j-config=<filename>               set logger configuration file
--log-trace-msg                         enable additional communication trace messages

IDM reports activity related to its operation and messages from devices of different severity types. By default, IDM shows activity messages under the main Control View Activity TAB and also under each device’s view Activity tab. When run as –daemon, it will print messages to the console output, unless –log4j-config is provided.

The –severity switch defines a global severity level to be pushed into a console, GUI and system logger –log4j-config. The –log-trace-msg adds extra debugging messages used to support the debugging of the low-level communication protocol with hardware devices.

The system logging integration is provided by the Apache Log4j Package capable of various multiple logging configurations and integration with the standard syslog system. For more information on using syslog, follow to System Integration & Maintenance with Syslog.

Backward Compatibility Options

--Adisable-eom-loading                  disable %! end-of-messages indicator in device loading algorithm
--Acframe=short                         enable old frame processing protocol format

The –Adisable-eom-loading is provided to support older the Isotel myLab family, thermometers and voltage meters, and the –Acframe=short, a proprietary hardware.