Is it possible to run hard drive install from RAM?

When you run into problems installing MX Linux XFCE
Message
Author
User avatar
LysarZ
Posts: 6
Joined: Mon Nov 12, 2018 10:57 am

Is it possible to run hard drive install from RAM?

#1 Post by LysarZ »

My main computer is an old HP laptop with 16G RAM that I would like to get to run faster. Spending money to upgrade anything is not an option. Is it possible to install MX on the hard drive, have it load onto a ramdrive during boot, and then have changes copied back to the hard drive when shutting down/rebooting? I would keep separate data and swap partitions on the hard drive & only use the ramdrive for frequently accessed apps & data.

Code: Select all

System:    Host: <filter> Kernel: 5.10.0-9-amd64 x86_64 bits: 64 compiler: N/A 
           parameters: quiet splasht nosplash nomodeset 
           Desktop: Xfce 4.16.0 tk: Gtk 3.24.24 info: xfce4-panel wm: xfwm4 dm: LightDM 1.26.0 
           Distro: MX-21_x64 Wildflower October 20  2021 base: Debian GNU/Linux 11 (bullseye) 
Machine:   Type: Laptop System: Hewlett-Packard product: HP EliteBook 8740w v: N/A 
           serial: <filter> Chassis: type: 10 serial: <filter> 
           Mobo: Hewlett-Packard model: 1520 v: KBC Version 33.2F serial: <filter> 
           BIOS: Hewlett-Packard v: 68CAD Ver. F.20 date: 09/05/2011 
Battery:   ID-1: BAT0 charge: 49.9 Wh condition: 49.9/49.9 Wh (100%) volts: 16.3/14.4 
           model: Hewlett-Packard Primary type: Li-ion serial: <filter> status: Full 
CPU:       Topology: Quad Core model: Intel Core i7 Q 840 bits: 64 type: MT MCP arch: Nehalem 
           family: 6 model-id: 1E (30) stepping: 5 microcode: A L2 cache: 8192 KiB 
           flags: lm nx pae sse sse2 sse3 sse4_1 sse4_2 ssse3 bogomips: 29791 
           Speed: 1403 MHz min/max: 1199/1867 MHz boost: enabled Core speeds (MHz): 1: 1237 
           2: 1237 3: 1231 4: 1251 5: 1346 6: 1235 7: 1277 8: 1242 
           Vulnerabilities: Type: itlb_multihit status: KVM: VMX unsupported 
           Type: l1tf mitigation: PTE Inversion 
           Type: mds 
           status: Vulnerable: Clear CPU buffers attempted, no microcode; SMT vulnerable 
           Type: meltdown mitigation: PTI 
           Type: spec_store_bypass status: Vulnerable 
           Type: spectre_v1 mitigation: usercopy/swapgs barriers and __user pointer sanitization 
           Type: spectre_v2 mitigation: Full generic retpoline, STIBP: disabled, RSB filling 
           Type: srbds status: Not affected 
           Type: tsx_async_abort status: Not affected 
Graphics:  Device-1: NVIDIA G92GLM [Quadro FX 2800M] vendor: Hewlett-Packard driver: N/A 
           bus ID: 01:00.0 chip ID: 10de:061d 
           Display: x11 server: X.Org 1.20.11 driver: nouveau,vesa unloaded: fbdev,modesetting 
           alternate: nv resolution: 1600x1200~N/A 
           OpenGL: renderer: llvmpipe (LLVM 11.0.1 128 bits) v: 4.5 Mesa 20.3.5 compat-v: 3.1 
           direct render: Yes 
Audio:     Device-1: Intel 5 Series/3400 Series High Definition Audio vendor: Hewlett-Packard 
           driver: snd_hda_intel v: kernel bus ID: 00:1b.0 chip ID: 8086:3b56 
           Sound Server: ALSA v: k5.10.0-9-amd64 
Network:   Device-1: Intel 82577LM Gigabit Network vendor: Hewlett-Packard driver: e1000e 
           v: kernel port: 4020 bus ID: 00:19.0 chip ID: 8086:10ea 
           IF: eth0 state: up speed: 100 Mbps duplex: full mac: <filter> 
           Device-2: Intel Centrino Ultimate-N 6300 driver: iwlwifi v: kernel port: 3000 
           bus ID: 03:00.0 chip ID: 8086:4238 
           IF: wlan0 state: down mac: <filter> 
Drives:    Local Storage: total: 945.83 GiB used: 1.82 GiB (0.2%) 
           ID-1: /dev/sda vendor: Seagate model: ST1000LM014-1EJ164 size: 931.51 GiB block size: 
           physical: 4096 B logical: 512 B speed: 3.0 Gb/s rotation: 5400 rpm serial: <filter> 
           rev: SM15 scheme: MBR 
           ID-2: /dev/sdb type: USB vendor: SanDisk model: Cruzer Snap size: 14.32 GiB 
           block size: physical: 512 B logical: 512 B serial: <filter> rev: 1.00 scheme: MBR 
Partition: ID-1: / raw size: N/A size: 12.40 GiB used: 66.4 MiB (0.5%) fs: overlay 
           source: ERR-102 
           ID-2: swap-1 size: 512.0 MiB used: 0 KiB (0.0%) fs: swap swappiness: 15 (default 60) 
           cache pressure: 100 (default) dev: /dev/sda1 
Sensors:   System Temperatures: cpu: 56.0 C mobo: N/A 
           Fan Speeds (RPM): N/A 
Repos:     No active apt repos in: /etc/apt/sources.list 
           Active apt repos in: /etc/apt/sources.list.d/debian-stable-updates.list 
           1: deb http://deb.debian.org/debian bullseye-updates main contrib non-free
           Active apt repos in: /etc/apt/sources.list.d/debian.list 
           1: deb http://deb.debian.org/debian bullseye main contrib non-free
           2: deb http://security.debian.org/debian-security bullseye-security main contrib non-free
           Active apt repos in: /etc/apt/sources.list.d/mx.list 
           1: deb http://mxrepo.com/mx/repo/ bullseye main non-free
Info:      Processes: 251 Uptime: 2m Memory: 15.56 GiB used: 1.05 GiB (6.8%) Init: SysVinit 
           v: 2.96 runlevel: 5 default: 5 Compilers: gcc: 10.2.1 alt: 10 Shell: quick-system-in 
           running in: quick-system-in inxi: 3.0.36 

User avatar
entropyfoe
Posts: 626
Joined: Thu Apr 19, 2007 11:42 am

Re: Is it possible to run hard drive install from RAM?

#2 Post by entropyfoe »

I'll jump in here, though I don't know much about the remastering powers that MX has.

It sounds like what you want is to boot toram. This is usually done by adding the parameter to the boot line in grub

Code: Select all

toram
That is your first part.

The second sound like you MX Live session with persistence. Most do this from a USB stick, but a HD install might do this.

I hate to "rtfm" the topic, but the manual is really a "fine manual" and covers the persistence and boot codes. :rolleyes:

I am hoping some one more knowledgeable can comment as this is something I don't know much about. (D_O is expert in this as well as anticapitalista and many more of the gurus here)
Maybe a persistence is not need, just a regular install with a boot code toram?
MX 23.6 AHS on Asus PRIME B650
AMD Ryzen 9700X (16 threads @ 3.8 GHz)
64 Gig DDR4 6400 (Crucial)
Integrated Radeon graphics
Samsung 970 NVMe nvme0n1 P1-3=MX-23.5, P4=testing
Samsung 980 NVMe =2TB Data, plus 4TB WD =backups
on-board ethernet & sound

User avatar
fehlix
Developer
Posts: 12792
Joined: Wed Apr 11, 2018 5:09 pm

Re: Is it possible to run hard drive install from RAM?

#3 Post by fehlix »

LysarZ wrote: Tue Mar 01, 2022 10:33 pm My main computer is an old HP laptop with 16G RAM that I would like to get to run faster. Spending money to upgrade anything is not an option. Is it possible to install MX on the hard drive, have it load onto a ramdrive during boot, and then have changes copied back to the hard drive when shutting down/rebooting? I would keep separate data and swap partitions on the hard drive & only use the ramdrive for frequently accessed apps & data.
Yes, as mention it is possible to run the whole system from RAM. The way it's prepared by MX Linux is called "frugal" installation.
The installed files are on the "slow" HDD. At boot it loads the system from HDD into RAM and when running it is "blazing" fast compared to running from the "slow" rotating HDD.
The booting process is similar to boot from a LiveUSB, only with "frugal" from HDD instead from USB.
You do a frugal install, by selecting on the Live-boot menu a "frugal" option found under "persistence" option,
and you would later select a partition the frugal files get saved onto. It can be an NTFS partition or any other supported filesystem. Suggest would be to choose or prepare a ext4 partition to keep the frugal install files. Some people do prefer NTFS or even exFAT, I'd prefer ext4 as a bit more Linux oriented with the ability of self-repair file system failure due to it's journaling build-in feature.

Post Reply

Return to “Installation”