Redhat and kernel question

Jeff Macdonald jeff.macdonald at virtualbuilder.com
Thu Mar 13 10:36:32 EST 2003


On Thu, 2003-03-13 at 10:03, bscott at ntisys.com wrote:
> On 13 Mar 2003, at 9:44am, jeff.macdonald at virtualbuilder.com wrote:
> > How can I tell what CPU the kernel was compiled for?
> 
>   I believe 'uname -m' will indicate what CPU the currently running kernel
> was compiled for.
> 
> > It seems the query options of RPM don't show this info, or am I blind
> > today?
> 
>   Not by default.  This will:
> 
> 	rpm -q kernel --qf '%{NAME}-%{VERSION}-%{RELEASE} %{ARCH}\n'


Ah, I am blind. I saw that --qf option but didn't see the --querytags
option for listing the valid tags. As I was doing that command line to
see the tag list I think I found a bug in gnome-terminal and/or ssh (I'm
using Redhat 8.0). Try this after ssh'ing to a remote redhat 8.0 system
from a redhat 8.0 system (don't do it to localhost).

$ rpm --querytags <hit return>
<hit up arrow for history>
<move cursor to just before the double dash>
<hit the dash key>

The connection gets dropped. Weird.

Derek and Bayard responded with some options too:

uname -m

and

look at /boot (the file kernel.h has the needed info).

anybody notice the new options to uname? Heck, some of options don't
even seem to be the same thing anymore! And is it just me, or could -m,
-p and -i all be mistaken as the flags I wanted? 

[redhat 8.0]$ uname --help
Usage: uname [OPTION]...
Print certain system information.  With no OPTION, same as -s.

  -a, --all                print all information, in the following order:
  -s, --kernel-name        print the kernel name
  -n, --nodename           print the network node hostname
  -r, --kernel-release     print the kernel release
  -v, --kernel-version     print the kernel version
  -m, --machine            print the machine hardware name
  -p, --processor          print the processor type
  -i, --hardware-platform  print the hardware platform
  -o, --operating-system   print the operating system
      --help     display this help and exit
      --version  output version information and exit

[redhat 7.3]$ uname --help
Usage: uname [OPTION]...
Print certain system information.  With no OPTION, same as -s.

  -a, --all        print all information
  -m, --machine    print the machine (hardware) type
  -n, --nodename   print the machine's network node hostname
  -r, --release    print the operating system release
  -s, --sysname    print the operating system name
  -p, --processor  print the host processor type
  -v               print the operating system version
      --help       display this help and exit
      --version    output version information and exit


Ah, the info page makes it clearer, I think I want -p:

`-p'
`--processor'
     Print the processor type (sometimes called the instruction set
     architecture or ISA).


Anyhow, thanks for the replies.


-- 
Jeff Macdonald <jeff.macdonald at virtualbuilder.com>




More information about the gnhlug-discuss mailing list