WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: I still need more clarification on "Install" and "OnDemand" (formerly "Mount")  (Read 4659 times)

Offline baz

  • Full Member
  • ***
  • Posts: 216
I've read every forum post, and the Core Concepts article on the web many times over (which needs to be much better written, and I am working on that :) and I still don't really get it. I would much appreciate answers to these questions, and please assume a persistent tce/opt/home:

1. When I "Install" an extension, my understanding is that the tcz gets downloaded to my persistent tce, then it is loaded completely into ram. So when I run the program there is zero disk access at that point because it is already completely loaded into ram. Is this correct?

2. "Installed" extensions are all completely loaded into ram on boot (barring special boot codes and such) - so if I "installed" firefox, chrome and opera, I would basically be having 3 entire browsers running simultaneously in ram even though I have not yet opened any of them. Is this correct?

3. "OnDemand" only downloads the tcz, tells TC of its existence and then stops there without loading itself to ram until it is invoked. Is this correct?

4. Following, once an "OnDemand" extension is actually run, it is then completely loaded into ram and for all practical purposes it becomes almost exactly like it would be had I "instaled" it. Is this correct?

5. Some stuff is weird or awkward to make "OnDemand" like 915resolution or audio drivers, however bigger, higher-level programs like vlc or chrome make perfect candidates for loading "OnDemand". Correct? In fact, why would I ever not want high-level programs to be "OnDemand"?

6. I still haven't gotten anything "OnDemand" to actually work. In some posts it mentions running the ondemand command but that doesn't seem to do anything for me. And I never see menu entries for things "OnDemand". Why can't "OnDemand" be completely invisible in that in terms of UI everything is identical, however behind the scenes TC knows to first load it to ram?

That's all for now, thanks for your time!
Baz

Online Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14815
1. Starting from tc-2.7, the appbrowser does not give a choice and "mounts" the extensions.

2. Barring special boot codes (tce-load -ir), extensions are mounted.

3. Ondemand (run "ondemand" from a terminal window and follow the instructions) sets up a "right-click" menu for extensions in /tce/optional.

4. The extension is mounted.

5. 915resolution needs to be be run before starting the window manager, so there wouldn't be much point for it to work with ondemand. I would guess that some users would only want the extensions they use often in the ondemand menu in order to avoid a long list.

6. Running "ondemand" from a terminal window should work - what error message do you get?

Offline baz

  • Full Member
  • ***
  • Posts: 216
Thanks for the replies:

1. I am running 2.7, I do have a choice of install or ondemand?

2. Mounted meaning they are ready to be run but not actually loaded into ram? That is, I will NOT have 3 browsers in ram unless I run them?

3. I get no messages, no nothing, just as though the command finished running. These were quick tests in cloud mode, I will try with a proper install and report back.

4. Hehehe, so again "mounted" means that it is ready to be run, but not actually run untill first invoked? After initial invokcation it obviously stays in memory as "install" used to do?

5. Sounds good.

6. No error messages, no positive messages, just nothing.

Cheers,
Baz

Online Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14815
1. I am running 2.7, I do have a choice of install or ondemand?
Yes, you can use appsaudit (type "appsaudit" in a terminal window) - new menu option 'Install Options' to maintain two files - copy2fs.flg and copy2fs.lst or manually create and edit these files. Use flag for all, or list (lst) to specify extensions to be copied into the file system.

Quote
2. Mounted meaning they are ready to be run but not actually loaded into ram? That is, I will NOT have 3 browsers in ram unless I run them?
Mounted meaning the extension runs in real time from a loop file and is not loaded into ram

Quote
3. I get no messages, no nothing, just as though the command finished running. These were quick tests in cloud mode, I will try with a proper install and report back.
Strange.. what happens when you type "which ondemand" in a terminal window?

Quote
4. Hehehe, so again "mounted" means that it is ready to be run, but not actually run untill first invoked? After initial invokcation it obviously stays in memory as "install" used to do?
No, it stays mounted, but not in ram

Offline baz

  • Full Member
  • ***
  • Posts: 216
Quote
Yes, you can use appsaudit (type "appsaudit" in a terminal window) - new menu option 'Install Options' to maintain two files - copy2fs.flg and copy2fs.lst or manually create and edit these files. Use flag for all, or list (lst) to specify extensions to be copied into the file system.

So I see that and there is a new term "Copy Install" - is that like "Install" or "OnDemand" or something new?

Quote
Mounted meaning the extension runs in real time from a loop file and is not loaded into ram

Would you mind explaining what "Install" is?

Quote
Strange.. what happens when you type "which ondemand" in a terminal window?

/usr/bin/ondemand

Quote
No, it stays mounted, but not in ram

What kind of resources does, say, a huge extension take in this state? And does that mean while it is running it is constantly interacting with the disk?


Offline baz

  • Full Member
  • ***
  • Posts: 216
Quote
Strange.. what happens when you type "which ondemand" in a terminal window?

/usr/bin/ondemand

I rebooted into a fresh TC and now it works.

Offline roberts

  • Retired Admins
  • Hero Member
  • *****
  • Posts: 7361
  • Founder Emeritus
OnDemand is not formerly mount.

Place your mouse over the OnDemand button, there is a popup.
OnDemand is formerly Download Only.

Install, as was announced, now defaults to mounting extensions.
See: http://forum.tinycorelinux.net/index.php?topic=4315.0

If you wish to copy to ram, which is really  based on what type of installation you have,
and is therefore more properly called  "copy to filesystem",  you place copy2fs.flg or copy2fs.lst in your tce directory.

appsaudit has a new feature "Install Options" that helps you maintain copy2fs items in your tce directory.
10+ Years Contributing to Linux Open Source Projects.

Offline baz

  • Full Member
  • ***
  • Posts: 216
How much resources does it take to "Install" (mount) a 100mb extension?

Offline gerald_clark

  • TinyCore Moderator
  • Hero Member
  • *****
  • Posts: 4254
That is easy enough to test yourself.

Offline baz

  • Full Member
  • ***
  • Posts: 216
I installed vlc and it basically looks like it consumes near 0 resources - assuming its one of the "loop" processes. So is the purpose of OnDemand to speed up boot?

Offline gerald_clark

  • TinyCore Moderator
  • Hero Member
  • *****
  • Posts: 4254
Yes, it speeds boot by deferring the mount until it is requested.

Offline baz

  • Full Member
  • ***
  • Posts: 216
Ok, I really appreciate everyone's help, it is a lot more clear now! An additional question concerning ram, one of my favorite features of TC is that it runs in ram - not only for the speed but also because it prolongs the life of my cheap SSD - so what exactly does run in ram? Is it just the OS (no matter what mode you are in) or the extensions as well? The way I see it now:

Cloud Mode: Everything runs in RAM
Persistent TCE/OPT/HOME: OS runs in RAM but extensions write to the file system when they need to
Local Install: Both OS and extensions write to the filesystem like any other distro

Is this correct?

Offline Guy

  • Hero Member
  • *****
  • Posts: 1089
Quote
Cloud Mode: Everything runs in RAM
Yes

Quote
Persistent TCE/OPT/HOME: OS runs in RAM but extensions write to the file system when they need to
It depends on two files - copy2fs.flg and copy2fs.lst.
If programs are not listed in copy2fs.lst, and you don't have copy2fs.flg, extensions are mounted, and not loaded to ram until you use the program.
If they are listed in copy2fs.lst, or you have copy2fs.flg, they are loaded to ram when you start the computer, and run entirely from ram.

Quote
Local Install: Both OS and extensions write to the filesystem like any other distro
I assume this would be the same as the previous one. It would depend on copy2fs.flg and copy2fs.lst.
Many people see what is. Some people see what can be, and make a difference.

Offline thane

  • Hero Member
  • *****
  • Posts: 697
If I understand right, persistent HOME and/or OPT mean that HOME and/or OPT files are written to your save device (e.g. hard disk or USB stick) whenever the files are modified while TCL is running.

If you don't have persistent HOME or OPT, the file modifications are in RAM only and aren't saved until the backup when you shutdown. This is how my box is because I want to minimize writes to the USB stick.

The copy2fs.flg and copy2fs.list files only affect extensions and don't change how the basic OS works.

Is this correct?

Offline baz

  • Full Member
  • ***
  • Posts: 216
Quote
If I understand right, persistent HOME and/or OPT mean that HOME and/or OPT files are written to your save device (e.g. hard disk or USB stick) whenever the files are modified while TCL is running.

Yes, and because of this, one should make sure to remove all references to /home and /opt from .filetool.lst

Quote
If you don't have persistent HOME or OPT, the file modifications are in RAM only and aren't saved until the backup when you shutdown. This is how my box is because I want to minimize writes to the USB stick.

That's right, and again whatever you need to save in there should therefore be in .filetool.lst

Quote
The copy2fs.flg and copy2fs.list files only affect extensions and don't change how the basic OS works.

Don't know :)