Solar Hydel Hybrid Power Stations

We hear a lot of fuzz about solar-wind hybrid power plants. Its surprising why there’s no major projects which utilize solar energy to multiply the output from an existing hydro electric power station.

A solar-hydel hybrid plant would work, in a very basic sense, as below –

  1. Photo voltaic panels are deployed in arrays supported on floating barges in the reservoir. (OR on barren land if available in proximity)
  2. Additional penstock-turbine-generator circuits are built for the EXTRA power to be generated.
  3. A sump collects the water used by the NEW water circuits described in step 2.
  4. Solar energy created by the PV arrays are used by several DC motors to pump the water from sump back to the reservoir.

(Detailed design will involve output power, back-up duration, fluid flow losses etc as design parameters.)

This method has these advantages –

  1. Removes the need of batteries which are expensive to procure and maintain too. Instead here solar energy is stored as potential energy of water.
  2. Removes the  need for expensive power electronics for DC to AC conversion.
  3. Reduces evaporation losses of water from reservoir considerably.
  4. Reduces the need for new Dams for increasing power generation.

BoshServlet Updated

BoshServlet is updated at Google code (http://code.google.com/p/bosh-servlet/) with the following changes –

  1. Intermittent race condition and lock ups while serving requests fixed.
  2. Changed session initialization flow to fix an error while using STARTTLS.
  3. Automated response for server pings.
  4. Added an example HTML page on using the servlet.

Thank you for your patience with BoshServlet so far. Please use the latest version and let me know of any fix/feature you find as needed.

– Kj

Remove virus “myFolder.exe”

I could fix the usb-disks infected with the virus which replaces your folders with a file folderName.exe, by following these steps (on Windows) –

  1. Run the command attrib e:\*.* /d /s -h -r -s in the command prompt – this will display all the hidden files and folders.
  2. Delete the dll file that appears in the disk after the above command is run, and also the folders converted to .exe.

The disk should now be usable again.

javax.net.ssl.SSLHandshakeException: unable to find valid certification path to requested target

Error: javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target

Cause: The certificate not in trusted list of JVM.

Solution: Add the certificate to trusted list by compiling and running the following Java class from the download link below (modified from the one posted at http://code.naishe.in/2011/07/looks-like-article-no-more-unable-to.html). Note: The certificate file(path) may have to be edited and set to the file used by your JVM to look up certificates.

Download InstallCert.java

Implementing a custom query executor / custom data source in Jasper server

This is small article on how to implement a custom datasource or a custom query executor in Jasper Reports Server, focused on the missing information in other tutorials/documentation available on web.  Before we start lets be clear on some of the related facts –

  1. Implementing a custom datasource in Jasper reports server is DIFFERENT from  implementing a datasource to work with iReports, in both concept and method used.
  2. A custom datasource is a datastructure that holds the information to be presented and is NOT a query executor (Meaning its not a datasource in “JDBC” or iReport sense).
  3. A query executor may create and return a custom datasource OR an instance of one of the predefined datasources.  For most of the cases, using one of the predefined datasources with a custom query executor are good enough and need to create a cutom datasource seldom arises. (please refer JasperServer documentation for information on predefined datasources).

Please refer the attached sample application  (from jasper server source) to understand how custom data source and query executors are created.

Please note these with regard to the sample application –

  1. In addition to the xml configurations in the given sample, the new query language “webscraper” has to be added in the file WEB-INF/flows/queryBeans.xml
  2. Once this is done, if the language specified in the queryString node of a JRXML is webscraper, WebScraperQueryExecuterFactory (and then WebScraperQueryExecuter) will be invoked to execute that query. This is irrespective of the datasource you have set for that report.
  3. A custom datasource has real use only when it works with a custom query executor, or when it can be created and filled with required information without the need for a query (from the report XML).

Skip Authorization on MySQL DB

To skip authorizations and login without password to MySql server,

  1. sudo vi /etc/mysql/my.cnf
  2. Add the line skip-grant-tables after the linewhich reads skip-external-locking.
    1. Optionally comment the line bind-address = 127.0.0.1 if the db has to be accessed from external devices via TCP.
  3. Save and quit vim.
  4. restart mysql server ( sudo /etc/init.d/mysql restart in ubuntu)

Activate password authentication on Ubuntu VMs on Amazon EC2

ssh -i [path to private-key-file] [target IP]

# In the host shell

sudo adduser [username]     # Add a new user; this command also prompts for setting the password

sudo adduser admin            # Add this user to the admin group (to sudoers)

sudo vi /etc/ssh/sshd_config

# In the above file set "PasswordAuthentication" to "yes".

sudo reload ssh

The VM should now be ready for password based ssh authentication.