IBM Connections: Criando as Databases Manualmente: Difference between revisions

From Wiki
No edit summary
No edit summary
Line 1: Line 1:
Abrir um Shell com o usuário da instância exemplo db2inst1
Abrir um Shell com o usuário da instância exemplo db2inst1
= Criando o usuário LNTUSER =
useradd -g db2iadm1 -m -d /db2home/lcuser lcuser
Trocanco a senha
passwd lcuser
= Criando o Banco de Dados Manualmente =


Entrar com o usuário dono da instância
Entrar com o usuário dono da instância
Line 9: Line 19:
  cd /tmp/Wizards
  cd /tmp/Wizards


Criar o seguinte shell
Executar os comandos
 
#!/bin/bash
# Criandos as databases
db2 -c -w -i -td@ -vf connections.sql/activities/db2/createDb.sql
db2 -c -w -i -td@ -vf connections.sql/activities/db2/appGrants.sql
db2 -c -w -i -td@ -vf connections.sql/blogs/db2/createDb.sql
db2 -c -w -i -td@ -vf connections.sql/blogs/db2/appGrants.sql
db2 -c -w -i -td@ -vf connections.sql/cognos/db2/createDb.sql
db2 -c -w -i -td@ -vf connections.sql/cognos/db2/appGrants.sql
db2 -c -w -i -td@ -vf connections.sql/communities/db2/createDb.sql
db2 -c -w -i -td@ -vf connections.sql/communities/db2/appGrants.sql
db2 -c -w -i -td@ -vf connections.sql/communities/db2/calendar-createDb.sql
db2 -c -w -i -td@ -vf connections.sql/communities/db2/calendar-appGrants.sql
db2 -c -w -i -td@ -vf connections.sql/dogear/db2/createDb.sql
db2 -c -w -i -td@ -vf connections.sql/dogear/db2/appGrants.sql
db2 -c -w -i -td@ -vf connections.sql/files/db2/createDb.sql
db2 -c -w -i -td@ -vf connections.sql/files/db2/appGrants.sql
db2 -c -w -i -td@ -vf connections.sql/forum/db2/createDb.sql
db2 -c -w -i -td@ -vf connections.sql/forum/db2/appGrants.sql
db2 -c -w -i -td@ -vf connections.sql/metrics/db2/createDb.sql
db2 -c -w -i -td@ -vf connections.sql/metrics/db2/appGrants.sql
db2 -c -w -i -td@ -vf connections.sql/mobile/db2/createDb.sql
db2 -c -w -i -td@ -vf connections.sql/mobile/db2/appGrants.sql
db2 -c -w -i -td@ -vf connections.sql/pushnotification/db2/createDb.sql
db2 -c -w -i -td@ -vf connections.sql/pushnotification/db2/createTriggers.sql
db2 -c -w -i -td@ -vf connections.sql/wikis/db2/createDb.sql
db2 -c -w -i -td@ -vf connections.sql/wikis/db2/appGrants.sql
#
# Os arquivos de profiles, homepage não utilizavam o @ como finalizador do comando
db2 -c -w -i -td";" -vf connections.sql/profiles/db2/createDb.sql
db2 -c -w -i -td";" -vf connections.sql/profiles/db2/appGrants.sql
db2 -c -w -i -td";" -vf connections.sql/homepage/db2/createDb.sql
db2 -c -w -i -td";" -vf connections.sql/homepage/db2/appGrants.sql
db2 -c -w -i -td";" -vf connections.sql/homepage/db2/initData.sql
db2 -c -w -i -td";" -vf connections.sql/homepage/db2/reorg.sql
db2 -c -w -i -td";" -vf connections.sql/homepage/db2/updateStats.sql
# Se você utiliza o IBM Connections Content Manager (CCM)
db2 -c -w -i -td@ -vf connections.sql/library.gcd/db2/createDb.sql
db2 -c -w -i -td@ -vf connections.sql/library.gcd/db2/appGrants.sql
db2 -c -w -i -td@ -vf connections.sql/library.os/db2/createDb.sql
db2 -c -w -i -td@ -vf connections.sql/library.os/db2/appGrants.sql


Executar o
db2 -c -w -i -td@ -vf activities/db2/createDb.sql  -z /tmp/activities_create.log
db2 -c -w -i -td@ -vf activities/db2/appGrants.sql -z /tmp/activities_grants.log
db2 -c -w -i -td@ -vf blogs/db2/createDb.sql      -z /tmp/blogs_create.log ;
db2 -c -w -i -td@ -vf blogs/db2/appGrants.sql      -z /tmp/blogs_grants.log ;
db2 -c -w -i -td@ -vf cognos/db2/createDb.sql      -z /tmp/cognos_create.log ;
db2 -c -w -i -td@ -vf cognos/db2/appGrants.sql    -z /tmp/cognos_grants.log ;
db2 -c -w -i -td@ -vf communities/db2/createDb.sql -z /tmp/communities_create.log ;
db2 -c -w -i -td@ -vf communities/db2/appGrants.sql -z /tmp/communities_grants.log ;
db2 -c -w -i -td@ -vf communities/db2/calendar-createDb.sql -z /tmp/communities_createcalendar.log ;
db2 -c -w -i -td@ -vf communities/db2/calendar-appGrants.sql -z /tmp/communities_grantscalendar.log ;
db2 -c -w -i -td@ -vf dogear/db2/createDb.sql      -z /tmp/dogear_create.log ;
db2 -c -w -i -td@ -vf dogear/db2/appGrants.sql    -z /tmp/dogear_grants.log ;
db2 -c -w -i -td@ -vf files/db2/createDb.sql      -z /tmp/files_create.log ;
db2 -c -w -i -td@ -vf files/db2/appGrants.sql      -z /tmp/files_grants.log ;
db2 -c -w -i -td@ -vf forum/db2/createDb.sql      -z /tmp/forum_create.log ;
db2 -c -w -i -td@ -vf forum/db2/appGrants.sql      -z /tmp/forum_grants.log ;
db2 -c -w -i -td@ -vf homepage/db2/createDb.sql    -z /tmp/homepage_create.log ;
db2 -c -w -i -td@ -vf homepage/db2/appGrants.sql  -z /tmp/homepage_grants.log ;
db2 -c -w -i -td@ -vf homepage/db2/initData.sql    -z /tmp/homepage_initdata.log ;
db2 -c -w -i -td@ -vf homepage/db2/reorg.sql      -z /tmp/homepage_reorg.log ;
db2 -c -w -i -td@ -vf homepage/db2/updateStats.sql -z /tmp/homepage_updatestats.log ;
db2 -c -w -i -td@ -vf metrics/db2/createDb.sql    -z /tmp/metrics_create.log ;
db2 -c -w -i -td@ -vf metrics/db2/appGrants.sql    -z /tmp/metrics_grants.log ;
db2 -c -w -i -td@ -vf mobile/db2/createDb.sql      -z /tmp/mobile_create.log ;
db2 -c -w -i -td@ -vf mobile/db2/appGrants.sql    -z /tmp/mobile_grants.log ;
db2 -c -w -i -td@ -vf profiles/db2/createDb.sql    -z /tmp/profiles_create.log ;
db2 -c -w -i -td@ -vf profiles/db2/appGrants.sql  -z /tmp/profiles_grants.log ;
db2 -c -w -i -td@ -vf pushnotification/db2/createDb.sql -z /tmp/pushnotification_grants.log ;
db2 -c -w -i -td@ -vf pushnotification/db2/createTriggers.sql -z /tmp/pushnotification_grants.log ;
db2 -c -w -i -td@ -vf wikis/db2/createDb.sql      -z /tmp/wikis_create.log ;
db2 -c -w -i -td@ -vf wikis/db2/appGrants.sql      -z /tmp/wikis_grants.log ;


sh -x criaConnectionsDB.sh | tee resultado.txt
Se você for instalar o IBM Connections Content Manager


db2 -c -w -i -td@ -vf libraries.gcd/db2/createDb.sql -z /tmp/c50/libraries.gcd_create.log
db2 -c -w -i -td@ -vf libraries.gcd/db2/appGrants.sql -z /tmp/c50/libraries.gcd_grants.log
db2 -c -w -i -td@ -vf libraries.os/db2/createDb.sql -z /tmp/c50/libraries.os_create.log
db2 -c -w -i -td@ -vf libraries.os/db2/appGrants.sql -z /tmp/c50/libraries.os_grants.log


= Ver também =
= Ver também =

Revision as of 11:23, 29 August 2018

Abrir um Shell com o usuário da instância exemplo db2inst1

Criando o usuário LNTUSER

useradd -g db2iadm1 -m -d /db2home/lcuser lcuser

Trocanco a senha

passwd lcuser

Criando o Banco de Dados Manualmente

Entrar com o usuário dono da instância

su - db2inst1

Ir para o diretório onde você extraiu o Wizard

cd /tmp/Wizards

Executar os comandos

db2 -c -w -i -td@ -vf activities/db2/createDb.sql  -z /tmp/activities_create.log
db2 -c -w -i -td@ -vf activities/db2/appGrants.sql -z /tmp/activities_grants.log
db2 -c -w -i -td@ -vf blogs/db2/createDb.sql       -z /tmp/blogs_create.log ;
db2 -c -w -i -td@ -vf blogs/db2/appGrants.sql      -z /tmp/blogs_grants.log ;
db2 -c -w -i -td@ -vf cognos/db2/createDb.sql      -z /tmp/cognos_create.log ;
db2 -c -w -i -td@ -vf cognos/db2/appGrants.sql     -z /tmp/cognos_grants.log ;
db2 -c -w -i -td@ -vf communities/db2/createDb.sql -z /tmp/communities_create.log ;
db2 -c -w -i -td@ -vf communities/db2/appGrants.sql -z /tmp/communities_grants.log ;
db2 -c -w -i -td@ -vf communities/db2/calendar-createDb.sql -z /tmp/communities_createcalendar.log ;
db2 -c -w -i -td@ -vf communities/db2/calendar-appGrants.sql -z /tmp/communities_grantscalendar.log ;
db2 -c -w -i -td@ -vf dogear/db2/createDb.sql      -z /tmp/dogear_create.log ;
db2 -c -w -i -td@ -vf dogear/db2/appGrants.sql     -z /tmp/dogear_grants.log ;
db2 -c -w -i -td@ -vf files/db2/createDb.sql       -z /tmp/files_create.log ;
db2 -c -w -i -td@ -vf files/db2/appGrants.sql      -z /tmp/files_grants.log ;
db2 -c -w -i -td@ -vf forum/db2/createDb.sql       -z /tmp/forum_create.log ;
db2 -c -w -i -td@ -vf forum/db2/appGrants.sql      -z /tmp/forum_grants.log ;
db2 -c -w -i -td@ -vf homepage/db2/createDb.sql    -z /tmp/homepage_create.log ;
db2 -c -w -i -td@ -vf homepage/db2/appGrants.sql   -z /tmp/homepage_grants.log ;
db2 -c -w -i -td@ -vf homepage/db2/initData.sql    -z /tmp/homepage_initdata.log ;
db2 -c -w -i -td@ -vf homepage/db2/reorg.sql       -z /tmp/homepage_reorg.log ;
db2 -c -w -i -td@ -vf homepage/db2/updateStats.sql -z /tmp/homepage_updatestats.log ;
db2 -c -w -i -td@ -vf metrics/db2/createDb.sql     -z /tmp/metrics_create.log ;
db2 -c -w -i -td@ -vf metrics/db2/appGrants.sql    -z /tmp/metrics_grants.log ;
db2 -c -w -i -td@ -vf mobile/db2/createDb.sql      -z /tmp/mobile_create.log ;
db2 -c -w -i -td@ -vf mobile/db2/appGrants.sql     -z /tmp/mobile_grants.log ;
db2 -c -w -i -td@ -vf profiles/db2/createDb.sql    -z /tmp/profiles_create.log ;
db2 -c -w -i -td@ -vf profiles/db2/appGrants.sql   -z /tmp/profiles_grants.log ;
db2 -c -w -i -td@ -vf pushnotification/db2/createDb.sql -z /tmp/pushnotification_grants.log ;
db2 -c -w -i -td@ -vf pushnotification/db2/createTriggers.sql -z /tmp/pushnotification_grants.log ;
db2 -c -w -i -td@ -vf wikis/db2/createDb.sql       -z /tmp/wikis_create.log ;
db2 -c -w -i -td@ -vf wikis/db2/appGrants.sql      -z /tmp/wikis_grants.log ;

Se você for instalar o IBM Connections Content Manager

db2 -c -w -i -td@ -vf libraries.gcd/db2/createDb.sql -z /tmp/c50/libraries.gcd_create.log 
db2 -c -w -i -td@ -vf libraries.gcd/db2/appGrants.sql -z /tmp/c50/libraries.gcd_grants.log 
db2 -c -w -i -td@ -vf libraries.os/db2/createDb.sql -z /tmp/c50/libraries.os_create.log 
db2 -c -w -i -td@ -vf libraries.os/db2/appGrants.sql -z /tmp/c50/libraries.os_grants.log 

Ver também