How can I determine the architecture of my Red Hat Enterprise Linux system?


Red Hat Enterprise Linux 5
Red Hat Enterprise Linux 4


Red Hat Enterprise Linux is available for various 32-bit and 64-bit platforms.

There are two methods to determine what architecture of Red Hat Enterprise Linux you are running.

1) The output of “uname -a

Example output on a 32-bit system:

Linux my32bitsystem 2.6.18-53.1.4.el5 #1 SMP Wed Nov 14 10:37:33 EST 2007 i686 i686 i386 GNU/Linux
The i686 indicates this is a 32-bit system.

Example output on a 64-bit system:

Linux my64bitsystem 2.6.18-53.1.6.el5xen #1 SMP Wed Jan 16 04:10:44 EST 2008 x86_64 x86_64 x86_64 GNU/Linux
The x86_64 indicates this is a 64-bit system. Note that 64-bit hardware can also run 32-bit software.

2) The output of “arch
Example output on a 64bit PowerPC system:

[root@power5-2 getconf]# arch

getconfig LONG_BIT is not a good method. Because the result is determined by soft link /usr/libexec/getconf/default.
Different target of soft link, different result. For a example:

[root@power5-2 getconf]# getconf LONG_BIT
[root@power5-2 getconf]# mv default default.bak
[root@power5-2 getconf]# ln -s POSIX_V6_LP64_OFF64 default
[root@power5-2 getconf]# ll
total 48
lrwxrwxrwx 1 root root 19 Sep 22 22:55 default -> POSIX_V6_LP64_OFF64
lrwxrwxrwx 1 root root 20 Jul 28 00:32 default.bak -> POSIX_V6_ILP32_OFF32
-rwxr-xr-x 1 root root 0 Sep 22 22:54 POSIX_V6_ILP32_OFF32
-rwxr-xr-x 1 root root 19892 Jan 9 2009 POSIX_V6_ILP32_OFFBIG
-rwxr-xr-x 1 root root 26264 Jan 10 2009 POSIX_V6_LP64_OFF64
[root@power5-2 getconf]# getconf LONG_BIT
[root@power5-2 getconf]#

Leave a Reply

You must be logged in to post a comment.