Copy Image via netcat

This is for a High-Bandwidth Network. If you have a Low-Bandwidth Network you can try to switch lzo with bzip2.

Target:
nc -v -l -p 19000 | lzop -c -d | pv -s 70G | dd bs=16M of=/root/foo.img

  1. listen on port 19000 for connections.
  2. decompress the datapackages.
  3. pv displays a status bar.
  4. and wirte them into a file.

Source:
dd bs=16M if=/root/bar.img | lzop -3 -c | nc -v 10.0.01 19000

  1. dd reads the file in 16MB Blocks.
  2. each block will be compressed with lzo.
  3. nc connects 10.0.01 on port 19000 and pushes data.

OpenSSH with authentication key instead of password on Debian Squeeze/Wheezy/Derivatives

Generate the authentication public key on the Client

User@Client:~# ssh-keygen

Install the public key on the server

User@Client:~# ssh-copy-id -i /path/to/what/ever/id_rsa.pub user@server.tld

Or

User@Client:~# ssh-keygen -t rsa

Copy the public key to the server

User@Client:~# scp .ssh/id_rsa.pub user@server:/path/to/what/ever

Install the public key on the server

User@Server:~# cat /path/to/what/ever/id_rsa.pub >> .ssh/authorized_keys

server configuration (should not be needed today)

nano /etc/ssh/sshd_config
PubkeyAuthentication yes

to disable password login

PasswordAuthentication no

further info
SSH with authentication key instead of password
SSH

VLC compile on Debian/-derivat

Abhängigkeiten

build-essentials cmake

VLC Compilen

(make auf 2kernen laufen lassen: make -j 2 )
(make auf 3kernen laufen lassen: make -j 3 )
(make auf 4kernen laufen lassen: make -j 4 )
cd /usr/local/src/
wget http://download.videolan.org/pub/videolan/vlc/2.0.3/vlc-2.0.3.tar.xz
tar xvJf vlc-2.0.3.tar.xz
cd /usr/local/src/vlc-2.0.3/contrib/src/
../bootstrap
make
cd /usr/local/src/vlc-2.0.3/
./configure --enable-run-as-root --enable-x264 \
--enable-merge-ffmpeg --enable-live555 \
--enable-dvbpsi \
--with-contrib=/usr/local/src/vlc-2.0.3/contrib/x86_64-linux-gnu
make
make install

SAT Empfang und per HTTP bereitstellen auf Port 8000

/usr/local/bin/cvlc -vvvv dvb-s:// --dvb-frequency $FREQUENZ
--dvb-srate 27500000 --dvb-satno 1 --dvb-polarization=H --dvb-adapter
2 --dvb-caching=20000 --ttl 100 --program=$PROGRAMM --sout
#transcode{}:std{access=http,mux=ts,dst=:8000}

Per HTTP Holen, nach h264 konvertieren und wieder per HTTP auf Port
8001 bereitstellen

cvlc -vvv http://127.0.0.1:8000 --http-reconnect --sout
#transcode{venc=x264{keyint=60,profile=main},vcodec=x264,vb=1500,acodec=mp4a,ab=96,channels=2,samplerate=48000}:std{access=http,mux=ts,dst=:8001}

Geht auch in einem Schritt

/usr/local/bin/cvlc -vvvv dvb-s:// --dvb-frequency $FREQUENZ
--dvb-srate 27500000 --dvb-satno 1 --dvb-polarization=H --dvb-adapter
2 --dvb-caching=20000 --ttl 100 --program=$PROGRAMM --sout
#transcode{venc=x264{keyint=60,profile=main},vcodec=x264,vb=1500,acodec=mp4a,ab=96,channels=2,samplerate=48000}:std{access=http,mux=ts,dst=:8000}

using Qemu KVM virtualization on Debian 7 Weezy

Einfach folgende Pakete installieren:

aptitude install qemu-kvm libvirt-bin virtinst libvirt-clients virt-manager virsh
aptitude install qemu-kvm libvirt-bin virt-manager virsh virtinst

Den/Die Benutzer der Gruppe libvirt hinzufügen, welche qemu-kvm verwenden dürfen sollen

adduser <Benutzername> libvirt

in der Gui virt-manager starten oder in der Konsole (z.B. über SSH) virsh/virtinst verwenden

default Ordner für ISO images:

/var/lib/libvirt/images/

System erstellen auf der Console

virt-install --hvm --name VirtualMachineName --ram 512 --nodisks --livecd --vnc --cdrom /path/to/iso/debian-7.0.0-kfreebsd-amd64-netinst.iso --network network:default