[SOLVED] Swap pointless on a 32bit system with >4GiB hardware ram?
Linux - GeneralThis Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Since 32bit os has 4G limitation, is a swap partition even needed/used on a system with more than 4G hardware ram?
The 4GB limit is address space per process. After address space used by the kernel, you have a limit of 3GB of virtual memory per process.
But cache and buffer memory is outside the process address space and other processes have their own address spaces. So a 32 bit Linux may be using much more than 4GB of memory.
Having some swap space is generally a good idea. The amount of anonymous memory in idle processes determines the amount of swap space that will benefit your system. That is a characteristic of the set of programs you run, not of the amount of physical ram you have. So no computation of swap size based just on ram size is valid.
Also, if you have 4GB or more of physical ram, a 32 bit kernel needs PAE support to be able to use that ram. But you might use far more than 4GB of "memory" including swap even if your physical ram is less.
In your statement - "After address space used by the kernel, you have a limit of 3GB of virtual memory per process."
Is this one more appropriate - "After address space used by the kernel, you have a limit of 3GB of virtual memory per user mode process."
I might need to switch to i686 ArchLinux as flashplugin has been removed from the 64 bit version. Also, i could then install virtualbox-ose.
Since 32bit os has 4G limitation, is a swap partition even needed/used on a system with more than 4G hardware ram?
To my opinion: yes.
But, to be on the safe side (especially when running a candycane Linux) it cannot harm to use a 4 GB swap partition or a swapfile. Advantage of the swapfile is that you can easily change the size and do some performance experiments with the file size.
4GB is hardware limit not the software limit. You must have swap as kernel use it for virtual address space. this virtual address space starts with some offset.
Quote:
Originally Posted by onedingo
Hey.
I might need to switch to i686 ArchLinux as flashplugin has been removed from the 64 bit version. Also, i could then install virtualbox-ose.
Since 32bit os has 4G limitation, is a swap partition even needed/used on a system with more than 4G hardware ram?
4GB is hardware limit not the software limit. You must have swap as kernel use it for virtual address space. this virtual address space starts with some offset.
Wrong.
You can run without Swapspace: I did it for years, but the system gets sluggish when you reach the limits of RAM. On a 128 MB machine, that is pretty soon. On a 4 GB system that might never be.
In the past I used to run with "swap = half of RAM" and that worked very well. With a 4 GB RAM system, 1 GB swap will be more than enough. In the rare case that a memory leak eats up the full 4 GB of RAM, you may get into trouble. But then again: with a swap space added, you will get in the same trouble, but only later.
I saw this question from the other angle: Why go back to a 32-bit install when you can merely add the 32-bit libs to your existing 64-bit install?
You should also be able to get the 64-bit plugin right from Adobe and put it in mozilla/plugins unless something blew up over there that I haven't heard about yet.
I saw this question from the other angle: Why go back to a 32-bit install when you can merely add the 32-bit libs to your existing 64-bit install?
I'm not sure they provide a lib32 package or not. Will have to look into.
Quote:
Originally Posted by zeno0771
You should also be able to get the 64-bit plugin right from Adobe and put it in mozilla/plugins unless something blew up over there that I haven't heard about yet.
I'm not sure they provide a lib32 package or not. Will have to look into.
IIRC we used to just run a 32-bit version before a 64-bit version even existed, though I suppose it depends on why you need it (i.e. besides just Firefox).
Have you considered just running what you need in a chroot jail? This is just the thing for when you have to have a 32-bit version of something but can't/don't want to go back to 32-bit:
64 bit hardware running 64 bit os with 32 bit libs added to run virtualbox hosting 32 bit os.
Waitaminute...
Are you holding on to VBox-OSE because you want totally open-source, free-as-in-speech-style? If not, the Personal Use version is only limited in terms of redistribution; you're not limited really any other way:
Quote:
§ 2 Grant of license. (1) Oracle grants you a personal, non-exclusive, non-transferable, limited license without fees to reproduce, install, execute, and use internally the Product a Host Computer for your Personal Use, Educational Use, or Evaluation. “Personal Use” requires that you use the Product on the same Host Computer where you installed it yourself and that no more than one client connect to that Host Computer at a time for the purpose of displaying Guest Computers remotely. “Educational use” is any use in an academic institution (schools, colleges and universities, by teachers and students). “Evaluation” means testing the Product for a reasonable period (that is, normally for a few weeks); after expiry of that term, you are no longer permitted to evaluate the Product.
(2) The “VirtualBox Guest Additions” are a set of drivers and utilities that are shipped as a subset of the Product for the purpose of being installed inside a Guest Computer to improve its performance and cooperation with the rest of the Product. In addition to and independent of the rights granted by subsection 1, Oracle allows you to install, execute, copy and redistribute a) unmodified copies of the ISO installation medium of the VirtualBox Guest Additions as shipped with the Product and b) the VirtualBox Guest Additions together with the Guest Computer into which they have been installed.
I use VBox-PUEL 64-bit with no problems in my Arch64 install and can run both 32 and 64-bit guest OSes; in fact the only reason I have 32-bit binaries is for WINE and their stay on my machine may be limited.
If I'm missing something please let me know; I'd hate to see you go to all the effort because of a misunderstanding.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.