aptitude update: Segmentation Fault

In case i forget again…

Problem on Ubuntu 10.04 (Lucid Lynx) x64:

$ sudo aptitude update
Hit http://security.ubuntu.com lucid-security Release.gpg
Ign http://security.ubuntu.com/ubuntu/ lucid-security/main Translation-en_US
Ign http://security.ubuntu.com/ubuntu/ lucid-security/restricted Translation-en_US
...
Hit http://us.archive.ubuntu.com lucid-updates/multiverse Sources
Reading package lists... Done
Segmentation fault

Solution:

$ sudo rm /var/cache/apt/*.bin
$ sudo apt-get update

Aptitude should now work again.

“The MSI ” failed” when uninstalling VMware Workstation 8 on Windows 7

This has bugged me for 2 days now. There are many forum threads, KB articles and guides out there that point to the right direction, but none of them worked out for me. However, today I finally got rid of Workstation 8!

And here is what I did:

First I got the VMware installer from the VMware Homepage.
Then I opened a command prompt as a local administrator. I switched to the location of the installer, and started it in “Uninstall mode”.

C:\>cd C:\Downloads
C:\Downloads>VMware-workstation-full-8.0.1-528992.exe /x

On the dialogue I choose “Repair”. After the installer finished his work and my machine has rebooted, I was able to uninstall VMware Workstation. iWin!
Questions? Comments?

Keeping SSH-Connections open

while true; do date; sleep `rand -s $(date +%N) -M 30`; done

From `man rand`:

-s number
       the seed for the random numbers generator (default time(NULL))
-M, --max number
       the limit of the random numbers (default 32576)

By setting the seed to `date +%N` (nanoseconds) we can avoid getting multiple zeros out of rand.

How to play Minecraft via Proxy

If you google “Minecraft via proxy”, you’ll find this one:

java -Dhttp.proxyHost=yourproxyserver.com -Dhttp.proxyPort=1234 -jar minecraft.jar

However, this won’t work for current Versions. Reason: HTTPS. Solution:

java -Dhttp.proxyHost=yourproxyserver.com -Dhttp.proxyPort=1234 -Dhttps.proxyHost=yourproxyserver.com -Dhttps.proxyPort=1234 -jar minecraft.jar

Eh voila :D

(Substitute yourproxyserver.com and 1234 with your proxy server and port number)

Note for Windows Users: For Win, you have to type “Minecraft.exe” instead of “minecraft.jar” – the Rest is exactly the same!

Update: To pass proxy authentication, add this:

-Dhttp.proxyUser=someUserName -Dhttp.proxyPassword=somePassword

iOS 4 Mobile Data Fix – Fix my iPhone!

Das installierte Swisscom-APN-Profil

Bei mir (und vielen andern auch) verweigerte nach dem Upgrade auf iOS4 die Mobile Datenübertragung den Dienst. Werder 3G noch EDGE waren gewillt, auch nur ein Bit zu übertragen.

Schuld daran sind offenbar falsche APN-Daten.

Für Swisscom-Benutzer habe ich nun dafür ein Konfigurationsprofil erstellt:

Einfach mit dem iPhone http://wona.ch/swisscom-apn.mobileconfig ansurfen, das Profil installieren und gut ist. (Bei Bedarf ev den Flugmodus an- und wieder aussschalten)

Auf Anfrage kann ich auch Profile für andere Mobilfunkanbieter bereitstellen!

Hinweis: Auf einigen iPhones kann man die APN-Daten auch von Hand setzen. Sie sind unter Einstellungen -> Allgemein -> Netzwerk -> “Mobile Daten” zu finden.

Swisscom APN Settings
APN: gprs.swisscom.ch
Benutzername: leer
Passwort: leer
Proxy: leer
iPhone-Profil: http://wona.ch/swisscom-apn.mobileconfig

Orange APN Settings
APN: internet
Benutzername: leer
Passwort: leer
Proxy: leer
iPhone-Profil: http://wona.ch/orange-apn.mobileconfig

Fonic APN Settings
APN: pinternet.interkom.de
Benutzername: leer
Passwort: leer
Proxy: leer
iPhone-Profil: http://wona.ch/fonic-apn.mobileconfig

Congstar APN Settings
APN: internet.t-mobile
Benutzername: t-mobile
Passwort: tm
Proxy: leer
iPhone-Profil: http://wona.ch/congstar-apn.mobileconfig

Tele.Ring APN Settings
APN: web
Benutzername: web@telering.at
Passwort: web
Proxy: leer
iPhone-Profil: http://wona.ch/telering-apn.mobileconfig

E-Plus APN Settings Updated
APN: internet.eplus.de
Benutzername: eplus
Passwort: gprs
Proxy: leer
iPhone-Profil: http://wona.ch/eplus-apn.mobileconfig

A1
APN: a1.net
Benutzername: ppp@A1plus.at
Passwort: ppp
Proxy: leer
iPhone-Profil: http://wona.ch/eplus-apn.mobileconfig

Klarmobil
APN: internet.mobilcom
Benutzername: leer
Passwort: leer
Proxy: leer
iPhone-Profil: http://wona.ch/eplus-apn.mobileconfig

MySQL Administrations-Einsmaleins

Auflisten von Schemas, Tabellen, Grants etc:
[cc lang="sql"]show schemas;
show tables;
show grants for user@localhost;[/cc]

Rechte hinzufuegen
[cc lang="sql"]grant all privileges on schema.* to username@localhost identified by ‘passwort’;[/cc]

Rechte entfernen
[cc lang="sql"]– einzeln
revoke all privileges on schema.* from user@localhost;
– alle rechte
drop user user@localhost;[/cc]

Zugriff auf VMware Server via SSH Tunnel

Ausgangslage

VMware Server auf HostA. Wir arbeiten am Client auf HostB. Zugriff von HostB auf HostA nur via SSH moeglich.

Wir moechten nun von HostB aus aufs Webinterface UND auf die Remotekonsole auf HostA zugreifen.

Lösung

Zum Glueck klappt das ganze vie SSH-Tunnels. Man muss nur wissen welche Ports das sind :)

  • 8222 - Webinterface HTTP (0der gem. Config)
  • 8333 - Webinterface HTTPS (0der gem. Config)
  • 902 - Remote Console (0der gem. Config)
  • 8307 - ?Soap?; Wird auch fuer die Remote Console gebraucht.

Das wars, nun kann via http://localhost:8222/ auf die VMware Konsole zugegriffen werden!

Firefox blockiert Ports – Was man dagegen tun kann

Problem

Man will mit Firefox ein Webinterface/SSH-Tunnel/whatever auf Port 6000 (oder sonst irgendeinem Port) ansteuern. Doch Firefox kontert mit einer haesslichen Fehlermeldung:

Fehler: Port aus Sicherheitsgründen blockiert
Die aufgerufene Adresse fordert einen Port, der normalerweise nicht zum Browsen im Web verwendet wird. Die Anfrage wurde zu Ihrem Schutz abgebrochen.

Lösung

  1. Die Firefox-Konfiguration oeffnen (in der Adressleiste [cci]about:config[/cci] eingeben)
  2. Rechtsklick -> Neu -> String
  3. Als Eigenschaftsname wird [cci]network.security.ports.banned.override[/cci] angegeben
  4. Als Wert wird der entsprechende Port (hier: 6000) angegeben
  5. Fertig!

Quelle: Mozilla Port Blocking @ mozilla.org