OctoPrint/CustoPiZer

failing to umount dev/pts

TheSin- opened this issue · 3 comments

not sure why, but custopizer keeps failing at the end with

+ apt-get clean
+ apt-get autoremove -y
Reading package lists...
Building dependency tree...
Reading state information...
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
/CustoPiZer/workspace /
Unmounting /CustoPiZer/workspace/mount/var/cache/apt...
Unmounting /CustoPiZer/workspace/mount/dev/pts...
umount: /CustoPiZer/workspace/mount/dev/pts: target is busy.

I've done it 3 times and this happens before to rebuilds the fs to shrink it so the img is large, I haven't tested to see if it's usable at this stage. Any ideas, should there be a force or a wait on this for pts to finish up?

looks like it must happen here

sudo umount $m

I'm still trying to figure out if I should put a loop to try a few times with a sleep, then force it, or just force it ;)

EDIT: running it now with umount -f in script 99, might be too early but I want to see if it'll finish.

EDIT2: maybe just adding || true to the amount call to make sure it can't fail?

odd that didn't work, so it must mount and unmount at once after script 99??

+ umount -f /CustoPiZer/workspace/mount/dev/pts
umount: /CustoPiZer/workspace/mount/dev/pts: umount failed: No such file or directory.

I works perfectly if I use it to update an image, but not if I'm making a new image, not sure if that helps.