Skip to content

Instantly share code, notes, and snippets.

View krha's full-sized avatar

Kiryong Ha krha

  • Carnegie Mellon University
  • Pittsburgh
View GitHub Profile
@krha
krha / cloudlet-log
Created December 2, 2016 01:09
cloudlet-log for checking reset_blob_pos
time:1480640859.745537, bdrv_discard, sector_num:8951808, sector_size:8
time:1480640859.746831, bdrv_discard, sector_num:271064, sector_size:8
time:1480640859.747133, bdrv_discard, sector_num:271032, sector_size:8
time:1480640859.747500, bdrv_discard, sector_num:78880, sector_size:8
time:1480640859.747849, bdrv_discard, sector_num:94344, sector_size:8
time:1480640859.748264, bdrv_discard, sector_num:8830768, sector_size:8
time:1480640859.748595, bdrv_discard, sector_num:8830688, sector_size:8
time:1480640859.748962, bdrv_discard, sector_num:8830104, sector_size:8
time:1480640859.749315, bdrv_discard, sector_num:8820616, sector_size:8
time:1480640859.749701, bdrv_discard, sector_num:8653104, sector_size:16
# Minimal ``local.conf`` for single node devstack installation
# Please find the details at http://docs.openstack.org/developer/devstack/guides/single-machine.html#run-devstack
#
# The minial values to set up is
# 1) passwords for SERVICE_TOKEN, ADMIN_PASSWORD, MYSQL_PASSWORD, RABBIT_PASSWORD, and SERVICE_PASSWORD
# 2) FLAT_INTERFACE
# 3) PUBLIC_INTERFACE
#
# For details of each key, please read the comment on them.
@krha
krha / loca
Last active October 16, 2022 01:02
Minimal ``local.conf`` for single node devstack installation
# Minimal ``local.conf`` for single node devstack installation
# Please find the details at http://docs.openstack.org/developer/devstack/guides/single-machine.html#run-devstack
#
# The minial values to set up is
# 1) passwords for SERVICE_TOKEN, ADMIN_PASSWORD, MYSQL_PASSWORD, RABBIT_PASSWORD, and SERVICE_PASSWORD
# 2) FLAT_INTERFACE
# 3) PUBLIC_INTERFACE
#
# For details of each key, please read the comment on them.
@krha
krha / local.conf
Created February 12, 2016 21:18
Minimal ``local.conf`` for single node devstack installation
# Minimal ``local.conf`` for single node devstack installation
# Please find the details at http://docs.openstack.org/developer/devstack/guides/single-machine.html#run-devstack
#
# The minial values to set up is
# 1) passwords for SERVICE_TOKEN, ADMIN_PASSWORD, MYSQL_PASSWORD, RABBIT_PASSWORD, and SERVICE_PASSWORD
# 2) FLAT_INTERFACE
# 3) PUBLIC_INTERFACE
#
# For details of each key, please read the comment on them.
#!/bin/bash
# tc uses the following units when passed as a parameter.
# kbps: Kilobytes per second
# mbps: Megabytes per second
# kbit: Kilobits per second
# mbit: Megabits per second
# bps: Bytes per second
# Amounts of data can be specified in:
# kb or k: Kilobytes
# mb or m: Megabytes
# Sample ``local.conf`` for user-configurable variables in ``stack.sh``
# NOTE: Copy this file to the root ``devstack`` directory for it to
# work properly.
# ``local.conf`` is a user-maintained setings file that is sourced from ``stackrc``.
# This gives it the ability to override any variables set in ``stackrc``.
# Also, most of the settings in ``stack.sh`` are written to only be set if no
# value has already been set; this lets ``local.conf`` effectively override the
# default values.
def control_migration(self):
self.qmp.connect()
counter_check_comp_size = 0
ret = self.qmp.qmp_negotiate()
if not ret:
raise CloudletGenerationError("failed to connect to
@krha
krha / monex.py
Last active August 29, 2015 14:07 — forked from yy/monex.py
#!/usr/bin/env python
# encoding: utf-8
"""
MONitor & EXecute
Yong-Yeol Ahn (http://yongyeol.com/)
This script monitors multiple files and executes the given command when
any of those files is changed.
"""
import sys
@krha
krha / gist:5744228
Last active December 18, 2015 07:09
<domain type='kvm' id='44' xmlns:qemu='http://libvirt.org/schemas/domain/qemu/1.0'>
<name>instance-0000014c</name>
<uuid>48084680-c244-40c5-a22d-100efa0ec733</uuid>
<devices>
<emulator>/usr/lib/python2.7/dist-packages/synthesis/lib/bin/x86_64/qemu-system-x86_64</emulator>
<disk type='file' device='disk'>
<driver name='qemu' type='raw' cache='none'/>
<source file='/var/tmp/vmnetfs-sXVNJo/disk/image'/>
<target dev='vda' bus='virtio'/>
<alias name='virtio-disk0'/>
@krha
krha / VM_XML
Created October 9, 2012 22:06
Cloudlet Template XML
<domain type='kvm' xmlns:qemu='http://libvirt.org/schemas/domain/qemu/1.0'>
<name>cloudlet</name>
<uuid>c7a5fdbd-cdaf-9455-926a-d65c16db1801</uuid>
<memory>1048576</memory>
<currentMemory>1048576</currentMemory>
<vcpu>4</vcpu>
<cpu>
<topology sockets='1' cores='4' threads='1'/>
</cpu>
<os>