You may create a special swap-partition.
In fdisk, you specify the partition-type 82 (Linux-swap) and call mkswap (man mkswap for correct parameters).
My old PC has on 48 Mb RAM.
I have done a HD install.
Before KDE starts, it tells me that there is not
enough memory and a swap file can be
created on a DOS partition.
I let it create a 300 Mb swap file in a 600 MB DOS partition.
This works fine. I use the PC for a few hours and then I shut down the PC.
Come back a few hours later and again - Before KDE starts,
it tells me that there is not enough memory and a swap
file can be created on a DOS partition. What happened
to the 300 Mb swap file we just created?
How can I make a swap file permament?
Do I need to use the DOS partition?
Can I create a swap file in the current ext3 partition?
You may create a special swap-partition.
In fdisk, you specify the partition-type 82 (Linux-swap) and call mkswap (man mkswap for correct parameters).
Thanks. That worked.

Fanxiang 1/2/5/10Pcs 2.5'' SATA SSD Lot 1TB 2TB 4TB 512GB 256GB TLC Internal SSD
$755.99
Dell Latitude 14" Laptop Computer Intel i7 Up To 32GB RAM 1TB SSD Windows 11 Pro
$360.73
Dell Latitude 14" Laptop Computer Intel i5 Up To 32GB RAM 1TB SSD Windows 11 Pro
$427.63
HP Pavilion 15.6" Touchscreen Laptop - Intel Core i3 / 16GB RAM / 1TB SSD
$329.00
Acer Aspire 14" AI Copilot+PC Laptop Core Ultra 5 226V Gen 4 ARC 16GB 1TB Refurb
$438.51
1TB Kingston DataTraveler Max DTMAX/1TB USB Type-C Flash Drive
$86.95
1TB HDD/SSD 2.5" SATA Hard Drive Laptop with Windows 11 Pro UEFI Installed Used
$50.00
Netac 2TB 1TB 500GB Internal SSD M.2 NVMe PCIe3.0 Solid State Drive lot
$75.99
Dell Windows 11 Pro Desktop Computer PC Up To i7 8th Gen. 32GB RAM 4TB SSD/HDD
$438.27
Seagate ST1000VM002 1TB 5900RPM 3.5" SATA 6Gb/s HDD | PC DVR CCTV | | 1Y
$55.95