Category: Privat

  • Using an HTTP proxy when a VPN is used

    Background: When I connect to my University’s VPN service I need to use a HTTP proxy in order to access the WWW. I use GNOME and Network-Manager. The Openconnect plugin manages to establish the VPN connection nicely, but previously I had to enable the proxy in Firefox manually afterwards. This is my solution on how to set GNOMEs http proxy settings automatically when a VPN connection with the name “UniiHH” is established and works by using a script in /etc/Network-Manager/dispatch.d.

    This is my 10_enablevpnproxy (needs permission 755):

    #!/bin/sh -e
    # Script to set up the University of Hamburg web proxy when the Openconnect VPN connected
    # credits to https://wiki.ubuntuusers.de/NetworkManager/Dispatcher/
    
    VPN_CONNECTION_NAME="UniHH"
    USER="spaetz"
    
    # VPN connection started or stopped?
    case "$2" in
        vpn-up)
        active_vpn=$(nmcli -t --fields NAME con show --active|grep "${VPN_CONNECTION_NAME}" -q)
        if $active_vpn; then
            # VPN to UNI HH was started
        else
            #Irrelevant VPN started, do nothing
            exit 0
        fi
        # gsettings will fail if dbus is not launched with:
        # "dconf-WARNING **: failed to commit changes to dconf: Cannot autolaunch D-Bus without X11 $DISPLAY
        sudo -u "$USER" dbus-launch gsettings set org.gnome.system.proxy mode 'manual' 
        sudo -u "$USER" dbus-launch gsettings set org.gnome.system.proxy.http host 'proxy.uni-hamburg.de'
        sudo -u "$USER" dbus-launch gsettings set org.gnome.system.proxy.http port 3128
        ##gsettings set org.gnome.system.proxy.ftp host 'proxy.localdomain.com'
        ##gsettings set org.gnome.system.proxy.ftp port 3128
        sudo -u "$USER" dbus-launch gsettings set org.gnome.system.proxy.https host 'proxy.uni-hamburg.de'
        sudo -u "$USER" dbus-launch gsettings set org.gnome.system.proxy.https port 3128
        sudo -u "$USER" dbus-launch gsettings set org.gnome.system.proxy ignore-hosts "['localhost', '127.0.0.0/8', '10.0.0.0/8', '192.168.0.0/16', '172.16.0.0/12' , 'fc00::/8' , '*.fritz.box' ]"
            ;;
        vpn-down)
        # Disable all proxies on VPN shutdown, this might be to simple
        # for your case, it works for me.
        echo "VPN connection was stopped"
        sudo -u "$USER" dbus-launch gsettings set org.gnome.system.proxy mode 'none'
            ;;
    esac
    exit 0;

    The script is run as root by network-manger so, I needed to hardcode the user whose proxy settings I want to modify in the script. And admittedly the part about calling sudo -u $USER dbus-launch multiple times is quite clumsy and should be solved more elegantly. The problem is that gsettings needs to a) run as the user whose values we want to change and b) needs access to a running dbus-session or it will spit out:

    Cannot autolaunch D-Bus without X11 $DISPLAY

    Helpful links were: https://wiki.archlinux.org/index.php/proxy_settings https://wiki.ubuntuusers.de/NetworkManager/Dispatcher/ http://askubuntu.com/questions/645968/error-cannot-autolaunch-d-bus-without-x11-display

    P.S. Of course, sudo needs to be installed for this script.

  • Getting WiFi rtl8723be to work in Debian

    After crashing my previous laptop, I bought a HP 15-ba055ng that contains a rtl8723be Wifi card. However, under Linux the connection would become instable after a short while and refuse to reconnect. I needed to do a series of things to fix this:

    1. Apparently only 1 antenna is connected to the card while the card is configured to use a different antenna slot, leading to an abysmal signal. A new parameter was introduced in kernen 4.0.7 (or so) that lets on select the antenna in the kernel module.
      Create a file /etc/modprobe.d/rtl8723be.conf and enter

      options rtl8723be ant_sel 1

      (the default is 0). This let to a much better signal reception (as visible by doing iwlist scanning). But it still did not help, connection got refused after a while.

    2. Some other options need to be changed to make it work. Most people say that disabling sleep parameter fwlps (FW control power save, default 1) helped. So, that would be adding fwlps=0 to the above line. I did that.In addition some claim, that setting ips=0 or msi=1 has helped them to get a better reception. Try it, I use ips=0, but msi=1 seemed not necessary, so that my current options look like this: options rtl8723be ant_sel=1 ips=0 fwlps=0
    3. Some claim that windows fasstboot mode needs to be disabled in order to make WiFi work reliably. (in case you dualboot) However, I have not tried that yet, nor found it necessary.

    All this is on a Debian Jessie system. On a final note: I find it pretty sad that a laptop sold in 2016 has no 5Ghz capabilities. I did not even fact-check that before my purchase as it did not occur to me that this could be an issue.

    Relevant links I used for trouble-spotting (plus a ton of other links I forgot about):

    • https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1461174/comments/35
    • https://unix.stackexchange.com/questions/229221/rtlwifi-rtl8723befw-bin-wireless-stop-working-then-laptop-needs-to-reboot-to
    • http://askubuntu.com/questions/635625/how-do-i-get-a-realtek-8723be-wireless-card-to-work
    • https://ubuntuforums.org/showthread.php?t=2304607&page=4
    • https://bugzilla.kernel.org/show_bug.cgi?id=83641#c1
  • Barrierefrei und (kein) Spaß dabei in Hamburg

    Derzeit müssen wir den HVV mit einem Rollstuhl benutzen. Statt 1 Std Fahrzeit muss man fast 2 Std bis ins Krankenhaus Altona einplanen und die Fahrt ist die Hölle. Als Gesamtnote gibt es für den HVV per Rollstuhl, Rollator oder Kinderwagen ein klares mangelhaft.

    Haltestelle Meiendorfer Weg? Kein Lift, keine Rolltteppe, nur eine normale Treppe. Dabei ist hier das große Albertinenkrankenhaus mit angeschlossenem Seniorenheim.

    Umsteigen am Jungfernstieg? Kein Lift! Zweite Option: Umsteigen am Hauptbahnhof? 3 Lifte, ein extraweiter Fussumweg und man muss wissen wo man langlaufen soll, was keineswegs trivial (oder beschildert ist). Bei den ungepflegten, oft siffigen, Liften leuchtet teilweise das Wartungssymbol, sie sind megalangsam und es gibt lange Warteschlangen (15 Minuten vor einem Lift zu warten war nicht ungewöhnlich).
    Dritte Option: Umsteigen am Stephansplatz mit seinem neuen Lift (gut!). Bloss fand den meine Frau nicht weil es nur den einen an einem Eingang gibt. Am anderen Eingang auf der Seite Dammtor kein Hinweis auf Existenz oder Ort eines Liftes ist. Nach einem Fussmarsch zum Bahnhof Dammtor prangt an dessen einzigem Lift folgendes Schild:

    image
    Nicht das einzige Schild seiner Art

    und so geht das die ganze Reise weiter. HVV, barrierefrei, kein Spass dabei!

    Bitte: Wenn es Lifte gibt, dafür sorgen dass sie sauber sind und funktionieren. Wege beschildern, dass man diese Lifte auch findet. Die vielen wichtigen Stationen die noch gar nicht ausgebaut sind, schneller ausbauen. Momentan darf man jedenfalls in Hamburg keine Kinderwagen, Rollatoren oder schwere Koffer dabei haben wenn man U- oder S-Bahn fahren will.

  • Mein letztes Amazonreview

    Mein letztes Amazonreview wurde abgelehnt, es entspricht nicht den Amazon Guidelines. Ist es nicht ok wenn man zum Datenkabels für eine Sony-kamera von einem 3.Hersteller schreibt?:

    Funktioniert einwandfrei
     
    Auch wenn nicht vom Originalhersteller Sony, so funktioniert das Kabel hier tipp topp; Lieferzeit war akzeptabel. Warum sind Original Ersatzteile dermassen überteuert?

    Wenn Amazon meine Urteile nicht haben will, werde ich meine Meinung ab sofort eben für mich behalten.

  • Hamburger Service Qualität – 3 Geschichten

    Herr Scholz ist vielleicht zufrieden mit Hamburger Service-qualität. Ich bin es nicht. 3 Erlebnisse:

    Antrag auf Baumfällgenehmigung

    Abgeschickt im November 2014. Nachgefragt im Januar 2015 (Aktennummer genannt bekommen). Besuch eines Richters des Bezirksamtes Wandsbek im Juni 2015. Mündliche Zusage der Fällgenehmigung. Aktueller Stand Juli 2015: Bisher noch nichts Schriftliches erhalten. Wenn diese Tanne unseren Nachbarn aufs Dach fällt ist die Stadt dran.

    Beantragung eines neuen Reisepasses

    Das Bürgeramt “Walddörfer” nimmt Anträge für neue Reisepässe NUR mit vorigem Termin an (übers Internet buchbar). Im Juni 2015 versucht einen Termin zu bekommen, da der Pass im September abläuft. FÜR DAS GESAMTE RESTLICHE JAHR GAB ES KEINEN TERMIN MEHR! Nicht gelogen! Ausserdem macht das Bürgeramt im Sommer 6 Wochen zu. Die Begründung auf unsere Nachfrage: Wegen erhöhtem Andrang in dieser Zeit macht unser Bürgeramt zu weil die Angestellten in die zentralere Bürgerämter versetzt werden. Keinen Termin für einen Reisepassantrag in den nächsten 7 Monaten! ECHT??

    Integrationsamt

    Das ist überhaupt die härteste Geschichte. Muss aber noch geschrieben werden…

    Anfang April einen Antrag auf Verlängerung der Integratinsförderung gestellt. Fast einen Monat später eine Eingangsbestätigung bekommen. (Ich kriegs nicht mehr zusammen, aber es war unschön glaubt es mir…)

  • mmh, Pasta!

    Pasta, Basta!
    Pasta, Basta! ©Ulrike Spaeth

    Oliver liebt Nudeln, und er weiss genau dass man “Körner” zu “Mehl” mahlt, aus dem man “Teig” macht. Und dass Pasta nicht nur aus der Tüte kommen, sondern auch aus Teig gemacht werden können, weiss er jetzt auch.

  • Citizenship Duties

    Although being a Swiss secondo (a 2nd generation foreigner), Oliver seems to take his German citizenship duties pretty seriously. (in stark contrast ot his non-voting parents)

    Secondos do seem to engage politically!
    Secondos do seem to engage politically!
  • Raser von der Strasse!

    Ordnungsbusse für Raser

    100km/h (statt erlaubter 80)= 240 Franken
    Nicht ich sondern Almut als Kriminelle= unbezahlbar
  • Auf dem Weg nach Spiekeroog

    Alternative Verkehrsmittel geniessen hier Rechte!
    Alternative Verkehrsmittel geniessen hier Rechte!
    Lock them Up!
    Lock them Up!
  • Snowshoeing

    Flumserberg Almut’s friend Gwen visited us last week. As they wanted to see some real snow, we did a snowshoe-hike in Flumserberg. Our neighbor Rita joined as well.

    It had been raining in Zurich all week, but this one day was beautiful. Sun, blue sky (with fog underneath in the valley), and powdery snow. It was great fun.

    Gwen and Dave returned to Manchester on Sunday. Hope they’ll get some snow up there too.