Login Register
Hdparm can be used to view or set many hardware characteristics of IDE or SATA drives including optical drives (and even some SCSI drives).  For example, the read-lookahead feature can be enabled or disabled.  Also of interest is that the on board write caching can be disabled.  This may or may not be of use when trying to optimize the writing of data to the drive especially when the operating system and/or file system itself may also perform write caching.

Some options of hdparm are dangerous and are generally listed as such in the man page.

Hdparm is available from SourceForge and there is even a version for Windows.
Published in Blogs
A really nice plugin for eclipse that lets you write/edit  Trac wiki pages in eclipse.
Published in Blogs

DRBD (Distributed Replicated Block Device) forms the storage redundancy portition of a HA cluster setup. Explained in basic terms DRBD provides a means of achieving RAID 1 behavoir over a network, where whole block devices are mirrored accross the network.

To start off you will need 2 indentically sized raw drives or partitions. Many how-to's on the internet assume the use of whole drives, of course this will be better performance, but if you are simply getting familar with the technology you can repartition existing drives to allow for two eqaully sized raw partitions, one on each of the systems you will be using.

There are 3 DRBD replication modes:
• Protocol A: Write I/O is reported as completed as soon as it reached local disk and local TCP send buffer
• Protocol B: Write I/O is reported as completed as soon as it reached local disk and remote TCP buffer cache
• Protocol C: Write I/O is reported as completed as soon as it reached both local and remote disks.

If we were installing the HA cluster on a slow LAN or if the geogrphical seperation of the systems involved was great, then I recommend you opt for asyncronous mirroring (Protocol A) where the notifcation of a completed write operation occurs as soon as the local disk write is performed. This will greatly improve performance.

As we are setting up our HA cluster connected via a fast LAN, we will be using DRBD in fully syncronous mode, protocol C.
Protocol C involves the file system on the active node only being notified that the write operation was finished when the block is written to both disks of the cluster. Protocol C is the most commonly used mode of DRBD.


global { usage-count yes; }
common { syncer { rate 10M; } }
resource r0 {
protocol C;
net {
max-buffers 2048;
ko-count 4;
on bailey {
device    /dev/drbd0;
disk      /dev/sda4;
meta-disk internal;
on giskard {
device    /dev/drbd0;
disk      /dev/sda3;
meta-disk internal;

drbd.conf explained:

Global section, usage-count. The DRBD project keeps statistics about the usage of DRBD versions. They do this by contacting a HTTP server each time a new DRBD version is installed on a system. This can be disabled by setting usage-count no;.

The common seciton contains configurations inhereted by all resources defined.
Setting the syncronisation rate, this is accoimplished by going to the syncer section and then assigning a value to the rate setting. The syncronisation rate refers to rate in which the data is being mirrored in the background. The best setting for the syncronsation rate is related to the speed of the network with which the DRBD systems are communicating on. 100Mbps ethernet supports around 12MBps, Giggabit ethernet somewhere around 125MBps.

in the configuration above, we have a resource defined as r0, the nodes are configured in the "on" host subsections.
"Device" configures the path of the logical block device that will be created by DRBD
"Disk" configures the block device that will be used to store the data.
"Address" configures the IP address and port number of the host that will hold this DRBD device.
"Meta-disk" configures the location where the metadata about the DRBD device will be stored.
You can set this to internal and DRBD will use the physical block device to store the information, by recording the metadata within the last sections of the disk.
Once you have created your configuration file, you must conduct the following steps on both the nodes.

Create device metadata.

$ drbdadm create-md r0
v08 Magic number not found
Writing meta data...
initialising activity log
NOT initialized bitmap
New drbd meta data block sucessfully created.

Attach the backing device.
$ drbdadm attach r0

Set the syncronisation parameters.
$ drbdadm syncer r0

Connect it to the peer.
$ drbdadm connect r0

Run the service.
$ service drbd start


Heartbeat provides the IP redundancy and the service HA functionailty.
On the failure of the primary node the VIP is assigned to the secondary node and the services configured to be HA are started on the secondary node.

Heartbeat configuration:


## /etc/ha.d/ on node1
## This configuration is to be the same on both machines
## This example is made for version 2, comment out crm if using version 1
// replace the node variables with the names of your nodes.

crm no
keepalive 1
deadtime 5
warntime 3
initdead 20
bcast eth0
auto_failback yes
node bailey
node giskard

// The configuration below set authentication off, and encryption off for the authentication of nodes and their packets.
//Note make sure the authkeys file has the correct permisisions chmod 600

## /etc/ha.d/authkeys
auth 1
1 crc

// is the VIP (Virtual IP) assigned to the cluster.
//the "smb" in the configuration line represents the service we wish to make HA
// /devdrbd0 represents the resource name you configured in the drbd.conf

## /etc/ha.d/haresources
## This configuration is to be the same on both nodes

bailey drbddisk Filesystem::/dev/drbd0::/drbdData::ext3 smb

Published in Blogs

There's a nice article on IBM developerworks describing how to package software using RPM. You can read it here.

Published in Blogs
After installing nomachine, if you get an error connecting whereby nomachine errors out after  "Negotiating link parameters"

When installing nomachine on redhat 5.3 64-bit be sure to:

  1. Make sure you have installed the 64-bit packages as the 32-bit ones will not work.
  2. add the hostname to /etc/hosts
  3. Check "Disable encryption of all traffic" (in configuration / advanced tab)
On Centos 32-bit:
  1. add the hostname to /etc/hosts
  2. make sure the host IP is not specified as line
  3. Uncheck "Disable encryption of all traffic" (in configuration / advanced tab)
Published in Blogs
Add this directive to your /etc/httpd/httpd.conf file and restart apache.
DirectoryIndex default.rsp index.html 
Published in Blogs
When the node is clicked set editable to false. Set editable to true in the double-click event handler.
// the click event handler 
private function onclick_sourcetree(e:Event):void  {     
    yourTree.editable = false; 

// the doubleclick event handler  
private function ondoubleclick_sourcetree(e:Event):void  {     
    yourTree.editable = true;    
    yourTree.editedItemPosition = {columnIndex:0, rowIndex:sourceTree.selectedIndex}; 
Published in Blogs
Mac OS X leopard supports Universal Binaries so executables and dynamic libraries can be run on multiple architectures. A good example of this is the default apache install on Mac OS X. 
In order to compile apache modules for this architecture you must use the following flags when configuring the apache install.
 ./configure CFLAGS='-arch x86_64' APXSLDFLAGS='-arch x86_64' --with-apxs=/usr/sbin/apxs
Then you must pass the these additional flags to the apxs command in order to generate a Universal Binary shared module.
-Wl,-dynamic -Wl,'-arch ppc' -Wl,'-arch ppc64' -Wl,'-arch i386' -Wl,'-arch x86_64' 
-Wc,-dynamic -Wc,'-arch ppc' -Wc,'-arch ppc64' -Wc,'-arch i386' -Wc,'-arch x86_64' 
If you then do a file command on the shared module it should return; 
$ file Mach-O universal binary with 4 architectures (for architecture ppc7400): Mach-O bundle ppc (for architecture ppc64): Mach-O 64-bit bundle ppc64 (for architecture i386): Mach-O bundle i386 (for architecture x86_64): Mach-O 64-bit bundle x86_64
The apache module files are stored in the /usr/libexec/apache2/ directory on a default apache install on the Mac and the configuration file is /private/etc/apache2/httpd.conf
Published in Blogs
Subclipse is an Eclipse Team Provider plug-in providing support for Subversion within the Eclipse IDE. This plugin is required in order to use the recital eclipse workspace.
Published in Blogs

Recital is a dynamic programming language with an embedded high performance database engine particularly well suited for the development and deployment of high transaction throughput applications.

The Recital database engine is not a standalone process with which the application program communicates. Instead, the Recital database is an integral part of any applications developed in Recital. 

Recital implements most of the SQL-99 standard for SQL, but also provides lower level navigational data access for performing high transaction throughput. It is the choice of the application developer whether to use SQL, navigational data access, or a combination of both depending upon the type of application being developed.

The Recital database engine, although operating as an embedded database in the user process, multiple users and other background processes may access the same data concurrently. Read accesses are satisfied in parallel. Recital uses automatic record level locking when performing database updates. This provides for a high degree of database concurrency and superior application performance and differentiates the Recital database from other embeddable databases such as sqlite that locks the entire database file during writing. 

Key features of the Recital scripting language include:

  • High performance database application scripting language
  • Modern object-oriented language features
  • Easy to learn, easy to use
  • Fast, just-in-time compiled
  • Loosely-typed
  • Garbage collected
  • Static arrays, Associative arrays and objects
  • Develop desktop or web applications
  • Cross-platform support
  • Extensive built-in functions
  • Superb built-in SQL command integration
  • Navigational data access for the most demanding applications
  • Scripting  language is upward compatible with FoxPRO

Key features of the Recital database include:

  • A broad subset of ANSI SQL 99, as well as extensions
  • Cross-platform support
  • Stored procedures
  • Triggers
  • Cursors
  • Updatable Views
  • System Tables
  • Query caching
  • Sub-SELECTs (i.e. nested SELECTs)
  • Embedded database library
  • Fault tolerant clustering support
  • Chronological data versioning with database timelines
  • Optional DES3 encrypted data
  • Hot backup
  • Client drivers for ODBC, JDBC and .NET 
Published in Blogs

Copyright © 2019 Recital Software Inc.



User Registration
or Cancel