Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.user > #244851 > unrolled thread

i386 or AMD64 - Which is currently running?

Started byRichard Owlett <rowlett@cloud85.net>
First post2022-01-31 13:40 +0100
Last post2022-01-31 20:20 +0100
Articles 20 on this page of 29 — 12 participants

Back to article view | Back to linux.debian.user


Contents

  i386 or AMD64 - Which is currently running? Richard Owlett <rowlett@cloud85.net> - 2022-01-31 13:40 +0100
    Re: i386 or AMD64 - Which is currently running? Curt <curty@free.fr> - 2022-01-31 13:40 +0100
      Re: i386 or AMD64 - Which is currently running? Richard Owlett <rowlett@cloud85.net> - 2022-01-31 17:00 +0100
        Re: i386 or AMD64 - Which is currently running? Curt <curty@free.fr> - 2022-01-31 17:40 +0100
          Re: i386 or AMD64 - Which is currently running? Greg Wooledge <greg@wooledge.org> - 2022-01-31 17:40 +0100
            Re: i386 or AMD64 - Which is currently running? Brian <ad44@cityscape.co.uk> - 2022-01-31 21:10 +0100
              Re: i386 or AMD64 - Which is currently running? Stefan Monnier <monnier@iro.umontreal.ca> - 2022-01-31 22:40 +0100
                Re: i386 or AMD64 - Which is currently running? Greg Wooledge <greg@wooledge.org> - 2022-01-31 22:50 +0100
                  Re: i386 or AMD64 - Which is currently running? Stefan Monnier <monnier@iro.umontreal.ca> - 2022-02-01 03:10 +0100
                    Re: i386 or AMD64 - Which is currently running? David Wright <deblis@lionunicorn.co.uk> - 2022-02-01 04:00 +0100
                      Re: i386 or AMD64 - Which is currently running? Stefan Monnier <monnier@iro.umontreal.ca> - 2022-02-01 06:30 +0100
                    Re: i386 or AMD64 - Which is currently running? Michael Stone <mstone@debian.org> - 2022-02-01 04:20 +0100
                      Re: i386 or AMD64 - Which is currently running? Stefan Monnier <monnier@iro.umontreal.ca> - 2022-02-01 06:40 +0100
                        Re: i386 or AMD64 - Which is currently running? Michael Stone <mstone@debian.org> - 2022-02-01 14:40 +0100
                Re: i386 or AMD64 - Which is currently running? Richard Owlett <rowlett@cloud85.net> - 2022-02-01 01:40 +0100
                Re: i386 or AMD64 - Which is currently running? <tomas@tuxteam.de> - 2022-02-01 06:50 +0100
                Re: i386 or AMD64 - Which is currently running? Curt <curty@free.fr> - 2022-02-01 13:30 +0100
                  Re: i386 or AMD64 - Which is currently running? Stanislav Vlasov <stanislav.v.v@gmail.com> - 2022-02-01 17:20 +0100
                    Re: i386 or AMD64 - Which is currently running? Curt <curty@free.fr> - 2022-02-01 18:50 +0100
              CLARIFICATION --- Re: i386 or AMD64 - Which is currently running? Richard Owlett <rowlett@cloud85.net> - 2022-02-01 01:40 +0100
                Re: CLARIFICATION --- Re: i386 or AMD64 - Which is currently running? songbird <songbird@anthive.com> - 2022-02-01 07:20 +0100
                  Re: CLARIFICATION --- Re: i386 or AMD64 - Which is currently running? Richard Owlett <rowlett@cloud85.net> - 2022-02-01 13:10 +0100
        Re: i386 or AMD64 - Which is currently running? Stefan Krusche <linux@stefan-krusche.de> - 2022-02-01 11:50 +0100
    Re: i386 or AMD64 - Which is currently running? Greg Wooledge <greg@wooledge.org> - 2022-01-31 14:40 +0100
      Re: i386 or AMD64 - Which is currently running? David Wright <deblis@lionunicorn.co.uk> - 2022-01-31 17:50 +0100
    Re: i386 or AMD64 - Which is currently running? Teemu Likonen <tlikonen@iki.fi> - 2022-01-31 14:40 +0100
      Re: i386 or AMD64 - Which is currently running? Greg Wooledge <greg@wooledge.org> - 2022-01-31 14:40 +0100
    Re: i386 or AMD64 - Which is currently running? Stefan Monnier <monnier@iro.umontreal.ca> - 2022-01-31 14:40 +0100
    Re: i386 or AMD64 - Which is currently running? David Wright <deblis@lionunicorn.co.uk> - 2022-01-31 20:20 +0100

Page 1 of 2  [1] 2  Next page →


#244851 — i386 or AMD64 - Which is currently running?

FromRichard Owlett <rowlett@cloud85.net>
Date2022-01-31 13:40 +0100
Subjecti386 or AMD64 - Which is currently running?
Message-ID<DLE8p-3SP-1@gated-at.bofh.it>
Due to historical circumstances, I have laptops which multi-boot various 
Debian releases. There be 32 bit and 64 bit versions of the same release 
on a particular machine.

1. From current console, how can I determine which is running?
    [ equivalent of /etc/debian_version would be ideal ]

2. As superuser, how can I determine which is installed on a different
    partition?
    [ My typical installation routine has been a descriptive label for
      each root partition. But not always done ;{ ]

Web search gave plethora of hits related to which to install. Nothing 
for my particular question.

TIA

[toc] | [next] | [standalone]


#244852

FromCurt <curty@free.fr>
Date2022-01-31 13:40 +0100
Message-ID<DLE8p-3SP-3@gated-at.bofh.it>
In reply to#244851
On 2022-01-31, Richard Owlett <rowlett@cloud85.net> wrote:
> Due to historical circumstances, I have laptops which multi-boot various 
> Debian releases. There be 32 bit and 64 bit versions of the same release 
> on a particular machine.
>
> 1. From current console, how can I determine which is running?
>     [ equivalent of /etc/debian_version would be ideal ]

 uname -m


> 2. As superuser, how can I determine which is installed on a different
>     partition?
>     [ My typical installation routine has been a descriptive label for
>       each root partition. But not always done ;{ ]

If the superuser doesn't know, I surely don't know.

> Web search gave plethora of hits related to which to install. Nothing 
> for my particular question.

Inexplicable.

> TIA
>
>
>


-- 

[toc] | [prev] | [next] | [standalone]


#244868

FromRichard Owlett <rowlett@cloud85.net>
Date2022-01-31 17:00 +0100
Message-ID<DLHfY-5Gb-3@gated-at.bofh.it>
In reply to#244852
On 01/31/2022 06:37 AM, Curt wrote:
> On 2022-01-31, Richard Owlett <rowlett@cloud85.net> wrote:
>> Due to historical circumstances, I have laptops which multi-boot various
>> Debian releases. There be 32 bit and 64 bit versions of the same release
>> on a particular machine.
>>
>> 1. From current console, how can I determine which is running?
>>      [ equivalent of /etc/debian_version would be ideal ]
> 
>   uname -m

That returns a related piece of information.
"uname -r" better answers the question I asked.
*HOWEVER*, Greg's response, "The real command the OP is looking for is 
dpkg --print-architecture", answers the question I _should have_ asked.

> 
> 
>> 2. As superuser, how can I determine which is installed on a different
>>      partition?
>>      [ My typical installation routine has been a descriptive label for
>>        each root partition. But not always done ;{ ]
> 
> If the superuser doesn't know, I surely don't know.

I was trying to determine what another boot-able OS on the machine would do.

I suspect the appropriate use of the "--admindir=?????" option to 
"dpkg-query" may be appropriate [I need to carefully re-read man-pages 
for dpkg-query and dpkg.]


> 
>> Web search gave plethora of hits related to which to install. Nothing
>> for my particular question.
> 
> Inexplicable.

No. I needed a different set of search terms or an wise search engine.

> 

Thanks for the responses received so far - especially Greg's mind-reading.

[toc] | [prev] | [next] | [standalone]


#244869

FromCurt <curty@free.fr>
Date2022-01-31 17:40 +0100
Message-ID<DLHSF-68t-3@gated-at.bofh.it>
In reply to#244868
On 2022-01-31, Richard Owlett <rowlett@cloud85.net> wrote:
> On 01/31/2022 06:37 AM, Curt wrote:
>> On 2022-01-31, Richard Owlett <rowlett@cloud85.net> wrote:
>>> Due to historical circumstances, I have laptops which multi-boot various
>>> Debian releases. There be 32 bit and 64 bit versions of the same release
>>> on a particular machine.
>>>
>>> 1. From current console, how can I determine which is running?
>>>      [ equivalent of /etc/debian_version would be ideal ]
>> 
>>   uname -m
>
> That returns a related piece of information.

Are you saying that that doesn't reveal whether I've installed a 64 or a 32
bit release?

[toc] | [prev] | [next] | [standalone]


#244871

FromGreg Wooledge <greg@wooledge.org>
Date2022-01-31 17:40 +0100
Message-ID<DLHSG-68t-17@gated-at.bofh.it>
In reply to#244869
> >>   uname -m

> Are you saying that that doesn't reveal whether I've installed a 64 or a 32
> bit release?

It does not.  It only reveals which kernel is running.

As I said in another message, you could have a 32-bit userspace with
a 64-bit kernel.  If that's the case, then uname -m gives you the wrong
answer.

You want dpkg --print-architecture, or else file /bin/ls (or some other
program that's guaranteed to be there, and to be a compiled native
executable file).

[toc] | [prev] | [next] | [standalone]


#244883

FromBrian <ad44@cityscape.co.uk>
Date2022-01-31 21:10 +0100
Message-ID<DLL9U-8eW-3@gated-at.bofh.it>
In reply to#244871
On Mon 31 Jan 2022 at 11:38:17 -0500, Greg Wooledge wrote:

> > >>   uname -m
> 
> > Are you saying that that doesn't reveal whether I've installed a 64 or a 32
> > bit release?
> 
> It does not.  It only reveals which kernel is running.
> 
> As I said in another message, you could have a 32-bit userspace with
> a 64-bit kernel.  If that's the case, then uname -m gives you the wrong
> answer.
> 
> You want dpkg --print-architecture, or else file /bin/ls (or some other
> program that's guaranteed to be there, and to be a compiled native
> executable file).

Technically correct, but Curt's response was good enough for Richard
Owlett to make progress. Richard Owlett is very unlikely to be using
a 64-bit kernel with 32-bit userspace.

-- 
Brian.

[toc] | [prev] | [next] | [standalone]


#244885

FromStefan Monnier <monnier@iro.umontreal.ca>
Date2022-01-31 22:40 +0100
Message-ID<DLMyZ-vu-3@gated-at.bofh.it>
In reply to#244883
> Technically correct, but Curt's response was good enough for Richard
> Owlett to make progress. Richard Owlett is very unlikely to be using
> a 64-bit kernel with 32-bit userspace.

BTW, for the twisted-minded it's probably possible to run a 64bit
userspace on a 32bit kernel.


        Stefan

[toc] | [prev] | [next] | [standalone]


#244886

FromGreg Wooledge <greg@wooledge.org>
Date2022-01-31 22:50 +0100
Message-ID<DLMIF-yM-1@gated-at.bofh.it>
In reply to#244885
On Mon, Jan 31, 2022 at 04:37:37PM -0500, Stefan Monnier wrote:
> > Technically correct, but Curt's response was good enough for Richard
> > Owlett to make progress. Richard Owlett is very unlikely to be using
> > a 64-bit kernel with 32-bit userspace.
> 
> BTW, for the twisted-minded it's probably possible to run a 64bit
> userspace on a 32bit kernel.

No.  Or at least, not that I've ever heard of.  If technology has been
invented to make this possible, it's new to me.

[toc] | [prev] | [next] | [standalone]


#244894

FromStefan Monnier <monnier@iro.umontreal.ca>
Date2022-02-01 03:10 +0100
Message-ID<DLQMh-38P-1@gated-at.bofh.it>
In reply to#244886
Greg Wooledge [2022-01-31 16:45:52] wrote:
> On Mon, Jan 31, 2022 at 04:37:37PM -0500, Stefan Monnier wrote:
>> BTW, for the twisted-minded it's probably possible to run a 64bit
>> userspace on a 32bit kernel.
> No.  Or at least, not that I've ever heard of.  If technology has been
> invented to make this possible, it's new to me.

I don't think there's any need to invent anything for that.  I don't see
anything particularly hard about emulating a 64bit instruction set on
a 32bit system.  Performance may not be great, but that's a secondary concern.


        Stefan

[toc] | [prev] | [next] | [standalone]


#244895

FromDavid Wright <deblis@lionunicorn.co.uk>
Date2022-02-01 04:00 +0100
Message-ID<DLRyF-3o7-1@gated-at.bofh.it>
In reply to#244894
On Mon 31 Jan 2022 at 21:02:17 (-0500), Stefan Monnier wrote:
> Greg Wooledge [2022-01-31 16:45:52] wrote:
> > On Mon, Jan 31, 2022 at 04:37:37PM -0500, Stefan Monnier wrote:
> >> BTW, for the twisted-minded it's probably possible to run a 64bit
> >> userspace on a 32bit kernel.
> > No.  Or at least, not that I've ever heard of.  If technology has been
> > invented to make this possible, it's new to me.
> 
> I don't think there's any need to invent anything for that. I don't see
> anything particularly hard about emulating a 64bit instruction set on
> a 32bit system.

I wasn't aware that anybody did emulate the /instruction/ set.
I was under the impression that such systems only ran on 32-bit
systems that were themselves running on 64-bit hardware. Just a
more complicated host-guest relationship in that case.

> Performance may not be great, but that's a secondary concern.

Cheers,
David.

[toc] | [prev] | [next] | [standalone]


#244897

FromStefan Monnier <monnier@iro.umontreal.ca>
Date2022-02-01 06:30 +0100
Message-ID<DLTTP-54c-1@gated-at.bofh.it>
In reply to#244895
> I wasn't aware that anybody did emulate the /instruction/ set.

Qemu lets you do that.
Can be quite handy for some cross-compilation.


        Stefan

[toc] | [prev] | [next] | [standalone]


#244896

FromMichael Stone <mstone@debian.org>
Date2022-02-01 04:20 +0100
Message-ID<DLRS1-3PL-1@gated-at.bofh.it>
In reply to#244894
On Mon, Jan 31, 2022 at 09:02:17PM -0500, Stefan Monnier wrote:
>Greg Wooledge [2022-01-31 16:45:52] wrote:
>> On Mon, Jan 31, 2022 at 04:37:37PM -0500, Stefan Monnier wrote:
>>> BTW, for the twisted-minded it's probably possible to run a 64bit
>>> userspace on a 32bit kernel.
>> No.  Or at least, not that I've ever heard of.  If technology has been
>> invented to make this possible, it's new to me.
>
>I don't think there's any need to invent anything for that.  I don't see
>anything particularly hard about emulating a 64bit instruction set on
>a 32bit system.  Performance may not be great, but that's a secondary concern.

that's not running a 64bit userspace on a 32bit kernel, that's running a 
64bit userspace on an emulator running in 32bit userspace on a 32bit kernel

this is unlike running the i386 userspace on an amd64 kernel (something 
that's not particularly uncommon and has certain advantages)--you cannot 
run the amd64 userspace on an i386 kernel

linux was not the first to do that, and many systems let you run 
binaries from an older version on a newer version, but I'm not aware of 
any that worked the other way around

[toc] | [prev] | [next] | [standalone]


#244898

FromStefan Monnier <monnier@iro.umontreal.ca>
Date2022-02-01 06:40 +0100
Message-ID<DLU3w-57d-7@gated-at.bofh.it>
In reply to#244896
> that's not running a 64bit userspace on a 32bit kernel,

Why not?  You have a 64bit system on top, a 32bit kernel at the bottom
and whether execution of those 64bit binaries is performed directly by
the CPU or via binfmt + qemu is just an implementation detail.

There is an important difference, of course: while you can run a "pure
i386" system on top of an amd64 kernel, you'll need some of the 32bit
system installed (e.g. qemu) in order to run the rest of the system.

> linux was not the first to do that, and many systems let you run binaries
> from an older version on a newer version, but I'm not aware of any that
> worked the other way around

It's typically used to run systems from an "incomparable" CPU.
E.g. to run RISC-V code on an PC.  Which one is older and which one is
newer doesn't really matter.


        Stefan

[toc] | [prev] | [next] | [standalone]


#244910

FromMichael Stone <mstone@debian.org>
Date2022-02-01 14:40 +0100
Message-ID<DM1y1-1fA-1@gated-at.bofh.it>
In reply to#244898
On Tue, Feb 01, 2022 at 12:32:24AM -0500, Stefan Monnier wrote:
>> that's not running a 64bit userspace on a 32bit kernel,
>
>Why not?  You have a 64bit system on top, a 32bit kernel at the bottom
>and whether execution of those 64bit binaries is performed directly by
>the CPU or via binfmt + qemu is just an implementation detail.

Because it's a different thing than native execution, irrelevant in the 
context of the discussion, and fairly uninteresting to belabor the point 
that you can run basically anything in an emulator.

[toc] | [prev] | [next] | [standalone]


#244890

FromRichard Owlett <rowlett@cloud85.net>
Date2022-02-01 01:40 +0100
Message-ID<DLPnb-2bw-1@gated-at.bofh.it>
In reply to#244885
On 01/31/2022 03:37 PM, Stefan Monnier wrote:
>> Technically correct, but Curt's response was good enough for Richard
>> Owlett to make progress. Richard Owlett is very unlikely to be using
>> a 64-bit kernel with 32-bit userspace.
> 
> BTW, for the twisted-minded it's probably possible to run a 64bit
> userspace on a 32bit kernel.

Though I'm *NOT* that twisted. [ROFL]
IIRC I came across instructions some where to do that.

[toc] | [prev] | [next] | [standalone]


#244899

From<tomas@tuxteam.de>
Date2022-02-01 06:50 +0100
Message-ID<DLUdc-5ao-1@gated-at.bofh.it>
In reply to#244885

[Multipart message — attachments visible in raw view] — view raw

On Mon, Jan 31, 2022 at 04:37:37PM -0500, Stefan Monnier wrote:
> > Technically correct, but Curt's response was good enough for Richard
> > Owlett to make progress. Richard Owlett is very unlikely to be using
> > a 64-bit kernel with 32-bit userspace.
> 
> BTW, for the twisted-minded it's probably possible to run a 64bit
> userspace on a 32bit kernel.

While we're at it, also RISC-V userspace on Arm64 ;-)

Yay, qemu + multi-arch!

Cheers
-- 
t

[toc] | [prev] | [next] | [standalone]


#244906

FromCurt <curty@free.fr>
Date2022-02-01 13:30 +0100
Message-ID<DM0sh-Di-1@gated-at.bofh.it>
In reply to#244885
On 2022-01-31, Stefan Monnier <monnier@iro.umontreal.ca> wrote:
>> Technically correct, but Curt's response was good enough for Richard
>> Owlett to make progress. Richard Owlett is very unlikely to be using
>> a 64-bit kernel with 32-bit userspace.
>
> BTW, for the twisted-minded it's probably possible to run a 64bit
> userspace on a 32bit kernel.

Oh nuts. I was going to say I was at least half correct.

>
>         Stefan
>
>


-- 

[toc] | [prev] | [next] | [standalone]


#244912

FromStanislav Vlasov <stanislav.v.v@gmail.com>
Date2022-02-01 17:20 +0100
Message-ID<DM42S-2Rx-3@gated-at.bofh.it>
In reply to#244906
2022-02-01 17:20 GMT+05:00, Curt <curty@free.fr>:
> On 2022-01-31, Stefan Monnier <monnier@iro.umontreal.ca> wrote:
>>> Technically correct, but Curt's response was good enough for Richard
>>> Owlett to make progress. Richard Owlett is very unlikely to be using
>>> a 64-bit kernel with 32-bit userspace.
>>
>> BTW, for the twisted-minded it's probably possible to run a 64bit
>> userspace on a 32bit kernel.

Me used that some years ago - 4GB ram was accessible only with 64bit
kernel and proprietary 32bit software.

> Oh nuts. I was going to say I was at least half correct.

This will print what you need
dpkg --print-architecture

-- 
Stanislav

[toc] | [prev] | [next] | [standalone]


#244923

FromCurt <curty@free.fr>
Date2022-02-01 18:50 +0100
Message-ID<DM5rY-3AN-5@gated-at.bofh.it>
In reply to#244912
On 2022-02-01, Stanislav Vlasov <stanislav.v.v@gmail.com> wrote:
> 2022-02-01 17:20 GMT+05:00, Curt <curty@free.fr>:
>> On 2022-01-31, Stefan Monnier <monnier@iro.umontreal.ca> wrote:
>>>> Technically correct, but Curt's response was good enough for Richard
>>>> Owlett to make progress. Richard Owlett is very unlikely to be using
>>>> a 64-bit kernel with 32-bit userspace.
>>>
>>> BTW, for the twisted-minded it's probably possible to run a 64bit
>>> userspace on a 32bit kernel.
>
> Me used that some years ago - 4GB ram was accessible only with 64bit
> kernel and proprietary 32bit software.
>
>> Oh nuts. I was going to say I was at least half correct.
>
> This will print what you need
> dpkg --print-architecture
>

Yes, I've adequately absorbed this information. But I don't need it.  I
mean, despite my advancing years, I remember, like the vast majority of
people here, I suppose, whether I installed a 64 or a 32 bit release
(although the consequences of not remembering appear to me to be
rather innocuous for my use case).

[toc] | [prev] | [next] | [standalone]


#244891 — CLARIFICATION --- Re: i386 or AMD64 - Which is currently running?

FromRichard Owlett <rowlett@cloud85.net>
Date2022-02-01 01:40 +0100
SubjectCLARIFICATION --- Re: i386 or AMD64 - Which is currently running?
Message-ID<DLPnc-2bw-9@gated-at.bofh.it>
In reply to#244883
On 01/31/2022 02:01 PM, Brian wrote:
> On Mon 31 Jan 2022 at 11:38:17 -0500, Greg Wooledge wrote:
> 
>>>>>    uname -m
>>
>>> Are you saying that that doesn't reveal whether I've installed a 64 or a 32
>>> bit release?
>>
>> It does not.  It only reveals which kernel is running.
>>
>> As I said in another message, you could have a 32-bit userspace with
>> a 64-bit kernel.  If that's the case, then uname -m gives you the wrong
>> answer.
>>
>> You want dpkg --print-architecture, or else file /bin/ls (or some other
>> program that's guaranteed to be there, and to be a compiled native
>> executable file).
> 
> Technically correct, but Curt's response was good enough for Richard
> Owlett to make progress. Richard Owlett is very unlikely to be using
> a 64-bit kernel with 32-bit userspace.
> 

My hardware can support either 32 or 64 bit OS.
I *ONLY* use one or the other.
My goal is to determine which I chose at installation.

[toc] | [prev] | [next] | [standalone]


Page 1 of 2  [1] 2  Next page →

Back to top | Article view | linux.debian.user


csiph-web