Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

16 Bit app performance issues

Status
Not open for further replies.

Nostferatu

IS-IT--Management
Feb 16, 2001
63
GB
Hi all,

Well its the age old question, I have 3 Metaframe 1.8 servers load balancing Oracle Financials which is a 16bit client installed app, anyone got any brilliant 16bit app performance tweaks, because I have used up about all the ideas I have for it, and it is still running too slowly.

Any given user can suddenly grab 99% of the processor causing the rest of the world to run like a dog who has just been shot with 16ounces of prozak, already has been awake for 6 days solid and has been put on a king size bed with the most comfortable eider down quilt one has ever had the pleasure to sleep on...

we will be upgrading to Oracle 8i in the next few months, which I am anticipating will aid things here, and there are a few (infamous) oracle patches to apply to the database which will improve the server and reporting processes, but this does not directly effect the navigation of the client app...

Any and all input is most welcome,

Thanks in advance for any help Steve Marshall
Group IT
Technical Support Supervisor
(aka General Meddler)
The Expro Group
Reading
UK
 
I've not yet played with Oracle 8i (although I will be in the next few weeks), but a couple of years ago I did an Oracle Financials roll out to 750 (non simultaneous) users across 6 MetaFrame servers.

The three things that really stand out;

1. Using Filemon to troubleshoot just about everything.
2. The hideous quantity of Java apps. Get up to about 20, and the client starts to drag.
3. Any changes to the client should be done in change user/install mode, to propagate them through the user community.


16-bit app tweaks:

Run each process in its own memory space - but you've done that, right?

Use DOSKBD to reduce keyboard polling?


Oracle 8i

I heard that the report writer background engine RWRBE60.EXE has issues with PCL printer drivers. Apparently earlier versions are OK.


That's about as much info as I have, off the top of my head.

I'll have a dig in the archives - because I'll be doing this myself and watching this post very carefully :)

Good Luck!
 
OK....

DOSKBD..... any feasable way of trying to get a solution with it.... ???? Without spending 20 years to do so

Thanks in advance Steve Marshall
Group IT
Technical Support Supervisor
(aka General Meddler)
The Expro Group
Reading
UK
 
Instead of DOSKBD, grab a copy of TAME (check download.com or wherever). Does a much better job of tuning keyboard polling, and can actually be understood by humans... - Bill

"You can get anything you want out of life, if you'll just help enough other people get what they want" - Zig Ziglar
 
I have installed the Oracle8i client purely for ODBC so if ya want screen dumps of the install and recommended minimum components required for ODBC, I can send.
 
Thanks all for your input...

Our DBA has also found some rogue code which is being looked into, but is onlt part of the problem, im getting TAME now, so will see what it does...

Thanks again and again... keep those cogs going ! Steve Marshall
Group IT
Technical Support Supervisor
(aka General Meddler)
The Expro Group
Reading
UK
 
Got this from
A document at JSIINC.com suggests the following...
0986 » How do I tune ill-behaved apps to be good Terminal Server citizens?
If a 16 or 32 bit application uses too many cycles when idle, you can tune the performance by editing the registry. Use Regedt32 to navigate to: HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\Current Version\TerminalServer\Compatibility\Applications
Add Key name YourApplicationExe (without the extension). Leave the Class blank.
Add the following 4 Value names as type REG_DWORD entries: (see the SETUP sub-key if you rather Save Key and Restore):
FirstCountMsgQPeeksSleepBadApp - The default is 0xf (15). This is the number of times the application must query the message queue before Terminal Server decides that it is ill-behaved. Decrease this value to put the application to sleep more often, so it uses less CPU time.
MsgQBadAppSleepTimeInMillisec - The default is 0x1 (1). This is the number of milliseconds the application is suspended when Terminal Server has decided that it is ill-behaved. Increase this value to use less CPU time. If this value is zero, polling detection is disabled.
NthCountMsgQPeeksSleepBadApp - The default is 0x5 (5). This is the number of times the application must query the message queue before it is suspended again. Decrease this value to use less CPU time.
Flags - The default is 0x8 (8). The possible values are:
0x4 (4) for Win16 applications only.
0x8 (8) for Win32 applications only.
0xC (12) for either Win16 or Win32 applications.
You should run performance monitor while tuning the application.
You may want to have a look at the compatibility bits utility which does this graphically for you.
Here is a document from the Citrix KB that explains how to tune your application to make it behave.

Performance Tuning CPU Usage on 16-bit and 32-bit Windows Applications

Synopsis:
Depending on how an application is written, it is possible that a 16-bit or 32-bit Windows application may use too much CPU time even when it`s idle (no keyboard or mouse events).

Details:

This technote documents the use of WinFrame`s polling detection mechanism for Windows 16-bit and 32-bit applications. Some applications constantly look for keyboard input even while they appear to be doing nothing, thereby consuming a great deal of system CPU. WinFrame has built-in logic to detect this behavior. When this type of behavior is detected, the application`s execution is suspended, allowing other applications to utilize the CPU and making multitasking much more efficient. It is necessary to instruct WinFrame to look for this behavior by adding information to the Registry that is specific to the application in question.

Modifying the Registry

1. Run REGEDT32.EXE and locate the following key:

HKEY_LOCAL_MACHINE\SOFTWARE\Citrix\Compatibility\Applications

2. Double-click the Applications subkey to reveal several application settings that are pre-defined. Select SETUP under the Applications subkey. The following values are displayed on the right side of the Registry Editor window:

FirstCountMsgQPeeksSleepBadApp:REG_DWORD:0xF
Flags:REG_DWORD:0xc
MsgQBadAppSleepTimeInMillisec:REG_DWORD:0
NthCountMsgQPeeksSleepBadApp:REG_DWORD:0x5

3. With the SETUP subkey highlighted, select Save Key from the Registry pull-down menu. The filename can be anything, such as SETUP.REG. Once the SETUP values are saved, you need to create a subkey for your application.

4. With the Applications subkey highlighted, choose Add Key on the Edit pull-down menu. Set the Key Name field to the name of the executable in question, minus the extension. For example, for the application MYAPP.EXE, type MYAPP in the Key Name field. Leave the Class field blank. Click OK.

5. To copy the values from the SETUP subkey, select your new subkey (for example, MYAPP) and choose Restore from the Registry pull-down menu. Choose the filename you created in Step 3. Click Yes when the warning dialog box is displayed. Your new application subkey now has the same values as the SETUP subkey.

6. You must now fine tune the values for your application. The values are described in the following sections.

"Bad Application" Registry Values

The default values for the bad application settings are:

FirstCountMsgQPeeksSleepBadApp = 0xF
MsgQBadAppSleepTimeInMillisec = 0x1
NthCountMsgQPeeksSleepBadApp = 0x5
Flags: 0x8

FirstCountMsgQPeeksSleepBadApp is the number of times the application must query the message queue before WinFrame decides that it is ill-behaved. Decrease this value to put the application to sleep more often so it uses less CPU time.

MsgQBadAppSleepTimeInMillisec is the number of milliseconds the application is suspended once WinFrame has decided that it is ill-behaved. Increase this value to use less CPU time. If this value is zero, polling detection is disabled.

NthCountMsgQPeeksSleepBadApp After the application is determined to be "bad," this setting is the number of times the application must query the message queue before it is suspended again. Decrease this value to use less CPU time.

Flags is set to a value corresponding to the type of Windows application. Valid values are:

0x4 for Win16 applications only
0x8 for Win32 applications only
0xC for either Win16 or Win32 applications

"Bad Application" Settings

All values are expressed in hexadecimal. When changing the values, first click
the Decimal button and input the decimal value. For instance, if you want the MsgQBadAppSleepTimeInMillisec value to be set to 200 milliseconds, perform
the following steps:

1. Double click MsgQBadAppSleepTimeInMillisec
2. Click the Decimal radio button
3. Enter 200 in the Data field
4. Click OK

The value is now converted to 0xc8, the hexadecimal equivalent of 200 decimal.

NOTES:

1. To modify polling detection for DOS applications, use the DOSKBD utility.

2. When tuning these parameters, make sure the Performance Monitor up and running. These parameters will affect the amount of CPU used by an application. These parameters usually trade off CPU usage versus application responsiveness.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top