Monday, December 7, 2020

L2TP with Raspberry PI

Make sure the debug dump option is not used -- otherwise it will crash pppd.

/etc/ppp/options.l2tpd.client:


ipcp-accept-local

ipcp-accept-remote

refuse-eap

require-mschap-v2

noauth

mtu 1200

mru 1200

noipdefault

debug

defaultroute

usepeerdns

connect-delay 5000

name <username>

password <password>


/etc/ipsec.conf:


# ipsec.conf - strongSwan IPsec configuration file


# basic configuration


config setup

  # strictcrlpolicy=yes

  # uniqueids = no


# Add connections here.


# Sample VPN connections


conn %default

  ikelifetime=60m

  keylife=20m

  rekeymargin=3m

  keyingtries=1

  keyexchange=ikev1

  authby=secret

  ike=3des-sha1-modp1024!

  esp=3des-sha1!


conn myvpn

  keyexchange=ikev1

  left=%defaultroute

  auto=add

  authby=secret

  type=transport

  leftprotoport=17/1701

  rightprotoport=17/1701

  right=<IP address>

Thursday, March 26, 2020

Overscan monitor issues on HP 2509m

If you're noticing that you can't see the title bar and the bottom status bar, it's because the overscan settings need to be changed.

The instructions at the bottom of this blog post (https://ishan.co/external-monitor-underscan) worked for me:

 1. Make a backup of the current file:
 2. cp /var/db/.com.apple.iokit.graphics /tmp/.com.apple.iokit.graphics.backup
 3. With the “troubled” monitor connected, open Display Preferences, and change its settings. For example, I changed the rotation.
 4. Run the “diff” command to see what had changed in that file after you made the changes:

56a57,58
>   framebuffer-rotation
>   0
58c60
<   10000
---
>   9000

5. I derived 9000 from -10% less overscan, which works great!

The process is automated in this Bashmatic script! (https://github.com/pioneerworks/lib-bash/blob/master/lib/osx.sh#L41-L53)