Mostrando entradas con la etiqueta tips and tricks. Mostrar todas las entradas
Mostrando entradas con la etiqueta tips and tricks. Mostrar todas las entradas

domingo, 13 de marzo de 2011

Add t1.micro support to ElasticFox


A lot of people, including me depend on the ElasticFox firefox plugin to interact with Amazon Web Services and its easy to see why. It has GUI support for almost everything that you'd need to interact with AWS.
However, it seems that, as of today, ElasticFox has yet to add support for the t1.micro instances that Amazon introduced recently.

Well, I just couldn't stand waiting for the latest release, and if you're just as impatient, you might want to try the following:

  1. Check out the elasticfox code from svn:
    svn co https://elasticfox.svn.sourceforge.net/svnroot/elasticfox/trunk elasticfox
  2. Open up
    trunk\src\chrome\content\ec2ui\newinstancesdialog.js
    in your favorite editor. Go to line 247 and add the following:
    if (this.image.rootDeviceType == "ebs") {
    typeMenu.appendItem("t1.micro", "t1.micro");
    }
Now, its time to build the code into a plugin.
Download and install the firefox extension developer plugin
Open Firefox. Go to Tools->Extension Developer->Extension Builder, browse for your working directory and hit 'Build extension'.
You can then drag this resulting .xpi file into the browser window to install the plugin

You should now be able to select a t1.micro instance for a corresponding valid AMI

lunes, 14 de diciembre de 2009

Memorizing Design Patterns - the fun way

Just stumbled upon a wonderful way to memorize stuff at memorize.com

Say you want to test yourself or just plain want to memorize Design Patterns for example, just head over here and discover how fun it can be.

Design Patterns
Core JEE Design Patterns

I must admit, this is a really unique way of using a wiki!


*I am in no way affiliated with memorize.com. I just happen to like their stuff

martes, 21 de abril de 2009

Damn Small Linux: Install files with .dsl extension

The DamnSmallLinux live CD/USB allows you run DSL in memory. It also allows you to run apps that you download from the MyDSL repository. If you install DSL to HDD/USB then you'll want to have these apps permanently on your system. You can do this easily.
If you look carefully, the MyDSL repository, contains a lot of files (apps) with the .dsl extension.


A .dsl extension file is nothing but a compressed archive in the tar-gzip format.


All you need to do is:
  1. download the .dsl file to any location (lets say /home/dsl)
  2. cd /
  3. tar -zxvf /home/dsl/.dsl
and you're through!

miércoles, 20 de agosto de 2008

Improve windows networking (especially if hosting webservers)


First of all, I forgive you for having to use windows to host your web server :)

Now that thats out of the way, here's how you speed up networking performance on windows (especially if you happen to host Apache, IBM HTTP Server, or any other web server on a windows machine)

Create a .reg file (eg: perf.reg) with the contents that follow:


Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters]
"MaxUserPort"=dword:00008000
"TcpTimedWaitDelay"=dword:0000001e
"TcpMaxDataRetransmissions"=dword:00000005

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters\Interfaces]
"TcpAckFrequency"=dword:00000001
"TcpDelAckTicks"=dword:00000000

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\AFD\Parameters]
"EnableDynamicBacklog"=dword:00000001
"MinimumDynamicBacklog"=dword:00000020
"MaximumDynamicBacklog"=dword:00001000
"DynamicBacklogGrowthDelta"=dword:00000010
"KeepAliveInterval"=dword:00000001

Double click on the file to merge its contents into the registry. Restart the machine.
You're done.


viernes, 13 de junio de 2008

WebSphere Portal Server migration Issues - Part I

You've got WebSphere Portal Server 6.x comfortably hooked up to Oracle / Oracle RAC and then someone wants you to move to another Oracle installation (on a different machine possibly).

IBM has told you that all you need to do is export your database and import it into the other installation.


You're confident. You try it. You do a full=y export and do a full=y import into the new database, change your datasources to point to the new oracle instances, check all the connections and everything is fine.... start your server .... and BOOM!



Part I - tells you about this stack trace that you receive:

Unable to locate default library category Error while calling a function retrieveItemsByCMId of PLS data manager.
Unable to locate webContent library category Error while calling a function retrieveItemsByCMId of PLS data manager.
javax.jcr.RepositoryException: Error while calling a function retrieveItemsByCMId of PLS data manager.

What do you do Jack? Don't raise a PMR for one. The answer is simple for this one.
You're DBA has forgotten to check the tablespaces that were involved with the Oracle Instance for the Portal.

You'd need to tell the DBA (should you be so unlucky to have one who couldn't figure this out) to create the following tablespaces BEFORE the import.:


# These are for Oracle RAC. For plain, standalone Oracle, you'd specify the datafile location after the 'datafile' keyword

create tablespace ICMLFQ32 datafile size 300M autoextend on
next 10M maxsize UNLIMITED extent management local autoallocate;


create tablespace ICMLNF32 datafile size 25M autoextend on
next 10M maxsize UNLIMITED extent management local autoallocate;


create tablespace ICMVFQ04 datafile size 25M autoextend on
next 10M maxsize UNLIMITED extent management local autoallocate;


create tablespace ICMSFQ04 datafile size 150M autoextend on
next 10M maxsize UNLIMITED extent management local autoallocate;


create tablespace ICMLSNDX datafile size 10M autoextend on
next 10M maxsize UNLIMITED extent management local autoallocate;


Run the database import again and you'll be fine.


miércoles, 28 de mayo de 2008

WebSphere Process Server / Portal Server with Oracle RAC

If you're thinking that you'll get out-of-the-box Oracle RAC support for an IBM WebSphere Process Server or Portal Server installlation, you're sadly mistaken.

All the scripts that are generated by the installation process (for the oracle database) are for a standalone installation and will fail or make your DBA very angry if they are run on one of the RAC nodes!

Well, there's a way out, but you'd have to edit the scripts that these monstrous products generate.

For example:
You'll find a line like this in Portal server scripts:

create tablespace ICMLFQ32 datafile '/oracle/tb/ICMLFQ32_01.dbf' size 300M reuse autoextend on next 10M maxsize UNLIMITED extent management local autoallocate;

you'll have to change it to :

create tablespace ICMLFQ32 datafile size 300M autoextend on next 10M maxsize UNLIMITED extent management local autoallocate;

i.e. remove the location of the datafile specified.

There's another thing that you'd need to do if your using Oracle RAC as the datastore for WebSphere Process and WebSphere Portal Servers... change your JDBC string.

I got this tip from the an IBM developerworks article on Oracle RAC with Process Server

Change your datasource from:

jdbc:oracle:thin:@{hostname}:{port number}:{DBName}


to:
jdbc:oracle:thin:@(DESCRIPTION=(ADDRESS_LIST=
(ADDRESS=(PROTOCOL=TCP)(HOST= myoraclehost1.ibm.com)(PORT=1521))
(ADDRESS=(PROTOCOL=TCP)(HOST= myoraclehost2.ibm.com)(PORT=1521))
(FAILOVER=on)(LOAD_BALANCE=on)
(CONNECT_DATA=(SERVER=DEDICATED)
(SERVICE_NAME=dbservice)))

I should be posting more gotchas with the IBM stack .... check the 'IBM' tags