RHEL - Ignition 8.0.12 Data Directory Change

Hello Team,

I am installing Ignition 8 on RHEL 7. Is there a way to change data directory location to any directory other than ‘/var/lib/ignition/data’ ?

I tried to update ignition.conf as below and restarted services but it failed -

wrapper.java.additional.1=-Ddata.dir=/apps/local/ignition/data

Thanks,
Satya

How did it fail? What was the error when you restarted the service?

Hey Kevin,

PFB error logs -

INFO | jvm 1 | 2020/06/05 13:43:56 | WrapperManager: Initializing…
INFO | jvm 1 | 2020/06/05 13:43:56 | 13:43:56.591 [WrapperSimpleAppMain] WARN com.inductiveautomation.ignition.gateway.logging.GatewayLoggingManagerImpl - The database log appender is not installed, the gateway will not be able to query logs. Other appenders may be installed and may be logging successfully, but the events will not be displayed in the gateway.
INFO | jvm 1 | 2020/06/05 13:43:56 | 13:43:56.629 [WrapperSimpleAppMain] ERROR IgnitionGateway - Error initializing web manager:
INFO | jvm 1 | 2020/06/05 13:43:56 | java.lang.IllegalStateException: Could not find /apps/local/bin/ignition/data//gateway.xml or /apps/local/bin/ignition/data//gateway.xml_clean.
INFO | jvm 1 | 2020/06/05 13:43:56 | at com.inductiveautomation.catapult.util.FileUtil.ensureFileExists(FileUtil.java:108)
INFO | jvm 1 | 2020/06/05 13:43:56 | at com.inductiveautomation.ignition.gateway.web.WebResourceManagerImpl.readGatewayProperties(WebResourceManagerImpl.java:419)
INFO | jvm 1 | 2020/06/05 13:43:56 | at com.inductiveautomation.ignition.gateway.web.WebResourceManagerImpl.(WebResourceManagerImpl.java:105)

Did you copy the old data dir to that new location?

Are you suggesting to copy all below files to new location -

ls -ltr
total 32
-rw-r–r-- 1 ignition root 176 Apr 21 18:46 jnlp-opens.conf
-rw-r–r-- 1 ignition root 341 Apr 21 18:46 jnlp-exports.conf
-rw-r–r-- 1 ignition root 2144 Apr 21 18:56 logback.xml
lrwxrwxrwx 1 ignition root 27 May 29 10:10 ignition.conf -> /etc/ignition/ignition.conf
lrwxrwxrwx 1 ignition root 25 May 29 10:10 gateway.xml -> /etc/ignition/gateway.xml
lrwxrwxrwx 1 ignition root 30 May 29 10:10 log4j.properties -> /etc/ignition/log4j.properties
-rw-r–r-- 1 ignition ignition 0 May 29 10:10 response
-rw-r–r-- 1 ignition ignition 0 May 29 10:10 request
-rw-rw-r-- 1 ignition ignition 63 May 29 11:10 init.properties.bak
drwxr-xr-x 4 ignition ignition 70 May 29 11:10 certificates
drwxrwxr-x 2 ignition ignition 6 May 29 11:10 redundant_state
drwxrwxr-x 2 ignition ignition 4096 May 29 11:10 module-info
drwxrwxr-x 20 ignition ignition 4096 May 29 11:10 jar-cache
-rw-rw-r-- 1 ignition ignition 139 May 29 11:10 commissioning.json
drwxrwxr-x 2 ignition ignition 6 May 29 11:10 sfc
drwxrwxr-x 5 ignition ignition 58 May 29 11:10 opcua
drwxrwxr-x 3 ignition ignition 48 May 29 11:10 modules
drwxrwxr-x 3 ignition ignition 51 May 29 11:10 projects
drwxrwxr-x 3 ignition ignition 19 May 29 15:40 datacache
drwxr-xr-x 3 ignition root 40 Jun 4 17:05 db
drwxrwxr-x 2 ignition ignition 24 Jun 5 13:42 metricsdb
-rw-rw-r-- 1 ignition ignition 1345 Jun 5 13:42 redundancy.xml

or some specifics ?

Probably all of them.

I copied all the files and it failed again -

/etc/init.d/ignition start
Starting Ignition-Gateway…
FATAL | wrapper | Unable to open configuration file: /var/lib/ignition/data/ignition.conf (No such file or directory)
FATAL | wrapper | Current working directory: /apps/local/bin/ignition
FATAL | wrapper | The Wrapper will stop.
Waiting for Ignition-Gateway…
WARNING: Ignition-Gateway may have failed to start.

I think there may be a path to ignition.conf in ignition.sh that needs updating as well then.

1 Like

You might find it easier to use the zip distributions instead of the installers if you’re going to be using custom locations for things. You’ll still have to make some changes to point things to the right directories but you won’t be starting from a state where files are spread over 3 or 4 directories or whatever the installer does.

Tried basic scripting and updated new path in below files -

web.xml
ignition.sh
gwcmd.sh
gateway.xml
ignition.conf

And looks like it worked. Running some test cases to confirm :slight_smile:

1 Like