- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: TOP Memory Sorting
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
12-06-2006 03:36 AM
12-06-2006 03:36 AM
So...is there a way to sort by the RES column in TOP? I've read threads where supposedly the 'M' command while in TOP will sort that column...but no dice. This is on HP-UX B.11.23.
Any comments appreciated, thanks in advance.
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-06-2006 03:50 AM
12-06-2006 03:50 AM
SolutionYou can use 'ps' under the XPG4 (UNIX95) option and sort processes by descending process size:
# UNIX95= ps -e -o "user,vsz,pid,ppid,args" | awk 'NR>1' | sort -rnk2
Note the blank (space) character after the equal sign and before the 'ps' command. This 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
12-06-2006 04:27 AM
12-06-2006 04:27 AM
Re: TOP Memory Sorting
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-06-2006 04:59 AM
12-06-2006 04:59 AM
Re: TOP Memory Sorting
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-06-2006 05:35 AM
12-06-2006 05:35 AM
Re: TOP Memory Sorting
William LeFebvre's version of top, available at the Porting and Archiving Center, does support sorting top output by a number of fields, including res.
According to top(1):
-ofield
Sort the process display area on the specified field. The field
name is the name of the column as seen in the output, but in
lower case. Likely values are "cpu", "size", "res", and "time",
but may vary on different operating systems. Note that not all
operating systems support this option.
http://hpux.connect.org.uk/hppd/hpux/Sysadmin/top-3.6alpha9/man.html
PCS