# uname -m
i386 or i686 then it is 32 bit
x86_64 is 64bit
HP –UNIX Machine:
# getconf KERNEL_BITS
# ps -ef |grep RT
# file /stand/vmunix
If 64 bit it will show something like: ELF-64 executable object file
Sun Solaris Machine:
# isainfo -v
Windows XP/2003 Machine:
Click Start, and then click Run. Type winmsd.exe, and then click OK.
When System Summary is selected in the navigation pane, locate Processor under Item in the details pane. Note the value. If the value that corresponds to Processor starts with x86, the computer is running a 32-bit version of Windows. If the value that corresponds to Processor starts with ia64 or AMD64, the computer is running a 64-bit version of Windows.
Windows Vista/Windows 7 Machine:
Click Start, type system in the Start Search box, and then click System Information in the Programs list. When System Summary is selected in the navigation pane, the operating system is displayed as follows:
For a 64-bit version operating system: x64-based PC appears for the System type under Item.
For a 32-bit version operating system: x86-based PC appears for the System type under Item.