This is a quick guide to mounting a qcow2 disk images on your host server. This is useful to reset passwords, edit files, or recover something without the virtual machine running.
Step 1 - Enable NBD on the Host
modprobe nbd max_part=8
Recently I acquired (md5: ADF639AFE9855EE86C8FAAD216C970D9) the Zynq bootrom, and during the reversing process uncovered some interesting secrets, one of which is an as-of-yet undocumented UART loader. As documented the Zynq bootrom will load from NOR/NAND/SPI flashes, eMMC/SDIO-based storage (unfortunately) not USB, or anything else more complex.
Not sure why Xilinx didn't document this. In my brief testing it is super unreliable if you just spit everything at once - they reset the RX/TX paths during the process, so timing is critical, but that might be the janky meter-long ftdi cable. You can change the baudrate during the process, but I was too lazy to do the math.
Here's the disassembly that made me look twice (that, and checks for the MIO boot_mode[2:0]
that weren't specified in the docs :)):
ROM:0000A220 BL uart_init
# -*- coding: utf-8 -*- | |
from __future__ import unicode_literals | |
""" | |
*************************************************************************** | |
* Copyright (c) <mario52> 2014 2015 2016 2017 2018 2019 2020 2021 2022 * | |
* 2023 2024 * | |
* This file is a supplement to the FreeCAD CAx development system. * | |
* * | |
* This program is free software; you can redistribute it and/or modify * | |
* it under the terms of the GNU Lesser General Public License (LGPL) * |
#include <stdio.h> | |
#include <stdlib.h> | |
#include <printf.h> | |
static int print_coin (FILE *stream, | |
const struct printf_info *info, | |
const void *const *args) | |
{ |
defmodule XmlNode do | |
require Record | |
Record.defrecord :xmlAttribute, Record.extract(:xmlAttribute, from_lib: "xmerl/include/xmerl.hrl") | |
Record.defrecord :xmlText, Record.extract(:xmlText, from_lib: "xmerl/include/xmerl.hrl") | |
def from_string(xml_string, options \\ [quiet: true]) do | |
{doc, []} = | |
xml_string | |
|> :binary.bin_to_list | |
|> :xmerl_scan.string(options) |
/* | |
step.c | |
Program to verify new algorithm for linear acceleration. | |
Author: Pramod Ranade <pramod.ranade@spjsystems.com> | |
*/ | |
#include <stdio.h> | |
#include <io.h> | |
#include <stdlib.h> |
I'm tired of massive delay (500-1000 ms pings) while uploading large files. QoS helps some, but a significant portion remains due to bufferbloat (100-150ms). This leads to delay in VoIP calls and generally sluggish web browsing while uploading.
The new Codel algorithm in OpenWRT / Attitude Adjustment should help a lot. The results below show only ~5-6ms of added latency during uploads (i.e. 14ms vs 500+ms before!). Insane.
These instructions are for the TP-Link TL-WDR4300, because I got a good deal. If you have the money, buy a Netgear WNDR3800 and install CeroWRT, you'll probably see even better results.
In short, its fully supported in OpenWRT Attitude Adjustment and works well for my needs:
#!/usr/bin/ruby | |
# encoding: utf-8 | |
# author : Marc Quinton, april 2015 | |
# name : rvitalk : ruby P300 protocol implementation to handle IO to Viessmann heating systems | |
# object : connect to a Viessmann heating system via Optolink adaptator to query internal values. | |
# version : 0.5 - added write mode for commands, P300 constants, | |
# requirements : ruby >= 2.1, ruby-serialport, a serial USB optolink adapter, a Viessman heating system. | |
# licence : MIT | |
# links : http://openv.wikispaces.com/vcontrold ; https://gist.github.com/mqu |