Cancel
Showing results for 
Search instead for 
Did you mean: 

ugs_router -version (should be upper case V)

Genius
Genius

Hi people,

 

first time posting in TC forum, I'm an NX not a TC admin but the two are kind of intertwined.

Anyway, a customer has 2 different TC environments (production and development), and for some reason, NX doesn't start in development environment. When starting it with the NX button in TC the following errors comes up:

error.JPG

 

When I check the check the start_nxmanager.bat, everything seems fine as it is a direct copy of the production systems where the line to start it looks like this:

start "Teamcenter Integration for NX" /B "%UGII_ROOT_DIR%\ugs_router" -ugm -enable_cancel -version=%UG_VERSION% %*

 

In productive it works fine, but in DEV it has a problem with the upper case V.

I even tried entering manually -version=V29.0 instead of letting it being read from another variable with no success.

 

Does anyone know what I am doing wrong?

 

9 REPLIES

Re: ugs_router -version (should be upper case V)

Solution Partner Phenom Solution Partner Phenom
Solution Partner Phenom
Do you have both Production and Dev clients installed on the same workstation perhaps? The start_nxmanager.bat location is actually stored as a registry setting. You can validate which start_nxmanager.bat is being called by reviewing the registry key: HKCR\ugmportalfile\Shell\Open\command

To fix it so the correct start_nxmanager.bat is called when I launch a 4t rich client, add in portal.bat (TEM) or otwportal.bat (OTW):
reg add HKCR\ugmportalfile\Shell\Open\command /d "\"%TPR%\start_nxmanager.bat\"" /f


Randy Ellsworth, Teamcenter Architect, Applied CAx, LLC
NX 11 | SW 2016 | Creo 4 | TcUA 11.4
Evaluating: AW 3.4

Re: ugs_router -version (should be upper case V)

Genius
Genius

Hi @RandyEllsworth, yes, both environments are set up on the same client.

I checked the registry and it did indeed point to the start_nxmanager of the production system. Adding the line in portal.bat did not change the registry entry, I even tried changing it manually to point to the Dev system and even then the same error comes.

 

I will also try to export the registry key, change it and force import it via start script, but then I will have to reverse the process when switching back to Prod.

Re: ugs_router -version (should be upper case V)

Creator
Creator

Check all registry entries below.

[HKEY_CLASSES_ROOT\UG Bookmark\shell\open\command]

 

[HKEY_CLASSES_ROOT\UG Bookmark\DefaultIcon]

 

[HKEY_CLASSES_ROOT\UGManager Bookmark\shell\open\command]

 

[HKEY_CLASSES_ROOT\ugmportalfile\Shell\Open\Command]

 

[HKEY_CLASSES_ROOT\UGpalettefile\shell\open\command]

 

[HKEY_CLASSES_ROOT\UGpartfile\shell\open\command]

 

[HKEY_CLASSES_ROOT\ugsimanfile\Shell\Open\Command]

 

[HKEY_CLASSES_ROOT\.ugmportal]

 

[HKEY_CLASSES_ROOT\.ugs]

 

Also Check the NX version defined in Distribustion Server Instance.

 NXVersionV29.0

 

 

If you add registry entries in portal.bat OR Otwportal.bat. It must run with "Admin" to update the registry

 

Re: ugs_router -version (should be upper case V)

Genius
Genius

Hi guys! It's been a while and I'm still struggling with this issue. After checking the registry I saw it was pointing to the wrong environment as you said, but even after changing the registry key, I still have the same problem.

 

This is my current setting after running the "reg add" command: 

Capture.JPG

 

Any suggestions would be more than helpful.

Thanks!

Re: ugs_router -version (should be upper case V)

Solution Partner Phenom Solution Partner Phenom
Solution Partner Phenom
The registry doesn't understand what TPR is unless you set a system environment variable that you would need to change each time you switched environments. Which is basically what the script is doing but not at the system level. The script understands what TPR is because its defined earlier in the script. If you are going to manually change the registry outside of the script then you have to provide the real value for TPR (for example C:\Siemens\Teamcenter\portal\start_nxmanager.bat).

Randy Ellsworth, Teamcenter Architect, Applied CAx, LLC
NX 11 | SW 2016 | Creo 4 | TcUA 11.4
Evaluating: AW 3.4

Re: ugs_router -version (should be upper case V)

Genius
Genius

I actally added the line in the portal.bat script which changed my registry entry, now it looks like this:

set TPR=C:\plm\tc112_NP\portal
if not defined FMS_HOME set FMS_HOME=C:\plm\tc112_NP\tccs

rem use AUX_PATH env var for any additional required paths
rem save original path for external applications
set ORIGINAL_PATH=%PATH%
rem for optimal startup performance, keep the PATH length at a minimum
set PATH=%SYSTEMROOT%\system32;%FMS_HOME%\bin;%FMS_HOME%\lib;%TPR%;%AUX_PATH%

set JAVA_HOME=%TC_JRE_HOME%
set JRE_HOME=%TC_JRE_HOME%

reg add "HKCR\ugmportalfile\Shell\Open\command" /d "\"%TPR%\start_nxmanager.bat\"" /f

:start_portal
cd /d %TPR%
set CLASSPATH=.;
set VM_XMX=1024m

 tc112_NP is our DEV environment.

Re: ugs_router -version (should be upper case V)

Solution Partner Phenom Solution Partner Phenom
Solution Partner Phenom
That is a good start but only part of the solution. You'll need to remove "if not defined FMS_HOME" to force the setting of the correct FMS_HOME (for Dev) and then stop any previously running FCC to ensure files are written to the correct environment as specified by FMS_HOME.

set FMS_HOME=C:\plm\tc112_NP\tccs

:: After setting JAVA_HOME and JRE_HOME but before start_portal
:: Stop old FCC.
%FMS_HOME%\bin\fccstat -stop
:: Location of start_nxmanager
reg add "HKCR\ugmportalfile\Shell\Open\command" /d "\"%TPR%\start_nxmanager.bat\"" /f

Randy Ellsworth, Teamcenter Architect, Applied CAx, LLC
NX 11 | SW 2016 | Creo 4 | TcUA 11.4
Evaluating: AW 3.4

Re: ugs_router -version (should be upper case V)

Genius
Genius

This is done in another script before calling the portal:

if not exist %SPLM_APPL_DIR%\tc112 goto fcc_done
if not %SIDT_PAR2% equ portal_client goto fcc_done
echo Found tc112.
echo Setting FMS_HOME to DEV.
set FMS_HOME=%SPLM_APPL_DIR%\tc112\tccs
echo Killing FCC for tc112prod
%SPLM_APPL_DIR%\tc112\tccs\bin\fccstat.exe -kill
:fcc_done
echo done.
echo.


rem ------------------------------------------------------------------------------
rem set FMS_HOME for Teamcenter
rem ------------------------------------------------------------------------------

set FMS_HOME=%SPLM_APPL_DIR%\tc112_NP\tccs
cd /D C:\plm\tc112_NP\portal
 
CALL portal.bat

 

Re: ugs_router -version (should be upper case V)

Solution Partner Phenom Solution Partner Phenom
Solution Partner Phenom
Looks complicated. I'm guessing you have another script for SPLM_APPL_DIR and SIDT_PAR2. Why not simply edit/add the three lines in portal.bat? Seems much easier.

Randy Ellsworth, Teamcenter Architect, Applied CAx, LLC
NX 11 | SW 2016 | Creo 4 | TcUA 11.4
Evaluating: AW 3.4