Sponsored Content
Operating Systems HP-UX How should I know the total RAM available on UNIX Post 302108193 by hildymon on Friday 23rd of February 2007 05:06:07 PM
Old 02-23-2007
Script for finding hardware information

I put this together for 11.00 and now 11.11 servers - just copy and paste into a ksh script and run.

#!/bin/ksh
# Collect system information
# System
echo Name: `hostname`
echo Model: `model`
echo OS: `uname`
echo OS Level: `uname -r`
#
# Memory:
#
HPUX=/stand/vmunix
MAJORREV=$(uname -r | cut -f2 -d .)
if [ $MAJORREV -ge "11.0" ]
then
MYSYMBOL="phys_mem_pages"
else
MYSYMBOL="physmem"
fi
MYMEM=$(echo "${MYSYMBOL}/D" | adb $HPUX /dev/kmem | grep "${MYSYMBOL}: *." | awk '{print $2*4/1024}')
echo Memory: $MYMEM
#
# Number of processors
#
echo Processors: `sar -Mu 1 1|awk 'END {print NR-5}' `
#
# Processor speed:
#
HPUX=/stand/vmunix
MHZ=$(echo itick_per_tick/D | adb -k $HPUX /dev/kmem | tail -1 | awk '{print $2/10000}')
echo Process Speed: $MHZ
 

9 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

UNIX for 386 SX 4MB RAM

How, where from and which UNIX or LINUX can I download so that I can use it normally working on 386 SX 4MB RAM. I want to use only its basic functions and C and C++ compiler on it. I need it for my studies. P.S I need a stable UNIX or LINUX including a full set of functions of C... (4 Replies)
Discussion started by: Traiancho
4 Replies

2. UNIX for Dummies Questions & Answers

Total ram

Hi How can i find the total ram in the system? :confused: (4 Replies)
Discussion started by: orca
4 Replies

3. UNIX for Dummies Questions & Answers

RAM size in Digital unix

Hi All Im currntly working on a digital unix machine and must know what is the amount of MB\GB instaled ( i do not have physical access to the machine). can anyone help me here? 10x!!!!!!!!!!!!!!! (1 Reply)
Discussion started by: dindan100
1 Replies

4. UNIX for Advanced & Expert Users

RAM Drive in UNIX?

Hello, I will be processing 47000 zip files each of size 5.5 MB. Following operation will be performed for each zip file: 1. Unzip the file. 2. Read each text and binary file. 3. Preprocess the files. 4. Store the files in different tables in Oracle. 5. Delete the extracted... (7 Replies)
Discussion started by: joshivaibhav
7 Replies

5. Shell Programming and Scripting

View the Server Total Ram in GB

Hello, I want to view server RAM in GB i.e 4 GB or 6 GB via command line to use it in bash script waiting Any Ideas :) Thanks :):) (2 Replies)
Discussion started by: LinuxCommandos
2 Replies

6. Red Hat

red hat Linux 5.0 is detecting 3gb ram but physical ram is 16gb

Hi, On server 64bit Hw Arch , Linux 5.0(32bit) is installed it is showing only 3gb of ram though physical is 16gb can u give me idea why? (4 Replies)
Discussion started by: manoj.solaris
4 Replies

7. Shell Programming and Scripting

Calculate total space, total used space and total free space in filesystem names matching keyword

Good afternoon! Im new at scripting and Im trying to write a script to calculate total space, total used space and total free space in filesystem names matching a keyword (in this one we will use keyword virginia). Please dont be mean or harsh, like I said Im new and trying my best. Scripting... (4 Replies)
Discussion started by: bigben1220
4 Replies

8. UNIX for Dummies Questions & Answers

Total RAM not recognised

Hi We have a redhat 4 with 8GB ram in it but free -m only recognises 3 GB of total ram please could some one help me why this happens HP syetems insight manager showing 4* 2 GB RAMS # free -m total used free shared buffers cached Mem: 3290... (6 Replies)
Discussion started by: robo
6 Replies

9. Shell Programming and Scripting

How to read total RAM in GBs?

I am aware of the commands to find the total RAM on Linux and Unix for example vmstat. Can you please tell me which tool / command can give me the Total RAM reading in GBs on Solaris Unix and Linux ? (2 Replies)
Discussion started by: mohtashims
2 Replies
echo(1B)					     SunOS/BSD Compatibility Package Commands						  echo(1B)

NAME
echo - echo arguments to standard output SYNOPSIS
/usr/ucb/echo [-n] [argument] DESCRIPTION
echo writes its arguments, separated by BLANKs and terminated by a NEWLINE, to the standard output. echo is useful for producing diagnostics in command files and for sending known data into a pipe, and for displaying the contents of envi- ronment variables. For example, you can use echo to determine how many subdirectories below the root directory (/) is your current directory, as follows: o echo your current-working-directory's full pathname o pipe the output through tr to translate the path's embedded slash-characters into space-characters o pipe that output through wc -w for a count of the names in your path. example% /usr/bin/echo "echo $PWD | tr '/' ' ' | wc -w" See tr(1) and wc(1) for their functionality. The shells csh(1), ksh(1), and sh(1), each have an echo built-in command, which, by default, will have precedence, and will be invoked if the user calls echo without a full pathname. /usr/ucb/echo and csh's echo() have an -n option, but do not understand back-slashed escape characters. sh's echo(), ksh's echo(), and /usr/bin/echo, on the other hand, understand the black-slashed escape characters, and ksh's echo() also understands a as the audible bell character; however, these commands do not have an -n option. OPTIONS
-n Do not add the NEWLINE to the output. ATTRIBUTES
See attributes(5) for descriptions of the following attributes: +-----------------------------+-----------------------------+ | ATTRIBUTE TYPE | ATTRIBUTE VALUE | +-----------------------------+-----------------------------+ |Availability |SUNWscpu | +-----------------------------+-----------------------------+ SEE ALSO
csh(1), echo(1), ksh(1), sh(1), tr(1), wc(1), attributes(5) NOTES
The -n option is a transition aid for BSD applications, and may not be supported in future releases. SunOS 5.10 3 Aug 1994 echo(1B)
All times are GMT -4. The time now is 08:35 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy