Friday, August 13, 2010

/etc/alternatives/-->Debian alternatives system

Where is location of java on ubuntu?
Finding out the answer is not just use "whereis java" or "which java":

The alternatives directory lead to the alternative concept. when you type java, it could refer to a different real java location if a new version has just installed.
Eg. I was using java 5, typing java would start JVM 5; after installing java 6, type java would start JVM6.

Intuitively, I think having this extra level of indirection is useless...

Saturday, August 7, 2010

burst.net vps outrage counter

I have purchased the cheapest VPS from burst.net and I think it is the cheapest around.
However, there had been at least three outrages during the last three month. When I say at least three outrages. Because each time I type top, the uptime is different, there had been three occasions.

Now I am going to keep a record of outrages, every time when i type top, if system had been done, i would put a record here.

08/Aug/10 top - 04:42:16 up 3 days,

swap on VPS(OpenVS)

I have problem starting java virtual machine on my VPS. The cause is there is not enough heap to be allocated for JVM.

$ java
Error occurred during initialization of VM
Could not reserve enough space for object heap
Could not create the Java virtual machine.
The fix for me is that my java is OpenJDK, so I uninstalled it and reinstalled the Sun implementation and fixed the problem.



Related stuff:
This came down to my VPS has only 500mb memory. I want to try if adding more swap can solve the problem. And ended up finding out Swap is not allowed on OpenVS. from this link. http://forums.vpslink.com/linux/1567-how-create-swapfile-your-vps.html

When I tried to create swap file according to https://help.ubuntu.com/community/SwapFaq  I get:

   swapon failed: Operation not permitted
Burstnet suggested me to increase my memory.
I would want to if there are other solutions..