WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: Max tcz mounts  (Read 12519 times)

Offline fladd

  • Jr. Member
  • **
  • Posts: 65
Max tcz mounts
« on: September 14, 2009, 01:03:14 PM »
Hi there,

what is the max of loop devices (to mount tcz extensions) wihtout specifying the grub parameter?
Also, I can imagine a system becoming so complex that it has tio exceed the 255 loop devices. What happens then? Isn't this a serious general limitation of the concept (as much as I like the modular idea)?

Regards,
fladd

Offline Jason W

  • Retired Admins
  • Hero Member
  • *****
  • Posts: 9730
Re: Max tcz mounts
« Reply #1 on: September 14, 2009, 03:04:56 PM »
There was a page on the Slax site about the limit of 256 max loops being done away with in kernel 2.6.24.  It seems to say you can boot with max_loop=500 and you would have 500 loops available.  I have ran out of loops with my max_loop=255, and I will see what happens if I set it higher and keep adding extnesions.

I saw that page in the early days of TC but we didn't have enough extensions to test it with at the time.

Offline Guy

  • Hero Member
  • *****
  • Posts: 1089
Re: Max tcz mounts
« Reply #2 on: September 14, 2009, 03:32:50 PM »
In the future, it may be beneficial / necessary to combine extensions which are normally used together into larger extensions, reducing the number.
Many people see what is. Some people see what can be, and make a difference.

Offline roberts

  • Retired Admins
  • Hero Member
  • *****
  • Posts: 7361
  • Founder Emeritus
Re: Max tcz mounts
« Reply #3 on: September 14, 2009, 03:56:35 PM »
You don't have to mount everything. You can selectively load into ram.
10+ Years Contributing to Linux Open Source Projects.

Offline fladd

  • Jr. Member
  • **
  • Posts: 65
Re: Max tcz mounts
« Reply #4 on: September 14, 2009, 04:35:15 PM »
You don't have to mount everything. You can selectively load into ram.

Well, not with only 128MB, though. The ability to just mount it and save RAM is a great thing. So the kernel standard now is 256 and that can be extended up to 500?

fladd

Offline Jason W

  • Retired Admins
  • Hero Member
  • *****
  • Posts: 9730
Re: Max tcz mounts
« Reply #5 on: September 14, 2009, 05:28:38 PM »
Slax claims it sponsored code that supports unlimited loop devices by simply using the max_loop boot parameter and it was added to 2.6.24 and later. 

http://www.slax.org/documentation_loop_mount.php

Offline Jason W

  • Retired Admins
  • Hero Member
  • *****
  • Posts: 9730
Re: Max tcz mounts
« Reply #6 on: September 16, 2009, 08:52:12 PM »
I tried approaches using the instructions listed in the above link to make use of more than 255 loop devices, to no avail.  I looked in loop.c in the 2.6.29.1 kernel and the last commit to that file was in 2005.  So we seem to be stuck with a 255 limit on the number of tczs we can mount.  I read the threads where the patch was being discussed, but it evidently was not included.

Of course, correct me if I am wrong.

Offline fladd

  • Jr. Member
  • **
  • Posts: 65
Re: Max tcz mounts
« Reply #7 on: September 17, 2009, 02:45:15 PM »
Mmh, too bad. That might introduce a serious problem.

fladd

Offline bmarkus

  • Administrator
  • Hero Member
  • *****
  • Posts: 7183
    • My Community Forum
Re: Max tcz mounts
« Reply #8 on: September 17, 2009, 03:11:04 PM »
Quote
Mmh, too bad. That might introduce a serious problem.

Don't think soo.

1) We can investigate it a bit more, I mean SLAX and Kernel patch

2) You can combine extensions on a logical way to reduce number of loops.
Béla
Ham Radio callsign: HA5DI

"Amateur Radio: The First Technology-Based Social Network."

Offline Jason W

  • Retired Admins
  • Hero Member
  • *****
  • Posts: 9730
Re: Max tcz mounts
« Reply #9 on: September 17, 2009, 03:36:37 PM »
Though I can't find where the patch was applied, and cant get more than 256 loop mounts, there is a chance I am missing something.   I will review my steps and make sure something was not overlooked.

Right now I am mounting my tcz's by mounting the loop device instead of the tcz file, but still run into the 256 maximum, or the default maximum when not using max_loop parameter.  My tce directory has about 270 tcz extensions right now.  This is by no means on the front burner but I am curious about the loop limit and will keep my eye on what happens with it.   


Offline Jason W

  • Retired Admins
  • Hero Member
  • *****
  • Posts: 9730
Re: Max tcz mounts
« Reply #10 on: September 17, 2009, 08:41:28 PM »
TC 1.x will let you specify max_loop=700 and 700 devices get created.  TC 2.x will only let you specify 256 or no extras get created if you try to go higher and you will max out at the standard default.  I am now posting with 485 tcz extensions mounted.  Rather the same set of extensions copied to different directories and mounted in different places.  There is evidently a change in the kernel since 2.6.26.  So , and you don't even have to issue a different mount command once you get past 256 loops.  I am going to poke around and see what has changed.

Offline roberts

  • Retired Admins
  • Hero Member
  • *****
  • Posts: 7361
  • Founder Emeritus
Re: Max tcz mounts
« Reply #11 on: September 17, 2009, 09:31:21 PM »
If you peruse the comments of linux-2.6.29.1-tinycore/drivers/block/loop.c  you will see:
Code: [Select]
*
 * Maximum number of loop devices when compiled-in now selectable by passing
 * max_loop=<1-255> to the kernel on boot.
 * Erik I. Bolsø, <eriki@himolde.no>, Oct 31, 1999
 *
 * Completely rewrite request handling to be make_request_fn style and
 * non blocking, pushing work to a helper thread. Lots of fixes from
 * Al Viro too.
 * Jens Axboe <axboe@suse.de>, Nov 2000
 *
 * Support up to 256 loop devices
 * Heinz Mauelshagen <mge@sistina.com>, Feb 2002
 *
10+ Years Contributing to Linux Open Source Projects.

Offline Jason W

  • Retired Admins
  • Hero Member
  • *****
  • Posts: 9730
Re: Max tcz mounts
« Reply #12 on: September 17, 2009, 09:50:30 PM »
True, but 2.6.26 says the same thing but is able to create with max_loop more than 256 loop devices and mount them.

Offline bigpcman

  • Hero Member
  • *****
  • Posts: 719
Re: Max tcz mounts
« Reply #13 on: September 17, 2009, 10:10:17 PM »
Hi there,

what is the max of loop devices (to mount tcz extensions) wihtout specifying the grub parameter?
Also, I can imagine a system becoming so complex that it has tio exceed the 255 loop devices. What happens then? Isn't this a serious general limitation of the concept (as much as I like the modular idea)?

Regards,
fladd

On the other hand won't an excessive number of loop devices adversely affect performance?

I wonder how long it takes to boot 256 extensions?
« Last Edit: September 17, 2009, 10:28:19 PM by bigpcman »
big pc man

Offline Jason W

  • Retired Admins
  • Hero Member
  • *****
  • Posts: 9730
Re: Max tcz mounts
« Reply #14 on: September 17, 2009, 10:43:03 PM »
Each mounted loop device takes a few bytes of ram.  Mounted tcz's naturally show a small performance difference from having everything in RAM due to the gzip decompression as well as the speed of the device the tcz resides on.

On an 800mhz box, mounting 250 tczs adds about 20 seconds to the boot process.  Not exactly unlivable for a booting a pretty full sized system.