Find out your computer architecture

From LQWiki
Jump to: navigation, search

Sometimes, e.g. when you compile a kernel, you need to know your computer's architecture, also called platform. Existing platforms are listed here.

To find out the architecture your running kernel was built for, open a console and enter the command

uname --hardware-platform

and example response is

x86_64

Now there is a problem because on x64 hardware, both x64 and x86_32 kernels can run. To find out if your processor supports x86_64 commands, use the command

 hwinfo --cpu | grep -m 1 Features

If lm (long mode) is in the list of features, your processor supports x86_64 commands.