I installed the following packages: https://market.android.com/details?id=de.schaeuffelhut.android.openvpn.installer https://market.android.com/details?id=de.schaeuffelhut.android.openvpn
Then I discovered that the openvpn binary was not completely okay, especially the ifconfig parameter gave some unexpected errors on correct configurations. So I downloaded this file (mirror), unzipped it, and put it on the location of the original openvpn binary.
On my Fedora 15 laptop, I'm almost always connected to several VPNs simultaneously. One VPN to my office or to my home (depending on where I am), one to the data center, one to a customer. These connections all have their own DNS server with their own suffix.
To make all dns suffixes working, I created a script that redirects all outgoing DNS traffic to dnsmasq running on localhost, which in turn forwards all requests for .lan to 192.168.15.254 and all requests for .gl to 192.168.1.254.
The script was put in /etc/NetworkManager/dispatcher.d/10-DNS:
if [ -e /var/run/dnsmasq.localhost ]; then
cat /proc/`cat /var/run/dnsmasq.localhost`/cmdline |grep dnsmasq >/dev/null 2>/dev/null && \
kill `cat /var/run/dnsmasq.localhost`
fi if [ "$2" == "up" ]; then
cp /etc/resolv.conf /etc/resolv.conf.dhcp
echo nameserver 127.0.0.1 > /etc/resolv.conf
echo domain $DHCP4_DOMAIN_NAME >> /etc/resolv.conf
echo search $DHCP4_DOMAIN_NAME >> /etc/resolv.conf
/usr/sbin/dnsmasq -C /dev/null -r /etc/resolv.conf.dhcp --server=/gl/192.168.1.254 \
--server=/lan/192.168.15.254 --bind-interfaces --listen-address 127.0.0.1 \
--pid-file=/var/run/dnsmasq.localhost
fi
Once I had to fix resolv.conf manually when I connected my laptop to my Samsung Galaxy SII as well. This may mean I need to improve the script some day, but for the time being, it works good enough.
As I may have mentioned before VMWare Data Recovery is not my favorite backup solution. I'm pleased to report that VDR2.0 is a LOT better than 1.x ever was. Since upgrading, my backups haven't failed once. And it even has a built-in email reporting system.
Unfortunately, this mail system isn't too customizable. Since I'd like my subjects to be clear they need extra attention, I made a little fix. This script is started by socat.
Install socat
Socat handles incoming connections on port 25 for me. rpm -i http://download.fedora.redhat.com/pub/epel/5/x86_64/socat-1.7.1.3-1.el5.x86_64.rpm
Change the outgoing mailserver to localhost and test it. If everything's ok, you'll get a mail with 1 warning and 2 error-message, as the test-mail doesn't contain the fields that indicate no backups failed.
Security
The iptables firewall does not allow incoming connections to port 25, so you will not become an open relay using this script.
This page contains raw notes and/or untested notes. They may be incorrect, parts may be missing or the article may contain parts that are not needed and more. An update will probably follow some day.
To print labels on my Dymo, I'm running a custom built webapp that allows users in the entire network to print. It has a memory, prints KIX-codes (that make it easier for the postal service to process letters) and prints a logo.
In my setup, the server generating the logo and the server printing it are two different machines. But even if they weren't, this method keeps the webserver in its SELinux confinement.
Requirements
We need some tools, install the packages with the following command: yum install ripmime
Add the printer to CUPS
Add the printer to CUPS, so you can spool jobs to it. I'm not explaining this part.
Generate a label
Using PHP's GD extensions I generate a new image with width=1010 and height=540. Using this high resolution results in good quality prints.
The image is exported as a .png file, named [something-random].dymo.png and transported to the printserver through a special email-address.
Prepare the mailserver
I'm running a Postfix mailserver. This mailserver has a special address that accepts print jobs, extracts the files and prints them.
In /etc/postfix/master.cf, add the following lines:
printer unix - n n - - pipe
flags=F user=nobody argv=/etc/postfix/bin/printserver $sender$recipient
printer unix - n n - - pipe
flags=F user=nobody argv=/etc/postfix/bin/printserver $sender $recipient
Then in /etc/postfix/transport, we put:
printer.geeklab.info printer:
printer.geeklab.info printer:
The domain printer.geeklab.info doesn't necessarily need to exist, as long as you smtp right to this mailserver.
Finally in /etc/postfix/main.cf we enable the transport maps, if that hasn't been done before:
transport_maps = hash:/etc/postfix/transport
transport_maps = hash:/etc/postfix/transport
Write a script
In master.cf we start the script /etc/postfix/bin/printserver. Add this content to said script:
The script we just write uses ripmime and lpr and runs as the Postfix pipe user. To allow the Postfix pipe program to use these tools, run postfix_pipe_t in a permissive state: semanage permissive -a postfix_pipe_t Always remember to manage SELinux, not disable it.
Ubuntu/Debian
I'm running RedHat-based software on all of my machines. Above information may be useful for Ubuntu/Debian users, but it's not tested and I'm not supporting it.
Servers: RedHat Enterprise Linux/CentOS is more suitable for servers, as there's a lot of professional level support available. I think that's important, because if I say, get a car accident, I want the servers to be managable by another professional.
Desktops/Laptops: RPM packages are pretty exchangable between RedHat-based platforms. That's a good reason to run Fedora on the desktop.
To allow OpenVPN to run on a different port than 1194, you'll need to tweak your SELinux permissions: /usr/sbin/semanage port -a -t openvpn_port_t -p udp 61616
Open the file /data/local.prop - this file may or may not exist
Add the following line to the file: ro.camera.sound.forced=0
Reboot the phone
Now, if the phone is silent, the camera will be silent. But if the phone's volume is not turned down, you will still hear the camera. You can silence the camera even more by removing the sound files. Login through some kind of shell and type:
mount /system -o remount,rw
cd /system/media/audio/ui
mv Shutter_01.ogg Shutter_01.ogg-original
mv camera_click.ogg camera_click.ogg-original
mv camera_click_short.ogg camera_click_short.ogg-original
cd /
mount /system -o remount,ro
On my phone, the camera used to do a focus-beep, followed by a shutter-click. I got it to shut up the shutter, but I couldn't disable the focus. So if I really don't want the subject of the photo to hear me, I'll just turn down the volume.