[ 
https://issues.apache.org/jira/browse/TRAFODION-3272?focusedWorklogId=207368&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-207368
 ]

ASF GitHub Bot logged work on TRAFODION-3272:
---------------------------------------------

                Author: ASF GitHub Bot
            Created on: 04/Mar/19 19:09
            Start Date: 04/Mar/19 19:09
    Worklog Time Spent: 10m 
      Work Description: svarnau commented on pull request #1802: 
[TRAFODION-3272] Change installer settings: TRAF_LOG, TRAF_CONF, TRAF_VAR
URL: https://github.com/apache/trafodion/pull/1802#discussion_r262200568
 
 

 ##########
 File path: install/python-installer/db_uninstall.py
 ##########
 @@ -63,26 +63,21 @@ def main():
     else:
         pwd = ''
 
-    node_list = ''
-    # parse node list from trafodion_config
-    if os.path.exists(TRAF_CFG_FILE):
-        with open(TRAF_CFG_FILE, 'r') as f:
-            traf_cfgs = f.readlines()
-        try:
-            line = [l for l in traf_cfgs if 'NODE_LIST' in l][0]
-            node_list = re.search(r'NODE_LIST="(.*)"', line).groups()[0]
-        except Exception as e:
-            err_m('Cannot find node list info from %s: %s' % (TRAF_CFG_FILE, 
e))
-    # parse node list from installation config file
-    elif options.cfgfile:
+    try:
+      traf_var = run_cmd_as_user(TRAF_USER,"echo $TRAF_VAR")
+      node_list = run_cmd_as_user(TRAF_USER,"trafconf -name")
+    except:
+      if options.cfgfile:
         if not os.path.exists(options.cfgfile):
             err_m('Cannot find config file \'%s\'' % options.cfgfile)
         config_file = options.cfgfile
         p = ParseInI(config_file, 'dbconfigs')
         cfgs = p.load()
+        traf_var = cfgs['traf_var']
         node_list = cfgs['node_list']
-    # user input
-    else:
+      # user input
+      else:
+        traf_conf = '/var/lib/trafodion'
 
 Review comment:
   Good catch. I will fix it.
 
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


Issue Time Tracking
-------------------

    Worklog Id:     (was: 207368)
    Time Spent: 2h 10m  (was: 2h)

> Change installer settings for TRAF_LOG, TRAF_CONF, TRAF_VAR
> -----------------------------------------------------------
>
>                 Key: TRAFODION-3272
>                 URL: https://issues.apache.org/jira/browse/TRAFODION-3272
>             Project: Apache Trafodion
>          Issue Type: Improvement
>            Reporter: Steve Varnau
>            Assignee: Steve Varnau
>            Priority: Major
>          Time Spent: 2h 10m
>  Remaining Estimate: 0h
>
> For installed instances, instead of seting these based on TRAF_HOME, they 
> should be set to standard linux locations.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to