header

Commands to test COBOL server express

$PS_HOME/bin> ./ptpdbtst
$PS_HOME/bin> cobrun
$PS_HOME/bin> cob -v
$PS_HOME/bin> cob -V
$PS_HOME/bin> ls -l PSRUN*

Oracle cold backup database refresh

1.  Prepare controlfile creation script.  This can be done by
alter database backup controlfile to trace as '/export/home/oracle/ctlfile.sql';
2.  View the edit ctlfile.sql, so that it should contain the following
CREATE CONTROLFILE SET DATABASE "UATDB" RESETLOGS NOARCHIVELOG
  MAXLOGFILES 16
  MAXLOGMEMBERS 3
  MAXDATAFILES 100
  MAXINSTANCES 1
  MAXLOGHISTORY 453
LOGFILE
  GROUP 1 '/u01/oradata/UATDB/redo01.log' SIZE 200M,
  GROUP 2 '/u02/oradata/UATDB/redo02.log' SIZE 200M,
  GROUP 3 '/u03/oradata/UATDB/redo03.log' SIZE 200M
-- STANDBY LOGFILE
DATAFILE
  '/u01/oradata/UATDB/system01.dbf',
  '/u01/oradata/UATDB/undotbs01.dbf',
  '/u01/oradata/UATDB/users01.dbf',
  '/u01/oradata/UATDB/data01.dbf',
  '/u01/oradata/UATDB/tools01.dbf',
  '/u01/oradata/UATDB/perfstat01.dbf',
  '/u01/oradata/UATDB/sysaux01.dbf'
CHARACTER SET WE8ISO8859P1
;
3. Gernerate script to create TEMP tablespace
set long 2000
select DBMS_METADATA.GET_DDL('TABLESPACE','TEMP') from dual;
4. Shutdown UATDB cleanly
shutdown immediate
5. Copy the cold backup files from production to UAT box.
6. Start the database in nomount state

startup nomount
7. Run the create control file script
@/export/home/oracle/ctlfile.sql
8. Open the database with resetlogs
alter database open resetlogs;
9. Create temp tablespace from the script generated from step 3:
CREATE TEMPORARY TABLESPACE "TEMP1" TEMPFILE
'/u01/oradata/UATDB/TEMP01.dbf' SIZE 5242880000
EXTENT MANAGEMENT LOCAL UNIFORM SIZE 1048576

PeopleSoft database refresh steps

Below are steps can we followed for pre and post refresh of PeopleSoft application environment.Please also  copy the SQR,COBOL,Crystal for file object refresh.


  1. Export any security that you need to preserve from the target database to a flat file. Data Mover is a nice tool to use for this since you can qualify each table with a list of operator ID's to export. The tables you should consider exporting for specific users are PSOPRDEFN, PSOPRALIAS, PSROLEUSER, PSUSERATTR, PSUSEREMAIL, PSUSERPRSNLOPTN, PS_ROLEXLATOPR and PS_RTE_CNTL_RUSER.
  2. Stop the target application environment, including application servers and process schedulers. Stopping the web server is optional since it doesn't connect directly to the database. Be sure to clear cache.
  3. Overlay the target database with a recent backup of the Production database. The exact process will differ for your database platform, but your DBA should be able to do this with minimal direction.
  4. After the database comes back on-line, set DBNAME in PSDBOWNER back to the target database name.
  5. Set GUID to ' ' in the PSOPTIONS table. This will cause PeopleSoft to generate a new GUID so that change assistant can track it separately from the source database.
  6. Delete the data from the reporting tables, process scheduler tables and application messaging tables since this data isn't relevant in the target database. Run prcsclr.dms, rptclr.dms and appmsgpurgeall.dms. In addition, I also delete from the report manager tables PSRF_RATTR_TBL; PSRF_RSCRTY_TBL; PSRF_RINFO_TBL; and delete from PSRF_FINFO_TBL where PSRF_PRNT_FLDR_ID <> 0;
  7. If you have a script to reset everyone's e-mail address to a pre-defined value so that workflow messages from the Test environment don't get sent to real users, run it now. It should update the PSUSEREMAIL and PS_ROLEXLATOPR tables.
  8. Log on to the target database with data mover and run the following command to set the SYSADM password and any other back to it's pre-refreshed value:
    -- Author: Brent Martin, ERP Associates Inc.
    -- Date: February 10, 2006
    -- Purpose: Reset application passwords and purge PeopleTools tables after a database refresh so that
    -- the application can be started with minimal reconfiguration.
    -- Compatibility: This works with PeopleTools 8.4x releases
    -- Notice: This script modifies data in your PeopleSoft database. It changes account passwords, and
    -- it deletes data from process scheduler, report repository and integration broker tables.
    -- It as provided for reference purposes only. Use it at your own risk.

    set log c:\temp\dbrefresh.log;

    -- Change Access Password (SYSADM)
    CHANGE_ACCESS_PASSWORD SYSADM1 CHANGEME1;

    -- Change Application Password (PSAPPS)
    update psoprdefn set OPERPSWD = 'changeme1', encrypted = 0 where oprid = 'PSAPPS';
    encrypt_password PSAPPS;

    -- Set GUID to blank so PSEMAgent and Change Assistant doesn't get confused
    update psoptions set guid = ' ';

    -- Purge Process Scheduler
    RUN h:\fdmo881\scripts\PRCSCLR.DMS;

    -- Purge Report Repository Tables
    RUN h:\fdmo881\scripts\RPTCLR.DMS;

    -- Purge Application Messaging RUN h:\fdmo881\scripts\APPMSGPURGEALL.DMS;
  9. Import the security that you exported in step 1.
  10. While you're in data mover, change the user passwords that are configured in your application server, process scheduler, and integration broker configurations back to the pre-refresh values:
    update psoprdefn set OPERPSWD = 'devpswd', encrypted = 0 where oprid = ('PSAPPS');
    encrypt_password PSAPPS;
    update psoprdefn set OPERPSWD = 'devpswd', encrypted = 0 where oprid = ('PTWEBSERVER');
    encrypt_password PTWEBSERVER;
  11. Clear application server, web server and process scheduler cache if you haven't already done it. Start the target application environment.
  12. Log on through the web front end.
  13. Update the Report Node configuration and verify your Process Scheduler Servers are using the correct configuration. Make any Web Profile changes if needed.
  14. Navigate to PeopleTools > Utilities > Options and update the database name and description.
  15. Change password rules as appropriate for a development environment.
  16. Change your default local node if it should be named differently than the default local node from the source database. If it's not named differently, you may be at risk for a single sign-on vulnerability.
  17. Reconfigure attachment servers (if used)
  18. Reconfigure REN servers and clusters if the application server didn't configure it correctly at startup.
  19. Make sure you copy all of the batch objects (SQR's, Crystal Reports, COBOL programs, etc.) from your source to your target environment to keep the environment in synch. Don't forget to do this on both UNIX and Windows servers.
  20. Perform some sanity checks to make sure the environment is behaving itself before you let users back into it. At a minimum you should verify you can log on and run a report. Verify the report runs to completion, posts, and allows you to view the report without having to sign in a second time.

Windows COBOL compilation(Net Express)

Below are the commands to compile cobol on windows.The .gnt files - executable version of cobol will be generated after compilation and copied to CBLBINU for unicode version and CBLBIN for non unicode . Adjust the paths as necessary.


set PS_HOME=c:\pshome\hcm90

set PATH=%ps_home%\src\cbl\win32;%path%

set COBROOT="c:\program files\micro focus\net express\base"

cd %PS_HOME%\setup

cblbld c: \temp\compile

(make sure you have a space between the c: and the \temp\compile)

Here is the output:

ASCII Cobol Compilations Proceeding

Creating Directory c:\temp\compile

Logging progress to file c:\temp\compile\CBLBLD.LOG

COBOL compiler found in “c:\program files\micro focus\net express\base”  -- note the " and space

The system cannot find the path specified.

Target directory (c:\pshome\hcm90\CBLBINA) exists and is writable



Copying source files …

useful EXCEL formula to generate SQL DDL/grant scripts

TO generate update script:

---------------------------
Enter the formula as below to generate the multiple statement and drag colums to generate DDL statements
=CONCATENATE($E$3,A2,"';")
Where
$E$3 Excel cell -->update psoprdefn set operpswd = ' ' where oprid='  (or similar insert statement)
A2 Excel  cell --> list table names or user name
“’;” --> is a string


To Generate role and permision and grants
----------------------------------------------
="grant select, update, delete, insert on " & A1 & " to user_role;"
="create public synonym " & A1 & " for sysadm." & A1 & ";"


Where
& A1 & Excel column  contains the table list