Edit /etc/init.d/klogd
and set
KLOGD="-c 4"
#> mysqldump -u user -p --complete-insert --add-drop-table --databases db1 db2
other options
--no-data --no-create-info --no-create-db
ssh andi@gaz.splitbrain.org -R *:8888:localhost:80
$> perl -e 'print scalar(localtime(1098189697))."\n";'
Sometimes you need some swap space. Here is how to add some to a running system:
# dd if=/dev/zero of=/extraswap bs=1M count=512 # mkswap /extraswap # swapon /extraswap
Import GPG keys for installing via yum
rpm --import /usr/share/rhn/RPM-GPG-KEY-fedora
Sometimes you need a terminal which can display UTF-8 but your system still uses latin1. Here is what I did:
Install a unicode aware teminal emulator:
#> apt-get install rxvt-unicode
Make sure you have a UTF-8 locale available eg. en_US.utf-8
(check with locale -a
), use dpkg –reconfigure locales
to build one if needed.
Add this to your ~/.bashrc
alias uterm='LANG=en_US.utf8 urxvt'
Now run uterm
whenever you need the UTF-8 terminal.
find . | xargs grep 'string'
Or if you don't need the flexibility of find:
grep -R "string" *
(-R for recursive; the star as a file matching pattern)