On Thu, Jul 21, 2016 at 2:15 AM, Simon Bolek <simon.bo...@googlemail.com> wrote: > Hi Raj, > Thank you. > I have already tried this. > > I managed to start the USB installation by addding > kernel-modules > to core-image-minimal-initramfs.bb > > However after the installation, system will not boot up due to kernel panic: > VFS: Cannot open root device "sda2" or unknown block (0,0) Please append a > correct "root=" boot option;
can you add SYSLINUX_ROOT = "root=/dev/hda2" to local.conf and rebuild ? > > It seems, the SDD hard drive is found on installation time, but not on boot > time. > How is that possible? It did work with FIDO, but is not working with JETHRO. > Any hint what I have to look for now? Is it the drivers missing? Or maybe > some scripts not running at boot? > What will run at boot prior to mounting what is stated in root= in grub.cfg? > > kind regards > Simon :-) > > > On Sat, Jul 16, 2016 at 2:02 AM, Khem Raj <raj.k...@gmail.com> wrote: >> >> On Fri, Jul 15, 2016 at 3:17 PM, Simon Bolek <simon.bo...@googlemail.com> >> wrote: >> > Hi Raj, >> > >> > Maybe you could help me with this. >> > I found out that during rootfs (meta/lib/oe/rootfs.py), depmodwrapper >> > script >> > is beeing called. >> > I noticed, that it does generate /lib/modules/<kernel>.. directory >> > structure >> > under: >> > poky/build/tmp/work/genericx86-poky-linux/core-image-sato >> > However, at the end of the bitbake process, there is no /lib/modules >> > direcotry in >> > core-image-minimal-initramfs-genericx86-20160715210400.rootfs.cpio.gz >> > >> > Where are the steps, where this .cpio.gz file is beeing generated. There >> > must be a place where all the files, that are inside, are beeing put >> > together. >> >> initramfs image is a separate image. What you are seeing is the final >> image. >> you might have to add the kernel module to you machine conf >> >> MACHINE_EXTRA_RRECOMMENDS = " kernel-modules" >> >> > >> > HELP! >> > kind regards >> > Simon :-) >> > >> > >> > >> > On Fri, Jul 15, 2016 at 10:59 AM, Simon Bolek >> > <simon.bo...@googlemail.com> >> > wrote: >> >> >> >> Thanks, but neither: >> >> pkg_postinst_kernel-base () >> >> nor: >> >> pkg_postinst_kernel-image () >> >> from /meta/classes/kernel.bbclass gets called when running: >> >> - bitbake core-image-sato or >> >> - bitbake linux-yocto >> >> >> >> I put some commands in there, which are definitely wrong (like foobar) >> >> and >> >> bitbake run successfully. >> >> Whereas, in other funtions it caused problems. >> >> Any ideas how can fix this? >> >> >> >> thanks and best regards >> >> Simon :-) >> >> >> >> >> >> On Fri, Jul 15, 2016 at 1:30 AM, Khem Raj <raj.k...@gmail.com> wrote: >> >>> >> >>> On Thu, Jul 14, 2016 at 4:16 PM, Simon Bolek >> >>> <simon.bo...@googlemail.com> >> >>> wrote: >> >>> > Hi Raj, >> >>> > >> >>> > About depmod again. >> >>> > Should it be run from meta/classes/kernel.bbclass ? >> >>> > ... >> >>> > pkg_postinst_kernel-base () { >> >>> > if [ ! -e "$D/lib/modules/${KERNEL_VERSION}" ]; then >> >>> > mkdir -p $D/lib/modules/${KERNEL_VERSION} >> >>> > fi >> >>> > if [ -n "$D" ]; then >> >>> > depmodwrapper -a -b $D ${KERNEL_VERSION} >> >>> > else >> >>> > depmod -a ${KERNEL_VERSION} >> >>> > fi >> >>> > } >> >>> > ... >> >>> > >> >>> > Where is this function beeing called? >> >>> >> >>> It should be called during rootfs and image creation time. as well as >> >>> when you update the package using online package manager. >> >>> >> >>> > I did not find it anywhere. >> >>> > thanks and kind regards >> >>> > Simon :-) >> >>> > >> >>> > On Thu, Jul 14, 2016 at 8:32 AM, Simon Bolek >> >>> > <simon.bo...@googlemail.com> >> >>> > wrote: >> >>> >> >> >>> >> >> >>> >> On Wed, Jul 13, 2016 at 4:56 PM, Khem Raj <raj.k...@gmail.com> >> >>> >> wrote: >> >>> >>> >> >>> >>> On Wed, Jul 13, 2016 at 4:57 AM, Simon Bolek >> >>> >>> <simon.bo...@googlemail.com> >> >>> >>> wrote: >> >>> >>> > Hi Raj, >> >>> >>> > >> >>> >>> > So i tried to do manually, what init script does and udev >> >>> >>> > definitely >> >>> >>> > does >> >>> >>> > not recognize the SSD drive. >> >>> >>> > I ran >> >>> >>> > /lib/udev/udevd --daemon --debug > udev.debug 2>&1 & >> >>> >>> > from the cli and there is no trace of recognizing the SSD. Only >> >>> >>> > the >> >>> >>> > /dev/sda, which is the USB stick I am running the installation >> >>> >>> > from. >> >>> >>> > >> >>> >>> > I used 'meld' to compare the /initrd from current jethro image >> >>> >>> > and >> >>> >>> > previous >> >>> >>> > working fido image. >> >>> >>> > They are almost the same: >> >>> >>> > - in jethro /lib/modules... file structure is missing with: >> >>> >>> > modules.alias >> >>> >>> > modules.alias.bin >> >>> >>> > modules.builtin.bin >> >>> >>> > modules.dep >> >>> >>> > modules.dep.bin >> >>> >>> > modules.devname >> >>> >>> > modules.softdep >> >>> >>> > modules.symbols >> >>> >>> > modules.symbols.bin >> >>> >>> >> >>> >>> this means depmod did not run during initramfs image creation >> >>> >> >> >>> >> How can I make this happen during bitbake, so i have those files in >> >>> >> the >> >>> >> HDDIMG? >> >>> >> >> >>> >>> >> >>> >>> > >> >>> >>> > - there are slight differences between >> >>> >>> > /etc/init.d/udev >> >>> >>> > /etc/udev/scripts/mount.sh >> >>> >>> > , but I cannot tell, if this is the reason. >> >>> >>> >> >>> >>> what are the differences ? >> >>> >> >> >>> >> >> >>> >> Sorry for this patch-like copy/paste, but this was the simplest way >> >>> >> of >> >>> >> presenting the changes. >> >>> >> Do you see something important here, that might cause the SDD not >> >>> >> beeing >> >>> >> recognized? >> >>> >> >> >>> >> --- /home/simon/Development/Yocto-Project/initrd-ok/etc/init.d/udev >> >>> >> +++ >> >>> >> /home/simon/Development/Yocto-Project/initrd-jethro/etc/init.d/udev >> >>> >> @@ -14,20 +14,27 @@ >> >>> >> [ -d /sys/class ] || exit 1 >> >>> >> [ -r /proc/mounts ] || exit 1 >> >>> >> [ -x /lib/udev/udevd ] || exit 1 >> >>> >> +SYSCONF_CACHED="/etc/udev/cache.data" >> >>> >> +SYSCONF_TMP="/dev/shm/udev.cache" >> >>> >> +DEVCACHE_REGEN="/dev/shm/udev-regen" # create to request cache >> >>> >> regen >> >>> >> + >> >>> >> +# A list of files which are used as a criteria to judge whether >> >>> >> the >> >>> >> udev >> >>> >> cache could be reused. >> >>> >> +CMP_FILE_LIST="/proc/version /proc/cmdline /proc/devices" >> >>> >> +[ -f /proc/atags ] && CMP_FILE_LIST="$CMP_FILE_LIST /proc/atags" >> >>> >> + >> >>> >> +# List of files whose metadata (size/mtime/name) will be included >> >>> >> in >> >>> >> cached >> >>> >> +# system state. >> >>> >> +META_FILE_LIST="lib/udev/rules.d/* etc/udev/rules.d/*" >> >>> >> + >> >>> >> +# Command to compute system configuration. >> >>> >> +sysconf_cmd () { >> >>> >> + cat -- $CMP_FILE_LIST >> >>> >> + stat -c '%s %Y %n' -- $META_FILE_LIST | awk -F/ '{print $1 " " >> >>> >> $NF;}' >> >>> >> +} >> >>> >> + >> >>> >> [ -f /etc/default/udev-cache ] && . /etc/default/udev-cache >> >>> >> [ -f /etc/udev/udev.conf ] && . /etc/udev/udev.conf >> >>> >> [ -f /etc/default/rcS ] && . /etc/default/rcS >> >>> >> - >> >>> >> -readfiles () { >> >>> >> - READDATA="" >> >>> >> - for filename in $@; do >> >>> >> - if [ -r $filename ]; then >> >>> >> - while read line; do >> >>> >> - READDATA="$READDATA$line" >> >>> >> - done < $filename >> >>> >> - fi >> >>> >> - done >> >>> >> -} >> >>> >> >> >>> >> kill_udevd () { >> >>> >> pid=`pidof -x udevd` >> >>> >> @@ -57,38 +64,35 @@ >> >>> >> # the automount rule for udev needs /tmp directory available, >> >>> >> as >> >>> >> /tmp >> >>> >> is a symlink >> >>> >> # to /var/tmp which in turn is a symlink to /var/volatile/tmp, >> >>> >> we >> >>> >> need to make sure >> >>> >> # /var/volatile/tmp directory to be available. >> >>> >> - mkdir -p /var/volatile/tmp >> >>> >> + mkdir -m 1777 -p /var/volatile/tmp >> >>> >> >> >>> >> # Cache handling. >> >>> >> - # A list of files which are used as a criteria to judge >> >>> >> whether >> >>> >> the >> >>> >> udev cache could be reused. >> >>> >> - CMP_FILE_LIST="/proc/version /proc/cmdline /proc/devices >> >>> >> /proc/atags" >> >>> >> if [ "$DEVCACHE" != "" ]; then >> >>> >> if [ -e $DEVCACHE ]; then >> >>> >> - readfiles $CMP_FILE_LIST >> >>> >> - NEWDATA="$READDATA" >> >>> >> - readfiles /etc/udev/cache.data >> >>> >> - OLDDATA="$READDATA" >> >>> >> - if [ "$OLDDATA" = "$NEWDATA" ]; then >> >>> >> - (cd /; tar xf $DEVCACHE > /dev/null >> >>> >> 2>&1) >> >>> >> + sysconf_cmd > "$SYSCONF_TMP" >> >>> >> + if cmp $SYSCONF_CACHED $SYSCONF_TMP >/dev/null; then >> >>> >> + tar xmf $DEVCACHE -C / -m >> >>> >> not_first_boot=1 >> >>> >> [ "$VERBOSE" != "no" ] && echo "udev: >> >>> >> using >> >>> >> cache file $DEVCACHE" >> >>> >> - [ -e /dev/shm/udev.cache ] && rm -f >> >>> >> /dev/shm/udev.cache >> >>> >> + [ -e $SYSCONF_TMP ] && rm -f >> >>> >> "$SYSCONF_TMP" >> >>> >> + [ -e "$DEVCACHE_REGEN" ] && rm -f >> >>> >> "$DEVCACHE_REGEN" >> >>> >> else >> >>> >> # Output detailed reason why the cached /dev is >> >>> >> not >> >>> >> used >> >>> >> - if [ "$VERBOSE" != "no" ]; then >> >>> >> - echo "udev: udev cache not used" >> >>> >> - echo "udev: we use $CMP_FILE_LIST as criteria >> >>> >> to >> >>> >> judge whether the cache /dev could be resued" >> >>> >> - echo "udev: olddata: $OLDDATA" >> >>> >> - echo "udev: newdata: $NEWDATA" >> >>> >> - fi >> >>> >> - echo "$NEWDATA" > /dev/shm/udev.cache >> >>> >> + cat <<EOF >> >>> >> +udev: Not using udev cache because of changes detected in the >> >>> >> following >> >>> >> files: >> >>> >> +udev: $CMP_FILE_LIST >> >>> >> +udev: $META_FILE_LIST >> >>> >> +udev: The udev cache will be regenerated. To identify the detected >> >>> >> changes, >> >>> >> +udev: compare the cached sysconf at $SYSCONF_CACHED >> >>> >> +udev: against the current sysconf at $SYSCONF_TMP >> >>> >> +EOF >> >>> >> + touch "$DEVCACHE_REGEN" >> >>> >> fi >> >>> >> else >> >>> >> if [ "$ROOTFS_READ_ONLY" != "yes" ]; then >> >>> >> # If rootfs is not read-only, it's possible that a >> >>> >> new >> >>> >> udev cache would be generated; >> >>> >> # otherwise, we do not bother to read files. >> >>> >> - readfiles $CMP_FILE_LIST >> >>> >> - echo "$READDATA" > /dev/shm/udev.cache >> >>> >> + touch "$DEVCACHE_REGEN" >> >>> >> fi >> >>> >> fi >> >>> >> fi >> >>> >> @@ -97,7 +101,7 @@ >> >>> >> kill_udevd > "/dev/null" 2>&1 >> >>> >> >> >>> >> # trigger the sorted events >> >>> >> - echo -e '\000\000\000\000' > /proc/sys/kernel/hotplug >> >>> >> + [ -e /proc/sys/kernel/hotplug ] && echo -e '\000' >> >>> >> >/proc/sys/kernel/hotplug >> >>> >> /lib/udev/udevd -d >> >>> >> >> >>> >> udevadm control --env=STARTUP=1 >> >>> >> >> >>> >> >> >>> >>> >> >>> >>> > >> >>> >>> > Unfortunately I did not dig inside binary /lib/udev/udevd. >> >>> >>> > >> >>> >>> > So do you have any other ideas, what might be the reason for not >> >>> >>> > recognizing >> >>> >>> > the SSD? Maybe there are some additional recipes needed from >> >>> >>> > jethro >> >>> >>> > on? >> >>> >>> > >> >>> >>> > >> >>> >>> > thanks & kind regards >> >>> >>> > Simon :-) >> >>> >>> > >> >>> >>> > mit freundlichem Gruss / kind regards / pozdrawiam >> >>> >>> > Simon P. Bolek >> >>> >>> > ------------------------------------------------------ >> >>> >>> > Dipl. Inf. Simon P. Bolek >> >>> >>> > SAP Integration Architect >> >>> >>> > Business Mobile and IVI Solutions >> >>> >>> > mailto: simon.bo...@arcom-ivi.de >> >>> >>> > http://www.arcom-ivi.de/ >> >>> >>> > XING: https://www.xing.com/profile/SimonP_Bolek >> >>> >>> > >> >>> >>> > On Wed, Jul 13, 2016 at 9:03 AM, Simon Bolek >> >>> >>> > <simon.bo...@googlemail.com> >> >>> >>> > wrote: >> >>> >>> >> >> >>> >>> >> Thank you, >> >>> >>> >> >> >>> >>> >> I just guess, that it is the following function in init script >> >>> >>> >> to >> >>> >>> >> put >> >>> >>> >> the >> >>> >>> >> echos to? Is it? >> >>> >>> >> >> >>> >>> >> udev_daemon() { >> >>> >>> >> OPTIONS="/sbin/udev/udevd /sbin/udevd /lib/udev/udevd >> >>> >>> >> /lib/systemd/systemd-udevd" >> >>> >>> >> >> >>> >>> >> for o in $OPTIONS; do >> >>> >>> >> if [ -x "$o" ]; then >> >>> >>> >> echo $o >> >>> >>> >> return 0 >> >>> >>> >> fi >> >>> >>> >> done >> >>> >>> >> >> >>> >>> >> return 1 >> >>> >>> >> } >> >>> >>> >> >> >>> >>> >> >> >>> >>> >> cheers >> >>> >>> >> Simon:-) >> >>> >>> >> >> >>> >>> >> Viele Grüsse >> >>> >>> >> Simon Bolek :-) >> >>> >>> >> >> >>> >>> >> mit freundlichem Gruss / kind regards / pozdrawiam >> >>> >>> >> Simon P. Bolek >> >>> >>> >> ------------------------------------------------------ >> >>> >>> >> Dipl. Inf. Simon P. Bolek >> >>> >>> >> SAP Integration Architect >> >>> >>> >> Business Mobile and IVI Solutions >> >>> >>> >> mailto: simon.bo...@arcom-ivi.de >> >>> >>> >> http://www.arcom-ivi.de/ >> >>> >>> >> XING: https://www.xing.com/profile/SimonP_Bolek >> >>> >>> >> >> >>> >>> >> On Wed, Jul 13, 2016 at 8:36 AM, Khem Raj <raj.k...@gmail.com> >> >>> >>> >> wrote: >> >>> >>> >>> >> >>> >>> >>> On Tue, Jul 12, 2016 at 11:28 PM, Simon Bolek >> >>> >>> >>> <simon.bo...@googlemail.com> wrote: >> >>> >>> >>> > Thank you Raj, >> >>> >>> >>> > >> >>> >>> >>> > Is there a standard way to activate these initramfs logs, or >> >>> >>> >>> > do >> >>> >>> >>> > I >> >>> >>> >>> > have >> >>> >>> >>> > to >> >>> >>> >>> > implement it myself somewhere? >> >>> >>> >>> >> >>> >>> >>> you have to add printf etc. yourself into the init script in >> >>> >>> >>> initramfs >> >>> >>> >>> image >> >>> >>> >>> >> >>> >>> >>> > >> >>> >>> >>> > thank you and kind regards >> >>> >>> >>> > Simon :-) >> >>> >>> >>> > >> >>> >>> >>> > Viele Grüsse >> >>> >>> >>> > Simon Bolek :-) >> >>> >>> >>> > >> >>> >>> >>> > mit freundlichem Gruss / kind regards / pozdrawiam >> >>> >>> >>> > Simon P. Bolek >> >>> >>> >>> > ------------------------------------------------------ >> >>> >>> >>> > Dipl. Inf. Simon P. Bolek >> >>> >>> >>> > SAP Integration Architect >> >>> >>> >>> > Business Mobile and IVI Solutions >> >>> >>> >>> > mailto: simon.bo...@arcom-ivi.de >> >>> >>> >>> > http://www.arcom-ivi.de/ >> >>> >>> >>> > XING: https://www.xing.com/profile/SimonP_Bolek >> >>> >>> >>> > >> >>> >>> >>> > On Wed, Jul 13, 2016 at 1:36 AM, Khem Raj >> >>> >>> >>> > <raj.k...@gmail.com> >> >>> >>> >>> > wrote: >> >>> >>> >>> >> >> >>> >>> >>> >> On Tue, Jul 12, 2016 at 3:45 AM, Simon Bolek >> >>> >>> >>> >> <simon.bo...@googlemail.com> >> >>> >>> >>> >> wrote: >> >>> >>> >>> >> > Hello everyone! >> >>> >>> >>> >> > >> >>> >>> >>> >> > I am trying to install genericx86 core-image-sato >> >>> >>> >>> >> > (jethro) >> >>> >>> >>> >> > HDDIMG to >> >>> >>> >>> >> > an >> >>> >>> >>> >> > atom-pc. >> >>> >>> >>> >> > For this 2GB USB stick is used. >> >>> >>> >>> >> > When choosing 'install' option from boot menu I get the >> >>> >>> >>> >> > message: >> >>> >>> >>> >> > >> >>> >>> >>> >> > "Searching for hard drives... >> >>> >>> >>> >> > No hard drive selected. Installation aborted." >> >>> >>> >>> >> > >> >>> >>> >>> >> > Installatiion stops and i get the console. >> >>> >>> >>> >> > When I try to run fsck, it says: can't read '/etc/fstab': >> >>> >>> >>> >> > No >> >>> >>> >>> >> > such >> >>> >>> >>> >> > file >> >>> >>> >>> >> > or >> >>> >>> >>> >> > directory >> >>> >>> >>> >> > >> >>> >>> >>> >> > fdisk -l shows only the partitions of USB stick. >> >>> >>> >>> >> > >> >>> >>> >>> >> > After I choose 'boot' option to boot into live image, SDD >> >>> >>> >>> >> > drive >> >>> >>> >>> >> > is >> >>> >>> >>> >> > under >> >>> >>> >>> >> > /dev/sdb and USB installation stick under /dev/sda, >> >>> >>> >>> >> > >> >>> >>> >>> >> > What recipe/package is my installation missing? The SSD >> >>> >>> >>> >> > hard >> >>> >>> >>> >> > drive >> >>> >>> >>> >> > is >> >>> >>> >>> >> > not >> >>> >>> >>> >> > recognized for some reason. With previous yocto releases >> >>> >>> >>> >> > this >> >>> >>> >>> >> > package >> >>> >>> >>> >> > list >> >>> >>> >>> >> > DID work fine. >> >>> >>> >>> >> > So there is something missing in the background. >> >>> >>> >>> >> > Do you have any idea what this might be? >> >>> >>> >>> >> >> >>> >>> >>> >> udev should have run and found your hdd. So it seems its >> >>> >>> >>> >> not >> >>> >>> >>> >> finding >> >>> >>> >>> >> it when running from initramfs. Can you try to add logs to >> >>> >>> >>> >> initramfs >> >>> >>> >>> >> and see what udev is doing ? >> >>> >>> >>> >> >> >>> >>> >>> >> > >> >>> >>> >>> >> > Below is my package list from local.conf. >> >>> >>> >>> >> > >> >>> >>> >>> >> > thank you and kind regards >> >>> >>> >>> >> > Simon :-) >> >>> >>> >>> >> > >> >>> >>> >>> >> > EXTRA_IMAGE_FEATURES = "debug-tweaks ssh-server-openssh" >> >>> >>> >>> >> > IMAGE_INSTALL_append = " make \ >> >>> >>> >>> >> > initscripts \ >> >>> >>> >>> >> > grub \ >> >>> >>> >>> >> > initramfs-boot \ >> >>> >>> >>> >> > syslinux \ >> >>> >>> >>> >> > initramfs-live-install \ >> >>> >>> >>> >> > initramfs-live-install-efi \ >> >>> >>> >>> >> > initramfs-live-boot \ >> >>> >>> >>> >> > xinit \ >> >>> >>> >>> >> > xwininfo \ >> >>> >>> >>> >> > openssh-sftp \ >> >>> >>> >>> >> > openssh-sftp-server \ >> >>> >>> >>> >> > qtbase-plugins \ >> >>> >>> >>> >> > qtconnectivity \ >> >>> >>> >>> >> > qtdeclarative \ >> >>> >>> >>> >> > qtdeclarative-plugins \ >> >>> >>> >>> >> > qtdeclarative-tools \ >> >>> >>> >>> >> > qtdeclarative-qmlplugins \ >> >>> >>> >>> >> > qtenginio \ >> >>> >>> >>> >> > qtlocation \ >> >>> >>> >>> >> > qtmultimedia \ >> >>> >>> >>> >> > qtmultimedia-plugins \ >> >>> >>> >>> >> > qtmultimedia-qmlplugins \ >> >>> >>> >>> >> > qtsystems \ >> >>> >>> >>> >> > " >> >>> >>> >>> >> > >> >>> >>> >>> >> > Viele Grüsse >> >>> >>> >>> >> > Simon Bolek :-) >> >>> >>> >>> >> > >> >>> >>> >>> >> > mit freundlichem Gruss / kind regards / pozdrawiam >> >>> >>> >>> >> > Simon P. Bolek >> >>> >>> >>> >> > ------------------------------------------------------ >> >>> >>> >>> >> > Dipl. Inf. Simon P. Bolek >> >>> >>> >>> >> > SAP Integration Architect >> >>> >>> >>> >> > Business Mobile and IVI Solutions >> >>> >>> >>> >> > mailto: simon.bo...@arcom-ivi.de >> >>> >>> >>> >> > http://www.arcom-ivi.de/ >> >>> >>> >>> >> > XING: https://www.xing.com/profile/SimonP_Bolek >> >>> >>> >>> >> > >> >>> >>> >>> >> > -- >> >>> >>> >>> >> > _______________________________________________ >> >>> >>> >>> >> > yocto mailing list >> >>> >>> >>> >> > yocto@yoctoproject.org >> >>> >>> >>> >> > https://lists.yoctoproject.org/listinfo/yocto >> >>> >>> >>> >> > >> >>> >>> >>> > >> >>> >>> >>> > >> >>> >>> >> >> >>> >>> >> >> >>> >>> > >> >>> >> >> >>> >> >> >>> > >> >> >> >> >> > > > -- _______________________________________________ yocto mailing list yocto@yoctoproject.org https://lists.yoctoproject.org/listinfo/yocto