32 vs 64-bit OS determination (was: Re: Installation script for Dell OMSA 6.4 on Debian Lenny)

Mukarram Syed mukarram.syed at 8x8.com
Wed Feb 23 11:43:06 CST 2011


Hi Stephen,
The reason I asked this is because I didn't understand this statement from
the below link:

http://gloriousoblivion..com/2010/12/running-dell-omsa-63-under-debian-lenny.html

"Below are instructions for getting these packages to run under a Debian
Lenny i386 system that is using an x86_64 kernel (if your Dell system
doesn't support a 64-bit kernel then you won't be able to run these OMSA
packages). Unfortunately the packages have a few dependencies on libraries
that only exist in Debian Squeeze and not in Debian Lenny. Rather than doing
lots of backporting, the easiest solution is to create a Squeeze chroot and
run OMSA from there."
*

*So getting back to the resolution to this issue I have in hand is that I
need to install Debian Lenny i386 OS.
What if I use a 32bit debootstrap for --arch i386....which I am trying to do
right now:

debootstrap --arch i386 squeeze /srv/squeeze-i386
and then install OMSA from the instructions in the above link.

Has anyone tried this?
I'll let you know it goes.

Thanks

# mukarram




On Wed, Feb 23, 2011 at 3:18 AM, Stephen Dowdy <sdowdy at ucar.edu> wrote:

>
> It's not entirely clear to me what's being asked, however, here's
> some tidbits of useful info on some aspects of your operating
> environment (cpu/word-size of OS, etc), which i think will
> answer Mukarram's original question:
>
> 'getconf' is, i believe, a POSIX command (well, it works on many
> OS's including Solaris, *BSD, Linux). 'getconf LONG_BIT' will tell
> you the word size of the OS (32 or 64).  It is easier to parse than
> trying to figure out varying 'uname' output (e.g. 386,486,586,686,
> bigmem, vs x86_64, amd64, x64, etc) Also, to check if the processor
> is 64-bit capable both a 32-bit and a 64-bit kernel will indicate
> via /proc/cpuinfo whether your CPU(s) support LONGMODE, which is the
> flag indicating 64-bit capability.
>
> (getconf can give you many other useful info, e.g.:
> $ getconf GNU_LIBC_VERSION
> glibc 2.7
> $ getconf GNU_LIBPTHREAD_VERSION
> NPTL 2.7
> )
>
>
> [ 32-bit capable machine running a 32-bit Debian Lenny ]
> $ getconf LONG_BIT
> 32
> $ uname -a
> Linux lenny32 2.6.26-2-686-bigmem #1 SMP Thu Nov 25 01:59:22 UTC 2010 i686
> GNU/Linux
> $ printf "system does$(egrep -q '^flags.* lm( |$)' /proc/cpuinfo || echo '
> NOT') support 64bit\n"
> system does NOT support 64bit
>
>
> [ 64-bit capable machine running a 32-bit Debian Lenny ]
> # getconf LONG_BIT
> 32
> # uname -a
> Linux lenny64_32 2.6.26-2-686-bigmem #1 SMP Mon Jun 21 06:45:17 UTC 2010
> i686 GNU/Linux
> $ printf "system does$(egrep -q '^flags.* lm( |$)' /proc/cpuinfo || echo '
> NOT') support 64bit\n"
> system does support 64bit
>
>
> [ 64-bit capable machine running a 64-bit Debian Lenny ]
> $ getconf LONG_BIT
> 64
> $ uname -a
> Linux lenny64 2.6.26-2-amd64 #1 SMP Tue Jan 25 05:59:43 UTC 2011 x86_64
> GNU/Linux
> $ printf "system does$(egrep -q '^flags.* lm( |$)' /proc/cpuinfo || echo '
> NOT') support 64bit\n"
> system does support 64bit
>
>
> [ 64-bit on 64-bit capable RHEL ]
> # getconf LONG_BIT
> 64
> # uname -a
> Linux rhel64 2.6.18-194.17.1.el5 #1 SMP Mon Sep 20 07:12:06 EDT 2010 x86_64
> x86_64 x86_64 GNU/Linux
> # printf "system does$(egrep -q '^flags.* lm( |$)' /proc/cpuinfo || echo '
> NOT') support 64bit\n"
> system does support 64bit
>
>
>
> Additionally, you can use 'dmidecode' to see if your processor is
> 64-bit capable...  (this requires 'root', however)
> # dmidecode -t processor | grep '64-bit capable'
>                64-bit capable
>                64-bit capable
>
>
>
> Here's some more useful stuff you can glean from /proc/cpuinfo:
>
> ------------
> get_colon_delim_item() { sed -ne
> "/^[[:space:]]*$1[[:space:]]*:/{s/^.*:[[:space:]]//;p;q}" ;}
> getcpuflag() { egrep -q "^flags[[:space:]]*:.* $1( |\$)" /proc/cpuinfo ;}
>
>         ssi_cpu_count=$(grep 'processor' /proc/cpuinfo | wc -l)
>         ssi_cpu_clock=$(get_colon_delim_item 'cpu MHz' < /proc/cpuinfo)
>       ssi_cpu_sockets=$(get_colon_delim_item 'physical id' < /proc/cpuinfo)
>       ssi_cpu_sockets=$(grep 'physical id' /proc/cpuinfo | sort | uniq | wc
> -l)
> ssi_cpu_cores_per_chip=$(get_colon_delim_item 'cpu cores'  < /proc/cpuinfo)
> ssi_cpu_cores_per_chip=${ssi_cpu_cores_per_chip:-1}
>    ssi_cpu_core_count=$(expr ${ssi_cpu_sockets} \*
> ${ssi_cpu_cores_per_chip})
>      ssi_cpu_siblings=$(get_colon_delim_item 'siblings'  < /proc/cpuinfo)
>      ssi_cpu_siblings=${ssi_cpu_siblings:-1}
>         ssi_cpu_is_ht="$(if [ ${ssi_cpu_siblings} -gt
> ${ssi_cpu_cores_per_chip} ]; then echo 1; else echo 0; fi)"
>         ssi_cpu_is_mc="$(if [ ${ssi_cpu_cores_per_chip} -gt 1 ]; then echo
> 1; else echo 0; fi)"
>
> ssi_cpu_cap_vmx="$(if getcpuflag vmx; then echo 1; else echo 0; fi)"
> ssi_cpu_cap_svm="$(if getcpuflag svm; then echo 1; else echo 0; fi)"
> ssi_cpu_cap_pae="$(if getcpuflag pae; then echo 1; else echo 0; fi)"
> ssi_cpu_cap_nx="$(if getcpuflag nx; then echo 1; else echo 0; fi)"
> ssi_cpu_cap_ht="$(if getcpuflag ht; then echo 1; else echo 0; fi)"
> ssi_cpu_cap_lm="$(if getcpuflag lm; then echo 1; else echo 0; fi)"
> ------------
>
> $ set | grep ssi_
> You'll see output like:  (without the comments)
>
> ssi_cpu_cap_ht=1            Hyperthreading or Symmetric Multithreading
> ssi_cpu_cap_lm=1            Long-Mode (64-bit capable cpu)
> ssi_cpu_cap_nx=1            NoExec (Stack Protection)
> ssi_cpu_cap_pae=1           Programmable Address Extensions (32-bit
> extension to address >4GB physmem)
> ssi_cpu_cap_svm=0           AMD cpu virtualization
> ssi_cpu_cap_vmx=1           Intel cpu virtualization (Vanderpool)
> ssi_cpu_clock=2266.745      CPU clock speed (approximate, in MHz)
> ssi_cpu_core_count=4        Total core count
> ssi_cpu_cores_per_chip=4    CPU Cores per CPU package
> ssi_cpu_count=8             Total CPU Count (incl cores + HT/SMT instances)
> ssi_cpu_is_ht=1             Is Hyperthreading/SMT enabled
> ssi_cpu_is_mc=1             Is system Multi-Cored?
> ssi_cpu_siblings=8          Total # cpu siblings per package (cores+HT/SMT)
> ssi_cpu_sockets=1           # Sockets available on motherboard
>
> --stephen
>
>
> Gmaurice wrote, On 02/23/2011 02:28 AM:
> > Hi Mukarram (am i right with your first name ?),
> >
> > I'm using x86_64 Debian Lenny.
> >
> > Type "uname -a" to know if you are on x86_64 or i386.
> > It gave me :
> > Linux node1 2.6.32-4-pve #1 SMP Wed Dec 15 14:04:31 CET 2010 x86_64
> GNU/Linux
> > I'm using "pve" comes from ProxmoxVE distribution.
> >
> >
> > Le 23/02/11 03:48, Mukarram Syed a écrit :
> >> Hi,
> >> How do I know if I am running a  Debian Lenny i386 system that is using
> an x86_64 kernel...
> >> *
> >> *
> >> This is my kernel
> >> Debian GNU/Linux, kernel 2.6.29-bpo.2-686-bigmem
> >> ...and I am running this on R410 which could support x86_64 (64bit)
> installs.
>
> _______________________________________________
> Linux-PowerEdge mailing list
> Linux-PowerEdge at dell.com
> https://lists.us.dell.com/mailman/listinfo/linux-poweredge
> Please read the FAQ at http://lists.us.dell.com/faq
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.us.dell.com/pipermail/linux-poweredge/attachments/20110223/e2b52931/attachment-0001.htm 


More information about the Linux-PowerEdge mailing list