[Solved] copy2ram questions

Post here if you are a new Porteus member and you're looking for some help.
Post Reply
rodyaj
White ninja
White ninja
Posts: 16
Joined: 06 Jul 2012, 23:56
Location: Liverpool

[Solved] copy2ram questions

Post#1 by rodyaj » 14 Aug 2012, 19:12

Hi.

I installed Porteus to hard disk so I have enough storage for downloads and such, but I still boot with copy2ram:

Code: Select all

APPEND initrd=/boot/initrd.xz vga=791 copy2ram changes=/porteus/ kmap=gb lang=en_GB noload=kde
My system has 4gb of ram so I load in to ram to get the benefits of increased app start up times, but this means I quickly run out of space when I try to download large files. I'm guessing this means I need to mount my home directory on the hard disk filesystem instead? Is there a recommended way of doing this without breaking things?

Also, I'm not quite sure how loading into ram works. Are the files I download still getting stored on the hard disk install because the ram disk is just virtual? Or does it actually decrease the amount of ram available for access by running applications? If it does, I suppose I should point the 'changes=/porteus/' line to a hard disk as well?

Thanks for reading.
Last edited by rodyaj on 14 Aug 2012, 21:26, edited 2 times in total.

User avatar
brokenman
Site Admin
Site Admin
Posts: 5439
Joined: 27 Dec 2010, 03:50
Distribution: Porteus v3.2rcX all desktops
Location: Brazil
Contact:

Re: copy2ram questions

Post#2 by brokenman » 14 Aug 2012, 19:33

If I fill up ram with storage, does that actually decrease the amount of ram I have available for access by running applications? Will it slow down my system to a crawl? If it does, I suppose I should point the 'changes=/porteus/' line to a hard disk as well?
If you fill up ram with storage you indeed decrease the memory available for applications. The system puts aside a certain amount of ram to ensure the system doesn't go down easily. You shouldn't notice a speed decrease unless you fill up ram and are using swap, after which read times will increase slightly.

If you are using changes=/porteus/ then i would assume the porteus directory is on writable media (the place you installed porteus) which is where your changes are being stored. I'd recommend saving large files to external storage if using copy2ram.
How do i become super user?
Wear your underpants on the outside and put on a cape.

rodyaj
White ninja
White ninja
Posts: 16
Joined: 06 Jul 2012, 23:56
Location: Liverpool

Re: copy2ram questions

Post#3 by rodyaj » 14 Aug 2012, 19:36

Ok thanks for the help. Will the changes be persistent if I edit /etc/fstab to mount my home directory on the hard disk?

User avatar
fanthom
Site Admin
Site Admin
Posts: 4548
Joined: 28 Dec 2010, 02:42
Distribution: Porteus Kiosk
Location: Poland, currently - Cork, IE
Contact:

Re: copy2ram questions

Post#4 by fanthom » 14 Aug 2012, 20:34

@rodyaj

i guess that porteus is installed on NTFS/FAT formatted partition - is it?
otherwise 'changes=/porteus/' cheatcode would never let you fill up the RAM as all files would be saved on the partition where porteus is installed.
Will the changes be persistent if I edit /etc/fstab to mount my home directory on the hard disk?
Porteus is a live linux distro so fstab must be recreated at every boot.

i would recommend you using "magic folders" to pair your /home/guest folder with save.dat (if you have only windows fs around) or folder (if you have at least one linux fs on your hd).
I'm not quite sure how loading into ram works.
copy2ram tells linuxrc (booting script) to copy all modules to RAM first (you can find them in /mnt/live/memory/copy2ram folder). once done booting continues by using modules stored in RAM rather than by using modules placed on your booting media.
this way everything works faster.

copy2ram doesn't force storing everything in RAM.
you can use 'copy2ram' together with 'changes=' cheatcode so porteus will be working faster and your changes remain persistent (as saved on the hard drive)
same applies to 'copy2ram' + "magic folders".

Cheers
Please add [Solved] to your thread title if the solution was found.

rodyaj
White ninja
White ninja
Posts: 16
Joined: 06 Jul 2012, 23:56
Location: Liverpool

Re: copy2ram questions

Post#5 by rodyaj » 14 Aug 2012, 20:53

fanthom wrote:@rodyaj

i guess that porteus is installed on NTFS/FAT formatted partition - is it?
I installed on ext4.
otherwise 'changes=/porteus/' cheatcode would never let you fill up the RAM as all files would be saved on the partition where porteus is installed.
Yes I see that now. I only added 'changes=' today and didn't reboot to test it. Now that I have rebooted to test it, files are getting written just as I wanted all along. Any new files (that aren't added through modules) are getting written to the hard disk installation rather than the live system - just as I wanted. So now I can download without running out of disk space or using up ram.

Thanks for helping me understand how the system works. Very neat.

Post Reply