biemond / biemond-oradb

Puppet Oracle Database Module
Apache License 2.0
59 stars 113 forks source link

database.pp relies on LISTENERS entry in response file but doesn't manage listeners.ora #159

Closed wfsaxton closed 7 years ago

wfsaxton commented 7 years ago

When creating a database, using the database.pp module, the module creates database_testDb_Create.rsp from a template. The template has the entry:

#-----------------------------------------------------------------------------
# Name          : listeners
# Datatype      : String
# Description   : Specifies list of listeners to register the database with.
#               By default the database is configured for all the listeners specified in the
#               $ORACLE_HOME/network/admin/listener.ora
# Valid values  : The list should be comma separated like "listener1,listener2".
# Mandatory     : NO
#-----------------------------------------------------------------------------
listeners=LISTENER

Since this module does not create/manage the "listener.ora" file, the puppet module run fails when it attempts to run the response file. When I run the response file manually, it outputs this error:

[oracle@generic ~]$  /oracle/product/12.2/db/bin/dbca -silent -createDatabase -responseFile /var/tmp/database_testDb_Create
.rsp
[FATAL] [DBT-07505] Selected listener (LISTENER) does not exist.
   ACTION: Specify an existing listener.

How exactly is this module supposed to work if it can't get the listener information?

I do have a listener running, using the following code, but it doesn't seem to manage listeners.ora either:

db_listener{ 'startlistener':
      ensure          => 'running',  # running|start|abort|stop
      oracle_base_dir => '/oracle',
      oracle_home_dir => '/oracle/product/12.2/db',
      os_user         => 'oracle',
      listener_name   => 'listener' # which is the default and optional
  }
biemond commented 7 years ago

really that fails, it was working for me. I will re-test the 12.2 version. I see in 11.2 & 12.1 I don't set this parameter.

I will check this and push a new version

Thanks for reporting this

wfsaxton commented 7 years ago

I'm running this on Oracle Linux 7 if that matters.

biemond commented 7 years ago

it works now, can you also test this https://github.com/biemond/biemond-oradb/tree/puppet4_3_data

thanks

wfsaxton commented 7 years ago

Tested and it works. Thanks for the quick fix.

biemond commented 7 years ago

perfect , I will push a new version.

thanks again