16 07, 2012

Adding a new storage-device

By | 2017-10-12T10:28:22+00:00 July 16th, 2012|Uncategorized|0 Comments

This guide covers how to add a new storage device (such as a platter or a solid state drive) to your Linux machine. All work is done from the command-line. Selecting the right storage device This guide does not cover selecting the right model or kind of storage device. Plugging the device into the computer This guide does not cover how to plug the device into the computer. What's the device name? Now that the [...]

26 04, 2012

Bukkit read timed out

By | 2017-10-11T13:24:56+00:00 April 26th, 2012|Uncategorized|2 Comments

Are you perhaps familiar with the two phrases: read timed out connection reset Since recently I have become quiet familiar with them myself and in this post I will describe how to get rid of them. Reason 1 - Rouge plugin Reason Description Minecraft is mainly single-threaded. The main thread has a formal name when you look in the source code. It is called "Server thread". If a plugin isn't coded correctly the "Server thread" [...]

8 10, 2011

Searching for bukkit memory leaks

By | 2011-10-08T15:01:39+00:00 October 8th, 2011|Uncategorized|3 Comments

In this post I will describe how to search for memory leaks in your bukkit minecraft SMP server. Getting a heap dump The first step is to obtain a java heap dump to inspect. This is a nice article on the subject: http://blog.emptyway.com/2007/04/02/finding-memory-leaks-in-java-apps/ That article describes some different ways to obtain a heap dump. If you are using a JDK version of java instead of an JRE, you have some neat tools at your disposal [...]

1 10, 2011

Persistent ramdisk with tmpfs and rsync

By | 2012-10-21T08:15:22+00:00 October 1st, 2011|Uncategorized|4 Comments

Minecraft reads and writes a lot from disk. In order to speed this up we can store the files in memory instead. If you google "minecraft tmpfs" you will find a lot of info on this. The main issue is that ramdisks created using tmpfs are temporary. The content is wiped on a system reboot. The script I created takes care of persisting the ramdisk. It is a general solution that can be used for [...]

27 06, 2011

Quick link to edit the hosts file on windows 7

By | 2011-06-27T11:22:14+00:00 June 27th, 2011|Uncategorized|0 Comments

If you edit your hosts-file often it can be practical to have a shortcut that opens the file in a texteditor. This is how you would create such a shortcut on windows 7: Create a normal shortcut to the program notetad on your desktop. Edit the target of the link by adding "%SystemRoot%\system32\drivers\etc\hosts" at the end. That way the target of the link will be something like: "%windir%\system32\notepad.exe %SystemRoot%\system32\drivers\etc\hosts". When you use the link you [...]

21 06, 2011

Creating 301 redirects between many pairs of URLs

By | 2011-06-21T11:17:01+00:00 June 21st, 2011|Uncategorized|0 Comments

I recently upgraded a website. The website consisted of static html documents and some simple php scripts. I transformed it into a wordpress blog. In this process every url was changed. In order to keep the pagerank and not break any inlinks I created 301 redirects between them. If there had been an obvious pattern between the old and new urls this would have been a simple task. For example lets say urls of the [...]

4 04, 2011

Reading browser saved passwords

By | 2011-04-04T17:01:00+00:00 April 4th, 2011|Uncategorized|0 Comments

Assume you forgot you gmail password but you allowed the browser to remember it for you. You can still log in as the browser fills out the password for you, but you can not find out what the password is as all you see is some stars or dots. The situation is cool for now, as you can log in, but as soon as you clear your browser cache the brower will forget the password [...]

23 03, 2011

Creating a Minecraft SMP Bukkit Server

By | 2012-02-19T21:00:58+00:00 March 23rd, 2011|Uncategorized|0 Comments

Get a VPS In the long run you should use a VPS instead of hosting on your own computer. This way you can turn of your computer at home and still be able host the server 24/7. The server should have at least one gigabyte ram. The server should not use OpenVZ for virtualization. It would work but you might face memory allocation issues. You should go for Xen virtualization. In the continuation I will [...]

23 03, 2011

My server setup checklist

By | 2015-09-08T15:18:51+00:00 March 23rd, 2011|Uncategorized|1 Comment

This is the checklist I follow when I create a new Linux Debian Server. The goal is a safe shared hosting environment where every user can ssh to the server but no user can see the content of another users home folder. Setup language You need to setup language if you get error messages like this one [crayon-5a8898724340f499968186/] Run the following two commands to solve the issue: [crayon-5a88987243415036453538/] File Permissions Files should be restricted to [...]

8 02, 2011

I like .gitconfig

By | 2011-03-28T11:43:09+00:00 February 8th, 2011|Uncategorized|0 Comments

If you use git from the command line you can improve your usage experience by altering your git config file wich is called ".gitconfig". Find that file in your home folder. You can for example turn on color and add some handy shortcuts. Here is what I use: [crayon-5a8898724370d140185048/] It is also possible to alter the gitconfig from the commandline. The settings above would then look like this: [crayon-5a88987243712150490816/]