1 2 Previous Next 24 Replies Latest reply on Jun 12, 2016 1:33 AM by Gibo65

    Yet Another Debian available


      Here is my corrected release for the standard i386 Debian wheezy distribution for the Galileo to be written to an sdcard at least 4GB. I hope this image has solved the problem of naming the eth interface. Please report any discovered issues in this thread.



      md5sum: 68d4016f57f679c6da73f4284f901cd7  YAD4galileo1.img.zip


      The file YAD4galileo1.img.zip should be unzipped to the disk image file having a size of 3724541440 bytes.

      md5sum: 67dba3ef6eb5a34cc08ce1e8cae5bace  YAD4galileo1.img


      The YAD4galileo1.img file is then to be written to the sdcard using dd on linux or rawrite.exe on Windows. Do not simply copy the image to the sdcard. The linux command for dd is here:


      dd if=YAD4galileo1.img of=/dev/mmcblkX bs=1M conv=fsync


      Be sure to replace mmcblkX with the correct number of your device without the partition modifier. My notebook with only one slot for the sdcard is /dev/mmcblk0 although yours could be something else. The sdcard will be written with a new bootloader/partition table and the two new partitions. When done writing the image to the sdcard the brand new partition table should look like this:


      Device        Boot Start     End  Blocks Id System
      /dev/mmcblk0p1 *    2048  106493   52223  b W95 FAT32
      /dev/mmcblk0p2    106496 7274495 3584000 83 Linux


      The mmcblk0p2 is an ext3 filesystem and can be resized to any size after writing the almost 4Gig image to the sdcard. I use gparted on linux.


      I built this image starting with the IOT devkit SDCARD image. I use their kernel and kernel modules. I replaced the yocto with debian wheezy. The Galileo can be booted and reached with ssh or telnet over the ethernet without needing a serial rs-232 connection.


      Login with 'root' password of 'debian'. Login with 'user' password of 'debian'.


      I have a number of debian packages preinstalled including mc and dselect. Included is the vncserver. Also included is the fixed libpthread from earlier posts. Use apt-get to install anything from wheezy. This is ready to go.


      The fixed libpthread is installed in /lib/i386-linux-gnu/libpthread-2.13.so with symbolic links to libpthread.so.0 and has so far solved the segfaults caused by using the standard debian libpthread. There is a copy in the /root/ directory in case the fixed file is ever removed or replaced by dpkg or other file operations. Great thanks to samoht for fixing the buggy libpthread last month in here.


      Anybody can use this image for their own purposes. I don't expect to do any more to this image so I can begin toying with my electronics. I only get about an hour a day to use on my Galileo so I hope everybody overtakes me on their projects. This is basically a simple approach and not fancy so everybody can begin working without any problems.

        • 1. Re: Yet Another Debian available

          Hi tinkerer8473,


          thanks for your efforts to provide the community with a working debian image for the Galileo (including SSH on per default). I just downloaded you image and successfully put it onto an SD card. The Galileo board seems to boot the image, yet it does not seem to receive an IP address within my class-c home network (which works for any other DHCP configured devices).


          So I would like to ask on the network config within your image:

          1.) is DHCP active/working by default

          2.) is there a static config - which subnet and IP is used in this case?

          3.) are there any other special networking settings to get the image into a network to access it via SSH?


          Hope you can help out soon, as your image seems rather promising.


          Thanks in advance,


          • 2. Re: Yet Another Debian available

            The debian does have dhcp enabled not a static address.


            I have used the galileo with two routers and the big problem was finding the address the router assigned to the galileo. One router with openwrt does list the galileo with the hostname galileo so you might try 'ssh galileo'.


            Another router listed the galileo with a name of 'unknown' so I had to look through the dhcp list and remember the MAC address to figure out the dhcp assigned IP address for the galileo. To find the list of addresses assigned by dhcp you need to login to the router and find the listing. I have used or to see the assignments. If still unknown then you might try to ssh to everything connected to the router until you find the galileo.


            The eth0 is configured in the '/etc/network/interfaces' the same as plain debian. This image is configured as 'auto eth0' and 'iface eth0 inet dhcp'. You can change that into a static address if you prefer not to be looking for where the router puts the galileo. First you need to connect to the galileo so I hope this helps.

            • 3. Re: Yet Another Debian available

              Thanks for your quick reply and the information you provided. Sadly, I still do not receive an IP via my DHCP box (router) :/


              I checked the web-frontend of the router and it does not show any new leases for the Galileo. Interestingly, if I put a full Yocto image with DHCP enabled in it onto the same SD-Card with the very same Galileo the Yocto booted Galileo receives an IP in my setup... (?!?!). Something seems to be different or mabye the boot process hangs. As i do not have a serial (audio jack) to USB cable, I do not have any option to see the output of the boot process.


              Any ideas or suggestions?

              • 4. Re: Yet Another Debian available

                The only other idea I have would be to remove the sdcard and look at the /var/log/syslog for clues. The mmcblk0p2 is an ext3 partition and can be mounted in linux or with a linux live USB. I haven't had any problems with the eth0 or dhcp so can't imagine what might be causing the problem.

                • 5. Re: Yet Another Debian available

                  Ok, back again. I found the solution to the problem. The file "/etc/udev/rules.d/70-persistent-net.rules" contains a persistent naming for an ethernet device with corresponds to your very own MAC-address.


                  Either you remove the file completely or you change "your" specific entry

                  #SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="98:4f:ee:00:6b:d8", ATTR{dev_id}=="0x0", ATTR{type}=="1", KERNEL=="eth*", NAME="eth0"


                  by either:

                  • commenting it OR
                  • removing it completely

                  BEFORE you clone out the DD image again.


                  I think it would be great if you could build (repair) the galileo-debian dd-image in a "corrected" manner. Thus, many other developers could benefit by a rather clean and nice "starting" point for a real Linux on this nice and tiny Galileo.


                  The rest of the image seems to be working fine, nice job!


                  Hope it helps others.



                  • 6. Re: Yet Another Debian available

                    Thank you for finding the error. I hope that helps everybody else trying this release.


                    The corrected image YAD4galileo1.img.zip is now available in the first post of this thread. I hope this fixes the problem with the udev naming of the ethernet interface. I have an uncertain mixture of debian and yocto udev configuration files so please report any further difficulties.


                    I have also added the security and wheezy-backports repositories to the /etc/apt/sources.list and updated the files included with this distribution. There were several updates for openssl that are now already installed. I have also included python and nodejs for those who want to begin without delay. The npm is not included in the wheezy-backports except can probably be built from the npm install script.

                    • 7. Re: Yet Another Debian available

                      Just tested your modified dd image. Works like a charm!


                      • 8. Re: Yet Another Debian available

                        Hi, thanks for the image. It works great here on my end. The only issue I've run into is that I'm still seeing segfaults with libpthread-2.13.so but these are isolated specifically to git.


                        Great stuff otherwise. Cheers!

                        • 9. Re: Yet Another Debian available

                          Thank you for the report.


                          Could you confirm the file size for the /lib/i386-linux-gnu/libpthread-2.13.so if that is 116689 or not?


                          Also, could you show the segfaults listed in the /var/log/syslog?


                          Could you tell where the segfault is from among these choices?


                          libc6-dev:i386: /usr/lib/i386-linux-gnu/libpthread.a
                          libc6-dev:i386: /usr/lib/i386-linux-gnu/libpthread_nonshared.a
                          libc6-dev:i386: /usr/lib/i386-linux-gnu/xen/libpthread_nonshared.a
                          libc6:i386: /lib/i386-linux-gnu/libpthread-2.13.so
                          libc6-i686:i386: /lib/i386-linux-gnu/i686/cmov/libpthread-2.13.so
                          libc6-dev:i386: /usr/lib/i386-linux-gnu/xen/libpthread.a
                          libc6-dev:i386: /usr/lib/i386-linux-gnu/libpthread.so
                          libc6-i686:i386: /lib/i386-linux-gnu/i686/cmov/libpthread.so.0
                          libc6:i386: /lib/i386-linux-gnu/libpthread.so.0
                          • 10. Re: Yet Another Debian available

                            Here's the output from /var/log/syslog and the filesize of libpthread-2.13.so


                            root@galileo:/lib/i386-linux-gnu# ls -laS

                            -rw-r--r--  1 root root  116689 Apr  8 16:18 libpthread-2.13.so


                            Apr 20 00:52:30 galileo kernel: [16403.903180] git[29606]: segfault at b77359f6 ip b771278c sp bfedd104 error ffff0007 in libpthread-2.13.so[b770d000+15000]


                            edit: I've also noticed the swap isn't enabled in this kernel. I'm guessing it is set that way in the IOT devkit kernel. I'm trying to compile an altcoin on the galileo and am receiving these errors


                            Apr 19 21:59:10 galileo kernel: [ 6003.475353] Out of memory: Kill process 13879 (cc1plus) score 888 or sacrifice child

                            Apr 19 21:59:10 galileo kernel: [ 6003.483432] Killed process 13879 (cc1plus) total-vm:228988kB, anon-rss:206556kB, file-rss:32kB


                            I tried to create a swap to fix this but hit this error when running swapon

                            swapon failed: Function not implemented

                            • 11. Re: Yet Another Debian available

                              Thank you for the reply.


                              The kernel swap support is not enabled in the kernel. The config.gz file in the /proc directory contains the kernel config:

                              #CONFIG_SWAP is not set

                              I imagine a new kernel could probably be built and easily substituted into the mmcblk0p1 with the modules placed into the mmcblk0p2 using the kernel source contained in the yocto repositories by someone with yocto experience. I have found the Galileo doesn't need much memory during normal operations except compiling a big job might be too much even for the 256Meg of memory. A linux live USB might be an alternative to build the anon-rss except I just googled the anon-rss and found people running out of memory with 4Gig installed so this could be a bug beyond just Galileo. Anyway, compiling a new yocto kernel with swap support shouldn't be impossible.


                              Solving the libpthread segfault now seems to be impossible for me and so that really is a show-stopper for this Debian on the Galileo. These segfaults are probably still caused by the old Pentium FOOF bug that we thought had been binary edited away in the libpthread so this is clearly very bad news. While I don't have git installed and haven't seen any segfaults yet and hopefully could continue to use the Galileo for my own purposes without running into the segfaults, the libpthread would certainly be a tragedy for many with requirements for things like git that they need. I am now reconsidering this entire project because I certainly can't solve this problem with segfaults.


                              Thank you for the important information.

                              • 12. Re: Yet Another Debian available

                                It worked for me

                                A possible addition would be to add the following to /etc/inittab
                                S0:2345:respawn:/sbin/getty 115200 ttyS1


                                That way you can still use the 3.5mm serial jack if a spare network connection is unavailable.

                                • 13. Re: Yet Another Debian available

                                  Hi, bit of an update here.


                                  I managed to get git to run without segfaulting.

                                  I used these instructions


                                  # cd /root

                                  # apt-get install liblocale-msgfmt-perl gettext libcurl4-openssl-dev curl ntpdate unzip libexpat1-dev python

                                  # wget https://github.com/git/git/archive/v1.7.0.9.zip

                                  # unzip v*

                                  # cd git-*

                                  # make -j8 prefix=/usr/local all

                                  # make -j8 prefix=/usr/local install


                                  from here http://wiki.ros.org/IntelGalileo/Debian


                                  git clone works fine now.


                                  edit: just to note the build will take a decent amount of time.

                                  • 14. Re: Yet Another Debian available

                                    That is very good news about compiling your own git compared to the git in the debian repository. I wonder if the problems with libpthread could be fixed by rebuilding on the Galileo. Building the entire libc might require the swap to be enabled because building libc is a big job.

                                    Congratulations for your discovery and that might be a clue to the problem with the debian build.

                                    1 2 Previous Next