Skip to content

Instantly share code, notes, and snippets.

@gdamjan
gdamjan / 0-image.sh
Last active October 30, 2016 04:02
grub imagelet to start VMs from an image without bootloader
# Create the grub boot image
grub-mkimage -O i386-pc -o grub.img -c grub.cfg \
at_keyboard configfile biosdisk ext2 linux test serial halt minicmd terminal cat acpi
# to create the unbootable linux image, no partitions
qemu-img create -f qcow2 unbootable.img 10G
sudo modprobe nbd max_part=16
sudo qemu-nbd -c /dev/nbd0 unbootable.img
sudo mkfs.ext4 -L ROOT /dev/nbd0
@mrlesmithjr
mrlesmithjr / nxlog.conf
Last active November 7, 2019 16:59
Windows nxlog.conf for Logstash
## Please set the ROOT to the folder your nxlog was installed into,
## otherwise it will not start.
#define ROOT C:\Program Files\nxlog
define ROOT C:\Program Files (x86)\nxlog
define ROOT_STRING C:\Program Files (x86)\\nxlog
Moduledir %ROOT%\modules
CacheDir %ROOT%\data
Pidfile %ROOT%\data\nxlog.pid
@LVLAaron
LVLAaron / Example output with no filters
Last active November 16, 2016 22:06
Config files used to send Windows Eventlog data with NXLOG to Logstash
{
"_index": "logstash-2013.12.23",
"_type": "logs",
"_id": "eMsyB2q4TA6sH0bW3kCBZA",
"_score": null,
"_source": {
"EventTime": "2013-12-22 22:45:27",
"Hostname": "aapc",
"Keywords": -9187343239835812000,
"EventType": "INFO",
@spion
spion / vegetables.md
Created January 2, 2013 11:52
Vegetable list

List of great vegetables

  • Amaranth or Chinese spinach
  • Artichoke
  • Artichoke hearts
  • Asparagus
  • Baby corn
  • Bamboo shoots
  • Beans (green, wax, Italian)
  • Bean sprouts
@spion
spion / food.md
Last active October 13, 2015 20:37
Diet basics

This article contains some basic condensed knowledge about food.

Basic metabolism mechanics

Water

Water - your metabolism needs it. Have a full hand-held bottle nearby at all times. Drink liberally - most estimates of recommended amount fall between 3-5 liters per day (a lot more than what you will usually drink).

Infact, forget all other drinks, especially soft drinks and artificial juices. Most of them are sugary and will become fat minutes after you drink them. Replace them all with water.

@robinsmidsrod
robinsmidsrod / logstash.conf
Created December 5, 2012 13:01
Logging Windows event log information to Logstash using nxlog and JSON transport
input {
tcp {
type => "syslog"
host => "127.0.0.1"
port => 3514
}
tcp {
type => "eventlog"
host => "10.1.1.2"
port => 3515