Linux - Newbie This forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to
LinuxQuestions.org , a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free.
Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please
contact us . If you need to reset your password,
click here .
05-19-2009, 08:42 AM
#1
Member
Registered: Apr 2009
Location: ~
Distribution: RHEL, Fedora
Posts: 165
Thanked: 21
32 bit or 64 bit
[
Log in to
get rid of this advertisement]
is there any way/command to find that the linux machine is a 32 bit or 64 bit
05-19-2009, 08:47 AM
#2
Senior Member
Registered: Apr 2008
Location: Nagpur, India
Distribution: Ubuntu Karmic, CentOS 5.4
Posts: 2,487
Thanked: 158
You can find what version of kernel you are using by uname -a or uname -m
05-19-2009, 08:48 AM
#3
Member
Registered: Apr 2009
Location: ~
Distribution: RHEL, Fedora
Posts: 165
Thanked: 21
Original Poster
it says i686 now what type of machine is it
05-19-2009, 08:53 AM
#4
Guru
Registered: Sep 2003
Location: Bologna, Italia
Distribution: OpenSUSE 11.1 CentOS 5.4 VectorLinux 6.0
Posts: 5,127
Thanked: 463
The uname command tells you if the
kernel is 32-bit or 64-bit. i686 means 32-bit (otherwise it would be x86_64). To discover if the
CPU is 32 or 64-bit do:
Code:
grep flags /proc/cpuinfo | grep lm
if output is null you have a 32-bit CPU, if output is non null the CPU is 64-bit. lm stats for "Long Mode" that is a feature of 64-bit machines.
Last edited by colucix; 05-19-2009 at 08:54 AM ..
05-19-2009, 08:53 AM
#5
Senior Member
Registered: May 2001
Location: Belgium
Distribution: Debian/GNU Linux
Posts: 4,504
Thanked: 441
i686 means a 32 bit machine
x86_64 means 64 bit
Code:
grep flags /proc/cpuinfo
lm means Long mode - 64 bit CPU
Real mode 16 bit CPU
Protected Mode is 32-bit CPU
05-19-2009, 08:53 AM
#6
Senior Member
Registered: Apr 2008
Location: Nagpur, India
Distribution: Ubuntu Karmic, CentOS 5.4
Posts: 2,487
Thanked: 158
Mine also says i686 and is 32bit.
05-19-2009, 09:24 AM
#7
Member
Registered: Apr 2009
Location: ~
Distribution: RHEL, Fedora
Posts: 165
Thanked: 21
Original Poster
This is what i get when i do
grep flags /proc/cpuinfo
flags : fpu vme de pse tsc msr pae mce cx8 apic mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe constant_tsc pni monitor ds_cpl cid xtpr
flags : fpu vme de pse tsc msr pae mce cx8 apic mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe constant_tsc pni monitor ds_cpl cid xtpr
uname -m gives
i686
Then it should be 64 bit if i am not worng
05-19-2009, 09:25 AM
#8
Member
Registered: Apr 2009
Location: ~
Distribution: RHEL, Fedora
Posts: 165
Thanked: 21
Original Poster
I am sorry the output was
grep flags /proc/cpuinfo | grep --color lm
flags : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe nx lm constant_tsc pni monitor ds_cpl vmx est tm2 cx16 xtpr lahf_lm
flags : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe nx lm constant_tsc pni monitor ds_cpl vmx est tm2 cx16 xtpr lahf_lm
05-19-2009, 09:30 AM
#9
Guru
Registered: Sep 2003
Location: Bologna, Italia
Distribution: OpenSUSE 11.1 CentOS 5.4 VectorLinux 6.0
Posts: 5,127
Thanked: 463
Quote:
Originally Posted by
PMP
flags : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe nx lm constant_tsc pni monitor ds_cpl vmx est tm2 cx16 xtpr lahf_lm
You have a 64-bit machine with a 32-bit OS (kernel) installed.
05-19-2009, 09:31 AM
#10
Senior Member
Registered: May 2001
Location: Belgium
Distribution: Debian/GNU Linux
Posts: 4,504
Thanked: 441
the processor is 64 bit
the kernel is 32 bit
05-19-2009, 09:35 AM
#11
LQ Newbie
Registered: May 2009
Location: San Antonio, Texas
Distribution: CentOS, SunOS
Posts: 5
Thanked: 0
On my CentOS boxes I look in root and If I see a lib64 directory then it is 64 bit.
Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
All times are GMT -5. The time now is 01:20 AM .
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know .
Latest Threads
LQ News
LQ Podcast
LQ Radio