About Me

My photo
I work for Fusion5 Australia . Connect with me on linked in here . I'm raising money for a good cause at the moment, follow donate to leukemia foundation

Monday, 31 August 2009

Recompress specs

sign into dep server DEP812 environment goto GH9083

package build history.

Find your package (oh err!)

Open latest date, client, compression options and choose spec (note that is all I want to compress)

Choose “Reset status”

Change to 01|01 and reset

Highlight word client and then resubmit build

Choose cancel on the “Generate NER” popup.

And OK

**Note that I had this problem a couple of times.  I could not delete the spec.cab file, so did a NET SESSION command on the deployment server and then deleted any of the SESSIONS that came up in the list.

I then submitted the recompress again:

I’m my situation, the following log (CompressErrors.txt) in the package main directory

31/08/2009 01:03:58 1 FCIAddFile() failed: code 4 [Could not create a temporary file]

31/08/2009 01:03:58 1 System error code (errno): 13, Permission denied

31/08/2009 01:03:58 1 The file that cannot be added is: <\\XX\E812\DV812\package\DV812GF\spec\SPEC_DV812GF.mdf>

Locking in Oracle and JDE

So you see that there is locking and you want to know what is going on in the database…


The following SQL is going to help with identifying what is being locked and blocked.


select session_id "sid",SERIAL#  "Serial",
substr(object_name,1,20) "Object",
substr(os_user_name,1,10) "Terminal",
substr(oracle_username,1,10) "Locker",
nvl(lockwait,'active') "Wait",
decode(locked_mode,
2, 'row share',
3, 'row exclusive',
4, 'share',
5, 'share row exclusive',
6, 'exclusive', 'unknown') "Lockmode",
OBJECT_TYPE "Type"
FROM
SYS.V_$LOCKED_OBJECT A,
SYS.ALL_OBJECTS B,
SYS.V_$SESSION c
WHERE
A.OBJECT_ID = B.OBJECT_ID AND
C.SID = A.SESSION_ID
ORDER BY 1 ASC, 5 Desc


Details of the process, get pid’s from above SQL:



select process as "PID:THREAD", server, ltrim(rtrim(program)), ltrim(rtrim(machine)), lockwait

from v$session where sid = 1504 or sid = 1176



This will give you the PID and thread ID of the E1 job that is holding the locks.  You can the use the following to kill the offending pids (or jde kernels).



Database level:



alter system kill session 'session-id,session-serial'


This command kills a session. The session-id and session-serialparameters are found in the v$session view (columns sid and serial#).



Operating System Level:



a) UNIX - I always locate the Server PID (SPID) from v$process and issue the UNIX .



ps –ef |grep SPID [to see the proc]



kill –9 SPID [to kill the proc]



b) The Windows command to kill this session would be as follows. This uses SID and thread as the parameters:

C:\oracle9i\bin>orakill ORCL92 768



I’m guessing that you might want to be careful with connection pooling if this is the case.

Wednesday, 26 August 2009

Strange oracle SQL results, using NULL and <>

here are a couple of SQL examples, test your skills.

back ground:

Select count(1) from CRPDTA.F03B14;

>20467464 rows

select count(1) from CRPDTA.F03B14 WHERE rzpost <> ‘D’

>0 rows

select count(1) from CRPDTA.F03B14 WHERE RZPOST = ‘D’

>2767142 rows

So, do you see the problem?  2.7 million rows are ‘D’, 0 are not ‘D’, yet there are 18 millions rows not accounted for!

These rows ARE NULL!

So, what would I get with:

select count(1) from CRPDTA.F03B14 where RZPOST = NULL ?

>0 rows

WTF???  0, I thought I’d get 18000000.  Well, here is another idiosyncrasy of oracle SQL:

select count(1) from CRPDTA.F03B14 where RZPOST IS NULL;

>17709320 rows

Monday, 24 August 2009

server manager and WAS cluster… not happy with debugging

You think that server manager is the answer to all of your problems…  You use WAS ND to serve up the web…  You go live…  Everything is good…

Until…

Lets say…

You want to turn on logging for a user…  And you can get the the logging section for one of the cluster nodes…  Actually you can’t get to any of them…  that is not cool…

Or maybe you want to use SM to report of failed logins or other metrics for the web servers, sorry – you can’t do that either.

Hmmm, so not the perfect solution you thought.

The better way is to contact www.myriad-it.com for their virtual load balancer and some advice on what to do with your architecture… I’d avoid ND and use apache load balance directives or the myLB.

Monday, 17 August 2009

What update package was that object in

I get asked this all of the time…

SELECT BDPKGNAME FROM SY812.F9622 WHERE BDPKGOPTION = ‘R0010”’ ;

It’s that simple.  BDVERS contains the version information too.  BDUPMJ is also a good field.

find big PDF files

find $EVRHOME/PrintQueue –name “*_PDF” –size +1000k –exec ls –l \; |wc

above will give you a list of PDF files that are > 1 Mb.

If you wanted to delete or mv them, then change ls –l {} \; to rm {} \;

Note also that this is a handy way of getting around the old “The parameter list is too long” – WTF!!!  120K entries causes this…  Come on unix, I think that windoz has got you on that one.

No seriously, use of the find command gets around that little nugget easily

Thursday, 13 August 2009

transaction server, pile of crap

So I’ve been working with the 8.98.1.1 txn server and server manager of the same release.  I gotta tell you that this thing is a pile of poo.  We are hitting it hard (250000 messages at a time), but it breaks with different error messages all of the time.

I’ve been getting terrible responses from oracle too, untimely and inaccurate.

But, one thing they did provide was an IBM product called the service integration bus explorer – it’s awesome!

http://www.alphaworks.ibm.com/tech/sibexplorer

You can see all your queues with accurate numbers.  Take it from me – the queue count in SM is an approximation at best…

The purge functionality works and you don’t have to wait hours to see the queued message count.  It’s been a very positive step seeing this in action. 

rownum and between – oracle result sets

Limiting your resultset with rownum is a powerful feature in oracle sqlplus.  Because the rownum is applied to the result set, a between statement is not possible…  So here is a sneaky and cheeky way of doing a between.

insert into testdta.F55001CM
(select aian8, 109170, 141300, 'SQL', 'A', 'MOIRS'
  from ( select a.*, rownum rnum
           from (
  select aian8, 109170, 141300, 'SQL', 'A', 'MOIRS'
  from testdta.f03012,testdta.F0101
  where AIAN8 = ABAN8
  and substr(ABALKY, 1, 2) in ('AY','LM','NY','NA','EA')) a
          where rownum <= 236000)
where rnum >= 235000 )

Monday, 3 August 2009

o-dear… ODIR…

I hate outlook and nokia software and synch and EVERYTHING related to these topics.  I’m sick of duplicate entries everywhere, it’s a nightmate…

But I discovered a decent freeware tool for de-duplication.  http://techie-buzz.com/utilites/free-outlook-email-contacts-and-calendar-duplicate-remover.html worked first time, no license keys, no secret downloads, no limitations…  Woo Hoo!

Got rid of all the dups, placed them in a “duplicates” folder.  I now see people names and not random numbers (my use of random is not factual, because of course the numbers are not actually random…) when people call me.