Endeca ecastore exists - Failed to create database eacstore while running Initialise Services


Caused by: java.sql.SQLException: Failed to create database '/u01/app/endeca/PlatformServices/workspace/state/eacstore', see the next exception for details.
    at org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(Unknown Source)
    at org.apache.derby.impl.jdbc.SQLExceptionFactory40.wrapArgsForTransportAcrossDRDA(Unknown Source)
    ... 54 more
Caused by: java.sql.SQLException: The database directory '/u01/app/endeca/PlatformServices/workspace/state/eacstore' exists. However, it does not contain the expected 'service.properties' file. Perhaps Derby was brought down in the middle of creating this database. You may want to delete this directory and try creating the database again.
    at org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(Unknown Source)
    at org.apache.derby.impl.jdbc.SQLExceptionFactory40.wrapArgsForTransportAcrossDRDA(Unknown Source)
    at org.apache.derby.impl.jdbc.SQLExceptionFactory40.getSQLException(Unknown Source)
    at org.apache.derby.impl.jdbc.Util.generateCsSQLException(Unknown Source)
    at org.apache.derby.impl.jdbc.TransactionResourceImpl.wrapInSQLException(Unknown Source)
    at org.apache.derby.impl.jdbc.TransactionResourceImpl.handleException(Unknown Source)
    at org.apache.derby.impl.jdbc.EmbedConnection.handleException(Unknown Source)
    ... 51 more
Caused by: ERROR XBM0A: The database directory '/u01/app/endeca/PlatformServices/workspace/state/eacstore' exists. However, it does not contain the expected 'service.properties' file. Perhaps Derby was brought down in the middle of creating this database. You may want to delete this directory and try creating the database again.
    at org.apache.derby.iapi.error.StandardException.newException(Unknown Source)
    at org.apache.derby.impl.services.monitor.StorageFactoryService.vetService(Unknown Source)
    at org.apache.derby.impl.services.monitor.StorageFactoryService.access$600(Unknown Source)
    at org.apache.derby.impl.services.monitor.StorageFactoryService$9.run(Unknown Source)
    at java.security.AccessController.doPrivileged(Native Method)
    at org.apache.derby.impl.services.monitor.StorageFactoryService.createServiceRoot(Unknown Source)
    at org.apache.derby.impl.services.monitor.BaseMonitor.bootService(Unknown Source)
    at org.apache.derby.impl.services.monitor.BaseMonitor.createPersistentService(Unknown Source)
    at org.apache.derby.iapi.services.monitor.Monitor.createPersistentService(Unknown Source)


Solution

If you get the exception like above,then navigate to the folder /endeca/PlatformServices/workspace/state , take a backup of the folder eacstore,then delete the folder eacstore,once the folder is deleted,
stop the Platform Service (shutdown.sh - /endeca/PlatformServices/6.1.3/tools/server/bin),then
start the Platform Service (startup.sh -  /endeca/PlatformServices/6.1.3/tools/server/bin). Now navigate to the folder where the endeca application is deployed and initialize the service with --force option or delete the current applications which is already provisioned and configure the cim to deploy your Endeca Application and try to initialize ,this time ideally this issue wont come.

See how to delete the Provisioned Application and re-initialize 

practice set of questions and answers to test your knowledge

Application has three different email handlers:one for the testing ,one for the internal mail and one for the external.Content Administration  uses the internal mail handler to send the asset update notification to the managers,which of the following directories would be the best place to configure SMTPEmail.emailHandlerHostName?

a: atgdir/home/localconfig
b: atdir/home/server/yourserver/localconfig
c: atdir/yourapp/config
d: atdir/yourapp/liveconfig
e: atdir/yourapp.versioned/config
f: atgdir/yourapp.versioned/live config

Answer : b e and f

Use the -Standalone option when assembling your ATG application to allow you to :

a: Run the application without using a separate application server such as Weblogic or JBoss
b: Run a server type with only single instance such as the CA server.
c: Deploy EJBs and Web Applications into seperate EARs
d: Run the application on a host on which ATG is  not installed

Answer : d

There should be a node manager for every:

a: Domain
b: Site
c: Server
d: Machine

Answer : d

Every host in the site need to have installed (pick all that apply):

a: The application server(such as weblogic)
b: The atg platform
c: java
d: A database server
e: A web server

Answer :a and c

which of the following can be imporoved by using application clustering in a production environment (choose all that apply)

a: Performance
b: Reliability
c: Security
d: Customer Experience
e: Data Integrity


Answer :a b and d

Which of the following asset types can Content Administration deploy(choose all that apply)

a: Configuration files
b: Java classes
c: Java source files
d: Site content
e: Images
f: Setup scripts


Answer :a d and e
 

setting nohup in linux for logging and start admin console without startup script

Generally the Application Server Startup logs which has the information of ATG Modules,ATG Classpath,ATG Version etc running under Managed Weblogic Server will not be logged to the logs folder under the ATG Application Server log path (ATG_HOME/server/ATGProduction/logs).Ideally the Application Server would be logging this to the console which includes the output from the stdout and stderr,but as a best practice you may need to manually capture these console logs to some file,otherwise it might loose once the console buffer is filled,its also very difficult to read and thereby troubleshoot an issue.

Also in Unix if you run a startup script of an Application Server, The same Server will shutdown if you accidentaly  close the window or somehow the connection is lost to that session. So inorder to address the above issues you can try the below steps

I have taken a typical example of Weblogic Application Server.You may change the based on your Application Server startup scripts.

1. ./startWeblogic.sh ATGProductionStartup.log 2>&1

Here ATGProductionStartup.log  is the filename where the logs will be written
and 2>&1  will do the redirect from stderr to stdout so the file can capture both the logs.

2.  nohup  ./startWeblogic.sh &

This will create a file nohup.out in the same folder and the logs are written in this file , you may press ctrl+c , and use
tail -100f nohup.out to see the server console logs getting genrated dynamically.

Also if your console requires a username and password you need to do some modifications to the configurations

copy the folder security from domain_home/servers/AdminServer/security folder to a temporary location,modify the boot.properties file,change the value of username and password from encrypted values to non encrypted text string(eg->
username=weblogic
password=weblogic123),and paste the entire security folder  to your
domain_home/servers/ATGProduction folder.Restart your server.Repeat the steps for other managed Weblogic Servers.

Endeca application already exists with the name CRS use --force option

*** info    Thu Jun 06 18:06:31 IST 2013    1370522191743    atg.cim.task.ant.utility.AntLogger    Total time: 0 seconds
**** info    Thu Jun 06 18:06:33 IST 2013    1370522193801    atg.cim.productconfig.endeca.EndecaInitializeTask    Intitializing Endeca Application
**** info    Thu Jun 06 18:06:33 IST 2013    1370522193824    atg.cim.task.ant.utility.AntLogger   
**** info    Thu Jun 06 18:06:33 IST 2013    1370522193824    atg.cim.task.ant.utility.AntLogger    edeca-init.nonwindows:
**** info    Thu Jun 06 18:06:33 IST 2013    1370522193831    atg.cim.task.ant.utility.AntLogger         [exec] Initializing Endeca App
**** info    Thu Jun 06 18:06:36 IST 2013    1370522196128    atg.cim.task.ant.utility.AntLogger         [exec] [06.06.13 18:06:36] SEVERE: An application already exists with the name, "CRS". Please use the '--force' option if you want to replace all existing configuration.
**** info    Thu Jun 06 18:06:36 IST 2013    1370522196156    atg.cim.task.ant.utility.AntLogger   
**** info    Thu Jun 06 18:06:36 IST 2013    1370522196156    atg.cim.task.ant.utility.AntLogger    BUILD FAILED
**** info    Thu Jun 06 18:06:36 IST 2013    1370522196156    atg.cim.task.ant.utility.AntLogger    /home/atgint/ATG/ATG10.2/CIM/plugins/Base/ant/cim-ant.xml:871: exec returned: 1
**** info    Thu Jun 06 18:06:36 IST 2013    1370522196156    atg.cim.task.ant.utility.AntLogger   
**** info    Thu Jun 06 18:06:36 IST 2013    1370522196156    atg.cim.task.ant.utility.AntLogger    Total time: 2 seconds
**** Error    Thu Jun 06 18:06:36 IST 2013    1370522196157    atg.cim.productconfig.endeca.EndecaInitializeTask    ---    /home/atgint/ATG/ATG10.2/CIM/plugins/Base/ant/cim-ant.xml:871: exec returned: 1
**** Error    Thu Jun 06 18:06:36 IST 2013    1370522196157 

Solution 
  
This error basically occurs if we already have a CRS Endeca Provisioned  in your Application.

To know whether you have already an Application Provisioned use the command

eaccmd.sh list-apps/.bat , this will give you a list of applications Provisioned. 

Next use the command  ./runcommand.sh --remove-app/.bat . This will remove all your Provisioned application.Once this is done you can use the above command again to see it actually removed your Provisioned Applications. Ideally this should not list anything.

Next Modify your initialize_rs_feeds.sh/.bat file and remove eveerything from the line below the  word "echo creating fresh record stores " , this will basically delete the old records from the schemas which is created earlier at the time of Provisioning your Endeca Application.

Lastly remove your CRS Endeca Application,For that Remove the Folder CRS which will be usually located under C:\Endeca\Apps\CRS in Windows  or /usr/local/Endeca/Apps/CRS  in Linux Environments.

Now go back to your CIM configuration,Redeploy your CRS Endeca to the Production Server and do the Initialization, Hopefully you will not see the above error this time,once the Initialization has done successfully you can proceed with Indexing . Paste your Logs if you are encountering any issues.

Configure Endeca in Linux with Multiple Instances

While integrating ATG and Endeca in Linux with Multiple Instances ,we need to be really careful of the ports ATG, weblogic server and Endeca Services use.

Here are few tips on the how can we configure ATG,Weblogic and Endeca Application without conflicting ports.

First of all lets start with the Compatibility Matrix for ATG10.2.

ATG Compatibility
CRS10.2
CRS10.2 Mobile Web Application

Endeca Compatibility
Oracle Endeca Commerce 3.1.2
Oracle Endeca MDEX Engine 6.4.1
Oracle Endeca Platform Services 6.1.3
Oracle Endeca Tools and Frameworks with Experience Manager 3.1.2
Oracle Endeca Content Acquisition System 3.1.2

Application Server Compatibility
Weblogic 10.3.5 or Weblogic Server 10.3.6 or JBoss 5.1.2 EAP
Weblogic Server ports

ATG Configuring Admin Server, select 7003 as Admin port
In the WEBLOGIC ONLINE PORT BINDING menu, select [C] Choose Custom Port Binding.

In the CHOOSE CUSTOM WEBLOGIC ONLINE PORT BINDING menu, select [3] ports-02: http port is 7203 for Production and select [4] ports-03:http port is 7303 for Publishing.

Endeca Ports
MDEX Port: 15001
DGRAPH Port:15001, AGRAPH Port: 15003
WORKBENCH Port:8282
EAC Port: 8889
JCD Port:: 8098
CAS server Port: 8501

ATG Questions and Answers for ATG Commerce Implementation Certification

1. The design of the OrderFullfiller and the HardgoodFullfiller used the  
    ClientLockManager to -------------

A. Prevent one component from processing messages for two different orders 
    at  same time
B. Send messages to all the components that the order is being 
    modified.Components 
C. Helping in caching the order for better performance
D. Lock the order so client cannot modify his order after it is submitted
E.  Their Item Descriptors has cache mode property set to locked

Answer: A

Explanation:

The design of the OrderFullfiller and the HardgoodFullfiller uses the ClientLockManager to prevent one component from processing messages for two different orders at the same time.

2. Inorder to ensure versioning integrity,a deploying project obtains exclusive  
    locks on its assets when deployment starts.what is the effect of these locks?

A. Until a project's assets locks are released ,other projects that share those  
    assets cannot add the asset to the project
B. Until a project's asset locks are released,other projects that share those  
   assets cannot be in author mode.
C. Until a project's asset locks are released,other projects that share those 
    assets cannot deploy
D.Until a project's assets locks are released ,other projects that share those 
   assets cannot revert the assets to the project

Answer:C

Please find the full set of questions and answers in below link

implementation-developer-essentials
Related Posts Plugin for WordPress, Blogger...