IIS6.0 Temporary 307 redirect

To redirect a file or site without losing POST data you have to do some configuration in the IIS6.0 metabase to get it working. It took me some time to figure out, but when you know it it’s quite simple.

1. Install the metabase explorer from te IIS6.0 resource kit. Get it here

2. Fire up IIS Manager and rightclick on the site or virtual directory you want to redirect using a 307 Temporary redirect. Choose properties and open the tab Home Directory.

3. Choose “A redirection to a URL” and fill in the new URL. In my example i wanted to redirect traffic from http://example.test.com/ to http://new.test.com/ which is located on a new server. Click OK to Apply

4. Open up the metabase explorer and navigate to [servername] -> LM -> W3SVC -> [SiteID] -> root. There should be a entry whith the name “HttpRedirect” (ID 6011). The data of this entry should be the url you entered in step 3, in my example http://new.test.com. Doubleclick the entry and add “,TEMPORARY” at the end, http://new.test.com,TEMPORARY in my case, and click OK.

5. Now, if you do a post to http://example.text.com/process.aspx it should redirect to http://new.text.com/process.aspx without losing the POST Data. Remember, if you change Home Directory settings via IIS manager, it removes ,TEMPORARY and you have to re-add it.


Posted in IIS, Windows | Leave a comment

New-MailboxImport and ExportRequest not available after SP1 install

When i upgraded exchange 2010 from SP0 to SP1 the New_MailboxImport and Exportrequest where not available which are new in SP1. The following command can fix this (for the administrator user):

New-ManagementRoleAssignment –Role “Mailbox Import Export” –User Administrator


Posted in Exchange 2010 | Tagged , | Leave a comment

Outlook on Exchange 2010 server: No EMC permissions

This problem cost me some time to figure out: I configured a new profile in outlook 2003 using credentials of a testuser to test something. Later i tried to start the exchange managment console (emc) and found all my permission where gone. Apparently the credentials from outlook 2003 conflict with emc credentials and emc uses the outlook 2003 credentials.

To fix this you have to remove the credentials from the credential manager found in the control panel. After that, emc works again.


Posted in Exchange 2010, Windows | Tagged , , | Leave a comment


For a while a wanted to have a LAN to LAN vpn between my own server and the server somewhere else. This would be usefull for backups and other stuff. I wanted to create a situation that clientA on network A could connect to clientB on network B, see the image below.

Network drawing

So i had some experience with setting up a OpenVPN server for clients but never LAN-to-LAN, it requires some special options to work which i will explain below. The connection will be made from ServerA to ServerB, so ServerA is the client and ServerB is the Server.

The OpenVPN config of ServerB looks like this:

port 1194
proto tcp
dev tun
ca ./easy-rsa/2.0/keys/ca.crt
cert ./easy-rsa/2.0/keys/server.crt
key ./easy-rsa/2.0/keys/server.key 
dh ./easy-rsa/2.0/keys/dh1024.pem
client-config-dir /etc/openvpn/ccd/
ifconfig-pool-persist ipp.txt
push "route"
keepalive 10 120
status openvpn-status.log
log-append  /var/log/openvpn.log
verb 3

Notice the client-config-dir setting. This containts a file with the same name as the client. This is necessary for routing client to client, this site explains this option. The file looks like this:


The config name on the client and ccd filename must be the same. On serverB in the ccd dir i have a file ServerBtoServerA and the config on ServerA is named ServerBtoServerA.conf/crt/key.

We also need to enable ip4 forwarding and nat forwarding. I have added the following lines to my firewall script which runs at server boot:

echo "checking if we need to enable IP forwarding"
IPFWDCHK="`cat /proc/sys/net/ipv4/ip_forward`"
if ( [ "$IPFWDCHK" != "1" ] ); then
  echo "IP forwarding not enabled yet enabling forwarding now"
  echo 1 > /proc/sys/net/ipv4/ip_forward
echo "Setting NAT forwarding"

That is all the config needed for ServerB. Below you can find the OpenVPN config for ServerA (the client):

dev tun
proto tcp
remote 1194
ca ./config/ServerBtoServerA/ca.crt
cert ./config/ServerBtoServerA/ServerBtoServerA.crt
key ./config/ServerBtoServerA/ServerBtoServerA.key
verb 3

This server only needs IP forwarding, also done in the firewall script at server boot.

echo "checking if we need to enable IP forwarding"
IPFWDCHK="`cat /proc/sys/net/ipv4/ip_forward`"
if ( [ "$IPFWDCHK" != "1" ] ); then
  echo "IP forwarding not enabled yet enabling forwarding now"
  echo 1 > /proc/sys/net/ipv4/ip_forward

This is all the configuration that needs to be done on the servers. The only thing left to do is add routes on the client. On networkB the clients need the following routes

route add MASK
route add MASK

And the routes for networkA:

route add MASK
route add MASK

Ubuntu server Ubuntu 9.04
OpenVPN 2.1_rc11 i486-pc-linux-gnu

Ubuntu server 10.04.1 LTS
OpenVPN 2.1.0 x86_64-pc-linux-gnu


Posted in Linux, OpenVPN, Ubuntu | 3 Comments

ORA-01017 invalid username/password; logon denied

I was having some trouble with an java application connecting to a oracle 9i database. The problem was that the application sometimes gave the following error:

ORA-01017: invalid username/password; logon denied

The developer of the application could not find the cause of this error so i started some testing myself. I wrote a simple .net console app to test the connection. It gave the same problems: Sometimes a connection success and sometimes logon denied.

OracleConnection conn = null;
                conn = new OracleConnection(
                "Data Source=(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=myserver.com)(PORT=1521))(CONNECT_DATA=(SID=MySID)));User Id=MyUserId;Password=MyPassword;");
                Console.WriteLine(DateTime.Now + ": Connection Success! Version: " + conn.ServerVersion);
            catch (OracleException ex)
                Console.WriteLine(DateTime.Now + ": Oracle Error: " + ex.Message);
            catch (Exception ex)
                Console.WriteLine(DateTime.Now + ": Other Error: " + ex.Message);
                if (conn != null)

After some playing around with the connectionstring i found out that the following string did not give any problems:

"Data Source=(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=MyServer.com)(PORT=1521))(CONNECT_DATA=(SERVICE_NAME=MySid)));User Id=MyUserId;Password=MyPassword;"

I changed SID= to SERVICE_NAME= and this solved the problems.

Posted in .net, Oracle | 1 Comment

Install VMware Server 2.0.2 on Ubuntu 10.04 or higher

Today i’ve decided to upgrade my server from Ubuntu 9.10 Server (64bit) to 10.04 LTS. After the upgrade Vmware server (2.0.1) wasn’t working anymore. This is usually fixed by running vmware-install.pl (it rebuilds the modules). Unfortunately the script generated build errors:

make[2]: *** [/tmp/vmware-config1/vmmon-only/linux/driver.o] Error 1
make[1]: *** [_module_/tmp/vmware-config1/vmmon-only] Error 2
make[1]: Leaving directory `/usr/src/linux-headers-2.6.32-26-server'
make: *** [vmmon.ko] Error 2
make: Leaving directory `/tmp/vmware-config1/vmmon-only'
Unable to build the vmmon module.

After some googling i found this page via the Ubuntu help page. If you use this script to install Vmware Server it compiles just fine. Just execute the script and provide the directory containg the tar.gz file as argument. For example:

./vmware-server-2.0.x-kernel-2.6.3x-install.sh /usr/src/

/usr/src/ contains VMware-server-2.0.2-203138.x86_64.tar.gz. I used this script to install Vmware Server 2.0.2-203138 64bit.

Posted in Linux, Ubuntu, Vmware | 2 Comments

New phone

I’ve got a new phone with Android which has a WordPress app. I am posting this to test if it works. So if you can read this it works :D.

Posted in General | Tagged | 6 Comments

New tuser.nl online

The old site was never finished (made it myself) and that’s why i installed WordPress. I don’t think i will blog a lot, but you never know ;). I’ve never used WordPress but i like it already: easy install, easy to use and nice themes.

Posted in General | Leave a comment

Hello world!

Welcome to WordPress. This is your first post. Edit or delete it, then start blogging!

Posted in General | 1 Comment