Skip to content

Instantly share code, notes, and snippets.

View Spenser309's full-sized avatar

Spenser Gilliland Spenser309

View GitHub Profile
@Spenser309
Spenser309 / gist:2ec1358b03e2f7beaf07e77f3f680589
Created February 9, 2017 01:44
Example of how to resize and recompress a disk image for openstack
$ openstack --os-identity-api-version=3 image save --file <filename> <image name>
$ virt-df -h -a <filename> # shows used/free disk space
$ guestfish -a <filename> <<EOF
run
list-filesystems # informational only
e2fsck-f /dev/sda1
resize2fs-size /dev/sda1 <size>G
exit
EOF
$ qemu-img create -f qcow2 <filename>.qcow2 <size>.2G # Add 200MB as padding
PATH="/home/spenser/Code/buildroot_cubieboard/output/host/bin:/home/spenser/Code/buildroot_cubieboard/output/host/usr/bin:/home/spenser/Code/buildroot_cubieboard/output/host/usr/sbin/:/home/spenser/bin:/usr/lib/lightdm/lightdm:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games" PERLLIB="/home/spenser/Code/buildroot_cubieboard/output/host/usr/lib/perl" /usr/bin/make -j9 -C /home/spenser/Code/buildroot_cubieboard/output/build/mesa3d-demos-8.1.0/
make[1]: Entering directory `/home/spenser/Code/buildroot_cubieboard/output/build/mesa3d-demos-8.1.0'
Making all in src
make[2]: Entering directory `/home/spenser/Code/buildroot_cubieboard/output/build/mesa3d-demos-8.1.0/src'
Making all in util
make[3]: Entering directory `/home/spenser/Code/buildroot_cubieboard/output/build/mesa3d-demos-8.1.0/src/util'
make[3]: Nothing to be done for `all'.
make[3]: Leaving directory `/home/spenser/Code/buildroot_cubieboard/output/build/mesa3d-demos-8.1.0/src/util'
Making all in data
make[3]: Ent
PATH="/home/spenser/Code/buildroot_cubieboard/output/host/bin:/home/spenser/Code/buildroot_cubieboard/output/host/usr/bin:/home/spenser/Code/buildroot_cubieboard/output/host/usr/sbin/:/home/spenser/bin:/usr/lib/lightdm/lightdm:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games" PERLLIB="/home/spenser/Code/buildroot_cubieboard/output/host/usr/lib/perl" /usr/bin/make -j9 -C /home/spenser/Code/buildroot_cubieboard/output/build/mesa3d-demos-8.1.0/
make[1]: Entering directory `/home/spenser/Code/buildroot_cubieboard/output/build/mesa3d-demos-8.1.0'
Making all in src
make[2]: Entering directory `/home/spenser/Code/buildroot_cubieboard/output/build/mesa3d-demos-8.1.0/src'
Making all in util
make[3]: Entering directory `/home/spenser/Code/buildroot_cubieboard/output/build/mesa3d-demos-8.1.0/src/util'
make[3]: Nothing to be done for `all'.
make[3]: Leaving directory `/home/spenser/Code/buildroot_cubieboard/output/build/mesa3d-demos-8.1.0/src/util'
Making all in data
make[3]: Ent
<6>Bluetooth: HCI device and connection manager initialized
<6>Bluetooth: HCI socket layer initialized
<6>Bluetooth: L2CAP socket layer initialized
<6>Bluetooth: SCO socket layer initialized
<6>cfg80211: Calling CRDA to update world regulatory domain
<6>Switching to clocksource aw 64bits couter
<5>FS-Cache: Loaded
<6>Switched to NOHz mode on CPU #0
<6>CacheFiles: Loaded
<1>Unable to handle kernel paging request at virtual address ffffffff
cd /home/spenser/Code/buildroot_cubieboard/output/build/glmark2-2012.12 && PATH="/home/spenser/Code/buildroot_cubieboard/output/host/bin:/home/spenser/Code/buildroot_cubieboard/output/host/usr/bin:/home/spenser/Code/buildroot_cubieboard/output/host/usr/sbin/:/home/spenser/bin:/usr/lib/lightdm/lightdm:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games" PERLLIB="/home/spenser/Code/buildroot_cubieboard/output/host/usr/lib/perl" ./waf
Waf: Entering directory `/home/spenser/Code/buildroot_cubieboard/output/build/glmark2-2012.12/build'
[61/63] cxx: src/canvas-drm.cpp -> build/src/canvas-drm.cpp.2.o
[63/63] cxxprogram: build/src/benchmark-collection.cpp.2.o build/src/benchmark.cpp.2.o build/src/gl-headers.cpp.2.o build/src/gl-visual-config.cpp.2.o build/src/image-reader.cpp.2.o build/src/main-loop.cpp.2.o build/src/main.cpp.2.o build/src/mesh.cpp.2.o build/src/model.cpp.2.o build/src/options.cpp.2.o build/src/scene-buffer.cpp.2.o build/src/scene-build.cpp.2.o build/src/scene-bum
@Spenser309
Spenser309 / gist:5714245
Created June 5, 2013 14:24
modprobe bufferclass_ti
# modprobe bufferclass_ti
[ 1349.355377] Unable to handle kernel NULL pointer dereference at virtual address 00000000
[ 1349.364105] pgd = de4c0000
[ 1349.366943] [00000000] *pgd=9e4d7831, *pte=00000000, *ppte=00000000
[ 1349.373687] Internal error: Oops: 17 [#1] SMP ARM
[ 1349.378662] Modules linked in: bufferclass_ti(O+) omapdss pvrsrvkm(O) snd_soc_twl4030 snd_soc_omap_twl4030 snd_soc_omap snd_soc_omap_mcbsp snd_soc_core regmap_spi snd_compress snd_pcm snd_timer snd soundcore snd_page_alloc
[ 1349.399566] CPU: 0 Tainted: G W O (3.9.4 #1)
[ 1349.405212] PC is at AllocateDeviceID+0x0/0x48 [pvrsrvkm]
[ 1349.410919] LR is at PVRSRVRegisterBCDeviceKM+0xfc/0x218 [pvrsrvkm]
[ 1349.417510] pc : [<bf1e23f4>] lr : [<bf1de290>] psr: 400f0013
[ 91.290924] WARNING: at drivers/clk/clk.c:656 __clk_enable+0x94/0xa0()
[ 91.297790] Modules linked in: pvrsrvkm(O+) snd_soc_twl4030 snd_soc_omap_twl4030 snd_soc_omap snd_soc_omap_mcbsp snd_soc_core regmap_spi snd_compress snd_pcm snd_timer snd soundcore snd_page_alloc
[ 91.316314] [<c001ae84>] (unwind_backtrace+0x0/0xf0) from [<c0041d7c>] (warn_slowpath_common+0x4c/0x6c)
[ 91.326232] [<c0041d7c>] (warn_slowpath_common+0x4c/0x6c) from [<c0041db8>] (warn_slowpath_null+0x1c/0x24)
[ 91.336395] [<c0041db8>] (warn_slowpath_null+0x1c/0x24) from [<c04190ec>] (__clk_enable+0x94/0xa0)
[ 91.345794] [<c04190ec>] (__clk_enable+0x94/0xa0) from [<c0419118>] (clk_enable+0x20/0x3c)
[ 91.354583] [<c0419118>] (clk_enable+0x20/0x3c) from [<bf1f5384>] (EnableSGXClocks+0x1c/0xa4 [pvrsrvkm])
[ 91.364715] [<bf1f5384>] (EnableSGXClocks+0x1c/0xa4 [pvrsrvkm]) from [<bf1f5924>] (SysInitialise+0x1cc/0x250 [pvrsrvkm])
[ 91.376190] [<bf1f5924>] (SysInitialise+0x1cc/0x250 [pvrsrvkm]) from [<bf1e945c>] (PVRSRVDriverProbe+0
@Spenser309
Spenser309 / gist:5587802
Created May 15, 2013 22:06
Script to run a build for submission to an autobuilder.
#!/bin/bash
#
# Submit a build to the autobuilder. This script can be used to start a
# build which will be submitted to the autobuilder.
#
# This script must be run from the buildroot top dir.
TIMEOUT=${TIMEOUT:="2h"}
RESULTDIR=${RESULTDIR:=$(mktemp -d)}
BUILDDIR=${BUILDDIR:="output"}
(glib-compile-resources:17994): GLib-GObject-CRITICAL **: gtype.c:2722: You forgot to call g_type_init()
(glib-compile-resources:17994): GLib-GObject-CRITICAL **: gtype.c:2722: You forgot to call g_type_init()
(glib-compile-resources:17994): GLib-GObject-CRITICAL **: gtype.c:2722: You forgot to call g_type_init()
(glib-compile-resources:17994): GLib-GObject-WARNING **: interface type `<invalid>' or prerequisite type `<unknown>' invalid
(glib-compile-resources:17994): GLib-GObject-WARNING **: cannot add interfaces to invalid (non-instantiatable) type `<invalid>'
zh_HK.utf8
zh_SG.utf8
zh_TW.utf8
zu_ZA.utf8
/usr/bin/make -j1 -C /home/spenser/Research/buildroot/buildroot/output/toolchain/uClibc \
ARCH="microblaze" \
PREFIX=/home/spenser/Research/buildroot/buildroot/output/toolchain/uClibc_dev/ \
DEVEL_PREFIX=/usr/ \
RUNTIME_PREFIX=/home/spenser/Research/buildroot/buildroot/output/toolchain/uClibc_dev/ \
HOSTCC="/usr/bin/gcc" headers \