Magic Folders issue with /home/guest

Please reproduce your error on a second machine before posting, and check the error by running without saved changes or extra modules (See FAQ No. 13, "How to report a bug"). For unstable Porteus versions (alpha, beta, rc) please use the relevant thread in our "Development" section.
Post Reply
dein0s
White ninja
White ninja
Posts: 13
Joined: 10 Jun 2011, 23:49
Location: Minsk, BY

Magic Folders issue with /home/guest

Post#1 by dein0s » 24 Jun 2011, 12:15

just found another bug, with magic folder

folders.cfg

Code: Select all

/mnt/sdc1/porteus/magfo.dat /home/guest
after reboot getting this error: "Could not start kstartupconfig. Check your installation"

User avatar
Ahau
King of Docs
King of Docs
Posts: 1331
Joined: 28 Dec 2010, 15:18
Distribution: LXDE & Xfce 32/64-bit
Location: USA

Re: Magic Folders issue with /home/guest

Post#2 by Ahau » 24 Jun 2011, 16:36

@dein0s,

I’ve split this post from your other bug report (Porteus 1.0 bug).

I can confirm this bug. The problem is that the magic_folders setup script does not copy files from the source directory to the target directory when you use a .dat container.

Note to fanthom: files are correctly copied from source to target when a plain folder is used as the target; I took a look at the script and I believe it’s missing something for .dat containers, like mounting it on a loop before trying to copy files to it?

So, what happens is you are mounting a blank .dat directory to /guest/home/, which makes /guest/home empty. Without all of the config files, kde won’t start up properly.

My tested workaround (boy, this took me a lot of testing!):

1 ) Bootup Porteus as guest (if you have a messed up magic folder, use ‘nomagic’ cheatcode to avoid loading it)
2 ) Run the ‘magic_folders’ script (from GUI or console)
3 ) Specify the target as a .dat, and tell the system that you want to make a container file, and specify the size
4 ) Do not initialize magic folders at this point
5 ) su to root
6 ) mount your new .dat container: ‘mloop /mnt/sdb1/porteus/yourdat.dat’ or wherever you have it
7 ) cd to /mnt/
8 ) run this command: ‘chown guest:guest loop’ to change ownership of the /mnt/loop/ directory to guest
9 ) Open up konqueror (as guest), go to /home/guest. Enable viewing hidden files from the ‘view’ menu, then select all, copy.
10 ) Still within konqueror as guest, navigate to /mnt/loop, and paste all files there
11 ) Reboot as guest. It should be working now.

Note: If you create a .dat container with a different path or name, go clean up your /porteus/rootcopy/etc/magic_folders/config file so that the only line there is the one pointing to your new .dat container. If there are any broken folder links (missing .dat’s, etc), the script will stop and not mount the rest of the magic folders. This is probably a bug that could use some attention too (i.e. make it so that if mounting of any magic folders fails, the script continues on to the next line in the config file without exiting).

I hope this helps – let me know if it doesn’t.

EDIT: the reason you need to chown /mnt/loop is because you can't write to it as guest otherwise. If you try to copy your files from /home/guest to /mnt/loop as root, it will set root as the owner/group on all of those files. I'm sure there's a way to copy them while preserving ownership, but I'm a noob in some respects, and I don't know it. lol.
Please take a look at our online documentation, here. Suggestions are welcome!

User avatar
fanthom
Site Admin
Site Admin
Posts: 4593
Joined: 28 Dec 2010, 02:42
Distribution: Porteus Kiosk
Location: Poland, currently - Cork, IE
Contact:

Re: Magic Folders issue with /home/guest

Post#3 by fanthom » 25 Jun 2011, 05:25

@Ahau
good point :)

@dein0s
i have prepared a quick fix for magic_folders issue:
http://ponce.cc/porteus/x86_64/testing/ ... .0-fix.xzm

pls test it and report success/fail
Please add [Solved] to your thread title if the solution was found.

dein0s
White ninja
White ninja
Posts: 13
Joined: 10 Jun 2011, 23:49
Location: Minsk, BY

Re: Magic Folders issue with /home/guest

Post#4 by dein0s » 26 Jun 2011, 11:16

works fine now, just 1 thing:
when i'm trying to get access to my usb-flash trough "audacious" getting this ^

Code: Select all

Couldn't mount sdc1
mv: cannot move 'sbin/mount.fvat' to 'sbin/mount.fvat-tmp': Premission denied
mount: only root can do that
mv: cannot stat 'sbin/mount.vfat-tmp': No such file or directory

User avatar
Blaze
DEV Team
DEV Team
Posts: 1432
Joined: 28 Dec 2010, 11:31
Distribution: ⟰ Porteus 3.2 Cinnamon x86_64
Location: ☭ Russian Federation, Lipetsk region, Dankov
Contact:

Re: Magic Folders issue with /home/guest

Post#5 by Blaze » 26 Jun 2011, 12:35

dein0s, you are need to run root account for this premissions.
Linux porteus 4.13.3-porteus #1 SMP PREEMPT Sat Sep 23 18:22:13 x86_64 Intel(R) Core(TM) i5-6600K CPU @ 3.50GHz GenuineIntel GNU/Linux
MS-7A12 » [AMD/ATI] Tobago PRO [Radeon R7 360 / R9 360 OEM] (rev 81) » Vengeance LPX 16GB DDR4 K2 3200MHz C16

Post Reply