If you are unable to create a new account, please email support@bspsoftware.com

 

News:

MetaManager - Administrative Tools for IBM Cognos
Pricing starting at $2,100
Download Now    Learn More

Main Menu

How to Cube swap & optimize Multipartitioned cubes?

Started by snadgir30, 24 Jul 2008 11:36:50 AM

Previous topic - Next topic

snadgir30

Hi CognosGurus,
  We have server setups where in we build cube(s) on different server - Say A & then optimize ,cube swap it on reporting server  - say B.
This Cube building on A & transferring it to B , optimizing & cube swapping is automated preocess using batch files.
Now we have a model that build cube in size that exceeds 2GB which is possible to be in the form of Multipartitioned cube only.We have implemented such change which will build the cube having 1 mdc n several mdps depending on the data.

Now our cube swap batch file is built for single mdc -Optimization & swap.
so my doubt/question is , is there any standard way/existing/Cognos way to optimize,swap such multipartitioned cube?

Thanks in advance.
Regards,
snadgir30

Ty Clabbers

Why not optimize the cube on build time (on commandline "-dEnablePCOptimizer=1" or in the trnsfrm.ini file)?
For the cubeswap, your swap needs to point to the mdc file. You can't open the mdp files (the partitioned files) anyway. They are only accessed by opening the mdc file.

snadgir30

Hi
Thanks for the  quick response!
Now its not an issue to optimize multipartitioned cube but its about swapping the cube.
About Cube swap - it is second step in our cube building automated process that is to say first we build cube on transformer server then copy it over to reporting server where we optimze n cube swap to newly built cube.
In cube swap we create copy of the original cube to which we point  datasource to temporarily & then overwrite original cube with newly built cube & again point back datasource to newly built cube.
The doubt is when create copy of original cube for temporary pointing of datasource -- Do we need to create copies of mdp files as well ?bocz in case of multipartioned cube MDC holds pointers to MDPs having data.
Then overwrite original(old) mdcs n mdps with newly built mdc n mdps.
I Hope i have putforward my doubt in as simple words as possible.

Regards
snadgir30

Ty Clabbers

I have never tested to rename a partitioned cube so i can't help you on that. I solved this problem by creating my new cubes in a seperate folder (based on the builddate) and then swapping to this new folder. This will also eliminate the need to first create a copy. This is done by setting the variable "dCubeSaveDirectory" in the batch script. My batch file looks like this:

echo ---------------------------------------------------------------------------
echo Create a variabele based on systime and sysdate
set cube_creation_date=%date:~10,4%-%date:~4,2%-%date:~7,2%_%time:~0,2%%time:~3,2%

echo ---------------------------------------------------------------------------
echo Create new cube
"D:\Program Files\Cognos\cer4\bin\trnsfrmr" -n2 -r4 -i -dLogFileDirectory="D:\cognos-data\Powerplay\Operationele kubus\output" -dMultiFileCubeThreshold=7500000 -dEnablePCOptimizer=1 -dDataSourceDirectory="D:\cognos-data\Powerplay\Operationele kubus\iqd" -dCubeSaveDirectory="D:\cognos-data\Powerplay\Operationele kubus\output\%cube_creation_date%" -dDataWorkDirectory="D:\cognos-data\Powerplay\TempCognos\Operationele Kubus" -dModelWorkDirectory="D:\cognos-data\Powerplay\TempCognos\Operationele Kubus" -dModelSaveDirectory="D:\cognos-data\Powerplay\Operationele kubus\output" -kDWHMDN=XXXX/XXXXX "D:\cognos-data\Powerplay\Operationele kubus\model\operationele_kubus.mdl"

echo ---------------------------------------------------------------------------
echo Add the create date to name of the logfile
move "d:\cognos-data\powerplay\operationele kubus\output\operationele_kubus.log"         "d:\cognos-data\powerplay\operationele kubus\output\%cube_creation_date%_operationele_kubus.log"

echo ---------------------------------------------------------------------------
echo Copy the cubefiles to the cognos servers
xcopy  "d:\cognos-data\powerplay\operationele kubus\output\%cube_creation_date%"                              "\\l2pndprdapp10.nl.rsg\d$\cognos-data\kubussen\operationele kubus\%cube_creation_date%\"  /Y /F /R /E
copy /b /y "d:\cognos-data\powerplay\operationele kubus\output\%cube_creation_date%_operationele_kubus.log"   "\\l2pndprdapp10.nl.rsg\d$\cognos-data\kubussen\operationele kubus\%cube_creation_date%_operationele_kubus.log"

xcopy  "d:\cognos-data\powerplay\operationele kubus\output\%cube_creation_date%"                              "\\l2pndprdapp11.nl.rsg\d$\cognos-data\kubussen\operationele kubus\%cube_creation_date%\"  /Y /F /R /E
copy /b /y "d:\cognos-data\powerplay\operationele kubus\output\%cube_creation_date%_operationele_kubus.log"   "\\l2pndprdapp11.nl.rsg\d$\cognos-data\kubussen\operationele kubus\%cube_creation_date%_operationele_kubus.log"

xcopy  "d:\cognos-data\powerplay\operationele kubus\output\%cube_creation_date%"                              "\\l2pndprdapp12.nl.rsg\d$\cognos-data\kubussen\operationele kubus\%cube_creation_date%\"  /Y /F /R /E
copy /b /y "d:\cognos-data\powerplay\operationele kubus\output\%cube_creation_date%_operationele_kubus.log"   "\\l2pndprdapp12.nl.rsg\d$\cognos-data\kubussen\operationele kubus\%cube_creation_date%_operationele_kubus.log"

echo ---------------------------------------------------------------------------
echo Swap the new cube
start "Operationele kubus"         /D"d:\Program Files\Cognos\c8MR2\webapps\utilities\cubeSwap" /B /WAIT cubeSwap.bat -dispatchername="http://%COMPUTERNAME%:9300" -datasource="Operationele kubus"         -url="http://%COMPUTERNAME%:9300/p2pd/servlet/dispatch" -username="COGNOSUSER" -password="PASSWORD" -namespaceid="Series7" -windowscube="D:\cognos-data\kubussen\operationele kubus\%cube_creation_date%\operationele_kubus.mdc"

echo ---------------------------------------------------------------------------
echo Remove files from the build server
rmdir /S /Q "d:\cognos-data\powerplay\operationele kubus\output\%cube_creation_date%"
del "d:\cognos-data\powerplay\operationele kubus\output\%cube_creation_date%_operationele_kubus.log"