#1585 Run script to consolidate all projects into a single project-data database NEEDS SCRIPT

v1.0.0
closed
sf-2 (994)
General
nobody
2015-08-20
2011-02-28
No

Adjust an existing script

# First, do a full database backup in case stuff breaks.  NOTE: script will log to /var/log/allura/allura.log 
# Initial run: migrate kajiki only (actually everything in project-data-i)
allurapaste script /var/local/config/production.ini ../scripts/migrate_project_database.py kajiki
# Second test: migrate allura (actually everything in project-data-a)
allurapaste script /var/local/config/production.ini ../scripts/migrate_project_database.py allura
# Full migration (remaining shards)
allurapaste script /var/local/config/production.ini ../scripts/migrate_project_database.py

Related

Tickets: #1792

Discussion

  • Dave Brondsema

    Dave Brondsema - 2011-03-31
    • Description has changed:

    Diff:

    --- old 
    +++ new 
    @@ -1,0 +1,1 @@
    +Adjust an existing script 
    
    • size: --> 2
     
  • Rick Copeland - 2011-04-06
    • status: open --> in-progress
    • assigned_to: Rick Copéland
     
  • Rick Copeland - 2011-04-06

    on forge:rc/1585

    QA: code-review and run the script (forge/scripts/migrate_project_database.py). Unfortunately it won't do anything, as all our test data has been consolidated into one database already. Instructions for running the script in QA are just like the 'Full Migration' listed in the ticket body.

    (forge)(rc/1585)
    : rick446@legolas-vm: ~/src/forge/Allura; git qa
    Todays unlucky sucker is: JWH
    
     
  • Rick Copeland - 2011-04-06
    • summary: Run script to consolidate all projects into a single project-data database --> Run script to consolidate all projects into a single project-data database NEEDS SCRIPT
    • Description has changed:

    Diff:

    --- old 
    +++ new 
    @@ -1,1 +1,11 @@
     Adjust an existing script 
    +
    +~~~~
    +# First, do a full database backup in case stuff breaks.  NOTE: script will log to /var/log/allura/allura.log 
    +# Initial run: migrate kajiki only (actually everything in project-data-i)
    +allurapaste script /var/local/config/production.ini ../scripts/migrate_project_database.py kajiki
    +# Second test: migrate allura (actually everything in project-data-a)
    +allurapaste script /var/local/config/production.ini ../scripts/migrate_project_database.py allura
    +# Full migration (remaining shards)
    +allurapaste script /var/local/config/production.ini ../scripts/migrate_project_database.py
    +~~~~
    
    • status: in-progress --> code-review
    • assigned_to: Rick Copéland --> John Hoffmann
     
  • John Hoffman - 2011-04-07
         if project is None:
    -        log.fatal('Project %s not found', pname)
    -        print 'Project %s not found' % pname
    +        log.fatal('Project %s not found', project.shortname)
    

    If project is None, I'm not sure we can log using project.shortname?

     
  • Rick Copeland - 2011-04-07

    heh. Good point. Fixed and repushed

     
  • John Hoffman - 2011-04-07
    • status: code-review --> validation
    • assigned_to: John Hoffmann --> Rick Copéland
     
  • John Hoffman - 2011-04-07

    Looks good, no errors during the run on a rebuilt sandbox. Setting to validation so it can be closed once SOG runs on production.

     
  • Dave Brondsema

    Dave Brondsema - 2011-04-12
    • status: validation --> closed
     

Log in to post a comment.