Backup Raspberry SD Card with MacOS

septiembre 18, 2014 Deja un comentario
To dump the card into a file:
 sudo dd if=/dev/disk2 of=/Volumes/example/raspberry.img bs=1m 

Compress the file

 gzip raspberry.img 
To re-flash the SD card:
 gzip -dc ~/Desktop/pi.gz | sudo dd of=/dev/rdisk1 bs=1m 
Categorías: Uncategorized

How to create a MySQL Dump

noviembre 27, 2012 1 comentario

mysqldump -h localhost -u root -ppassword -c --add-drop-table --add-lock --all --quick --lock-tables [database_name] > sqldump.sql

mysqldump reference

Categorías: Uncategorized Etiquetas:

Case insensitive BeanComparator

junio 5, 2012 Deja un comentario

Transformer transformer = new Transformer() {
public Object transform(Object arg) {
return ((String)arg).toLowerCase();
}
};
Comparator comparator = new TransformingComparator(transformer);
Collections.sort(list, new BeanComparator("field", comparator));

http://www.opensubscriber.com/message/commons-user@jakarta.apache.org/2094876.html

Categorías: java, programacion

Bash: execute commands in sequence

abril 27, 2012 3 comentarios

One command after another. An error will not stop the sequence: ;
cd /home/tipp/ ; ls
An error will stop the sequence:
cd /home/tipp/ && ls
All commands run at the same time
cd /home/tipp/ & ls

Backgrounded commands:
jobs

Also, handy commands:
bg, fg

Categorías: linux Etiquetas: ,

Ubuntu 12.04 TLS Update. Problem with JNI

abril 27, 2012 7 comentarios

After upgrading to Ubuntu 12.04, the location of the JNI library changed.

To solve this problem I removed the jni library:
apt-get purge libsvn-java
and reinstalled it:
apt-get install libsvn-java
After that I updated the following property in eclipse.ini:
-Djava.library.path=/usr/lib/x86_64-linux-gnu/jni

Maybe only the property in eclipse.ini should be changed.

Categorías: java, linux Etiquetas: , , , , , , ,

Installing TEX and its tools on MacOS

septiembre 19, 2011 1 comentario

TEX is a typesetting system that allows to produce high-quality books and provides a system that gives the same result on all computers. LATEX is the markup language used in the TEX typesetting system.

Steps to install it on MacOS:

  1. Download the Mac distribution, or the smaller distribution.
  2. After installing it, run the following commands:

    sudo bash
    PATH=/usr/local/texlive/2011basic/bin/universal-darwin:$PATH; export PATH
    texhash
    sudo tlmgr paper $PAPER
    sudo fmtutil-sys --all

    Where $PAPER is either «letter» or «a4».

With the tool tlmgr is possible to manage the TEX packages: update, install and remove them.

Categorías: latex, macos

SSH Connect Timeout

agosto 27, 2011 Deja un comentario

Es ist etwa unbequem, wenn die ssh Verbindung nach 2 Minuten getrennt wird. Um das zu vermeiden, muss man die ssh_config Datei bearbeiten, in dem man die key ConnectTimeout zu 0 setzt.

Categorías: linux, macos, ssh

Virtual Box Virtual Image kopieren

junio 2, 2011 Deja un comentario

VBoxManage clonevdi Origen.vdi Copia.vdi

Categorías: Uncategorized

Tomcat unter MacOS installlieren

junio 1, 2011 Deja un comentario

1. Tomcat herunterladen.
2. Das Packet entpacken: $ tar -xzf apache-tomcat-6xxxx
3. Zu /user/local schieben: $ mv apache-tomcat-6xxxx /usr/local
4. Für zukünftige Aktualisierungen man kann ein symbolisches Link erstellen: sudo ln -s /usr/local/apache-tomcat-6xxxx /usr/local/tomcat
5. Umfeld Variablen erstellen. In /etc/profile die folgende Befehle hinzufügen:
export JAVA_HOME=/Library/Java/Home
export CATALINA_HOME=/usr/local/tomcat

Categorías: Uncategorized

Cron – Linux

junio 1, 2011 1 comentario

Jobsteuerung von Linux, die wiederkehrende Aufgaben automatisch zu einer bestimmten Zeit ausführen kann.
Ein Nutzer kann cron nutzen wenn er in der Datei /etc/cron.allow aufgelistet ist.

Crontab

Um die Crontab Datei zu bearbeiten:
VISUAL=vim crontab -e
Crontab Datei Format:
Minute Stunde Tag Monat Wochentag Befehl

Categorías: Uncategorized