Instalacion ambiente web am en linux red hat

29
PREREQUISITOS INSTALACIÓN DEL CLIENTE ASSET MANAGER WEB EN LINUX Instalar JDK Si debemos desinstalar una versión anterior de JDK comando para desinstalar java Yum remove java-1.8.0-openjdk-1.8.0.65-3.b17.el7.x86_64 o eliminar la carpeta de instalación directamente Descargamos el archivo de JDK correspondiente de la página de Oracle en este caso jdk -8u65-linux - x64.tar.gz y lo copiamos en el directorio /usr/java Descomprimimos el archivo tar.gz con el comando tar zxvf jdk-8u65-linux-x64.tar.gz Ejecutamos el comando java version para verificar que el JDK quedó instalado. Configurar variable JAVA_HOME que apunte a la carpeta de instalación del JDK Configurar la variable LD_LIBRARY_PATH=/ home/bsmucmdb/Software/Asset/AssetManager/x64 en el bash_profile para que Asset Manager encuentre las librerías .so Igualmente configuramos la variable ORACLE_HOME para que apunte a la carpeta de instalación del cliente Oracle y la añadimos al PATH y al LD_LIBRARY_PATH En la ruta / etc/ld.so.conf.d con usuario root creamos el archivo AssetManager-x86_64.conf lo editamos colocando la misma ruta que en la variable LD_LIBRARY_PATH y ejecutamos el comando ldconfig --verbose para actualizar la caché.

Transcript of Instalacion ambiente web am en linux red hat

Page 1: Instalacion ambiente web am en linux red hat

PREREQUISITOS INSTALACIÓN DEL CLIENTE ASSET MANAGER WEB EN LINUX

Instalar JDK

Si debemos desinstalar una versión anterior de JDK comando para desinstalar java Yum remove

java-1.8.0-openjdk-1.8.0.65-3.b17.el7.x86_64 o eliminar la carpeta de instalación directamente

Descargamos el archivo de JDK correspondiente de la página de Oracle en este caso jdk -8u65-linux-

x64.tar.gz y lo copiamos en el directorio /usr/java

Descomprimimos el archivo tar.gz con el comando tar zxvf jdk-8u65-linux-x64.tar.gz

Ejecutamos el comando java – version para verificar que el JDK quedó instalado.

Configurar variable JAVA_HOME que apunte a la carpeta de instalación del JDK

Configurar la variable LD_LIBRARY_PATH=/home/bsmucmdb/Software/Asset/AssetManager/x64

en el bash_profile para que Asset Manager encuentre las librerías .so

Igualmente configuramos la variable ORACLE_HOME para que apunte a la carpeta de instalación

del cliente Oracle y la añadimos al PATH y al LD_LIBRARY_PATH

En la ruta /etc/ld.so.conf.d con usuario root creamos el archivo AssetManager-x86_64.conf lo

editamos colocando la misma ruta que en la variable LD_LIBRARY_PATH y ejecutamos el comando

ldconfig --verbose para actualizar la caché.

Page 2: Instalacion ambiente web am en linux red hat

Configuración de JVM para Tomcat

Tenemos dos instalaciones de tomcat 1 para el Asset Manager y otra para el Asset Manager Web

Service.

Buscamos el archivo setenv.sh para editar los parámetros en este caso la ruta es /opt/tomcat -

Amwebservice/bin

Page 3: Instalacion ambiente web am en linux red hat

Con comando vi setenv.sh editamos los parámetros de JVM Para Asset Manager Web así:

JAVA_OPTS="$JAVA_OPTS -Djava.awt.headless=true -Xms2048M -Xmx2048M -XX:+UseTLAB -

XX:+UseParNewGC -XX:+UseConcMarkSweepGC -XX:SurvivorRatio=2 -XX:NewSize=256M -

XX:MaxNewSize=256m -XX:+UseBiasedLocking -server"

Copiar el archivo del servidor de la base de datos tnsnames.ora a la carpeta

$ORACLE_HOME/network/admin

INSTALACIÓN DEL CLIENTE ASSET MANAGER WEB EN LINUX

1. Copiamos instaladores a una carpeta dentro del sistema linux

Page 4: Instalacion ambiente web am en linux red hat

2. Descomprimimos el archivo .zip

3. Buscamos el archivo am-linux_UNICODE_9.60.13086_es.tgz lo dejamos fuera de la carpeta

Unix, en la carpeta de instalación.

4. Descomprimimos el archivo am-linux_UNICODE_9.60.13086_es.tgz

Vemos que el usuario con el que estamos renga los permisos para descomprimir, si no los tiene le

damos el comando: chmod 777 am-linux_UNICODE_9.60.13086_es.tgz y creamos un directorio con:

mkdir Asset.

A continuación pasamos el archivo am-linux_UNICODE_9.60.13086_es.tgz al directorio creado y le

damos el comando para descomprimir: tar xzvf am-linux_UNICODE_9.60.13086_es.tgz

Page 5: Instalacion ambiente web am en linux red hat

5. Editamos el archivo package.propierties que en esta instalación se encuentra en la ruta

/home/bsmucmdb/Software/Asset/AssetManager/websvc

Las propiedades que se encuentran en el archivo son las que vienen para una instalación

por defecto de Asset manager en Windows, para este caso cambiamos las propiedades

teniendo en cuenta que se está realizando una instalación en Linux Red Hat de 64 bits y

nos conectaremos a una base de datos Oracle 12C.

Con el comando Cat vemos las propiedades actuales del archivo así: cat package.properties

Con el comando: nano package.properties editamos las propiedades del archivo. Con las siguientes

propiedades:

Page 6: Instalacion ambiente web am en linux red hat

cambios en package.Properties

AssetManager.UserLogin=Admin

AssetManager.UserPwd=

DB.Engine= Oracle

DB.library.path=/home/bsmucmdb/Software/Asset/AssetManager/x64/

libaamapi96.so

arch=64

#Library.Extension=so

#Library.Prefix=lib

DB.datasource=ASSET

DB.login=Admin

DB.password=c:/temp/secret1.txt

DB.owner=Admin

Y queda:

# Possible values and their translations for the path to the dll/so library

Library.Architecture.Path=${arch}=32:bin,${arch}=x86:bin,${arch}=x64:x64,${arch}=64:x64

# the extension of the library files - "dll" for Windows, "so" for *nix

# this is set by the deploy shell script and included here only for reference purposes

#Library.Extension=so

# the prefix prepended to the library name (empty for windows, lib for *nix).

# this is set by the deploy shell script and included here only for reference purposes

#Library.Prefix=lib

# property names that should not be reported as not being changed if they are not present in this file

# the properties would normally be properties that configure a certain version of Asset Manager for

# proper functioning rather than customer preferences. Property names must be surrounded by

colons (:)

internalProperties=

# location of the ant task jars needed for the deployment script. Only relevant in the

# primary properties file. If you specify this setting on the command line you must prefix the

Page 7: Instalacion ambiente web am en linux red hat

# property name with "PRI." due to ant task library loading constraints.

# For example: -DPRI.ant.tasks.dir=lib

ant.tasks.dir=lib

# The name of the first file which stores the first part of PBKDF2 password. Make sure this file is

secure.

# Example: c:\\secret-share\\secret1.txt, or c:/secret-share/secret1.txt.

PBKDF2.Password.First.File=/home/bsmucmdb/Software/Asset/AssetManager/deploy/secret-

share/secret1.txt

# The name of the second file which stores the second part of PBKDF2 password. Make sure this file

is secure.

# Example: c:\\secret-share\\secret2.txt, or c:/secret-share/secret2.txt.

PBKDF2.Password.Second.File=/home/bsmucmdb/Software/Asset/AssetManager/deploy/secret -

share/secret2.txt

# Configurations for push adapter monitor

# Whether the monitor push adapter monitor is enabled

PushAdapter.Monitor.Enabled=false

# The UCMDB Server Host name

UCMDB.Server.Host=bpnt373bta.porvenir.net

# The UCMDB Server Port

UCMDB.Server.Port=8443

# The UCMDB Server log in User

UCMDB.Server.User=admin

# The UCMDB Server log in password

# The promptForPwd and encrypt parameters apply to this property,

# so this value may be overridden by a value input at deploy time and/or encrypted.

UCMDB.Server.Password=

Page 8: Instalacion ambiente web am en linux red hat

6. Editamos los parámetros del archivo package.Properties de Asset Manager Web Tier que

está en la ruta:

Archivo que por

defecto viene con los siguientes valores:

# The html string to display for counts that are not known (not yet counted and greater than the

# list paging size. Use {0} to place the paging size. The defaults display nothing.

# examples: "> {0}" results in "> 20", "{0}+" results in "20+", "??" results in "??"

Lists.Count.Unknown.Label=

# Open a new tab window for detail is editing status for linkedit, sublist, one2manylinkedit

Lists.DetailEditable.OpenNewTab=false

# Display a button that applies a filter without losing current selections in the list

Lists.Filter.Selections.Maintainable=false

# Default value of user preference for the maximum number of documents to show per page in a list

# The user can change this value themselves in the User Preferences screen, but this is the default.

Lists.Paging.Count.Maximum.Default=20

# List toolbar is to be displayed at the top or bottom. Recognized values are "both", "header" and

# "footer".

Lists.Toolbars.Display=both

# Default value of user preference to display the statistics combo box in lists.

# The user can change this value themselves in the User Preferences screen, but this is the default.

Lists.StatisticComboBox.Displayed=true

# Maximum number of documents to show child nodes in a tree list

Lists.Tree.ChildNode.Count.Maximum=200

# Remove the link name of remote field in list header

# Note: customized field label which end with brackets will be trimmed if this option is set to true,

# example: field label Asset(Computer) will be trimmed to Asset if this option is set to true.

Lists.RemoveLinkNameInHeader=false

# Comma-separated list of module to deactivate.

Page 9: Instalacion ambiente web am en linux red hat

# example : Cable,HelpDesk,SAM

Navigation.DisabledModules=Cable

#==================================================================== ======

=========================

# This section defines the type of deployment and password handling

#

# These properties are read from the primary properties file only, the one specified on the

# command line. Properties from other sections are combined with the properties from the secondary

# properties file (specified by properties.file2) to create a combination ear if

# combination.ear=true in the primary properties file.

#==========================================================================

=========================

# path to the webtier war that is to be directly modified for a war deployment and/or

# copied and modified for use in an ear deployment

war=../webtier/AssetManager.war

# the type of deployment(s) to perform. War deployments alter the war specified above. Ear

# deployments create a copy of the above war for modification and inclusion in the ear specified

# below

war.deployment=true

ear.deployment=false

#==========================================================================

=========================

# This section defines the deployment information needed for creating the ears

# for weblogic and websphere deployments

#==========================================================================

=========================

# the ear that is to be created during an ear deployment

ear=../weblogic/AssetManager.ear

# whether the created ear is to contain both the webtier and webservice (true) or not (false)

combination.ear=true

Page 10: Instalacion ambiente web am en linux red hat

# path to the webtier transformation properties file, used when combination.ear=true

properties.file2=../websvc/package.properties

# the context root to specify in the application.xml of the ear

context.root=AssetManager

# the application display name to specify in the application.xml of the ear

display.name=AssetManager

# the classpath to set in the manifest of the ear

manifest.classpath=

# additional files to place in the ear, separated by spaces

addl.files.root=..

addl.files=

# a space-delimited list of files to remove from the war that is placed within the ear - typically

# used for deployment on WebSphere 7

remove.war.files=

#==========================================================================

=========================

# This section contains Asset Manager settings that are less frequently modified

#==========================================================================

=========================

# Whether or not to show a confirmation screen before launching a script action

Actions.Scripts.Launch.Confirmation=false

# Whether to show budget alert messages. For CCS only.

BudgetAlert.Show=false

# Maximum number of items to display on a Business Home Page

BusinessHomePages.Items.Count.Maximum=6

# Maximum number of statistical breakdowns to display on a Business Home Page

BusinessHomePages.Statistics.Count.Maximum=10

# Currencies refresh interval in seconds (21600 seconds = 6 hours)

Cache.Currencies.Refresh. Interval=21600

# DbTables refresh interval in seconds (86400 seconds = 24 hours)

Cache.DbTables.Refresh.Interval=86400

Page 11: Instalacion ambiente web am en linux red hat

# Opened ItemizedList values refresh interval in seconds (1200 seconds = 20 minutes)

Cache.OpenedItemizedLists.Refresh.Interval=1200

# The idle time of cache of opened ItemizedList values (unit:seconds)

Cache.OpenedItemizedLists.timeToIdleSeconds=1200

# The live time of cache of opened ItemizedList values (unit:seconds)

Cache.OpenedItemizedLists.timeToLiveSeconds=1200

# Workflow refresh interval in seconds (86400 seconds = 24 hours)

Cache.Workflows.Refresh. Interval=86400

# Max number of categories (e.g. bars) to display on a chart

Charts.Categories.Count.Maximum=20

# Colors to be used in bars or pie segments when generating charts

Charts.General.Colors=\#4FC1E9;\#AC92EC;\#A0D468;\#5D9CEC;\#FC6E51;\#FFCE54;\#EC87C

0;\#CCD1D9;\#ED5565;\#48CFAD;\#F5F7FA;\#656D78

# General statistics chart height (pixels)

Charts.General.Height=500

# General statistics chart width (pixels)

Charts.General.Width=625

# Statistics chart height in Dashboards (pixels)

Charts.Dashboards.Height=500

# Statistics chart width in Dashboards (pixels)

Charts.Dashboards.Width=625

# Statistics chart height in Statistics screens (pixels)

Charts.StatisticsScreens.Height=600

# Statistics chart width in Statistics screens (pixels)

Charts.StatisticsScreens.Width=750

# Statistics chart height in Wizards (pixels)

Charts.Wizards.Height=600

# Statistics chart width in Wizards (pixels)

Charts.Wizards.Width=750

# Max number of items per dashboard

Dashboards.Items.Count.Maximum=6

# Whether or not to globally permit documents to be opened within the browser window

Page 12: Instalacion ambiente web am en linux red hat

Documents.Downloads.OpenInBrowser.AllowAll=false

# Which file types to allow being opened within the browser window. This value is only used

# if Documents.OpenInBrowser.AllowAll=false

Documents.Downloads.OpenInBrowser.AllowedFileTypes=txt|pdf|png|gif|jpg|jpeg

# Whether extjs charts will be enabled

Extjs.Charts.Enabled=true

# For color choosers, the color value is displayed in white for darker colors.

# This parameter determines the minimum darkness (0-1) at which the color value

# is displayed in white rather than black (0 is darkest, 1 is lightest).

Fields.ColorChooser.Font.White.ColorDarknessLevel=0.7

# Enable or disable full text search

FullTextSearch.Enabled=false

# Full text search server url

FullTextSearch.Server.URL=

# Show dashboard as welcome page

Welcome.ShowDashboard=false

#For canvas caption font

Workflows.Diagrams.Captions.Font=Arial

# Web service used for authentication

WebService.Service.Authentication=Core

# Dashboard service provider - Uses the amDashboardItem screen in the amDashboardItem table

WebService.Service.Dashboard=Administration

# Functional Domain Homepage object - Uses the amDashboardItem screen in the

amDashboardItem table

WebService.Object.Dashboard=Action

# DateAlarm service provider - Uses the amDateAlarm screen in the amDateAlarm table

WebService.Service.DateAlarm=Administration

# File upload/download service provider - Uses the amDocBlob screen in the amDocBlob table

WebService.Service.DocBlob=Administration

# Functional domain service provider - Uses the FuncDomainHomePage screen in the

amFuncDomain table

WebService.Service.FunctionalDomainHomePage=Core

Page 13: Instalacion ambiente web am en linux red hat

# Functional Domain Homepage object - Uses the FuncDomainHomePage screen in the

amFuncDomain table

WebService.Object.FunctionalDomainHomePage=FuncDomDisplay

# Functional domain service provider - Uses the amFuncDomain screen in the amFuncDomain table

WebService.Service.FunctionalDomain=Administration

# Mail service provider - Uses the amMail screen in the amMail table

WebService.Service.Mail=Administration

# Profile service provider - Uses the amMasterProfile screen in the amMasterProfile table

WebService.Service.Profile=Administration

# Read mail wizard service provider - Uses the sysCoreReadMsg wizard

WebService.Service.ReadMailWizard=Core

# Reports service provider - Uses the amReports screen in the amReports table

WebService.Service.Reports=Administration

# Workflow schema service provider

WebService.Service.WorkflowSchema=Administration

# Location of Global HTML Help index page

globalHelpUrl=

# An alternate or custom theme. The standard theme is "am"

alternateTheme=am-default

# The layout type to list-detail(Horizontal or Vertical), The default value is Horizontal

ListDetail.layout=Horizontal

#==========================================================================

=========================

# This section defines debugging values that should only be modified at the request of technical

# support personnel. Changing these values could have severe impact on performance!

#==========================================================================

=========================

# Whether additional debugging info should be displayed on all pages

Debug.Display.State=false

Page 14: Instalacion ambiente web am en linux red hat

# Whether the javascript source files should be the developer versions, where available

Debug.Javascript.Source=false

# Whether the constructed JSPs should be written to disk for debug purposes

Debug.JSP.WriteToDisk=false

# Path to which to write debugging JSPs, if enabled with Debug.JSP.WriteToDisk

Debug.JSP.Path=c:/jsp_out

#==========================================================================

=========================

# This section defines miscellaneous values that are needed for the deployment process and will

# likely never need to be edited.

# Note that passwords are not currently used by the webclient itself.

#==========================================================================

=========================

# message to display at the end of a war deployment

war.message=CAUTION\: the parameters just set in the web.xml may be overridden in the\n

AssetManager.xml (or corresponding file) if you are\n using tomcat as an application server\!

# message to display at the end of a ear deployment

#ear.message=

# property names that should not be reported as not being changed if they are not present in this file

# the properties would normally be properties that configure a certain version of Asset Manager for

# proper functioning rather than customer preferences. Property names must be surrounded by

colons (:)

internalProperties=:PowerButtons.Unsupported:Wizards.CommandButtons.Disabled:Fields.All.Refr

eshOnChange:

# location of the ant task jars needed for the deployment script. Only relevant in the

# primary properties file. If you specify this setting on the command line you must prefix the

# property name with "PRI." For example: -DPRI.ant.tasks.dir=lib

ant.tasks.dir=lib

helpUrl=/AssetManagerDoc/index.htm

Page 15: Instalacion ambiente web am en linux red hat

tenantUrl=/Administration/sysMTChangePrimaryTenant/wizard.jsf

# Shortcuts to New button

Accesskey.button.new=w

# Shortcuts to Delete button

Accesskey.button.delete=e

# Shortcuts to Cancel button

Accesskey.button.cancel=c

# Shortcuts to Modify button

Accesskey.button.modify=m

# Shortcuts to Duplicate button

Accesskey.button.duplicate=u

# Shortcuts to Save button

Accesskey.button.save=s

# Shortcuts to Yes button

Accesskey.button.yes=y

# If csrfguard filter is enabled. Enable it for security, disable it for performance.

org.owasp.csrfguard.Enabled=true

# The name of the first file which stores the first part of PBKDF2 password. Make sure this file is

secure.

# Example: c:\\secret-share\\secret1.txt, or c:/secret-share/secret1.txt.

PBKDF2.Password.First.File=

# The name of the second file which stores the second part of PBKDF2 password. Make sure this file

is secure.

# Example: c:\\secret-share\\secret2.txt, or c:/secret-share/secret2.txt.

PBKDF2.Password.Second.File=

# Delay mask display, default value is set to 3 seconds

maskMessageDelay=3

Page 16: Instalacion ambiente web am en linux red hat

# set the session timeout (in minutes)

sessionTimeout=30

# set the maximum file size when uploading (k/m/g)

# eg: 1m/1g/100k

uploadMaxFileSize=1m

Editamos los valores que haya que editar:

WebService.EndPoint.RS=http://localhost:8080/AssetManagerWebService/rs

WebService.Version=Asset Manager 9.60

FullTextSearch.Enabled=true

FullTextSearch.Server.URL=http://<hostname>.<domain>:<AssetManagerWebServicePort>/quicks

earch/search

PBKDF2.Password.First.File=c:/temp/secret1.txt

Documents.Downloads.OpenInBrowser.AllowedFileTypes=txt|pdf|png|gif|jpg|jpeg|xls|xlsx

uploadMaxFileSize=20m

7. Editamos los valores del quicksearch.properties que se encuentra en la carpeta de de

instalación / websvc y que por defecto trae los siguientes valores:

[bsmucmdb@VPLX36BTA websvc]$ cat quicksearch.properties

# File for setting the <env-entry> values found in the webservice's web.xml

#

# NOTE: Whitespace is not trimmed from the values specified here. Do not add whitespace after

the

# equals sign (=) or at the end of the line if you do not intend the whitespace to be part of

# the value!

#

# Values not specified in this file or on the command line are not changed in the web.xml.

# Values specified in this file that have no value (eg. Name=) delete the env-entry-value of

# the corresponding env-entry in the web.xml

Page 17: Instalacion ambiente web am en linux red hat

#=======================================================================

============================

# This section contains settings normally or frequently modified for a particular installation.

# Less frequently modified settings can be found further down in this file.

#=======================================================================

============================

# Asset Manager user login to be used by the WebService

AssetManager.UserLogin=Admin

# Asset Manager user password to be used by the WebService

AssetManager.UserPwd=

# The database engine that is used by this installation of Asset Manager. Can be one of Generic,

# MSSQL, Oracle or DB/2. If Generic is specified, the connection string used is that specified by

# the datasource (DB.datasource)

DB.engine=MSSQL

# The name of the database (e.g. 16.157.134.163/myAmDb or AMDemo96en)

DB.datasource=AMDemo96en

# The database engine login id

DB.login=itam

# The password corresponding to this login. The promptForPwd and encrypt parameters apply

to this

# property, so this value may be overridden by a value input at deploy time and/or encrypted.

DB.password=password

# Whether the DB cache is enabled

DB.cache.enabled=true

# The cache directory

DB.cache.dir=/tmp

# The cache size in KB (1048576 = 1GB)

DB.cache.size=1048576

# The owner of the DB

DB.owner=

# The path to the aamapiXX library. The variable @{Library.Architecture.Path}@ can be used

and will be

Page 18: Instalacion ambiente web am en linux red hat

# automatically replaced by either "bin" or "x64" depending on which version of deployment is

# specified (32 bit or 64 bit). The AssetManager.InstallPath and Library.Extension parameters

# are passed in from the deployment script if they can be determined. If the path to the library

# is different from that found in the installation directory this setting MUST be modified (though

# if desired the @{Library.Architecture.Path}@ variable can still be used in the value.

# e.g. DB.library.path=/opt/lib/aamapiXX.so or DB.library.path=D:/libs/aamapiXX.dll

DB.library.path=${AssetManager.InstallPath}/@{Library.Architecture.Path}@/${Library.Prefix}aa

mapi${AssetManager.Version.Short}.${Library.Extension}

DB.expand.typedlinks=|amDocument|amWfWorkItem|amHistory|amReconcProposal

# The following two options are newly added and the useage should be documented

DB.auth.type=

DB.ws.address=

DB.passphrase=

# Set the fetching size for each query result

DB.FetchingArraySize=101

# Comma-separated list of Web Services to load on startup

# example : Head/Administration, Head/* , R50/*

WebService.LoadOnStartup=Head/*

# Full text record search dll path

AssetManager.ApiPath=${AssetManager. InstallPath}/@{Library.Architecture.Path}@/${Library.

Prefix}aamapi${AssetManager.Version.Short}.${Library.Extension}

# Full text record search index directory

AssetManager.RecordSearchIndexDir=c:/index

# Asset Manager service tag name for full text search

AssetManager.ServiceTag=Head

# Comma-separated list of modules to deactivate, example : Cable,HelpDesk,SAM

AssetManager.DisabledModules=Cable

# Full text indexing scheduler configuration

AssetManager.CronConfig=0 0 1 * * ?

Page 19: Instalacion ambiente web am en linux red hat

# Max number of sections displayed in a single search result page

AssetManager.TopTreeNumber=10

# Max number of records under a single section

AssetManager.TreeRecordsNumber=100

# Max number of indexed results

AssetManager.IndexRsNumber=5000

# Lightweight SSO

LWSSO.domain=asiapacific.hpqcorp.net

LWSSO.userNameHeaderName=SM_USER

LWSSO.initString=lwsso-shared-encryption-key

#=======================================================================

============================

# This section defines the type of deployment and password handling

#

# These properties are read from the primary properties file only, the one specified on the

# command line. Properties from other sections are combined with the properties from the

secondary

# properties file (specified by properties.file2) to create a combination ear if

# combination.ear=true in the primary properties file.

#=======================================================================

============================

# path to the webservice war that is to be directly modified for a war deployment and/or

# copied and modified for use in an ear deployment

war=../websvc/quicksearch.war

# the type of deployment(s) to perform. War deployments alter the war specified above. Ear

# deployments create a copy of the above war for modification and inclusion in the ear specified

# below

war.deployment=true

ear.deployment=false

# whether to ask for passwords during the deployment process.

Page 20: Instalacion ambiente web am en linux red hat

# setting to true will cause any value provided for a password field in this file or on the command

# line to be ignored, and you will be prompted to provide the value.

promptForPwd=true

#=======================================================================

============================

# This section defines the deployment information needed for creating the ears

# for weblogic and websphere deployments

#=======================================================================

============================

# the ear that is to be created during an ear deployment

ear=../weblogic/quicksearch.ear

# whether the created ear is to contain both the webtier and webservice (true) or not (false)

combination.ear=false

# path to the webtier transformation properties file, used when combination.ear=true

properties.file2=../webtier/package.properties

# the context root to specify in the application.xml of the ear

context.root=quicksearch

# the application display name to specify in the application.xml of the ear

display.name=QuickSearch

# the classpath to set in the manifest of the ear

manifest.classpath=/am-jni-${AssetManager.Version.Short }.jar /am-constants-

${AssetManager.Version.Short}.jar

# additional files to place in the ear, separated by spaces

addl.files.root=..

addl.files=@{Library.Architecture.Path}@/${Library.Prefix}aamapi${AssetManager.Version.Shor

t}.${Library.Extension}

@{Library.Architecture.Path}@/${Library.Prefix}amjni${AssetManager.Version.Short}.${Library.

Extension} websvc/lib/am-constants-${AssetManager.Version.Short}.jar websvc/lib/am-jni-

${AssetManager.Version.Short}.jar

Page 21: Instalacion ambiente web am en linux red hat

#=======================================================================

============================

# This section contains Asset Manager settings that are less frequently modified

#=======================================================================

============================

# Asset Manager Jaas configuration file

acws.jaas.config.location=

#=======================================================================

============================

# This section defines miscellaneous values that are needed for the deployment process and will

# likely never need to be edited.

#=======================================================================

============================

# message to display at the end of a war deployment

war.message=CAUTION: the parameters just set in the web.xml may be overridden in the\n

AssetManagerWebService.xml (or corresponding file) if you are\n using tomcat as an

application server!

# message to display at the end of a ear deployment

#ear.message=

# property names that specify passwords.

# these properties will be dealt with according to the other values in this section and if

# the promptForPwd property is set to true, a prompt for input of all of these fields will be

# generated. Property names must be surrounded by colons (:)

pwdEntries=:AssetManager.UserPwd:DB.password:

# DB name connection property to set, constructed from the other properties given above

dbNameProperty=AssetManager.DB.Name

# the connection string pattern for all but the Generic db engine

# possible components are listed in the first section of this file:

# @DB.cache.enabled@

# @DB.cache.dir@

# @DB.cache.size@

# @DB.datasource@

Page 22: Instalacion ambiente web am en linux red hat

# @DB.engine@

# @DB.library.path@

# @DB.login@

# @DB.owner@

# @DB.password@

# @DB.ws.address@

# @DB.auth.type@

# @DB.passphrase@

dbConnectionPattern=[@DB.engine@;@DB.datasource@;@DB.auth.type@;@DB.ws.address

@;@DB.passphrase@;@DB.login@;@DB.password@;@DB.cache.enabled@;@DB.cache.dir

@;@DB.cache.size@;@DB.owner@AmApiDll='@DB.library.path@';ExpandTypedLinks='@DB.

expand.typedlinks@';[email protected]@]

# names of tokens in the connection pattern that are optional and must not be included if a value

# is not provided. Token names must be surrounded by colons (:)

dbConnectionPattern.optional.token=DB.owner

# string(s) to place before and/or after an optional parameter that is included in the connection

string

dbConnectionPattern.optional.token.prefix=Owner=

dbConnectionPattern.optional.token.suffix=;

# The short version number used in various files and settings

AssetManager.Version.Short=96

# The architecture of the deployment targetted. Valid value are:

# 32 or x86 for 32bit architecture, and

# 64 or x64 for 64bit architecture

arch=32

# Possible values and their translations for the path to the dll/so library

Library.Architecture.Path=${arch}=32:bin,${arch}=x86:bin,${arch}=x64:x64,${arch}=64:x64

# the extension of the library files - "dll" for Windows, "so" for Linux/Unix

# this is set by the deploy shell script and included here only for reference purposes

Page 23: Instalacion ambiente web am en linux red hat

#Library.Extension=dll

# the prefix prepended to the library name (empty for windows, "lib" for Linux/Unix).

# this is set by the deploy shell script and included here only for reference purposes

Library.Prefix=

# property names that should not be reported as not being changed if they are not present in this

file

# the properties would normally be properties that configure a certain version of Asset Manager

for

# proper functioning rather than customer preferences. Property names must be surrounded by

colons (:)

internalProperties=

# location of the ant task jars needed for the deployment script. Only relevant in the

# primary properties file. If you specify this setting on the command line you must prefix the

# property name with "PRI." due to ant task library loading constraints.

# For example: -DPRI.ant.tasks.dir=lib

ant.tasks.dir=lib

# The name of the first file which stores the first part of PBKDF2 password. Make sure this file is

secure.

# Example: c:\\secret-share\\secret1.txt, or c:/secret-share/secret1.txt.

PBKDF2.Password.First.File=

# The name of the second file which stores the second part of PBKDF2 password. Make sure

this file is secure.

# Example: c:\\secret-share\\secret2.txt, or c:/secret-share/secret2.txt.

PBKDF2.Password.Second.File=

[bsmucmdb@VPLX36BTA websvc]$ nano quicksearch.properties

GNU nano 2.3.1 File: quicksearch.properties

Modified

# File for setting the <env-entry> values found in the webservice's web.xml

#

# NOTE: Whitespace is not trimmed from the values specified here. Do not add whitespace after

the

Page 24: Instalacion ambiente web am en linux red hat

# equals sign (=) or at the end of the line if you do not intend the whitespace to be part of

# the value!

#

# Values not specified in this file or on the command line are not changed in the web.xml.

# Values specified in this file that have no value (eg. Name=) delete the env-entry-value of

# the corresponding env-entry in the web.xml

#=======================================================================

============================

# This section contains settings normally or frequently modified for a particular installation.

# Less frequently modified settings can be found further down in this file.

#=======================================================================

============================

# Asset Manager user login to be used by the WebService

AssetManager.UserLogin=Admin

# Asset Manager user password to be used by the WebService

AssetManager.UserPwd=

# The database engine that is used by this installation of Asset Manager. Can be one of Generic,

# MSSQL, Oracle or DB/2. If Generic is specified, the connection string used is that specified by

# the datasource (DB.datasource)

DB.engine=Oracle

# The name of the database (e.g. 16.157.134.163/myAmDb or AMDemo96en)

DB.datasource=AMDemo96en

# The database engine login id

DB.login=itam

# The password corresponding to this login. The promptForPwd and encrypt parameters apply

to this

# property, so this value may be overridden by a value input at deploy time and/or encrypted.

DB.password=password

# Whether the DB cache is enabled

DB.cache.enabled=true

Page 25: Instalacion ambiente web am en linux red hat

# The cache directory

DB.cache.dir=/tmp

# The cache size in KB (1048576 = 1GB)

DB.cache.size=1048576

# The owner of the DB

DB.owner=

En este caso editamos algunos valores así:

LWSSO.domain=http://localhost:8080/AssetManagerWebService

PBKDF2.Password.Second.File=/home/bsmucmdb/Software/Asset/secret1.txt

PBKDF2.Password.First.File=/home/bsmucmdb/Software/Asset/secret1.txt

AssetManager.UserLogin=Admin

AssetManager.UserPwd=

DB.Engine= Oracle

DB.library.path=/home/bsmucmdb/Software/Asset/AssetManager/x64/

libaamapi96.so

arch=64

Library.Extension=so

Library.Prefix=lib

DB.datasource=ASSET

DB.login=Admin

DB.password=

DB.owner=Admin

# The UCMDB Server Host name

UCMDB.Server.Host=bpnt373bta.porvenir.net

# The UCMDB Server Port

UCMDB.Server.Port=8443

# The UCMDB Server log in User

UCMDB.Server.User=admin

# The UCMDB Server log in password

# The promptForPwd and encrypt parameters apply to this property,

# so this value may be overridden by a value input at deploy time and/or encrypted.

Page 26: Instalacion ambiente web am en linux red hat

UCMDB.Server.Password=

8. Generamos los archivos de claves ejecutando el archivo generate-password.sh que se

encuentran en la ruta /AssetManager/deploy

Con comando sh ejecutamos el archivo.sh

Archivo tools.jar

/home/bsmucmdb/Software/jdk1.8.0_121/lib

Find type f –name tools.jar

Averiguamos cuál es la ruta de instalación de JDK con el comando: sudo update-alternatives --config

java y para saber la versión de java instalada usamos el comando: java –version

JAVA_HOME=/usr/java/jdk1.8.0_65

9. Editamos la variable bash de JAVA_HOME poniendo la ruta de instalación de JDK

Comando para editar la variable de entorno Bash: vi ~/.bash_profile

Page 27: Instalacion ambiente web am en linux red hat

Editamos dando i

Salimos guardando cambios con :x

Aplicamos los cambios realizados con el comando source ~/.bash_profile

Vemos como quedó la variable de entorno con el comando echo $JAVA_HOME

Ahora añadimos la variable JAVA_HOME a las variables de entorno con el comando sudo vi

etc/environment

Y ejecutamos ./studio.sh para lanzar el programa

10. Hacemos el despliegue

sh deploy.sh -ws8

/home/bsmucmdb/Software/Asset/AssetManager/websvc/package.properties

11. Borrar archivo Catalina de tomcat: rm -rf Catalina

Y borrar los logs de tomcat en la ruta opt/tomcat/logs y ejecutamos rm -rf *

12. Copiar archivos.war al webapps del tomcat con el comando: cp <archive.war>

/opt/tomcat/webapps

Page 28: Instalacion ambiente web am en linux red hat

Y verificamos así:

13. Subimos servicios del tomcat ejecutando los archivos catalina.sh de cada una de las dos

instancias instaladas una para Asset Manager Web Tier y otra para Asset Manager web

Service

Page 29: Instalacion ambiente web am en linux red hat

Archivo amdb.ono