diff options
Diffstat (limited to 'recipes-devtools/net-kexec')
-rw-r--r-- | recipes-devtools/net-kexec/files/net-kexec.sh | 27 | ||||
-rw-r--r-- | recipes-devtools/net-kexec/net-kexec_1.0.bb | 20 |
2 files changed, 0 insertions, 47 deletions
diff --git a/recipes-devtools/net-kexec/files/net-kexec.sh b/recipes-devtools/net-kexec/files/net-kexec.sh deleted file mode 100644 index 44983d5..0000000 --- a/recipes-devtools/net-kexec/files/net-kexec.sh +++ /dev/null @@ -1,27 +0,0 @@ -#!/bin/sh -# Copyright (C) 2014 Romain Perier <romain.perier@gmail.com> -# Released under the MIT license (see COPYING.MIT for the terms) - -GATEWAY=$(route | grep default | sed 's/ [ ]*/:/g' | cut -d ':' -f 2) - -fail() { - echo $1 - exit 1 -} - -# If we are not already connected, connect eth0 with DHCP -ifconfig eth0 | grep 'inet addr:[0-9]*\.[0-9]*\.[0-9]*\.[0-9]* ' >/dev/null -if [ $? -ne 0 ]; then - echo "* Starting DHCP on eth0" - udhcpc -n -i eth0 || fail "Unable to establish a DHCP session with eth0" -fi - -tftp -g -r zImage $GATEWAY >/dev/null || fail "Unable to get zImage throught TFTP" -echo "* Found zImage on $TFTP_SERVER" -echo -n "Do you want to reboot to the new kernel on the fly ? [y/n] " -read boot - -if [ "$boot" = "y" ]; then - kexec -l zImage - kexec -e -fi diff --git a/recipes-devtools/net-kexec/net-kexec_1.0.bb b/recipes-devtools/net-kexec/net-kexec_1.0.bb deleted file mode 100644 index 4de0f0a..0000000 --- a/recipes-devtools/net-kexec/net-kexec_1.0.bb +++ /dev/null @@ -1,20 +0,0 @@ -# Copyright (C) 2014 Romain Perier <romain.perier@gmail.com> -# Released under the MIT license (see COPYING.MIT for the terms) - -SUMMARY = "Extremely basic script to kexec over the network" -LICENSE = "MIT" -LIC_FILES_CHKSUM = "file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420" -SRC_URI = "file://net-kexec.sh" - -PR = "r1" - -RDEPENDS_${PN} += "kexec" - -do_install() { - install -d ${D}/sbin - install -m 0755 ${WORKDIR}/net-kexec.sh ${D}/sbin/net-kexec -} - -inherit allarch - -FILES_${PN} += "/sbin/net-kexec" |