start new:
tmux
start new with session name:
tmux new -s myname
#!/bin/bash | |
if [ "$1" != "" ]; then | |
echo " | |
---------------------------------------------------------------------------- | |
http://www.kernel.org/doc/Documentation/vm/ksm.txt : | |
The effectiveness of KSM and MADV_MERGEABLE is shown in /sys/kernel/mm/ksm/: |
NOTE: This is a question I found on StackOverflow which I’ve archived here, because the answer is so effing phenomenal.
If you are not into long explanations, see [Paolo Bergantino’s answer][2].
This short howto describes how to install VMs via kickstart in VirtualBox. It's using PXE functionality built into the NAT network mode of the VirtualBox. The following instructions apply to CentOS installation but it should work for any RedHat-based distro.
Prepare directory structure
#!/usr/bin/perl | |
use warnings; | |
use strict; | |
use Getopt::Long; | |
use Data::Dumper; | |
my $debug = 0; | |
# Valid options for backuppcfs |
Simple guide for setting up OTG modes on the Raspberry Pi Zero - By Andrew Mulholland (gbaman).
The Raspberry Pi Zero (and model A and A+) support USB On The Go, given the processor is connected directly to the USB port, unlike on the B, B+ or Pi 2 B, which goes via a USB hub.
Because of this, if setup to, the Pi can act as a USB slave instead, providing virtual serial (a terminal), virtual ethernet, virtual mass storage device (pendrive) or even other virtual devices like HID, MIDI, or act as a virtual webcam!
It is important to note that, although the model A and A+ can support being a USB slave, they are missing the ID pin (is tied to ground internally) so are unable to dynamically switch between USB master/slave mode. As such, they default to USB master mode. There is no easy way to change this right now.
It is also important to note, that a USB to UART serial adapter is not needed for any of these guides, as may be documented elsewhere across the int
make_vbox() { | |
pushd "$HOME/src/forked/ipxe/src" >/dev/null && | |
#make bin/intel--virtio-net--pcnet32.dsk EMBED=../nic-menu.ipxe && | |
make CONFIG=vbox bin/intel--virtio-net--pcnet32.isarom && #EMBED=config/vbox/embedded.ipxe && | |
#perl util/padimg.pl --verbose --blksize 4096 bin/intel--virtio-net--pcnet32.isarom && | |
echo "Max size of VirtualBox ROM is 56KB, 57344 bytes" && | |
ls -l bin/intel--virtio-net--pcnet32.isarom && | |
prefix=$(date +%Y%m%d-%H%M%S) && | |
mkdir -p /ipxe/$prefix && | |
cp -v bin/intel--virtio-net--pcnet32.isarom /ipxe/$prefix/ && |
<?xml version="1.0" encoding="utf-8"?> | |
<service> | |
<short>chromecast-ssdp</short> | |
<port protocol="udp" port="1900"/> | |
<destination ipv4="239.255.255.250/32"/> | |
</service> |
Note: This gist may be outdated, thanks to all contributors in comments.
adb
is the Android CLI tool with which you can interact with your android device, from your PC
You must enable developer mode (tap 7 times on the build version in parameters) and install adb on your PC.
Don't hesitate to read comments, there is useful tips, thanks guys for this !
#!/usr/local/bin/php | |
<?php | |
require_once("config.inc"); | |
require_once("interfaces.inc"); | |
require_once("util.inc"); | |
$subsystem = !empty($argv[1]) ? $argv[1] : ''; | |
$type = !empty($argv[2]) ? $argv[2] : ''; |