Added record sound via rec
[grml-tips.git] / grml_tips
index ce98176..7e31b02 100644 (file)
--- a/grml_tips
+++ b/grml_tips
@@ -584,6 +584,10 @@ Save live audio stream to file:
 or
 
 % mencoder mms://file.wmv -o $FILE -ovc copy -oac copy
+
+or
+
+% mimms mms://file.wmv
 -- 
 Merge video files:
 
@@ -1715,7 +1719,7 @@ GET http://www.google.com HTTP/1.0 [press enter twice]
 Adjust system for use of qemu with kqemu:
 
 Make sure you have all you need:
-# apt-get update ; apt-get install qemu grml-kerneladdons-$KERNELVERSION
+# aptitude update ; aptitude install qemu kqemu-modules-$(uname -r)
 
 Then set up kqemu:
 
@@ -2630,6 +2634,187 @@ any further work.
 -- 
 Debugging SSL communications:
 
-% openssl s_client -connect webmail.grml.org:993
+% openssl s_client -connect server.adress:993
+
+or
 
 # ssldump -a -A -H -i eth0
+
+See http://prefetch.net/articles/debuggingssl.html for more details.
+-- 
+Remove bootmanager from MBR:
+
+# lilo -M /dev/hda -s /dev/null
+-- 
+Rewrite grub to MBR:
+
+# mount /mnt/sda1
+# grub-install --recheck --no-floppy --root-directory=/mnt/sda1 /dev/sda
+-- 
+Rewrite lilo to MBR:
+
+# mount /mnt/hda1
+# lilo -r /mnt/hda1
+-- 
+Create screenshot of plain/real console - tty1:
+
+# fbgrab -c 1 screeni.png
+-- 
+Create screenshot when running X:
+
+% scrot
+
+Tip: use the gkrellshoot plugin when using gkrellm
+-- 
+Redirect all connections to hostA:portA to hostB:portB, where hostA and hostB are
+different networks:
+
+Run the following commands on hostA:
+
+echo 1 > /proc/sys/net/ipv4/ip_forward
+iptables -t nat -A PREROUTING -p tcp --dport portA -j DNAT --to hostB:portB
+iptables -A FORWARD -i eth0 -o eth0 -d hostB -p tcp --dport portB -j ACCEPT
+iptables -A FORWARD -i eth0 -o eth0 -s hostB -p tcp --sport portB -j ACCEPT
+iptables -t nat -A POSTROUTING -p tcp -d hostB --dport portB -j SNAT --to-source hostA
+-- 
+Flash BIOS without DOS/Windows:
+
+Dump flash info and set the flash chip to writable:
+# flashrom
+
+Backup the original BIOS:
+# flashrom -r backup.bin
+
+Notice: the following step will overwrite your current BIOS!
+So make sure you really know what you are doing.
+
+Flash the BIOS image:
+# flashrom -wv newbios.bin
+
+Also check out LinuxBIOS: http://linuxbios.org/
+-- 
+Enable shadow passwords:
+
+# shadowconfig on
+-- 
+Set up an IPv6 tunneln on grml:
+
+# ipv6-tunnel start
+-- 
+Set up console newsreader slrn for use with Usenet:
+
+% grml-slrn
+-- 
+Calculate with IPv6 addresses:
+
+% ipv6calc
+
+For usage examples refer to manpage ipv6calc(8).
+-- 
+Common network debugging tools for use with IPv6:
+
+% ping6
+% tracepath6
+% traceroute6
+% tracert6
+% nc6
+% tcpspray6
+-- 
+Set up NFS (Network File System):
+
+Server-side
+~~~~~~~~~~~
+Make sure the relevant services are running on the server side:
+
+# /etc/init.d/portmap start
+# /etc/init.d/nfs-common start
+# /etc/init.d/nfs-kernel-server start
+
+Export shares via /etc/exports:
+
+/backups 192.168.1.100/24(rw,wdelay,no_root_squash,async,subtree_check)
+
+... or manually export a directory running:
+
+# exportfs -o rw,wdelay,no_root_squash,async,subtree_check 192.168.1.100:/backups
+
+and unexport a share running:
+
+# exportfs -u 192.168.1.100:/backups
+
+and every time when you modify /etc/exports file run
+
+# exportfs -ra
+
+Display what NFS components are running:
+
+# rpcinfo -p
+
+Display list of exported shares:
+
+# exportfs -v
+or
+# showmount -e
+
+Client-side
+~~~~~~~~~~~
+Make sure the relevant services are running on the client side:
+
+# /etc/init.d/portmap start
+# /etc/init.d/nfs-common start
+
+Verify that the server allows you to access its RPC/NFS services:
+
+# rpcinfo -p server_name
+
+Check what directories the server exports:
+
+# showmount -e server_name
+
+On the client side you can use something like the following in /etc/fstab:
+
+192.168.1.101:/backups /mnt/nfs nfs defaults,users,wsize=8192,rsize=8192 0 0
+-- 
+Mount a cloop file:
+
+# aptitude install cloop-src
+# m-a a-i cloop-src
+
+# modprobe cloop file=/path/to/cloop/file
+# mount -r -t iso9660 /dev/cloop /mnt/test
+-- 
+Create a PS/PDF of a plaintext file:
+
+% a2ps --medium A4dj -E -o output.ps input_file
+% ps2pdf output.ps
+-- 
+Print two pages on one in a PDF file:
+
+% pdfnup --nup 2x1 input.pdf
+
+Concatenate, extract pages/parts, encrypt/decrypt,
+compress PDFs using 'pdftk'.
+-- 
+Read a PS/PDF file on console:
+
+% pstotext file.pdf
+
+or on plain framebuffer console in graphical mode:
+
+% pdf2ps file.pdf ; ps2png file.ps file.png ; fbi file.png
+
+or
+
+% fbgs file.pdf
+-- 
+Bypass the password of a PDF file:
+
+% gs -q -dNOPAUSE -sDEVICE=pdfwrite -sOutputFile=output.pdf input.pdf -c quit
+-- 
+Record sound:
+
+% rec test.aiff
+
+This will record a AIFF audio file.
+-- 
+