В Linux стандартными средствами можно использовать часть оперативной памяти как диск. Для этого требуется указать тип монтирования tmpfs в команде mount
mount -t tmpfs -o size=5G tmpfs /mnt/ram
Теперь путь /mnt/ram можно использовать как обычный каталог. Для чего это может быть нужно?
▫️ Скорость работы с таким каталогом выше чем многие SSD и тем более HDD.
▫️ Если у вас очень быстрый SSD на NVMe M.2 то такой способ особо не прибавит вам скорости, но поможет сохранить ресурс SSD когда требуется обрабатывать очень много мелких файлов и оперативка позволяет выделить нужный объем.
▫️ Оперативка это энергозависимая память, поэтому выключении питания все файлы безвозвратно теряются. Такой "non persistent" каталог гарантирует удаление временных файлов.
Я написал небольшой скрипт для условного теста и сравнения скорости копирования файлов между SSD и RAM.
Вот мои результаты:
Single File Size: 30.0Gb
ssd > ssd: 0:00:12.850 / 2.3Gb/s
sdd > ram: 0:00:06.453 / 4.6Gb/s
ram > ram: 0:00:06.995 / 4.3Gb/s
ram > sdd: 0:00:06.217 / 4.8Gb/s
Dir size: 32.7Gb, File count: 11127
ssd > ssd: 0:00:15.063 / 2.2Gb/s
sdd > ram: 0:00:08.486 / 3.9Gb/s
ram > ram: 0:00:08.032 / 4.1Gb/s
ram > sdd: 0:00:07.026 / 4.7Gb/s
Скрипт для теста ↗️
На моём железе прирост скорости ~2x. Плюс экономия ресурса SSD.
В Windows такой фишки по умолчанию нет, но обязательно найдутся аналогичные решения
#linux#triks
#FLM/USDT analysis :
#FLM is forming higher highs (HHs) and higher lows (HLs) along the trendline support. The price has recently swept through the swing low stop losses and is now expected to move upward, resuming its bullish direction to test the swing high resistance level.
TF : 2H
Entry : $0.0423
Target : $0.0445
SL : $0.0409
#FLM/USDT analysis :
#FLM is currently in a bearish trend on the higher time frame. A retracement towards the 200 EMA is anticipated as the price forms a higher high structure. It is expected to move upward and test previous highs.
TF : 1H
Entry : $0.0584
Target : $0.0636
SL : $0.0560
#FLM/USDT analysis :
#FLM is currently in a downtrend, trading below the 200 EMA. The price is consolidating sideways within a support and resistance zone. It is currently facing rejection at the resistance zone and is expected to decline from this point, testing the support zone.
TF : 1D
Entry : $0.0620
Target : $0.0500
SL : $0.0700
#FLM🧐
👉EMA Confluence
👉Failure Swing
👉MACD
The second chart fully and automatically generated by our algorithm.
All drawings are based on only mathematical values and calculations instead of emotions.
Interested?
Check out -> www.coinlegs.com / www.legslabs.com