WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: [util-linux-ng] mount & "losetup --find", can not find free loop device ?  (Read 4612 times)

Offline Arslan S.

  • Hero Member
  • *****
  • Posts: 825
Code: [Select]
/usr/local/sbin/losetup --find
losetup: could not find any free loop device

same when testing from base

i need the full versions for some testing of udisks


Offline Jason W

  • Retired Admins
  • Hero Member
  • *****
  • Posts: 9730
If you have more than 255 extensions already mounted, then util-linux-ng will report no free loop devices.  Since the kernel supports unlimited loops, creating more may be necessary when using util-linux tools.  I had a line of code that would create a specified number of loops starting with the first free one,, a line that could be put in bootlocal.sh so loops would be available after booting and using over 256 for extensions.

That may be a way to go when more loops are needed, as opposed to a specified amount pre-created in base.

EDIT: As of TC 3.0, the standard 8 are in base, the rest created as needed by busybox mount.
« Last Edit: August 02, 2010, 10:42:11 AM by Jason W »

Offline Arslan S.

  • Hero Member
  • *****
  • Posts: 825
i have only 19 extensions loaded udisks.tcz and its deps + util-linux-ng

Offline Jason W

  • Retired Admins
  • Hero Member
  • *****
  • Posts: 9730
I will find and post the command for easy batch mode loop device creation for those who need extra loops at any point during runtime.

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 11041
Extension loading should work with util-linux loaded due to tce-load calling busybox mount.
If you need manual loops with the util-linux mount, set a suitable limit with the loop.max_loop param (500?). All devices up to the number will be pre-created.

edit: Loop's a module now, so the syntax is loop.max_loop, not max_loop.
« Last Edit: August 02, 2010, 04:35:44 PM by curaga »
The only barriers that can stop you are the ones you create yourself.

Offline Arslan S.

  • Hero Member
  • *****
  • Posts: 825
with max_loop=500 util-linux mount works now thanks
but "losetup --find" still fails, i assume this is normal

now i have another question: any idea why busybox mount returns "you have no permission to run this applet" ?
Code: [Select]
tc@box:~$ udisks --mount /dev/sda10
Mount failed: Error mounting: mount exited with exit code 1: helper failed with:
mount: you have no permission to run this applet!

tc@box:~$ sudo udisks --mount /dev/sda10
Mounted /org/freedesktop/UDisks/devices/sda10 at /mnt/sda10

with util-linux-ng, udisks can mount & unmount without super user permissions
« Last Edit: August 02, 2010, 04:54:28 PM by Arslan S. »