ModalAI Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Register
    • Login

    Out of space for docker load -i

    VOXL m500 Reference Drone
    5
    6
    727
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • Cristian AdamC
      Cristian Adam
      last edited by Cristian Adam

      Trying to follow this ros_environment guide

      that came about from the mavros page indicating docker is on the drone/needed to run stuff, but docker-on-voxl seems to be out of date, so figuring out how to run docker on voxl is being challenging - loading voxl-docker support seems like it worked correctly however -

      unable to run

      docker load -i roskinetic-xenial_v1_0.tgz
      

      it errors out with:

      
      
      ERRO[0511] Handler for POST /v1.21/images/load returned error: Untar re-exec error: exit status 1: output: write /482b910388d5d604cb01d5c10b07ab3dcf243a34d4f539749fe9249671a41856/layer.tar: no space left on device 
      ERRO[0511] HTTP Error                                    err=Untar re-exec error: exit status 1: output: write /482b910388d5d604cb01d5c10b07ab3dcf243a34d4f539749fe9249671a41856/layer.tar: no space left on device statusCode=500
      

      I have tried running this from the /data directory where there is space, but I am not sure how to re-map where docker expands images into or if I can (should) use the SD card slot for this instead

      There seems to be room on the disk, just not where it's being run from:

      voxl:/data$ df -h
      Filesystem      Size  Used Avail Use% Mounted on
      /dev/root       2.8G  1.8G  939M  66% /
      devtmpfs        1.8G     0  1.8G   0% /dev
      tmpfs           1.9G     0  1.9G   0% /dev/shm
      tmpfs           1.9G   17M  1.9G   1% /run
      tmpfs           1.9G     0  1.9G   0% /sys/fs/cgroup
      tmpfs           1.9G  8.0K  1.9G   1% /var/volatile
      /dev/sde12       12M  4.1M  7.4M  36% /dsp
      /dev/sda2       2.2M   80K  2.0M   4% /persist
      /dev/sde11       95M   33M   63M  35% /firmware
      /dev/sda3        58M   40K   57M   1% /cache
      /dev/sda9        15G  620M   14G   5% /data
      tmpfs           378M     0  378M   0% /run/user/0
      
      1 Reply Last reply Reply Quote 0
      • Chad SweetC
        Chad Sweet ModalAI Team
        last edited by

        Just for clarity, which part of the docs seems out of date? That would be our recommended approach. If there is something not working with that document, then maybe we could help there?
        https://docs.modalai.com/docker-on-voxl/

        S 1 Reply Last reply Reply Quote 0
        • S
          SMRC @Chad Sweet
          last edited by

          @Chad-Sweet I'm from the same team as the original poster. To answer the question on what was out of date on this page:

          • the references to VOXL-Software-Bundle and VOXL-Factory-Bundle both link to deprecated pages
          • the link to Voxl-Quickstart just links to the homepage
          • The references to voxl-configure-docker-support.sh are no longer valid because the current version of voxl-docker-support doesn't include that anymore
          • We also discovered we needed to run docker manually (it didn't start up on its own), and point it at a different partition for loading images, because otherwise it didn't have enough space. We used the command $docker daemon -g /data.
          • It also would have been useful to explain that docker is now included in the initial drone setup, because we spent a while wondering how to get docker onto the drone, since the old docker-support says it includes a version and the new docker-support says it doesn't.
          • also not sure if the section on running a docker image is still valid, as per my recent post, we're having some issues with that.

          Thank you for the quick response and for continuing to maintain all this documentation, we appreciate it!

          1 Reply Last reply Reply Quote 0
          • Chad SweetC
            Chad Sweet ModalAI Team
            last edited by

            thanks for the feedback. I just ran through and updated the docs here: https://docs.modalai.com/docker-on-voxl/

            It worked using the latest platform image

            T 1 Reply Last reply Reply Quote 0
            • T
              tpavlic @Chad Sweet
              last edited by

              @Chad-Sweet Also, PLEASE stop telling people to download the roskinetic-xenial docker image that you host. There is nothing modalAI-specific about your docker image, and forcing people to use xenial means forcing them to use Python 3.5 or lower. Furthermore, rosnoetic is far superior than roskinetic when it comes to ROSv1. There are important features added and bugs fixed in rosnoetic.

              On our modalAI drones, we simply do a docker pull of a rosnoetic image (that runs on Ubuntu focal):

              docker pull ros:noetic-robot
              

              You can find out more information about pulling a ROS docker image this way at the ROS docker tutorial here:

              http://wiki.ros.org/docker/Tutorials/Docker

              Then just run that docker image (using the docker run -it ... described at the link above) and start installing other packages you need. For example, we use apt-get to download important ROS packages we need, like mavros, mavros_msgs, etc. and geographic information required. You can follow the nice ROS with MAVROS installation guide (in the "Binary Installation (Debian/Ubuntu)" section):

              https://docs.px4.io/main/en/ros/mavros_installation.html

              Of course, you will have to create a MAVROS launcher file within the "launch" folder of a ROS package that is customized to the voxl-mavlink-server/voxl-vision-px4. Here is an example with the correct UDP port:

              <launch>
                      <!-- vim: set ft=xml noet : -->
                      <!-- example launch script for PX4 based FCU's -->
              
                      <!-- <arg name="fcu_url" default="/dev/ttyACM0:57600" /> -->
                      <arg name="fcu_url" default="udp://127.0.0.1:14551@:14551" />
                      <arg name="gcs_url" default="" />
                      <!-- <arg name="tgt_system" default="1" /> -->
                      <arg name="tgt_system" default="$(env PX4_SYS_ID)" />
                      <arg name="tgt_component" default="1" />
                      <arg name="log_output" default="screen" />
                      <arg name="fcu_protocol" default="v2.0" />
                      <arg name="respawn_mavros" default="true" />
                      <!-- <arg name="ns" default="drone_n" /> -->
                      <arg name="ns" default="drone$(env PX4_SYS_ID)" />
              
                      <include ns="$(arg ns)" file="$(find mavros)/launch/node.launch">
                              <arg name="pluginlists_yaml" value="$(find mavros)/launch/px4_pluginlists.yaml" />
                              <arg name="config_yaml" value="$(find mavros)/launch/px4_config.yaml" />
                              <arg name="fcu_url" value="$(arg fcu_url)" />
                              <arg name="gcs_url" value="$(arg gcs_url)" />
                              <arg name="tgt_system" value="$(arg tgt_system)" />
                              <arg name="tgt_component" value="$(arg tgt_component)" />
                              <arg name="log_output" value="$(arg log_output)" />
                              <arg name="fcu_protocol" value="$(arg fcu_protocol)" />
                              <arg name="respawn_mavros" default="$(arg respawn_mavros)" />
                      </include>
              </launch>
              

              Finally, you can also install python packages you might need, including pip3 itself (use apt-get to install pip and then use pip to install other packages). Once you're done, installing, you just need to commit before exiting your shell. So, in another terminal issue:

              docker ps
              

              to find the container ID (or at least the first few characters of it) for the currently running rosnoetic container. Then issue:

              docker commit CONTAINER_ID DESIRED_IMAGE_NAME:DESIRED_TAG
              

              For example, you might issue:

              docker commit 42c731c5 myproject-rosnoetic-focal:v1.0
              

              You can then exit your docker image. You can then remove the original ros-noetic image from your local library (if you wish). You can export your new docker image with:

              docker save myproject-rosnoetic-focal:v1.0 | gzip > myproject-rosnoetic-focal-v1.0.tar.gz
              

              Then transfer that resulting tarball (myproject-rosnoetic-focal-v1.0.tar.gz) to your /data partition on the m500 and use

              docker load -i myproject-rosnoetic-focal-v1.0.tar.gz
              

              to load the image onto the VOXL. The resulting image will work just as well as the roskinetic image. You can load it on the VOXL with the --net=host and -v outside_folder:inside_folder:rw options (among others) to make sure the docker image has the same network access as the VOXL and allows for a folder (or folders) on the VOXL to be mapped to folders inside the docker image (which makes it easier to develop code for your drone without having to rebuild the docker image each time). I believe that modalAI has documentation on this part.

              So, please, use a rosnoetic-focal image from ROS directly. It is crazy to be using a roskinetic image (with xenial!) in 2023 or beyond. Of course, ROSv1 will be deprecated in a couple of years anyway (if that's not pushed). Sadly, if you want a ROSv2 image, you will have to implement a ROS bridge between your docker image and the VOXL until the VOXL gets updated to ROSv2, but rosnoetic is very capable (and much better than roskinetic, especially given that you run rosnoetic on focal (not xenial)).

              Syed OmairS 1 Reply Last reply Reply Quote 1
              • Syed OmairS
                Syed Omair @tpavlic
                last edited by

                @tpavlic

                heyyy... i do agree that using roskinetic and xenial is kind of a dumb thing... could you help me with something ? are you using the m500 drone with voxl 1 here to do the "docker pull ros:noetic-robot" command? if you are i do get an error saying

                Error: Status 410 trying to pull repository library/ros: "<html>\r\n<head><title>410 Gone</title></head>\r\n<body>\r\n<center><h1>410 Gone</h1></center>\r\n<hr><center>openresty</center>\r\n</body>\r\n</html>\r\n"

                i really kind of want to use the higher versions of python and a more recent ubuntu distribution.

                any tips or suggestions ?

                1 Reply Last reply Reply Quote 0
                • Syed OmairS Syed Omair referenced this topic on
                • First post
                  Last post
                Powered by NodeBB | Contributors