View Single Post
Old 01-15-2017, 12:36 PM   #24
Analogus
Fanatic
Analogus ought to be getting tired of karma fortunes by now.Analogus ought to be getting tired of karma fortunes by now.Analogus ought to be getting tired of karma fortunes by now.Analogus ought to be getting tired of karma fortunes by now.Analogus ought to be getting tired of karma fortunes by now.Analogus ought to be getting tired of karma fortunes by now.Analogus ought to be getting tired of karma fortunes by now.Analogus ought to be getting tired of karma fortunes by now.Analogus ought to be getting tired of karma fortunes by now.Analogus ought to be getting tired of karma fortunes by now.Analogus ought to be getting tired of karma fortunes by now.
 
Analogus's Avatar
 
Posts: 568
Karma: 2170348
Join Date: Apr 2011
Device: 2x Sony PRS-350; PRS-300 (†), Paperwhite (†), Voyage
Nope...

Always the same error message:
losetup: /mnt/us/test/fonts.sqsh: No such file or directory

I tried different numbers for loop (17 is the next free number, 0 - 16 are in use).

Besides: I think there is an error in the original script with the variable:
nxt=$(losetup -f)
returnes
/dev/loop0
not
/dev/loop/0

But i fixed it by hand as you can see in the code - you can observe the variations I used:

Code:
# You need to find the next available loop device:
# nxt=$(losetup -f)
# echo "$nxt"  #error?

# You have to use that loop device to translate your new file into a device
# ls -l /mnt/us/test/*
# losetup /mnt/us/test/fonts.sqsh $nxt
losetup /mnt/us/test/fonts.sqsh /dev/loop/17
# losetup /mnt/us/test/fonts.sqsh /dev/loop/Largest_Number
# losetup /dev/loop/Largest_Number

# Then you have to mount the new device on top of the existing system at that mount point
# mount -t squashfs $nxt /usr/java/lib/fonts
# mount -t squashfs /dev/loop/17 /usr/java/lib/fonts

# Make cvm and its children let go of the old (now 'bottom') layer files
# initctl stop cvm

# Get everything just stopped, re-started again
# initctl start cvm

Edit:
There is a conundrum with the path.
I managed to copy the file on /opt/fonts.sqsh
Using this command:
Code:
losetup /opt/fonts.sqsh /dev/loop/17
Seems there is space enough.
Same return: there is no...

Last edited by Analogus; 01-15-2017 at 12:58 PM.
Analogus is offline   Reply With Quote