...
Step 1. Move and adapt OMK files
There are a couple of options to move configuration files:
- (Option 1): Adapt just needed configuration files in the destination server (Cleaner option).
- (Option 2): Move all configurations from origin server and adapt in the new server.
Configuration Files: Option 1
Copy
Copy - just - the configuration files customised from the source server:
Code Block |
---|
rsync -r root@myserver.com:/usr/local/omk/conf/opCommon /usr/local/omk/conf
... |
And all the customised files/folders (If needed).
opConfig:
Code Block |
---|
command_sets.d
compliance_policies
config_parsers
config_plugins
config_sets.d
phrasebooks
schedule |
opEvents:
Code Block |
---|
EventActions.nmis
EventDB.nmis
EventEmails.nmis
EventListRules.nmis
EventNmisRules.nmis
EventParserRules.nmis
EventRules.nmis
EventSyslogRules.nmis
EventTivoliRules.nmis
EventTrapRules.nmis
parser_plugins |
And users.dat file:
Code Block |
---|
ln -s ../nmis9/conf/users.dat conf/users.dat |
Convert to JSON
It can be done with the following command:
Code Block |
---|
/usr/local/omk# /usr/local/omk/bin/opcommon-cli.exe act=convert_json_dir dir=conf |
Configure
Update opCommon.json checking the customised item. You can use an useful script for that:
Code Block |
---|
/usr/local/omk/bin/opcommon-cli.pl act=compare_custom default=/usr/local/omk/install/opCommon.json custom=/usr/local/omk/conf/opCommon.json |
Configuration Files: Option 2
Copy
Copy the configuration directory from the source server.
...
Code Block |
---|
rsync -r root@myserver.com:/usr/local/omk/conf /usr/local/omk |
Convert to JSON
It can be done with the following command:
Code Block |
---|
/usr/local/omk# /usr/local/omk/bin/opcommon-cli.exe act=convert_json_dir dir=conf |
Configure
Update opCommon.json:
Code Block |
---|
"database": { "db_name": "omk_shared", ... "nmis": { "<nmis9_dir>": "/usr/local/nmis9", "<nmis9_logs>": "/usr/local/nmis9/logs", "nmis9_cgi_url_base": "/cgi-nmis9", "nmis9_dir": "/usr/local/nmis9", |
...