ubuntu:disk:ramdisk:persisting_ramdisk_data
Differences
This shows you the differences between two versions of the page.
Next revision | Previous revision | ||
ubuntu:disk:ramdisk:persisting_ramdisk_data [2021/06/22 11:01] – created peter | ubuntu:disk:ramdisk:persisting_ramdisk_data [2021/06/22 11:18] (current) – [Test] peter | ||
---|---|---|---|
Line 1: | Line 1: | ||
====== Ubuntu - Disk - Ramdisk - Persisting Ramdisk Data ====== | ====== Ubuntu - Disk - Ramdisk - Persisting Ramdisk Data ====== | ||
- | A Ramdisk | + | A Ramdisk |
- | The approach is: | + | When the computer is shutdown all the data within the Ramdisk is erased. |
+ | |||
+ | To ensure this data is retained, the approach | ||
* Save Ramdisk data to hard drive on system shutdown. | * Save Ramdisk data to hard drive on system shutdown. | ||
Line 9: | Line 11: | ||
<WRAP info> | <WRAP info> | ||
- | **NOTE: | + | **NOTE: |
+ | |||
+ | * In essence, | ||
</ | </ | ||
Line 49: | Line 54: | ||
WantedBy=multi-user.target | WantedBy=multi-user.target | ||
</ | </ | ||
+ | |||
+ | <WRAP info> | ||
+ | **NOTE: | ||
+ | </ | ||
+ | |||
+ | |||
+ | ---- | ||
+ | |||
+ | ===== Enable the ramdisk-sync service ===== | ||
+ | |||
+ | <code bash> | ||
+ | sudo systemctl enable ramdisk-sync.service | ||
+ | </ | ||
+ | |||
+ | <WRAP info> | ||
+ | **NOTE: | ||
+ | </ | ||
+ | |||
+ | ---- | ||
+ | |||
+ | ===== Reboot ===== | ||
+ | |||
+ | <code bash> | ||
+ | sudo reboot | ||
+ | </ | ||
+ | |||
+ | ---- | ||
+ | |||
+ | ===== Check whether the ramdisk-sync service is running ===== | ||
+ | |||
+ | <code bash> | ||
+ | sudo systemctl status ramdisk-sync | ||
+ | </ | ||
+ | |||
+ | ---- | ||
+ | |||
+ | ===== Check the contents of the / | ||
+ | |||
+ | <code bash> | ||
+ | ls / | ||
+ | </ | ||
+ | |||
+ | <WRAP info> | ||
+ | **NOTE: | ||
+ | </ | ||
+ | |||
+ | ---- | ||
+ | |||
+ | ===== Test ===== | ||
+ | |||
+ | Copy some files to the Ramdisk / | ||
+ | |||
+ | Reboot again. | ||
+ | |||
+ | Check again the contents of both the / | ||
+ | |||
+ | * They should be the same! | ||
+ | |||
+ | ---- | ||
+ | |||
ubuntu/disk/ramdisk/persisting_ramdisk_data.1624359661.txt.gz · Last modified: 2021/06/22 11:01 by peter