Here are the upgrade instructions

UI

On the demo server we want 2.3 to persist as an example, so we have to keep whats there and make a new env in a new tomcat and new database.  On an typical upgrade you will not keep the old env up and running like we do on the demo server, so ignore steps: 1, 2, 5, 8, 9, 10

  1. Create new mysql database, grouper_v2_4, utf8, utf
  2. Create a new user/pass with rights to that database
  3. Copy tomcat 8.5 from installer download
  4. Configure tomcat to use java8
  5. Copy the 2.3 webapp to the new tomcat, rename the dir, and change the database connect information to the new 2_4 database
  6. Convert sources.xml to subject.properties if not done already
  7. Convert ehcache.xml to grouper.cache.properties if not done already
  8. Create tables in the database

    [appadmin@i2midev6 bin]$ ./gsh -registry -runscript
  9. Copy data from 2.3 to 2.4 using SQLYog



    Note, there was an error about foreign keys, so I truncated the tables, rearranged the SQL a tad, and did it again and it was success.




  10. Change log directory
  11. Change the AJP connector in tomcat to allow REMOTE_USER from apache/shib

    <Connector port="8091" protocol="AJP/1.3" redirectPort="8443" tomcatAuthentication="false"
  12. Turn on the env and see that it works
  13. Upgrade Grouper

    [appadmin@i2midev6 upgrade]$ wget https://software.internet2.edu/grouper/release/2.4.0/grouperInstaller.jar
    [appadmin@i2midev6 upgrade]$ java -jar grouperInstaller.jar 
    upgrade
    ui
    /opt/tomcats/tomcat_b/webapps/grouper_v2_4
    run the change log temp to change log
    revert all patches

    This might not need to be done since we will fix it, but I reviewed jars for redundant jars, and see that I need to remove these:

    subject.jar
  14. Turn on and done!

WS

  1. Copy tomcat 8.5 from installer download
  2. Configure tomcat to use java8
  3. Copy the 2.3 webapp to the new tomcat, rename the dir, and change the database connect information to the new 2_4 database
  4. Convert sources.xml to subject.properties if not done already

    [appadmin@i2midev6 upgradeWs]$ java -jar grouperInstaller.jar 
    Do you want to 'install' a new installation of grouper, 'upgrade' an existing installation,
      'patch' an existing installation, 'admin' utilities, or 'createPatch' for Grouper developers
      (enter: 'install', 'upgrade', 'patch', 'admin', 'createPatch' or blank for the default) [install]: admin
    What admin action do you want to do (manage, upgradeTask, develop)? : upgradeTask
    What upgrade task do you want to do (convertEhcacheXmlToProperties, convertSourcesXmlToProperties)? : convertSourcesXmlToProperties
    Note, you need to convert the sources.xml file for each Grouper runtime, e.g. loader, WS, UI.
    Note, to use subject sources from subject.properties, you need to be running Grouper 2.3.0+ with API patch 40 installed.
    Enter the location of the sources.xml file: /opt/tomcats/tomcat_e/webapps/grouper-ws_v2_4/WEB-INF/classes/sources.xml
    Enter the location of the subject.properties file [/opt/tomcats/tomcat_e/webapps/grouper-ws_v2_4/WEB-INF/classes/subject.properties]: 
    File was written: /opt/tomcats/tomcat_e/webapps/grouper-ws_v2_4/WEB-INF/classes/subject.properties
    You should archive your sources.xml and remove it from your project since it is now unused:
      /opt/tomcats/tomcat_e/webapps/grouper-ws_v2_4/WEB-INF/classes/sources.xml
    [appadmin@i2midev6 upgradeWs]$ 
  5. Convert ehcache.xml to grouper.cache.properties if not done already
  6. Change log dir in log4.properties, and create log dir if not exist
  7. Upgrade Grouper

    [appadmin@i2midev6 upgrade]$ wget https://software.internet2.edu/grouper/release/2.4.0/grouperInstaller.jar
    [appadmin@i2midev6 upgrade]$ java -jar grouperInstaller.jar 
    upgrade
    ws
    /opt/tomcats/tomcat_e/webapps/grouper-ws_v2_4
    run the change log temp to change log
    revert all patches

    This might not need to be done since we will fix it, but I reviewed jars for redundant jars, and see that I need to remove these:

    subject.jar
  8. Convert vt-ldap to ldaptive

    ##### Change subject.properties
    
    
    # link back to grouper-loader.properties                                                                                            
    subjectApi.source.cmuDirectory.param.ldapServerId.value = cmuLdap
    
    # e.g. com.sun.jndi.ldap.LdapCtxFactory                                                                                             
    #subjectApi.source.cmuDirectory.param.INITIAL_CONTEXT_FACTORY.value = com.sun.jndi.ldap.LdapCtxFactory                              
    
    # e.g. ldap://localhost:389                                                                                                         
    #subjectApi.source.cmuDirectory.param.PROVIDER_URL.value = ldap://ldap.andrew.cmu.edu:389                                           
    
    # e.g. simple, none, sasl_mech                                                                                                      
    #subjectApi.source.cmuDirectory.param.SECURITY_AUTHENTICATION.value = none                                                          
    
    ##### Change grouper-loader.properties
    
    
    #################################                                                                                                   
    ## LDAP connections                                                                                                                 
    #################################                                                                                                   
    # specify the ldap connection with user, pass, url                                                                                  
    # the string after "ldap." is the ID of the connection, and it should not have                                                      
    # spaces or other special chars in it.  In this case is it "personLdap"                                                             
    
    #note the URL should start with ldap: or ldaps: if it is SSL.                                                                       
    #It should contain the server and port (optional if not default), and baseDn,                                                       
    #e.g. ldaps://ldapserver.school.edu:636/dc=school,dc=edu                                                                            
    ldap.cmuLdap.url = ldap://ldap.andrew.cmu.edu:389                                                                                   
    
    
    
  9. Turn on and done!


  • No labels