CSV File Format
You can add instances in bulk. The prerequisite is to have a CSV file with the following format:
"action:instance-import"
"dbms-type:sqlserver","given-name:SQLTEST001","host:local.dbwtest1.com","port:1433","admuser:sa","admpassword:Password1","group:Test","engine:true","service:demo"
"dbms-type:sqlserver","given-name:SQLTEST002","host:local.dbwtest2.com","port:1433","admuser:sa","admpassword:Password2","group:Test","engine:true","service:production_multiplatform"
"dbms-type:oracle","given-name:ORATEST001","host:local.dbwtest3.com","port:1521","sid:ORCL","admuser:sys as sysdba","admpassword:Password3","group:Test","engine:true","service:demo"
"dbms-type:mariadb","given-name:iridium","host:10.0.0.87","port:3306","group:mariadb","engine:true","adm-auth-mode:pwd","admuser:root","admpassword:9d500ec80e82789489ca770bd2d8b436","adm-all-global:true","service:production_multiplatform;all_performance_package"
"dbms-type:sqlserver","given-name:SQLPROD-001","host:SQLPROD-001.SECURE.DBWATCH.COM","port:1433","admuser:svc_dbwatch@SECURE.DBWATCH.COM","admpassword:SuperSecure001!","group:PROD","engine:true","service:demo","adm-auth-mode:kerberos","jdbc-driver:driver:com.microsoft.sqlserver:mssql-jdbc:9.4.0.jre8@connector:no.dbwatch.connectors:sqlserver"
———————————————————————————————————————————————————————————————————————————————————————————————————————————————————————————————————————
Let’s explain the tags more with the following table:
Tag | Is mandatory | Description |
dbms-type | yes | The database type (sqlserver, oracle, postgres, mysql, sybase) |
given-name | yes | The display name for the instance. |
host | yes | Host IP |
sid | only on Oracle | Specify Oracle SID |
port | yes | Port number |
admuser | yes | This user will be set as the properties user. If ‘engine’ is set to true, this user will be used to create the dbwatch schema |
admpassword | yes | The password for the admin user |
adm-auth-mode | no | What type of authentication is used, examples “adm-auth-mode:pwd” or “adm-auth-mode:kerberos” |
adm-all-global | no | Sets management / administration user for all users with access to an instance to the admuser credentials. Default false, values true/false. Example “adm-all-global:true” |
group | yes | The group to place the instance in. If ‘engine’ is set to true, the default values used during schema creation are from this group. |
subgroup | no | The sub group to place the instance in. |
engine | yes | If a dbwatch schema should be created (true, false). |
engine-database | no | The name of the dbwatch database. Use if engine=true, and you want another database name than is specified in the group. |
jobtemplate | no | Comma separated list of job templates. |
jobtemplatemode | no | The job template mode (“keep others”, “disable others”, “uninstall others”). |
service | yes | The licensing level to set for this instance. This can be a semicolon separated list of licenses to apply, lowercased. It is the same string as in the id in your license file. Examples: production_multiplatform, demo;production_sqlserver |
jdbc-driver | no | It is possible to specify the jdbc driver to use, example: “jdbc-driver:driver:com.microsoft.sqlserver:mssql-jdbc:9.4.0.jre8@connector:no.dbwatch.connectors:sqlserver” |
Uploading Instance File
Open ‘Server’->‘Upload resource’ menu.
A window will appear where you can upload resource files. Click on “Select Files” then choose the CSV file for bulk installation.
Afterwards, click on “Upload”.
After successfully uploading the Import.csv file.
You will see the 3(highlighted in yellow) additional instances that we’ve added.
Post your comment on this topic.
Ole wrote: Jul 2, 2021
It should be "given-name", and the blank line is not necessary.
Alexander Veitschegger wrote: Jul 2, 2021
it isn't clear if given-name or given name is correct. Is the blank line between the entries a 'must'?