You are not logged in.

#1 2024-12-24 10:47:46

approx
Member
Registered: 2024-12-21
Posts: 4

Reduce disk I/O. In any way.

Have a good time of day, forum,

a little explanation: I am currently developing an ISO of the full Arch Linux installation. The goal is to be able to write the iso to a USB flash drive (!) and get a portable Arch.

Problem - Flash drives have inexcusably slow speed - in practice, about 15-40 Mbps even on USB 3.0 devices. If you know the ways to reduce disk's IO as much as possible. Now my load average jumps from 1 to 20 (!)

My solutions, which, unfortunately, are not enough:

1. moved the journald on RAM (made it volatile).

2. «mounted» some folders on tmpfs: /tmp, /var/log, etc. by editing /etc/fstab.

3. disabled swap.

Naturally, it would be good to change the flash drive to a portable SSD, but nevertheless.

Also, root file system should be in ext4, not f2fs, because I need to be able to expand my root partition while mounted, on-line (resize2fs works only with ext*).

Thank you!

Offline

#2 2024-12-24 10:57:07

Head_on_a_Stick
Member
From: The Wirral
Registered: 2014-02-20
Posts: 8,672
Website

Re: Reduce disk I/O. In any way.

Perhaps try overlayfs with an mkinitcpio(8) hook?

Here's how Alpine do it: https://gitlab.alpinelinux.org/alpine/m … it.in#L720

Somebody here actually got it working (allegedly): https://www.reddit.com/r/linuxmasterrac … _stick_as/


Para todos todo, para nosotros nada

Offline

#3 2024-12-24 16:39:31

seth
Member
Registered: 2012-09-03
Posts: 60,683

Re: Reduce disk I/O. In any way.

Have you read https://wiki.archlinux.org/title/Instal … ble_medium ?

Naturally, it would be good to change the flash drive to a portable SSD. Period

Ftfy, nb. that w/o wear leveling the NAND will die in no time if you end up writing the same sectors over and over again.
Under no circumstances use it for any kind of swapping! (Use a zram swap device, zswap requires a physical swap device as backup)

moved the journald on RAM (made it volatile)

Frankly: disable the journal, you're "wasting" RAM you'll need for other stuff.

Online

Board footer

Powered by FluxBB