About Paede

IT-Administrator, Linux Fan aus Meilen (CH). Arbeite meist in Zürich Technopark.

find . -type f -exec grep -qi "foo" {} \; -print

or

grep -H searchterm *.rtf > sumbytes

or

root@spapplication:/var/www/pm# grep -r -l "searchterm" .

Zuerst checken ob eine Serial Port HW-mässig überhaupt vorhanden ist, visuell.

dann schauen ob er vom System erkannt ist:

dmesg | grep tty

wenn ja, das Program minicom starten, bei Ubuntu sudo nicht vergessen

Dann mit Einstellungen machen,
/dev/ttyS0 oder je nach dmesg grep
8n1,11500 (siehe manual vom Gerät)
kein Handshake
und bei “Modem and dialing” alle Strings löschen auf der ersten Zeile.

wichtig ist zuerst sortieren bevor man mit uniq die Doppelten löscht:
cat /var/log/anylog.log | grep suchbegriff* >> ~/temp_neutral_unsort
sort ~/temp_neutral_unsort | uniq > ~/temp_2

hier habe ich die noch nach datum sortiert (siehe vorheriger Eintrag)
/usr/local/bin/sortapache.sh ~/temp_2 neuerpfadunddatei
achtung diese Datei wächst und wächst, darum habe ich sie mit der gefixten Version ersetzt
cp neuerpfadunddatei ~/temp_neutral_unsort

I had to sort the apache log from the date,
I found this nice Scrip:

#!/bin/sh
if [ ! -f $1 ]; then
echo "Usage: $0 "
exit
fi
echo "Sorting $1"
sort -t ' ' -k 4.9,4.12n -k 4.5,4.7M -k 4.2,4.3n -k 4.14,4.15n -k 4.17,4.18n -k 4.20,4.21n $1 > $2

Script um via ssh auf den eine bliebige IP und Port via ssh Tunnel zuzugreifen
#! /bin/bash
# establish a connection to customer
# use Firefox with htp://localhost:8888
ssh -L 8888:"targetIP":"targetPort" root@host.office-on-the.net -p 22

paede@kamino:~$ sudo su
[sudo] password for paede:
root@kamino:/home/paede# VBoxManage clonevdi /home/paede/.VirtualBox/VDI/XPtest.vdi /home/paede/.VirtualBox/XPtes2

Einfach aus einem Laufwerk eine iso Datei machen:

paede@kamino:~$ cat /dev/scd0 > /home/paede/Myiso.iso

das scheint eine nicht soo profesionelle Methode die funktioniert, das soll besser sein:

Instead, you should be using the right tool for the right job. In this case, you need to check out the ‘readom’ command (read optical media). It does exactly what you’re looking for, and has built in error checking.

readom dev=/dev/scd0 f=/home/shamanstears/test.iso

If you want to record the ISO, then you should be using ‘wodim’, not ‘dd’, or any other horrible “solution”.

wodim -v -eject /home/shamanstears/test.iso