This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

DVSDK | nfs/tftp | how targetfs was created?

Other Parts Discussed in Thread: ASH

Hello, 

I use dvsdk 4.03 and want to create targetfs by myself and tune nfs and tftp also. I mean not launching setup.sh from dvsdk.

Please, tell in which way targetfs (that is in the filesystem archive that is untarring via setup.sh) was created? Where can I get scripts for it??

Thanks! 

  • Alyena, can you post here setup.sh?

    I use targetfs based on BusyBox, I think you also can use it. If you can't use NFS, you can build targetfs on your host and write it on flash via RS232. I don't know what targetfs use on your board, usuale used targetfs with JFFS2 and CRAMFS.

    For build CRAMFS you can use mkcramfs, for JFFS2 - http://processors.wiki.ti.com/index.php/Create_a_JFFS2_Target_Image

  • setup.sh is a script that launch several scripts in order. e.g. host-check.sh (check if you have appropriate version of Ubuntu), packages-install.sh (install some utilites from the internet), etc.

    I'm interesting in setup-targetfs-nfs.sh (it is very long and the main point of it is to untar dvsdk/filesystem/dvsdk-dm368-evm-rootfs.tar.gz archive and tune nfs). Apparentely I'm looking for a utilite that configured this already prepared FS as it is important to know while creating FS by ourselves.

  • Alyone, script setup-targetfs-nfs.sh is a very simple.

    1. It read from standart input destination directory or use default value if haven't input.
    2. Create destination directory and untar rootfs in it.
    3. If destination directory exist it can copy or rewrite it.
    4. Modify Rules.mk in DVSDK directory.
    5. Export directory with rootfs in NFS and restart NFS-server.

    You can make this manualy, where your have problem?

    P.S. This is question is not Davinci specified, I think you should post it  in http://e2e.ti.com/support/embedded/linux/default.aspx

  • I meant where can I get a list of components that targetfs for the board contains. To be able to create the same targetfs for the same board/processor. It could be a script or maybe a utilite produced by, as I suppose, Texas Instruments.

  • Alyona, your question not corrected because it depends on your task. Minimal list - linux and rootfs, usualy rootfs based on busybox, but you can use another base, e.g. emdebian. If you encode video you must put encode demon with depends on rootfs.

    If you havn't root privilegies your can unpack rootfs from DVSDK.
    $ ls
    dvsdk-dm365-evm-rootfs.tar.gz
    $ tar xzf dvsdk-dm365-evm-rootfs.tar.gz
    tar: dev/tty4: Cannot mknod: Operation not permitted
    tar: dev/ttyS0: Cannot mknod: Operation not permitted
    tar: dev/mmcblk0p1: Cannot mknod: Operation not permitted
    tar: dev/random: Cannot mknod: Operation not permitted
    ...........................
    $ls -F
    bin/  boot/  dev/  dvsdk-dm365-evm-rootfs.tar.gz  etc/  home/  lib/  linuxrc@  media/  mnt/  opt/  proc/  sbin/  srv/  sys/  tmp/  usr/  var/
    $ ls -F bin/ etc/
    bin/:
    addgroup@  chgrp@  dd@                   dumpkmap@  grep@      kill.util-linux-ng*   lsmod.26*            mount@                nice@            pwd@        sleep@      touch@                 usleep@
    adduser@   chmod@  delgroup@             echo@      gunzip@    ln@                   mkdir@               mountpoint@           pidof@           rm@         stty@       true@                  vi@
    ash@       chown@  deluser@              egrep@     gzip@      login@                mknod@               mountpoint.sysvinit*  pidof.sysvinit@  rmdir@      su@         umount@                watch@
    busybox*   cp@     df@                   false@     hostname@  login.util-linux-ng*  mktemp@              mount.util-linux-ng*  ping@            run-parts@  sync@       umount.util-linux-ng*  zcat@
    cat@       cpio@   dmesg@                fgrep@     ip@        ls@                   more@                mv@                   ping6@           sed@        tar@        uname@
    chattr@    date@   dmesg.util-linux-ng*  getopt@    kill@      lsmod@                more.util-linux-ng*  netstat@              ps@              sh@         tinylogin*  usb-devices*

    etc/:
    angstrom-version  dbus-1/             environment  group      init.d/  iproute2/   mke2fs.conf  network/       passwd      rc0.d/  rc4.d/  rpc             skel/            ts.conf
    asound.conf       default/            fb.modes     host.conf  inittab  issue       modutils/    nsswitch.conf  profile     rc1.d/  rc5.d/  scsi_id.config  terminfo/        udev/
    asound.state      device_table        filesystems  hostname   inputrc  issue.net   motd         opkg/          profile.d/  rc2.d/  rc6.d/  security/       timestamp        udhcpc.d/
    busybox.links     device_table-opkg*  fstab        hosts      ipkg@    localtime@  mtab@        pam.d/         protocols   rc3.d/  rcS.d/  services        tinylogin.links  version

    After you can create devices manually or via udev.

  • You mean to build the file system from scratch?  I think the question can rephased to be more pointed. Does TI use something like buildroot or bitbake to build the root fs for Arago? I believe bitbake is used for Angstrom and Android distros. I doubt that TI uses something like a script or utility. Build systems like buildroot have a Linux-style build menu system that allows you pick and choose what components are cross-compiled and installed into a file system.

    I think what others are suggesting is to use a pre-built root FS as a base. Delete what you don't want. Add what you want either by cross-compiling packages yourself or using opkg to install packages over the net. Probably a lot less work than building from scratch. Depends on the the level of customization,