yuuvis® RAD Q&A

0 votes
by (140 points)

Dear OS Team,

I am currently trying to install yuuvis (core-service, designer, elasticsearch, service-manager, rendition - in that order) using a command line script that I wrote. I have verified that the single steps work by copying them out of the script into PS one by one. However when running the script all at once I come accross the following errors and DMS does not start/register to the service manager.

services.log
....
....
d: ID-DBYUUVIS-1611044449322-0-2). On delivery attempt: 16 caught: java.io.IOException: dms service is not available, cowardly refusing to continue with operations
inboxservice.7231         : 2021-01-19 00:25:04.903  INFO 684 --- [      Thread-23] c.o.services.inbox.service.InboxService  : Connection to core-service could not be established - try again ...
inboxservice.7231         : 2021-01-19 00:25:06.903  INFO 684 --- [      Thread-23] c.o.services.inbox.service.InboxService  : Connection to core-service could not be established - try again ...
structureservice.7461     : 2021-01-19 09:25:08.308 WARN  Trying to reconnect to 127.0.0.1 using try 1 of 20.
structureservice.7461     : 2021-01-19 09:25:08.308 INFO  Message state is UP: Stomp messaging connect done. Subscribed to /topic/redServerChanged
inboxservice.7231         : 2021-01-19 00:25:08.965  INFO 684 --- [      Thread-23] c.o.services.inbox.service.InboxService  : Connection to core-service could not be established - try again ...
structureservice.7461     : 2021-01-19 09:25:10.684 WARN  Unable to retrieve instances for appId: DMS
structureservice.7461     : 2021-01-19 09:25:10.684 ERROR Error during health for component dms : {}
inboxservice.7231         : 2021-01-19 00:25:10.965  INFO 684 --- [      Thread-23] c.o.services.inbox.service.InboxService  : Connection to core-service could not be established - try again ...
inboxservice.7231         : 2021-01-19 00:25:12.965  INFO 684 --- [      Thread-23] c.o.services.inbox.service.InboxService  : Connection to core-service could not be established - try again ...
indexservice.7291         : 2021-01-19 00:25:14.154  INFO 4304 --- [timer://runOnce] c.os.services.index.service.EcmService   : waiting for dms service
indexservice.7291         : 2021-01-19 00:25:14.154  WARN 4304 --- [timer://runOnce] o.a.camel.processor.DefaultErrorHandler  : Failed delivery for (MessageId: ID-DBYUUVIS-1611044449322-0-1 on ExchangeI
d: ID-DBYUUVIS-1611044449322-0-2). On delivery attempt: 17 caught: java.io.IOException: dms service is not available, cowardly refusing to continue with operations
inboxservice.7231         : 2021-01-19 00:25:14.966  INFO 684 --- [      Thread-23] c.o.services.inbox.service.InboxService  : Connection to core-service could not be established - try again ...
inboxservice.7231         : 2021-01-19 00:25:16.967  INFO 684 --- [      Thread-23] c.o.services.inbox.service.InboxService  : Connection to core-service could not be established - try again ...
inboxservice.7231         : 2021-01-19 00:25:18.982  INFO 684 --- [      Thread-23] c.o.services.inbox.service.InboxService  : Connection to core-service could not be established - try again ...
inboxservice.7231         : 2021-01-19 00:25:20.982  INFO 684 --- [      Thread-23] c.o.services.inbox.service.InboxService  : Connection to core-service could not be established - try again ...
inboxservice.7231         : 2021-01-19 00:25:22.998  INFO 684 --- [      Thread-23] c.o.services.inbox.service.InboxService  : Connection to core-service could not be established - try again ...
application.ear.failed

"{
    \"WFLYCTL0412: Required services that are not installed:\" => [\"jboss.naming.context.java.jboss.DefaultJMSConnectionFactory\"],
    \"WFLYCTL0180: Services with missing/unavailable dependencies\" => [
        \"jboss.naming.context.java.module.application.\\\"dataaccess.sar\\\".DefaultJMSConnectionFactory is missing [jboss.naming.context.java.jboss.DefaultJMSConnectionFactory]\",
        \"jboss.naming.context.java.module.application.\\\"rendition.sar\\\".DefaultJMSConnectionFactory is missing [jboss.naming.context.java.jboss.DefaultJMSConnectionFactory]\",
        \"jboss.naming.context.java.module.application.jasee-ejb.DefaultJMSConnectionFactory is missing [jboss.naming.context.java.jboss.DefaultJMSConnectionFactory]\",
        \"jboss.naming.context.java.module.application.\\\"depository.sar\\\".DefaultJMSConnectionFactory is missing [jboss.naming.context.java.jboss.DefaultJMSConnectionFactory]\",
        \"jboss.naming.context.java.module.application.\\\"ecm.sar\\\".DefaultJMSConnectionFactory is missing [jboss.naming.context.java.jboss.DefaultJMSConnectionFactory]\",
        \"jboss.naming.context.java.module.application.\\\"fulltext.sar\\\".DefaultJMSConnectionFactory is missing [jboss.naming.context.java.jboss.DefaultJMSConnectionFactory]\",
        \"jboss.naming.context.java.module.application.bpm-ejb.DefaultJMSConnectionFactory is missing [jboss.naming.context.java.jboss.DefaultJMSConnectionFactory]\",
        \"jboss.naming.context.java.module.application.core-ejb.DefaultJMSConnectionFactory is missing [jboss.naming.context.java.jboss.DefaultJMSConnectionFactory]\",
        \"jboss.naming.context.java.module.application.\\\"repository.sar\\\".DefaultJMSConnectionFactory is missing [jboss.naming.context.java.jboss.DefaultJMSConnectionFactory]\",
        \"jboss.naming.context.java.comp.application.jasee-ejb.JndiContextBinderEjb.DefaultJMSConnectionFactory is missing [jboss.naming.context.java.jboss.DefaultJMSConnectionFactory]\",
        \"jboss.naming.context.java.module.application.\\\"jasee.sar\\\".DefaultJMSConnectionFactory is missing [jboss.naming.context.java.jboss.DefaultJMSConnectionFactory]\",
        \"jboss.naming.context.java.comp.application.jasee-ejb.TransactedInvocationEjb.DefaultJMSConnectionFactory is missing [jboss.naming.context.java.jboss.DefaultJMSConnectionFactory]\",
        \"jboss.naming.context.java.module.application.\\\"messaging.sar\\\".DefaultJMSConnectionFactory is missing [jboss.naming.context.java.jboss.DefaultJMSConnectionFactory]\",
        \"jboss.naming.context.java.module.application.\\\"jasmonitor.sar\\\".DefaultJMSConnectionFactory is missing [jboss.naming.context.java.jboss.DefaultJMSConnectionFactory]\",
        \"jboss.naming.context.java.module.application.\\\"dms.sar\\\".DefaultJMSConnectionFactory is missing [jboss.naming.context.java.jboss.DefaultJMSConnectionFactory]\",
        \"jboss.naming.context.java.module.application.\\\"security.sar\\\".DefaultJMSConnectionFactory is missing [jboss.naming.context.java.jboss.DefaultJMSConnectionFactory]\",
        \"jboss.naming.context.java.module.application.\\\"etl.sar\\\".DefaultJMSConnectionFactory is missing [jboss.naming.context.java.jboss.DefaultJMSConnectionFactory]\",
        \"jboss.naming.context.java.module.application.\\\"visualization.sar\\\".DefaultJMSConnectionFactory is missing [jboss.naming.context.java.jboss.DefaultJMSConnectionFactory]\",
        \"jboss.naming.context.java.module.application.\\\"bpm.sar\\\".DefaultJMSConnectionFactory is missing [jboss.naming.context.java.jboss.DefaultJMSConnectionFactory]\",
        \"jboss.naming.context.java.module.application.\\\"organisation.sar\\\".DefaultJMSConnectionFactory is missing [jboss.naming.context.java.jboss.DefaultJMSConnectionFactory]\",
        \"jboss.naming.context.java.module.application.\\\"typesystem.sar\\\".DefaultJMSConnectionFactory is missing [jboss.naming.context.java.jboss.DefaultJMSConnectionFactory]\",
        \"jboss.naming.context.java.module.application.\\\"core.sar\\\".DefaultJMSConnectionFactory is missing [jboss.naming.context.java.jboss.DefaultJMSConnectionFactory]\",
        \"jboss.naming.context.java.module.application.\\\"operations.sar\\\".DefaultJMSConnectionFactory is missing [jboss.naming.context.java.jboss.DefaultJMSConnectionFactory]\",
        \"jboss.naming.context.java.module.application.\\\"srv.sar\\\".DefaultJMSConnectionFactory is missing [jboss.naming.context.java.jboss.DefaultJMSConnectionFactory]\",
        \"jboss.naming.context.java.comp.application.core-ejb.IsolatedTransactionRunnerBean.DefaultJMSConnectionFactory is missing [jboss.naming.context.java.jboss.DefaultJMSConnectionFactory]\",
        \"jboss.naming.context.java.module.application.\\\"scripting.sar\\\".DefaultJMSConnectionFactory is missing [jboss.naming.context.java.jboss.DefaultJMSConnectionFactory]\",
        \"jboss.naming.context.java.comp.application.jasee-ejb.ApplicationDeployerEjb.DefaultJMSConnectionFactory is missing [jboss.naming.context.java.jboss.DefaultJMSConnectionFactory]\",
        \"jboss.naming.context.java.comp.application.bpm-ejb.EngineServiceBean.DefaultJMSConnectionFactory is missing [jboss.naming.context.java.jboss.DefaultJMSConnectionFactory]\",
        \"jboss.naming.context.java.module.application.\\\"ldapsync.sar\\\".DefaultJMSConnectionFactory is missing [jboss.naming.context.java.jboss.DefaultJMSConnectionFactory]\"
    ]
}"
rest-ws.war.failed

"{
    \"WFLYCTL0412: Required services that are not installed:\" => [\"jboss.naming.context.java.jboss.DefaultJMSConnectionFactory\"],
    \"WFLYCTL0180: Services with missing/unavailable dependencies\" => [\"jboss.naming.context.java.module.rest-ws.rest-ws.DefaultJMSConnectionFactory is missing [jboss.naming.context.java.jboss.Default
JMSConnectionFactory]\"]
}"

I would appreciate any pointers as to what could cause this problem (race conditions?).

Kind regards,
Tobias

1 Answer

0 votes
by (15.6k points)

Hello Tobias,

can you please post the script for installing the core-service - or at least tell me which parameters you have set in the cmd. I will try to reproduce it here.

Best regards
Nicolai

by (140 points)
Hello Nicolai,

the full script used for installation is:

# Run in PS with elevated permissions
# MSSQL

C:\Users\lindenbauer\Coding\core_dockerizing\mssql\setup.exe /IACCEPTSQLSERVERLICENSETERMS /CONFIGURATIONFILE="C:\Users\lindenbauer\Coding\core_dockerizing\mssql\Container_SQLServer_ConfigurationFile.ini"
cd "C:\Program Files\Microsoft SQL Server\Client SDK\ODBC\170\Tools\Binn"
C:\Users\lindenbauer\Coding\core_dockerizing\additional_setup_mssql\run_additional_setup_local.bat

cd "C:\Users\lindenbauer\Coding\core_dockerizing"

# Waits for MSSQLSERVER to be in a state where it is ready for client connections
$ew = new-object system.management.ManagementEventWatcher                                                         
$ew.query = "Select * From __InstanceCreationEvent Where TargetInstance ISA 'Win32_NTLogEvent'"                   
while(!(get-eventlog -logname 'Application' -Source 'MSSQLSERVER' | ? {$_.EventId -eq 17126})){
    $ew.WaitForNextEvent();
}

# YUUVIS

Start-Process -FilePath "core_service\yuuvis_rad_core-service_setup_6.12.12.exe" -Wait -ArgumentList "--systemuserapikey 2368b7b654a3413a6dcbaecbeb80b905 --installDir C:\Users\yuuvis\core_service --dbType MSSQL --dbName yuuvis --dbUser sa --dbPassword Sa_Pas*word --dataDir C:\Users\yuuvis\core_service\data --installer-language en --mode unattended --unattendedmodeui none --serviceName yuuvis_rad_core-service --serviceDisplayName yuuvis_rad_core-service --dbServer localhost --dbPort 1433  --dbInstance MSSQLSERVER  --dmsSidecarUrl http://localhost:7301 --baseinit 1";

Start-Process -Wait -FilePath "msiexec" -Verb RunAs -ArgumentList "/i","C:\Users\lindenbauer\Coding\core_dockerizing\designer\yuuvis_rad_designer_setup-6.12.2.msi","/qn","INSTALLDIR=C:\Users\yuuvis\designer";

Start-Process -Wait -FilePath "C:\Users\lindenbauer\Coding\core_dockerizing\elasticsearch\elasticsearch_setup.exe" -Verb RunAs -ArgumentList "--mode unattended --installDir C:\Users\yuuvis\elasticsearch --httpPort 9200 --dataDir C:\Users\yuuvis\elasticsearch_indices --maxMem 1000";

Start-Process -Wait -FilePath "C:\Users\lindenbauer\Coding\core_dockerizing\service_manager\yuuvis_rad_service-manager_setup_6.12.5.exe" -Verb RunAs -ArgumentList "--mode unattended --installDir C:\Users\yuuvis\service_manager --serviceName yuuvis_service_manager --serviceDisplayName yuuvis_service_manager --httpPort 7281 --dataDir C:\Users\yuuvis\service_manager\data  --dmsServer localhost --dmsApiKey 2368b7b654a3413a6dcbaecbeb80b905  --renditionPort 8090 --renditionServer localhost --dbType MSSQL --dbServer localhost --dbPort 1433 --dbInstance MSSQLSERVER --dbName yuuvis --dbSchema dbo --dbUser sa --dbPassword Sa_Pas*word --dbJdbc jdbc:sqlserver://`$(enaio.db.server);database=`$(enaio.db.name);"

Start-Process -Wait -FilePath "C:\Users\lindenbauer\Coding\core_dockerizing\rendition_plus\yuuvis_rad_rendition-plus_setup_4.5.0-master.exe" -Verb RunAs -ArgumentList "--installDir C:\Users\yuuvis\rendition_plus --httpPort 8090 --mode unattended --serviceName yuuvis_rendition_plus --serviceDisplayName yuuvis_rendition_plus --cacheDir C:\Users\yuuvis\rendition_plus\data\cache --dbDir C:\Users\yuuvis\rendition_plus\data\db --jobDir C:\Users\yuuvis\rendition_plus\data\jobs --tempDir C:\Users\yuuvis\rendition_plus\data\temp --dmsServer 127.0.0.1:7341";

# Additional config
Stop-Service -name "yuuvis_service_manager";

# Elasticsearch
Start-Service -Name "yuuvis_rad_core-service";
Start-Service -Name "elasticsearch-7-service-x64";
$elasticService = Get-Service -name "elasticsearch-7-service-x64";
$elasticService.WaitForStatus("Running");
C:\Users\yuuvis\elasticsearch\bin\elasticsearch-set-initial-passwords.bat;
"Initializing elasticsearch password";

#A problem occurs here, says that elasticsearch is not running and does not setup service. I tried using sleeps starting the bat multiple times, none of these worked in the script. Outside of the script I never had this problem. I suspect that this might be the cause of the main problem of the DMS not starting.

$validPath = (Test-Path -Path "C:\Users\yuuvis\elasticsearch\config\built-in.usr");

while(!($validPath)){
    $validPath = (Test-Path -Path "C:\Users\yuuvis\elasticsearch\config\built-in.usr");
    Start-Sleep 2;
}
$elasticPassword = (Get-Content -Path "C:\Users\yuuvis\elasticsearch\config\built-in.usr")[16] -replace 'PASSWORD elastic = ','';

# Service manager
# Modify config files of service manager
$updatedEsConfig = Get-Content -Path "C:\Users\yuuvis\service_manager\config\application-es.yml" | ForEach-Object {$_ -replace 'elasticsearch.password: generated_password',('elasticsearch.password: '+ $elasticPassword)};
Out-File -FilePath "C:\Users\yuuvis\service_manager\config\application-es.yml" -InputObject $updatedEsConfig;
"`nSet up elasticsearch:`n`n";
Get-Content -path "C:\Users\yuuvis\service_manager\config\application-es.yml"

$updatedProdConfig = Get-Content -Path "C:\Users\yuuvis\service_manager\config\application-prod.yml" | ForEach-Object {if($_ -eq "  connection-timeout-ms: 3000"){$_ -replace "  connection-timeout-ms: 3000","  connection-timeout-ms: 60000"}elseif($_ -eq "  socket-timeout-ms: 60000"){$_ -replace "  socket-timeout-ms: 60000","  socket-timeout-ms: 300000"}else{$_}}
Out-File -FilePath "C:\Users\yuuvis\service_manager\config\application-prod.yml" -InputObject $updatedProdConfig;
Add-Content -Path "C:\Users\yuuvis\service_manager\config\application-prod.yml" -Value "feign.hystrix.enabled: false"
Get-Content -path "C:\Users\yuuvis\service_manager\config\application-prod.yml"
"Installed service manager.";

Start-Service -name "yuuvis_rendition_plus"
Start-Service -name "yuuvis_service_manager"

I just tried it in this exact order and all 16 services go up as expected when copying it step by step. But in a ps script it does not work. I added a comment with what I suspect to be the problem, but have not been able to fix.

Best regards
Tobias
by (15.6k points)
edited by
Hello Tobias,

if the mssql database is running as the default instance (mssqlserver), then please do not set the --dbinstance parameter (just completely omit it).

Also after the line to wait for the elasticsearch-service to be in "RUNNING" state ($elasticService.WaitForStatus("Running");) add a sleep for about 30 seconds to let elasticsearch complete its startup process: Start-Sleep 30;
Depending on your system it might need to be more than 30 seconds or it can be less, please experiment.

Finally the batch-script to initialize the elasticsearch user passwords (elasticsearch-set-initial-passwords.bat) has a "pause" at the end, so you need to exit it by "pressing any button" - for example by pipeing a space to it:
" " | D:\yuuvis\elasticsearch\bin\elasticsearch-set-initial-passwords.bat;

With those changes everything should work out fine.
Best regards
Nicolai
...