Installing 32-bit Linux on an old laptop

247 views
Skip to first unread message

John Cremona

unread,
Dec 11, 2024, 12:54:59 PM12/11/24
to SAGE devel
I have a very old 32-bit laptop with Ubuntu 10.04 installed on it (yes really) and that cannot be upgraded, not can a newer version of Ubuntu be installed on it. I was thinking about installing some Linux system on it so I can test eclib (and even Sage) on a 32bit system.  (I did do Sage development on this laptop until 2008 -- I mean 2008, that's not a typo).

The laptop has 3gb ram.  What Linux distribution would people recommend? I see that Debian supports 32bit still.

John

Georgi Guninski

unread,
Dec 11, 2024, 3:41:32 PM12/11/24
to sage-...@googlegroups.com
> The laptop has 3gb ram. What Linux distribution would people recommend? I see that Debian supports 32bit still.

I don't know the answer, but you may consider trying Debian
with some lightweight window manager like XFCE or even possibly
no X, only console.
IMHO the bottleneck is not 32bit, but only 3GB RAM.
From my experience I have run XFCE in a virtual machine with only 4GB
RAM and one core and it is slow, but usable.

Dima Pasechnik

unread,
Dec 11, 2024, 5:52:05 PM12/11/24
to sage-...@googlegroups.com
Debian will most probably work, and it's pretty close to familiar to you Ubunty.
Or perhaps you rather get a distro with an up to date Sage there,
e.g. Void: https://voidlinux.org/
> --
> You received this message because you are subscribed to the Google Groups "sage-devel" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+...@googlegroups.com.
> To view this discussion visit https://groups.google.com/d/msgid/sage-devel/CAGUWgD9Y-HNCJNgB%2Bz1PeEO2S3xxk%2BHcxG35EORbPyrkrrGvXg%40mail.gmail.com.

Emil Widmann

unread,
Dec 12, 2024, 8:18:09 AM12/12/24
to sage-devel
MX Linux is pretty solid and debian based
There is a 32 bit build for MX Linux XFCE,

fluxbox version should be even lighter

John Cremona

unread,
Dec 12, 2024, 8:57:00 AM12/12/24
to sage-devel
Thanks for all the suggestions.  I made a boot disk USB for debian and am trying that right now.  I will report back.

John

John Cremona

unread,
Dec 13, 2024, 8:53:26 AM12/13/24
to sage-devel
I don't want to bore people with this, as it is only slightly sage-related.  Yesterday I tried and failed several times to install debian on the machine, both with the small size installation iso image (which then needs to download more as it goes) and the larger one.  It always fails during the stage called (something like) "select and install software", as far as I can see at that point apt gives up waiting for a remote server.  My internet connection is fine.  Of course I cannot rule out a problem with the machine itself (when I replaced it in 2008 there was some specific reason, though I do not remember exactly what -- I had access to funds, the old machine didn't have wifi and was certainly under-powered for Sage development!)).

I may try MX or fluxbox but my patience is wearing a bit thin and I have some other things to take to the recycling place in the next week...

John

Jackson Walters

unread,
Dec 13, 2024, 9:10:50 AM12/13/24
to sage-...@googlegroups.com
It sounds like you are going to be fighting this thing if you stick with it. I'm seeing some pretty nice refurbished machines with 8gb memory on eBay on the cheap. If that's not an option, I wouldn't think twice about recycling it and waiting until you have a machine that runs Sage easily.

John Cremona

unread,
Dec 13, 2024, 11:08:25 AM12/13/24
to sage-...@googlegroups.com
Thank Jackson -- I do have plenty of other, newer machines for Sage development!   But as I am the upstream provider of the eclib (a standard dependency of Sage) and regularly get told that something does not work on a 32-bit machine, I thought I could resurrect the ancient one for that purpose -- and that purpose only!

John

You received this message because you are subscribed to a topic in the Google Groups "sage-devel" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/sage-devel/pQw-LawYZPA/unsubscribe.
To unsubscribe from this group and all its topics, send an email to sage-devel+...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/sage-devel/CAGqtwVCCCjmRQHiXQP1Et-644bY0c0NNB%3DRZSc%3D0WYbOhdXnBQ%40mail.gmail.com.

Georgi Guninski

unread,
Dec 13, 2024, 12:19:22 PM12/13/24
to sage-...@googlegroups.com
> something does not work on a 32-bit machine, I thought I could resurrect the ancient one for that purpose -- and that purpose only!

You may try to run 32 bit guest on x86_64 host virtual machine,
probably using qemu/kvm.

I am not sure which virtual machines give good performance in your case.

Most x86_64 native linux include |qemu-system-i386| as a standard package.

So on a decent 64 bit host you may try:

qemu-system-i386 -m 4096 -drive=32bit_drive_file

If this works, you will benefit from the good CPU of the host.

There are frontends to qemu, but you will find the right options on
the man page or on a web search.

There are paranoid solutions to increase security using virtual
machines, e.g. Qubes OS.

John Cremona

unread,
Dec 13, 2024, 3:05:35 PM12/13/24
to sage-...@googlegroups.com
Using an emulator is a good idea, I will try that if installing MX fluxbox fails.  I came to the conclusion that the USB stick I had been using yesterday for my debian attempts was faulty,I am using a new one now.

BUT when I said that the laptop had 3gb I was wrong, that's my second-oldest laptop (from 2008).  The 32-bit one has... 512mb!  But I ran linux on it happily for several years.  It is certainly taking a long time to do anything now.    The first computer I installed and ran linux on, in the 1990s, had only 16mb.   

John

--
You received this message because you are subscribed to a topic in the Google Groups "sage-devel" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/sage-devel/pQw-LawYZPA/unsubscribe.
To unsubscribe from this group and all its topics, send an email to sage-devel+...@googlegroups.com.

Michael Orlitzky

unread,
Dec 13, 2024, 3:20:10 PM12/13/24
to sage-...@googlegroups.com
On 2024-12-13 15:04:58, John Cremona wrote:
> Using an emulator is a good idea, I will try that if installing MX fluxbox
> fails. I came to the conclusion that the USB stick I had been using
> yesterday for my debian attempts was faulty,I am using a new one now.
>
> BUT when I said that the laptop had 3gb I was wrong, that's my
> second-oldest laptop (from 2008). The 32-bit one has... 512mb! But I ran
> linux on it happily for several years. It is certainly taking a long time
> to do anything now. The first computer I installed and ran linux on, in
> the 1990s, had only 16mb.

If you're up for an adventure, Gentoo should still work. I use a
laptop from 2008 (albeit with a little more RAM) every day. Github
might as well be running on the Mars rover, but it's fast until you
start a web browser.

Georgi Guninski

unread,
Dec 13, 2024, 4:09:02 PM12/13/24
to sage-...@googlegroups.com
Partial results:

I managed to run 32 bit debian live cd in qemu virtual machine with 64 bit host.
It is very slow, but /proc/cpuinfo gives 8200 bogomips.

From
https://cdimage.debian.org/cdimage/archive/latest-oldstable-live/i386/iso-hybrid/
I downloaded:
https://cdimage.debian.org/cdimage/archive/latest-oldstable-live/i386/iso-hybrid/debian-live-11.11.0-i386-xfce.iso

Then on the host:
$ qemu-system-x86_64 -m 6000 -cdrom debian.iso
After several minutes:

User: user
Pass: live

Terminal starts slow, while correct solution should be at near native speed.

Btw, IIRC once upon a time 64 bit was backwards compatible with 32 bit,
is it still compatible?
In case of positive answer, you could run 32 bit on modern metal.

Meanwhile, you can run GNU/Linux in a browser:

https://bellard.org/jslinux/
https://bellard.org/jslinux/vm.html?url=alpine-x86-xwin.cfg&mem=256&graphic=1

Dima Pasechnik

unread,
Dec 13, 2024, 10:03:52 PM12/13/24
to sage-...@googlegroups.com
On Fri, Dec 13, 2024 at 6:19 AM Georgi Guninski <ggun...@gmail.com> wrote:
>
> > something does not work on a 32-bit machine, I thought I could resurrect the ancient one for that purpose -- and that purpose only!
>
> You may try to run 32 bit guest on x86_64 host virtual machine,
> probably using qemu/kvm.
>
> I am not sure which virtual machines give good performance in your case.
>
> Most x86_64 native linux include |qemu-system-i386| as a standard package.

Another VM option might be docker, which is much easier to install. I
never had patience to get qemu/kvm running for me,
but docker is easy.


>
> So on a decent 64 bit host you may try:
>
> qemu-system-i386 -m 4096 -drive=32bit_drive_file
>
> If this works, you will benefit from the good CPU of the host.
>
> There are frontends to qemu, but you will find the right options on
> the man page or on a web search.
>
> There are paranoid solutions to increase security using virtual
> machines, e.g. Qubes OS.
>
> --
> You received this message because you are subscribed to the Google Groups "sage-devel" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+...@googlegroups.com.
> To view this discussion visit https://groups.google.com/d/msgid/sage-devel/CAGUWgD-gBui_wD%2BMyKi2r%2BtPu%2BBNzg2WQ97ofq00VZNEvnuNqQ%40mail.gmail.com.

Georgi Guninski

unread,
Dec 14, 2024, 12:20:52 PM12/14/24
to sage-...@googlegroups.com
> Another VM option might be docker, which is much easier to install

I suspect docker will not solve Cremona's problem.
Docker uses the host CPU and kernel and can't run whole OS on it.
On qemu you emulate the CPU and can run arbitrary OS, possibly on
another architecture.
Might be wrong if things have changed.

Dima Pasechnik

unread,
Dec 14, 2024, 1:58:20 PM12/14/24
to sage-...@googlegroups.com
Right, I got things mixed up. Sorry, docker is out.

Apart from qemu/kvm, another alternative is VirtualBox. There is an Ubuntu package and a tutorial:
<https://ubuntu.com/tutorials/how-to-run-ubuntu-desktop-on-a-virtual-machine-using-virtualbox#1-overview>
There is also VMWare, and John's university might have support for it. VMWare is a commercial VM solution.


>

Georgi Guninski

unread,
Dec 14, 2024, 4:08:57 PM12/14/24
to sage-...@googlegroups.com
> VirtualBox VMWare

I have been using qemu for more than 10 years and i am satisfied.
Advantages: works fine everywhere. doesn't require any extra kernel modules
Disadvantages: misses some shiny "features" like shared clipboard,
but it is security advantage.

Volker Braun

unread,
Dec 15, 2024, 12:46:48 PM12/15/24
to sage-devel
Using qemu/kvm is definitely the way to go for development. You'll save lots of time compiling/testing with a modern CPU. There is also a number of utilities that simplify setting up virtual machines, e.g. gnome-boxes

John Cremona

unread,
Dec 15, 2024, 2:14:21 PM12/15/24
to sage-...@googlegroups.com
Well I am giving up on using my 20+-year-old hardware.  I have made many attempts to install a 32-bit distro (debian, MX, Mint) but all failed -- in the case of Mint, there was kernel panic before it even got going.  I did a 100% successful memtest but there must be other hardware problems.  To the dump!

I have never tried any emulation.  My own newest (9 year old) laptop has sufficient power but rather little space on its disk (even after deleting all those iso images I downloaded).  Other machines I have access to are heavily used by people who need them (e.g. for their PhDs) and quite old too, so I would be nervous about using them.

Without that, eclib will not get any 32-bit testing, unfortunately.

John

--
You received this message because you are subscribed to a topic in the Google Groups "sage-devel" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/sage-devel/pQw-LawYZPA/unsubscribe.
To unsubscribe from this group and all its topics, send an email to sage-devel+...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/sage-devel/c37d3e6e-6f99-48b9-a6f7-f0a1ed69d364n%40googlegroups.com.

William Stein

unread,
Dec 15, 2024, 2:35:13 PM12/15/24
to sage-...@googlegroups.com
On Sun, Dec 15, 2024 at 6:14 AM John Cremona <john.c...@gmail.com> wrote:
Well I am giving up on using my 20+-year-old hardware.  I have made many attempts to install a 32-bit distro (debian, MX, Mint) but all failed -- in the case of Mint, there was kernel panic before it even got going.  I did a 100% successful memtest but there must be other hardware problems.  To the dump!

I have never tried any emulation.  My own newest (9 year old) laptop has sufficient power but rather little space on its disk (even after deleting all those iso images I downloaded).  Other machines I have access to are heavily used by people who need them (e.g. for their PhDs) and quite old too, so I would be nervous about using them.

You could try this open source 32-bit arch linux in browser x86:   https://copy.sh/v86/?profile=archlinux

There is no network stack, so note the "Send files to emulator" button off to the right.  You can save the exact
state of the VM though (at the top) to avoid loss of work.

 -- William


 

Without that, eclib will not get any 32-bit testing, unfortunately.

John

On Sun, 15 Dec 2024 at 12:46, Volker Braun <vbrau...@gmail.com> wrote:
Using qemu/kvm is definitely the way to go for development. You'll save lots of time compiling/testing with a modern CPU. There is also a number of utilities that simplify setting up virtual machines, e.g. gnome-boxes


On Saturday, December 14, 2024 at 5:08:57 PM UTC+1 Georgi Guninski wrote:
> VirtualBox VMWare

I have been using qemu for more than 10 years and i am satisfied.
Advantages: works fine everywhere. doesn't require any extra kernel modules
Disadvantages: misses some shiny "features" like shared clipboard,
but it is security advantage.

--
You received this message because you are subscribed to a topic in the Google Groups "sage-devel" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/sage-devel/pQw-LawYZPA/unsubscribe.
To unsubscribe from this group and all its topics, send an email to sage-devel+...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/sage-devel/c37d3e6e-6f99-48b9-a6f7-f0a1ed69d364n%40googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/sage-devel/CAD0p0K68wAx5Vfsu8iRVfpqs6wWUC9JVcW-vOTq--bku-xsZWw%40mail.gmail.com.


--

Georgi Guninski

unread,
Dec 15, 2024, 3:28:57 PM12/15/24
to sage-...@googlegroups.com
Have you tried to run i386 installer on modern 64 bit hardware?
If the installer starts without SIGILL, then you can install it on
modern hardware. You need not install it, just check if it starts.

Searching google appears to suggest that they are backwards compatible, e.g. [1]

I have the partial result that i ran the debian live i386 iso on 64
bit qemu architecture guest OS.

The answer might depend on the exact definition of "64 bit CPU".

[1] https://www.pcmag.com/news/32-bit-vs-64-bit-oses-whats-the-difference

Grégory Vanuxem

unread,
Dec 15, 2024, 3:30:51 PM12/15/24
to sage-...@googlegroups.com
Hello, 


Le dim. 15 déc. 2024, 15:14, John Cremona <john.c...@gmail.com> a écrit :
Well I am giving up on using my 20+-year-old hardware.  I have made many attempts to install a 32-bit distro (debian, MX, Mint) but all failed -- in the case of Mint, there was kernel panic before it even got going.  I did a 100% successful memtest but there must be other hardware problems.  To the dump!

I have never tried any emulation.  My own newest (9 year old) laptop has sufficient power but rather little space on its disk (even after deleting all those iso images I downloaded).  Other machines I have access to are heavily used by people who need them (e.g. for their PhDs) and quite old too, so I would be nervous about using them.

Without that, eclib will not get any 32-bit testing, unfortunately.

I wonder why you are not cross compiling your eclib using -march etc. flags for gcc and consorts. If you use a Debian based distribution issue in your interpreter:

apt-cache search gcc | grep 32

You'll find what you are looking for. Google will help you also I think. I remember having compiled CMU CL in that way it's (was?) a 32 bits software.

Of course your processor must be able to run 32 bits applications, I hope it's the case.

Regards, 

- Greg


John

On Sun, 15 Dec 2024 at 12:46, Volker Braun <vbrau...@gmail.com> wrote:
Using qemu/kvm is definitely the way to go for development. You'll save lots of time compiling/testing with a modern CPU. There is also a number of utilities that simplify setting up virtual machines, e.g. gnome-boxes


On Saturday, December 14, 2024 at 5:08:57 PM UTC+1 Georgi Guninski wrote:
> VirtualBox VMWare

I have been using qemu for more than 10 years and i am satisfied.
Advantages: works fine everywhere. doesn't require any extra kernel modules
Disadvantages: misses some shiny "features" like shared clipboard,
but it is security advantage.

--
You received this message because you are subscribed to a topic in the Google Groups "sage-devel" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/sage-devel/pQw-LawYZPA/unsubscribe.
To unsubscribe from this group and all its topics, send an email to sage-devel+...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/sage-devel/c37d3e6e-6f99-48b9-a6f7-f0a1ed69d364n%40googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/sage-devel/CAD0p0K68wAx5Vfsu8iRVfpqs6wWUC9JVcW-vOTq--bku-xsZWw%40mail.gmail.com.

Grégory Vanuxem

unread,
Dec 15, 2024, 3:37:39 PM12/15/24
to sage-...@googlegroups.com
I forgot to say that you need also to install the 32 bits libc. Other libraries like GMP for example are likely available or you will have to also cross compile them.

Installing build stuff to cross compile your library will install 32 bits libc for you I think. This is necessary to run 32 bits applications. 

John Cremona

unread,
Dec 15, 2024, 4:18:38 PM12/15/24
to SAGE devel
Two more good ideas! I have an older 64bit laptop not in daily use on which I could certainly try installing a 32 but distro.  But if I can just tell GCC to build eclib for 32 bits (and can run what it produces) that would seem perfect.

I will try that tomorrow. Otherwise this will be waiting for 2025 as I have other things to do. Which are more fun...

John

Dima Pasechnik

unread,
Dec 16, 2024, 2:57:59 AM12/16/24
to sage-...@googlegroups.com, John Cremona, William Stein
We do have small budget to buy hardware - like we have an Apple M1
server hosted by William.
It's more a question of setting it up and hooking it on the internet.
Can one run a VM server, capable of running a 32-bit guest OS, on the
M1 machine?

Dima
> You received this message because you are subscribed to the Google Groups "sage-devel" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+...@googlegroups.com.
> To view this discussion visit https://groups.google.com/d/msgid/sage-devel/CAD0p0K68wAx5Vfsu8iRVfpqs6wWUC9JVcW-vOTq--bku-xsZWw%40mail.gmail.com.

John Cremona

unread,
Dec 17, 2024, 2:33:56 PM12/17/24
to sage-...@googlegroups.com
I do intend to try this but probably not before shutting down for a holiday.  If someone can tell me exactly which packages to install that would help.  I will either do it on my current laptop on which I currently have ubuntu 22.04.5 LTS (but which I plan to upgrade to ubuntu 24), or I might use an older laptop which is already on ubuntu 24, but on which I have very little installed.   I know that I will have to recompile all eclib's dependencies (pari, NTL, FLINT) in 32-bit mode, and am nervous about breaking things on the laptop I use every day for real work, hence my thought to use the older machine where it doesn't matter.  I am hoping that after installing lib32gcc-12-dev and perhaps some other stuff, setting CFLAGS and CXXFLAGS and LDFLAGS to include the right thing (-m32 at least), and configuring and building and installing all the prerequisites will work.  We'll see.

Emil Widmann

unread,
Dec 18, 2024, 9:13:19 AM12/18/24
to sage-devel
I think doing sage developement and testing on a machine with just 512 MB is not a good idea. Sage is a ressource hog and it will not work. I think it is better to use a good 64 bit machine with lots of RAM and either dual boot it to a 32 bit distro or use virtualisation as mentioned. Quemu is fine, although virtualbox/VMware could be substantially faster, i.e. better suited for testing purpose.

For the sake of completeness: This is the link to some debian based installation images wich are fine tuned for very low spec machines, also going back as far as debian squeeze for really old hardware. I do not recommend you try them for  sage developement, because it will not work with new sage code. But if anyone wants to revitalize some old machine this might be the best option. It is completely built with debian live, but has setup and code from puppy linux, which is very light.


best regards
Reply all
Reply to author
Forward
0 new messages