performance / tuning tips. to the point.                
 
About Us | Site Map | Privacy
Disclaimer | Feedback
About RSS Feed | Useful Links
Search Partner Links
Original Blog
Add to My Yahoo!
Google Reader or Homepage
del.icio.us performancewiki.com Latest Items


© 2005-2009 PerformanceWiki.com
All Rights Reserved.


Tech Notes from Performance Engineers



Increase file size limit on Unix

Logon as root.
Go to /etc/security
look at the file called limits
under defaults, locate fsize.
If it's not -1, change it to -1.
This will allow unlimited file sizes.

For example, on AIX, in the limits file, partly it contains:
--
default:
        fsize = 2097151
        core = 2097151
        cpu = -1
        data = 262144
        rss = 65536
        stack = 65536
        nofiles = 131072

root:
        fsize = -1

daemon:
--

For user 'daemon', since "fsize" isn't specified, it will use the default value of "2097151", or 2MB.
For user 'root', file size it deals with is unlimited. You can set it accordingly for your application
user in the 'limits' file.

Kill Remote Desktop Connection (to free up)

When you don't log off Windows Remote Desktop (or terminal service client), the connection becomes
orphaned. You may get the following screen:

Do the following to clean up connections (on Windows 2003 server). 
From a client machines CMD windows:

D:\>query session /SERVER:myserver.myco.com
 SESSIONNAME       USERNAME                 ID  STATE   TYPE        DEVICE
 console                                     0  Conn    wdcon
 rdp-tcp                                 65536  Listen  rdpwd
 rdp-tcp#11        Administrator             1  Active  rdpwd
 rdp-tcp#4         Administrator             2  Active  rdpwd

The above show 2 connections to "myserver". You can kill the sessions with ID 1, 2, 3, so on.

tsdiscon 1 /SERVER:myserver.myco.com

where 1  rdp-tcp#11        Administrator             1  Active  rdpwd "ID" col
Also, can tskill to remotely stop a process

Bypass password changing rules (Unix)

If the password for a user ID expired and rules do NOT allow you to re-use the same password (you need
the same password because it is used in all test cases for your application), do the following to bypass
the rules:

create a shell file that takes a user ID as parameter, say changeuser.sh:

chsec -f /etc/security/lastlog -a "unsuccessful_login_count=0" -s  $1
chuser rlogin='false' loginretries='365' histsize='0' maxage='0' minother='0' $1
pwdadm $1
pwdadm -c $1
chuser rlogin='false' loginretries='5' histsize='4' maxage='26' minother='1' $1


Run NMON as non-root user

You must be the root user or allow regular users to read the 
/dev/kmem file by typing the following command (as root):

        chmod ugo+r /dev/kmem

If you want the disk statistics, then also run (as root):

        chdev -l sys0 -a iostat=true 

Reboot AIX

Restart aix without shutting it down:
% shutdown -Fr

How to validate your IBM Visual Age C++ installation?

To validate your IBM Visual Age C++ installation, re-run the lslpp command: 

lslpp -l vacpp.cmp* 

You should see output that is similar to the following example output. Your actual 
data may vary, depending on the level of software that you install. 
(The example shown here was obtained after installing Version 5.0.2.0): 

vacpp.cmp.C            5.0.2.0  COMMITTED  VisualAge C++ C Compiler
vacpp.cmp.aix43.lib    5.0.2.0  COMMITTED  VisualAge C++ Libraries for AIX 4.3
vacpp.cmp.batch        5.0.2.0  COMMITTED  VisualAge C++ Batch Compiler
vacpp.cmp.core         5.0.2.0  COMMITTED  VisualAge C++ Compiler
vacpp.cmp.extension    5.0.2.0  COMMITTED  VisualAge C++ Extension Interface
vacpp.cmp.include      5.0.2.0  COMMITTED  VisualAge C++ Compiler Include Files 
vacpp.cmp.incremental  5.0.2.0  COMMITTED  VisualAge C++ Incremental Compiler
vacpp.cmp.lib          5.0.2.0  COMMITTED  VisualAge C++ Libraries
vacpp.cmp.rte          5.0.2.0  COMMITTED  VisualAge C++ Compiler Application Runtime 
vacpp.cmp.tools        5.0.2.0  COMMITTED  VisualAge C++ Tools 

Validate DB2 level

For a final verification, type the command 

# db2level

You should see data that is similar to the following example: 

DB21085I Instance "db2inst1" uses DB2 code release "SQL08010"
 with level identifier "01010106".
Informational tokens are "DB2 v8.1.1.0", "s021023", "" and FixPak "0".
Product is installed at "/usr/opt/db2_08_01".

Create Unix user ID and set password

__  1. 
 Create the user IDs: 

# mkuser pgrp=usrgrp1 groups=staff
# mkuser dbconct

__  2. 
 Assign initial passwords. You can set the initial password value to whatever you want
 (for example: "firstone". The first login will prompt you to change the password). 

# passwd dbconct

Hint: If you want to retain the password that you create and prevent operating 
systems from asking you to change the password after the first login, enter 
the following commands: 

# pwdadm -c dbconct
 
__  3. 
 Perform initial login. You are prompted to change the password. 

# login dbconct

Validate DB2 level

For a final verification, type the command 

# db2level

You should see data that is similar to the following example: 

DB21085I Instance "db2inst1" uses DB2 code release "SQL08010"
 with level identifier "01010106".
Informational tokens are "DB2 v8.1.1.0", "s021023", "" and FixPak "0".
Product is installed at "/usr/opt/db2_08_01".