- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: How to check for memory leak
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-21-2003 10:04 AM
07-21-2003 10:04 AM
One way I can think of is to check the value of free memory after each start and see if it goes down.
Is there a better way?
How to check to value of free memory, I do not have root access.
Thanks
Charles
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-21-2003 10:13 AM
07-21-2003 10:13 AM
SolutionUNIX95= ps -e -o vsz=Kbytes -o pid,args=Command-Line | sort -rnk1
It is all one line.
Then try it again later to find out what is using the most memory.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-21-2003 10:13 AM
07-21-2003 10:13 AM
Re: How to check for memory leak
UNIX95= ps -u oracle -o vsz,comm
That will display the current size of all oracle owned processes along with the name of the command. If you see that some of them grow significantly over time, there is your leak.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-21-2003 10:22 AM
07-21-2003 10:22 AM
Re: How to check for memory leak
Run this periodically and watch for growth in the process size:
...If you want to target a specific process by its command basename:
# UNIX95= ps -C thebasename -o "user,vsz,pid,ppid,args"
,,,or, if you want to look at all processes by descending process size:
# UNIX95= ps -e -o "user,vsz,pid,ppid,args" | awk 'NR>1' | sort -rnk2
In both cases, the blank (space) character after the equal sign and before the 'ps' command sets the UNIX95 option for the command line only.
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-21-2003 10:24 AM
07-21-2003 10:24 AM
Re: How to check for memory leak
Is there a way just to see how much memory is free, after each re-start of the oracle software. This server only runs this one oracle software, plus the systems software.
If the oracle software leaks memory, I will have to reboot the server.
Thanks
Charles
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-21-2003 10:28 AM
07-21-2003 10:28 AM
Re: How to check for memory leak
Oracles notes say the latest greatest patches address this issue. Oracle hasn't seemed to be able to get ias out the door without this problem.
You should follow the checklist below to minimize this and other problems:
java is on the latest version from http://www.hp.com/go/java and all required patches for your version are in. I believe that java 1.4 is not certified for any Oracle products. Take care that SHLIB_PATH is correct.
Oracle's required OS patches for 9ias, and the database are installed. Check this site for supersedes, almost nothing listed on http://metalkink.oracle.com is current with regards to HP-UX.
As always, I am most impressed with the commands listed by the esteemed Olympians.
SEP
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-21-2003 10:29 AM
07-21-2003 10:29 AM
Re: How to check for memory leak
Thanks
Charles
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-21-2003 10:47 AM
07-21-2003 10:47 AM
Re: How to check for memory leak
Memory leaks are programming errors. The "fix" is to correct the code. No amount of tuning is going to help.
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-21-2003 12:14 PM
07-21-2003 12:14 PM
Re: How to check for memory leak
Thanks
Charles
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-21-2003 12:15 PM
07-21-2003 12:15 PM
Re: How to check for memory leak
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-21-2003 12:17 PM
07-21-2003 12:17 PM
Re: How to check for memory leak
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-21-2003 12:22 PM
07-21-2003 12:22 PM
Re: How to check for memory leak
I would still like to get a command to just show me the free memory available everytime before I restart the 9iAS software. (Similar to what I can with top)
Thanks
Charles
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-21-2003 12:35 PM
07-21-2003 12:35 PM
Re: How to check for memory leak
With regard to your question of how to discover the free memory, do:
# echo freemem/D|adb /stand/vmunix /dev/kmem
The value returned is in 'pages'.
# getconf PAGE_SIZE
...returns the PAGE_SIZE (usually 4096 bytes). Thus if I have:
# echo freemem/D|adb /stand/vmunix /dev/kmem
freemem:
freemem: 39697
...with a PAGE_SIZE of 4096, I have:
39697*4095 = 162,598,912 bytes free
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-21-2003 01:01 PM
07-21-2003 01:01 PM
Re: How to check for memory leak
I do not have root access. Is there a way to get the free memory without root access?
Thanks
Charles
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-21-2003 05:09 PM
07-21-2003 05:09 PM
Re: How to check for memory leak
#!/bin/ksh
m=0
for j in `UNIX95= ps -e -o vsz=Kbytes -o ruser -o pid,args=Command-Line | sort -
rnk1 | grep -v Kbytes | grep ora | awk '{print $1}'`
do
m=`expr $m + $j`
done
echo "\n Oracle user claimed RAM is $m Kbytes.\n"
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-21-2003 05:18 PM
07-21-2003 05:18 PM
Re: How to check for memory leak
If you don't have root access you can check free memory on the system using either glance ('m' option) if its installed or vmstat.
In vmstat look at the "free" column & multiply by 4 to give free memory in KB.
Example:
# vmstat 1 2| tail -1 | awk '{printf "%d\n", ($5*4)/1024}'
This will show free menory in MB.
Cheers
Con
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-22-2003 04:02 AM
07-22-2003 04:02 AM
Re: How to check for memory leak
Sorry for my English.
May be it is parameters of mod PLSQL. Try off/on kache parameters (http://...../pls/admin_/)....
It helped us.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-22-2003 04:48 AM
07-22-2003 04:48 AM
Re: How to check for memory leak
One good way of checking it is as follows-
1 reboot server, do not start anything, note down mem utilization.
2. Start 9iAS, note down mem utilization
3 shut it down and again note down mem utilization.
4. Now this value at step 4 should almost match to the value taken at step 1
This is lengthy process, but would give you if 9iAS is causing the problem
You can also check the file proc_mem_leak under /opt/perf/examples/adviser.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-15-2005 03:29 AM
09-15-2005 03:29 AM