DX NetOps

  • 1.  Moving the Report Manager Database

    Posted Jul 17, 2017 11:37 AM

    Hi All,

    Currently we have spectrum oneclick and report manager installed on our windows system on a D: drive thats getting full, we should have started with a larger drive to allow for maintenance utilities. So we have added an additional drive with twice the space, an E: drive. Is it possible to move just the win32app/spectrum/mysql/data

    folder to the E: drive and have the Report manager function normally. I noticed in the \win32app\Spectrum\MySQL directory there is a my-spectrum.cnf file which points to the data directory. Can this be accomplished there. Can I just copy the data folder to the E: drive and change the config file pointer?

     

    TIA



  • 2.  Re: Moving the Report Manager Database
    Best Answer

    Posted Jul 17, 2017 04:47 PM

    Yes you can.

    You will utilize Mysql utilities and features.

     

    Check this out:

     

    https://dev.mysql.com/doc/refman/5.6/en/innodb-migration.html

     

    “Copying Data Files (Cold Backup Method)” is probably your best bet.

     

    What’s really important is that the directory name remains the same, otherwise the data dictionary will get “confused”.

    I.e. C:\win32app\spectrum\mysql -> D:\win32app\spectrum\mysql

    Then updating innodb_data_home_dir.

    https://dev.mysql.com/doc/refman/5.7/en/innodb-init-startup-configuration.html

     

    I would create a backup of the reporting database using mysqldump to have, just in case.

     

    Let me know if you have any questions or concerns.



  • 3.  Re: Moving the Report Manager Database

    Posted Jul 17, 2017 06:24 PM

    Hi Matt,

    If I just change the path in that CF file as you have shown below and then just re-initialize the data base, it will just start writing data to the E drive now correct? I don’t really care about the old data I was going to start fresh. I dont think I can do a mysqldump, my d: drive has 280gb used and only 91gb free.

     

    Thanks

    Patrick



  • 4.  Re: Moving the Report Manager Database

    Posted Jul 18, 2017 10:12 AM

    Hey Patrick,

     

    No, you will still have to move the tables and data files unfortunately.

    Simply updating that file would not create a new database on that new drive.

     

    You can mysqldump to a different drive as well – it does not have to stay local.

     

    Thanks,

    Matt



  • 5.  Re: Moving the Report Manager Database

    Posted Jul 18, 2017 10:35 AM

    Hi Matt, sorry for all the questions but I want to make sure I do this right the first time.

    1)So I do a mysqldump to the E drive

    2)copy over the win32app/spectrum/mysql/data directory to the E drive

    3)make the modification to the ‘win32app/spectrum/mysql/data’ statement  in the my-spectrum.cnf to point to the new drive letter

    4)do a restore with the mysqldump and that’s it?

     

    Am I leaving anything out?

     

    Thanks

    Patrick



  • 6.  Re: Moving the Report Manager Database

    Posted Jul 18, 2017 11:41 AM

    The mysqldump is to have in case you needed it as a backup.

    Since you don’t care about the data you can skip that step.

     

    Once you copy over the data directory though and update the innodb data dir you should be good to go.

     

    All of this is why I am excited for engineering to get MySQL upgraded.  MySQL Enterprise Backup can do all of this for us!

     

    So:

     

     

    1.       Stop MySQL Server – make sure it stops cleanly.

     

    2.       Copy mysql/data directory (including ibdata, ib_logfile*) to the new location with the same directory structure.

     

    3.       Update my-spectrum.cnf file for data dir and innodb data dir settings from the doc link I sent earlier.

     

    4.       Start Mysql – test by attempting to access the database via command line.