edison-fw / meta-intel-edison

Here is the meta-intel-edison that builds, tries to stay up to date. Master is based on Yocto Poky Gatesgarth LTS 5.10.yy vanilla kernels. It builds a 32bit kernel (Gatesgarth branch 64bit) with ACPI enabled and corresponding rootfs. Telegram group: https://t.me/IntelEdison Web-site:
https://edison-fw.github.io/meta-intel-edison/
MIT License
60 stars 37 forks source link

Not installing file to /home #84

Closed shawnhsoia97 closed 4 years ago

shawnhsoia97 commented 4 years ago

Hi ,I encounter some problem .My Edison has nothing in /home after the flashing. But my yocto rootfs have some thing.

ls out/linux64/build/tmp/work/edison-poky-linux/edison-image/1.0-r0/rootfs/home/ -l
total 16
drwxr-xr-x 2 shawn shawn 4096 Feb  7 10:08 bovia
drwxr-sr-x 2 shawn shawn 4096 Jan 30 08:53 root
drwxr-xr-x 2 shawn shawn 4096 Feb  7 10:08 tester
-rw-r--r-- 1 shawn shawn  167 Feb  7 10:01 wpa_supplicant-wlan0.conf

Other filles can be installed to root normally,but there is no way to install to /home.

htot commented 4 years ago

/home is on our rootfs image. But currently we don't build a home image. Actually we don't even flash the home partition (checkout flashall.sh).

So it might be that there are files on /home, but then the (empty?) home partition is mounted on top of it and hiding the files?

shawnhsoia97 commented 4 years ago

Yes,you are right.Files is appeared after I unmount home partition. Because my user directory is install on /home,so if home partition hiding the files,user directory can't be found. No directory, logging in with HOME=/ Thank you! Is there a way to format this partition separately in Yocto?(Don't build a home image) I can use mkfs -t ext4 /dev/disk/by-partlabel/home,but I want to format /dev/disk/by-partlabel/homein Yocto.

htot commented 4 years ago

You could add things to postinstall and let them be created once run time (after mount). Also I think Yocto provides a mechanism to add users, but I haven't investigated that yet. That should take care of user directory creation.

I have also been wondering why the user root has its home on /home/root. In case the home partition mount fails this causes problems to log in. This is not what debian does, that has user root home on /root. It can be changed see https://www.yoctoproject.org/docs/latest/mega-manual/mega-manual.html#var-ROOT_HOME

shawnhsoia97 commented 4 years ago

Yes,use to EXTRA_USERS_PARMS can create user directory,but this install to /hoom of rootsf,so I change MountPoint of /dev/disk/by-partlabel/home.

I think maybe /home/root was created on home partition ,because I can't build it after I remove /home/root.

Also I want to format all partition in Yocto,because just only format rootsh now.Do you know how solve it? Thank you.

htot commented 4 years ago

I am working to create one btrfs partition to replace home and rootfs, with @, @boot and @home subvolume. But after you do this flashall won't work any more. So, multiple things need changing.

shawnhsoia97 commented 4 years ago

I understand.Thank you!