Monday, September 7, 2009

Cloud Computing &Oracle -3

GETTING STARTED WITH CLOUD BACKUP
-----------------------------------
Sign up for Amazon S3 Service
The first step in getting started with the Oracle Secure Backup Cloud module is to
sign up for Amazon S3. This can be done by visiting the Amazon S3 website
(http://aws.amazon.com/s3). Upon successful registration, users will be
provided a pair of access identifiers called the Access Key ID and the Secret Access Key.
These access identifiers can be retrieved from the Amazon S3 web site by hovering
the mouse over the “Your Web Services Account” button on the upper right hand
side corner of the page and then clicking on the “AWS Access Identifiers” link.

Register for an Oracle.com or Oracle Technology Network (OTN) Account
--------------------------------------------------------------------------
An Oracle.com or OTN account is required to install the Oracle Secure Backup
Cloud module. New accounts may be created by visiting the OTN website
(http://otn.oracle.com) and clicking on the “Sign In/Register for Account” link at
the top of the page.

Install the Oracle Secure Backup Cloud Module
----------------------------------------------
The next step is to download the Oracle Secure Backup Cloud module install tool
from OTN, and run it to install and configure Cloud backups. The install tool is
pre-packaged with the AMIs provided by Oracle to ease Oracle software
deployment on Amazon EC2. Therefore, if the database being backed up is
running on Amazon EC2, there is no need to download the install tool – it can be
found in the /home/oracle/scripts/osbws directory.
The install tool can be invoked as follows:

$java -jar osbws_install.jar -AWSID -AWSKey
-otnUser -otnPass -walletDir -configFile -libDir
-proxyHost wwwproxy.
smallcompany.com

Oracle Secure Backup Database Web-Service Install Tool
OTN userid is valid.
AWS credentials are valid.
Creating new registration for this S3 user.
Created new log bucket.
Registration ID: 0f0a8aac-dad0-6254-7d70-be4ac4f112c4
S3 Logging Bucket: oracle-log-jane-doe-1
Create credential oracle.security.client.connect_string1

OSB web-services wallet created in directory
/orclhome/dbs/osbws_wallet.
OSB web-services initialization file /orclhome/dbs/osbwst1.ora
created.

Downloading OSB Web Services Software Library.
Downloaded 13165919 bytes in 204 seconds.
Transfer rate was 64538 bytes/second.
Download complete.
Extracted file /orclhome/lib/libosbws11.so

As can be seen from the above sample output, the install tool automatically
performs all the required steps to install and configure the Cloud backup module –
including downloading the software, creating a wallet containing the user’s AWS
identifiers, and creating the Cloud backup configuration file.
More details on how to run the install tool and the description of all of its
arguments can be found in the install tool readme document.

Configure Recovery Manager (RMAN) Settings
---------------------------------------
This optional, but highly recommended, step stores the configuration information
for the Cloud Backup module in the RMAN repository so that it does not need to
be specified each time a backup is invoked.

RMAN> configure channel device type sbt parms
'SBT_LIBRARY=/orclhome/lib/libosbws11.so
ENV=(OSB_WS_PFILE=/orclhome/dbs/osbwst1.ora)';

using target database control file instead of recovery catalog
new RMAN configuration parameters:

CONFIGURE CHANNEL DEVICE TYPE 'SBT_TAPE' PARMS
'SBT_LIBRARY=/orclhome/lib/libosbws11.so
ENV=(OSB_WS_PFILE=/orclhome/dbs/osbwst1.ora)';

new RMAN configuration parameters are successfully stored

Once the above step is completed, the system is fully configured for Cloud
backups. Cloud Backups can now be performed using the same RMAN commands
you usually use.

Similarly, all Cloud backup operations will be catalogued by RMAN in the same
manner as local disk or tape backups are, thereby ensuring a completely transparent
and seamless restore/recovery process. In another words, when a restore/recover
operation is initiated, RMAN and Oracle Secure Backup Cloud module will
automtically restore the required data from the Cloud - without requiring any
special user intervention.

Oracle recommends the following to optimize the
------------------------------------------------
• Use multiple RMAN channels. Prior to Oracle Database 11g, each datafile
could only be backed up by one RMAN channel. Consequently, the
effective degree of parallelism is limited by the number datafiles in the
database. Oracle Database 11g however has intra-datafile parallelism
capability that allows multiple channels to backup a single file in parallel.

• Compress your backups and use the new Oracle Database 11g Fast
Compressed Backup feature. Compared to pre-11g backup compression,
Oracle Database 11g Fast Backup Compression is significantly faster and
more efficient (in terms of CPU overhead).
• Consider making full database backups once a week and perform
incremental backups during the weekdays. This will results in faster
backups and may help save significant amount of network bandwidth. Use
the RMAN Block Change Tracking feature to optimize the performance
of your daily incremental backups.

Cloud Computing &Oracle -2

Cloud Backup Benefits
---------------------

Oracle’s Cloud backup functionality provides the following advantages over
traditional tape-based offsite backups:
Continuous Accessibility, Faster Restores: Backups stored in the
Cloud are always accessible – much in the same way local disk backups
are. As such, there is no need to call anyone, and no need to ship or load
tapes before a restore can be performed. Administrators can initiate
restore operations using their standard tools (Enterprise Manager, scripts,
etc.) just as if the offsite backup was stored locally. This can help make
restores faster and reduce down time from days to hours/minutes in many
cases.

Better Reliability: Storage Clouds are disk based and thus inherently
more reliable than tapes. Additionally, the Cloud vendors typically keep
multiple redundant copies of data for availability and scalability purposes.
reduction in backup size is directly realized as an increase in backup performance.
Unlimited Scaling and No Up-front Capital Expense: The Cloud
provides virtually unlimited capacity with no up-front capital expenditure.
Consequently, users need not worry about provisioning adequate tapes or
local storage to hold the required backup data. The Cloud scales seamlessly
and users pay only for what they use, when they use it.

Reduced Tape Backup and Offsite Storage Cost: Since Cloud backup
reduces or eliminates the need for tapes, this can lead to significant savings
in tape backup software licensing/support and offsite tape storage costs.
Quick Provisioning of Test and Dev Environments: As Cloud
Backups are accessible from anywhere via the Internet, they can be used to
quickly clone databases to create custom test, dev, or QA environments.
For instance, Cloud Backups stored in Amazon S3 can be cloned to
machines running in Amazon EC2 by running a simple script that is
included in the Oracle-provided Amazon Machine Images (AMIs). An
AMI is a virtual machine image that allows quick provisioning of a preinstalled
and pre-configured Oracle database environment on Amazon
EC2.

Cloud Computing &Oracle -1

Complete Data Security and Privacy with Built-In Encryption
---------------------------------------------------------------
Oracle Secure Backup provides the ability to encrypt backups to ensure data
security and privacy.While most Storage
Cloud vendors provide robust security to ensure that only authorized users can
access data, Oracle Secure Backup’s ability to encrypt data at its source

Intelligent, Network-Optimized Backup

----------------------------------------
Network bandwidth consumption and the time required to complete backups can
be another major concern while backing up databases to the Cloud, over the public
Internet.Intelligent, Network-Optimized Backup
Network bandwidth consumption and the time required to complete backups can
be another major concern while backing up databases to the Cloud, over the public
Internet. The Oracle Secure Backup Cloud module features a rich set of capabilities
to intelligently minimize the volume of backup data and also to compress backups.

Oracle Secure Backup is tightly integrated with the Oracle Database engine, Oracle Secure Backup can identify unused space (blocks) within the database and skip backing it up. Since database administrators typically allocate more space than they actually use, to provide headroom for future growth, this can lead to a substantial reduction in both backup size and time.

Additionally, starting with Oracle Database 11g,
Oracle Secure Backup can also eliminate committed undo data from backup by
identifying and backing up only the “active” undo data (i.e. undo data related to
transactions in progress at the time of backup). Database undo sizes typically range
from 10 to 100s of GB and this optimization can also lead to significant
improvements in backup performance.
It is important to note that both unused space and undo data backup optimization
are unique features of Oracle Secure Backup and are not available with any other
backup product.



With Oracle Secure Backup Cloud module, users can also utilize RMAN’s rich
compression capabilities. This includes the Oracle Database 11g Fast Compressed
Backup feature, which normally requires the Advanced Compression option.cost. Compression typically results in a 50% reduction in backup size.
When transmitting backups over slower networks, such as the public internet,any

 

 -------------------

Cloud Computing &Oracle

• Oracle software can now be licensed for the Cloud
– Amazon EC2 supported today
• Database, Middleware, Grid Control
– EE: Each virtual core counted as a physical x86 core (EE)
– SE/SE1 license based on the EC2 instance size
• 0-4 virtual cores = 1 processor (socket)
• >4 virtual cores = each 4 virtual core counted as a
processor (socket)
• Oracle Enterprise Linux
– Each EC2 instance is counted as a “System”
• Can buy new licenses or use existing ones
• Customers with ULAs can use EC2 without any
additional license

Deploying Oracle Software in the Cloud
--------------------------------------
• Pre-configured virtual machine images (AMIs) available for EC2
• Consists of Oracle Enterprise Linux + Oracle DB + APEX
– No RAC support currently (EC2 does not support clusters)
• Fully configured hardware and Oracle environment in less than 30 minutes

Oracle Secure Backup Cloud
--------------------------
Using the newly introduced Oracle Secure Backup
Cloud module, it is now possible to send local disk backups directly to the Storage
Cloud for offsite storage purposes. The Cloud backup module is a part of the
Oracle Secure Backup product family. Oracle Secure Backup is Oracle’s next generation
tape backup management solution and it now provides customers the
flexibility to back up data to either tape or the Cloud.

The Oracle Secure Backup Cloud module can also be used to stream backups
directly to the Cloud. This is particularly useful when the database is also running in the Cloud, using services such as Amazon Elastic Compute Cloud (EC2).

The Oracle Secure Backup Cloud module is implemented using the Oracle
Recovery Manager (RMAN) SBT interface. The SBT interface allows external
backup to be seamlessly integrated with RMAN. Consequently, the Oracle
Secure Backup Cloud module can be used to back up all supported versions of
Oracle Database i.e. Oracle Database 9i Release 2 or higher. In addition, database
administrators can continue to use their existing backup tools – Enterprise
Manager, scripts, etc. – to perform Cloud backups.



Oracle Secure Backup Cloud module is currently available for Linux and Windows
(32-bit only) platforms.

Cloud Computing & Amazon -3

Amazon Simple-Db is a web service providing the core database functions of data indexing and querying in the cloud.

Build your data set

* Use CreateDomain, DeleteDomain, ListDomains, DomainMetadata to create and manage query domains
* Use Put, Batch Put, & Delete to create and manage the data set within each query domain

Retrieve your data

* Use GetAttributes to retrieve a specific item
* Use Select to query your data set for items that meet specified criteria

API Summary


Amazon SimpleDB provides a small number of simple API calls which implement writing, indexing and querying data. The interface and feature set are intentionally focused on core functionality, providing a basic API for developers to build upon and making the service easy to learn and simple to use.

* CreateDomain — Create a domain that contains your dataset.
* DeleteDomain — Delete a domain.
* ListDomains — List all domains.
* DomainMetadata — Retrieve information about creation time for the domain, storage information both as counts of item names and attributes, as well as total size in bytes.
* PutAttributes — Add or update an item and its attributes, or add attribute-value pairs to items that exist already. Items are automatically indexed as they are received.
* BatchPutAttributes — For greater overall throughput of bulk writes, perform up to 25 PutAttribute operations in a single call.
* DeleteAttributes — Delete an item, an attribute, or an attribute value.
* GetAttributes — Retrieve an item and all or a subset of its attributes and values.
* Select — Query the data set in the familiar, “select target from domain_name where query_expression” syntax. Supported value tests are: =, !=, <, > <=, >=, like, not like, between, is null, is not null, and every (). Example: select * from mydomain where every(keyword) = ‘Book’. Order results using the SORT operator, and count items that meet the condition(s) specified by the predicate(s) in a query using the Count operator.


Amazon Simple Queue Service
(Amazon SQS) offers a reliable, highly scalable, hosted queue for storing messages as they travel between computers.

Amazon SQS Functionality

* Developers can create an unlimited number of Amazon SQS queues with an unlimited number of messages.

* A queue can be created in the United States or in Europe. Queue names and message stores are independent of other regions.
* The message body can contain up to 8 KB of text in any format.
* Messages can be retained in queues for up to 4 days.
* Messages can be sent and read simultaneously.

* When a message is received, it becomes “locked” while being processed. This keeps other computers from processing the message simultaneously. If the message processing fails, the lock will expire and the message will be available again.

# Developers can access Amazon SQS through standards-based SOAP and Query interfaces.
# Developers can securely share Amazon SQS queues with others. Queues can be shared with other AWS accounts and Anonymously. Queue sharing can also be restricted by IP address and time-of-day.

Basic Queue Requests

Amazon SQS employs a simple interface that is easy to use and highly flexible. The following requests are provided:

* CreateQueue: Create queues for use with your AWS account.
* ListQueues: List your existing queues.
* DeleteQueue: Delete one of your queues.
* SendMessage: Add any data entries to a specified queue.
* ReceiveMessage: Return one or more messages from a specified queue.
* ChangeMessageVisibility: Change the visibility timeout of previously received message.
* DeleteMessage: Remove a previously received message from a specified queue.
* SetQueueAttributes: Control queue settings like the amount of time that messages are locked after being read so they cannot be read again.
* GetQueueAttributes: See information about a queue like the number of messages in it.
* AddPermission: Add queue sharing for another AWS account for a specified queue.
* RemovePermission: Remove an AWS account from queue sharing for a specified queue.

Cloud Computing & Amazon -2

Amazon Simple Storage Service (S3)
-----------------------------------
• S3 - store files on Amazon storage cloud
– Primarily used for backups, images, virtual machine snapshots
• Asynchronously replicates data to several data centers for HA
and scalability
– Typically in minutes
– Claim to never have lost any data, but no guarantees
– 99.99% uptime SLA
• Pricing
– Storage
• $0.15 to $.18/GB/Month (Higher price for data stored in Europe)
– Bandwidth – free if from EC2
• $0.10 - $.017/GB Transferred/Month

Amazon Simple Storage Service (http://aws.amazon.com/s3) is part of the
Amazon Web Services (AWS) offering.Amazon S3 is storage for the Internet. Amazon S3 provides a simple web-services interface that can be used to store and retrieve any amount of data, at any time,from anywhere on the web. It provides users access to the same highly scalable,reliable, fast, inexpensive data storage infrastructure that Amazon uses to run its own global network of web sites.

Amazon S3 is the first Cloud vendor that Oracle has partnered with to enable
database backup in the Cloud. This functionality may be extended to more Cloud
platforms/vendors in the future.

Amazon S3 Functionality

* Write, read, and delete objects containing from 1 byte to 5 gigabytes of data each. The number of objects you can store is unlimited.
* Each object is stored in a bucket and retrieved via a unique, developer-assigned key.
* A bucket can be located in the United States or in Europe. All objects within the bucket will be stored in the bucket’s location, but the objects can be accessed from anywhere.
* Authentication mechanisms are provided to ensure that data is kept secure from unauthorized access. Objects can be made private or public, and rights can be granted to specific users.
* Uses standards-based REST and SOAP interfaces designed to work with any Internet-development toolkit.
* Built to be flexible so that protocol or functional layers can easily be added. Default download protocol is HTTP. A BitTorrent™ protocol interface is provided to lower costs for high-scale distribution.

Cloud Computing & Amazon -1

Sign up for Amazon Web Services and EC2
------------------------------
– Can use your regular Amazon account
– Create your secure X.509 certificate and create key pair
for command line access to EC2
• Using tools like SSH and PuTTY

Features

* Amazon CloudWatch – Amazon CloudWatch is a web service that provides monitoring for AWS cloud resources, starting with Amazon EC2. It provides you with visibility into resource utilization, operational performance, and overall demand patterns—including metrics such as CPU utilization, disk reads and writes, and network traffic. To use Amazon CloudWatch, simply select the Amazon EC2 instances that you’d like to monitor; within minutes, Amazon CloudWatch will begin aggregating and storing monitoring data that can be accessed using web service APIs or Command Line Tools .

* Amazon Virtual Private Cloud – Amazon VPC is a secure and seamless bridge between a company’s existing IT infrastructure and the AWS cloud. Amazon VPC enables enterprises to connect their existing infrastructure to a set of isolated AWS compute resources via a Virtual Private Network (VPN) connection, and to extend their existing management capabilities such as security services, firewalls, and intrusion detection systems to include their AWS resources.

* Elastic IP Addresses – Elastic IP addresses are static IP addresses designed for dynamic cloud computing. An Elastic IP address is associated with your account not a particular instance, and you control that address until you choose to explicitly release it. Unlike traditional static IP addresses, however, Elastic IP addresses allow you to mask instance or Availability Zone failures by programmatically remapping your public IP addresses to any instance in your account. Rather than waiting on a data technician to reconfigure or replace your host, or waiting for DNS to propagate to all of your customers, Amazon EC2 enables you to engineer around problems with your instance or software by quickly remapping your Elastic IP address to a replacement instance.

* Auto Scaling – Auto Scaling allows you to automatically scale your Amazon EC2 capacity up or down according to conditions you define. With Auto Scaling, you can ensure that the number of Amazon EC2 instances you’re using scales up seamlessly during demand spikes to maintain performance, and scales down automatically during demand lulls to minimize costs. Auto Scaling is particularly well suited for applications that experience hourly, daily, or weekly variability in usage. Auto Scaling is enabled by Amazon CloudWatch and available at no additional charge beyond Amazon CloudWatch fees

* Multiple Locations – Amazon EC2 provides the ability to place instances in multiple locations. Amazon EC2 locations are composed of Regions and Availability Zones. Availability Zones are distinct locations that are engineered to be insulated from failures in other Availability Zones and provide inexpensive, low latency network connectivity to other Availability Zones in the same Region. By launching instances in separate Availability Zones, you can protect your applications from failure of a single location. Regions consist of one or more Availability Zones, are geographically dispersed, and will be in separate geographic areas or countries. The Amazon EC2 Service Level Agreement commitment is 99.95% availability for each Amazon EC2 Region. Amazon EC2 is currently available in two regions: one in the US and one in Europe.

* Amazon Elastic Block Store – Amazon Elastic Block Store (EBS) offers persistent storage for Amazon EC2 instances.Amazon EBS volumes are highly available, highly reliable volumes that can be attached to a running Amazon EC2 instance and are exposed as standard block devices. Amazon EBS provides the ability to create point-in-time consistent snapshots of your volumes that are then stored in Amazon S3, and automatically replicated across multiple Availability Zones. These snapshots can be used as the starting point for new Amazon EBS volumes, and can protect your data for long term durability.

* Elastic Load Balancing – Elastic Load Balancing automatically distributes incoming application traffic across multiple Amazon EC2 instances. It enables you to achieve even greater fault tolerance in your applications, seamlessly providing the amount of load balancing capacity needed in response to incoming application traffic. Elastic Load Balancing detects unhealthy instances within a pool and automatically reroutes traffic to healthy instances until the unhealthy instances have been restored. You can enable Elastic Load Balancing within a single Availability Zone or across multiple zones for even more consistent application performance.

Cloud Computing & Amazon

Amazon Web Services (AWS) -- http://aws.amazon.com
------------------------------------------------------
• Amazon Data Center in the Cloud
• Fast, easy, inexpensive renting of servers / storage
– Elastic Compute Cloud (EC2) – Rent Linux virtual machines
• 10-80 cents/hour
– Simple Storage Service (S3) – Store files
• 15 cents/GB/month (US)
• 18 cents/GB/month (Europe)
– Bandwidth Costs
• 10 cents/GB incoming
• 10 – 17 cents/GB outgoing (based on volume)
• Customers demand for Oracle products to run on AWS
EC2

Amazon EC2 Features
------------------
• Elastic (Static) IP Addresses
– Pre-assigned static IP addresses that can be associated with any
EC2 instance
• Elastic Block Storage
– Persistent “NAS” style storage
– Allows users to create volumes and snapshots
– Default EC2 storage is ephemeral – you loose everything the
moment you shut down an instance
• Availability Zones
– Spread your instances across multiple locations for business
continuity
• Security
– Private/Public key pair based, SSH-only administrator access
– Ability to configure firewall and network port settings

Amazon Elastic Compute Cloud (Amazon EC2) is a web service that provides resizable compute capacity in the cloud. It is designed to make web-scale computing easier for developers.


To use Amazon EC2, you simply:


* Create an Amazon Machine Image (AMI) containing your applications, libraries, data & associated configuration settings.Or use pre-configured, templated images to get up & running immediately.
* Upload the AMI into Amazon S3.Amazon EC2 provides tools that make storing the AMI simple.Amazon S3 provides a safe,reliable & fast repository to store your images.
* Use Amazon EC2 web service to configure security and network access.
* Choose which instance type(s) and operating system you want, then start, terminate, and monitor as many instances of your AMI as needed, using the web service APIs or the variety of management tools provided.
* Determine whether you want to run in multiple locations, utilize static IP endpoints, or attach persistent block storage to your instances.

Service Highlights

Elastic – Amazon EC2 enables you to increase or decrease capacity within minutes, not hours or days. You can commission one, hundreds or even thousands of server instances simultaneously. Of course, because this is all controlled with web service APIs, your application can automatically scale itself up and down depending on its needs.

Completely Controlled
Flexible
Designed for use with other Amazon Web Services
Reliable
Secure
Inexpensive

Cloud Computing

Cloud Computing has emerged as the new industry buzzword.Cloud Computing allows users to tap into a

virtually unlimited pool of computing resources over the Internet (the Cloud).
Unlike traditional IT, Cloud users have little insight or control over the underlying
infrastructure, and they must interact with the Cloud via an API provided by the
Cloud vendors. The most exciting part of the Cloud, however, is its elasticity and
utility-style pricing. Users can provision resources dynamically in a self-service
manner and pay only for what they use – much like how we use utilities like
electricity or water.

CLOUD ANTI VIRUS IS LATEST TREND IN CLOUD COMPUTING

What Is Cloud Computing?

• Computing resources residing on
Internet (‘the cloud’)
• Underlying physical resources not
exposed
– Abstracted at various levels (virtual
machines, database as a service, etc.)
– No direct hardware control
• Infinitely scalable
• Billed by consumption
– Per hour, per GB, etc.
• Typical Interface: Web Services
– REST, SOAP

• Quick, Self-Service Provisioning
– Developers no longer waiting on IT to respond
– Eases and Speeds Up Application Development
• Elastic
– Scale up and down rapidly





Different Levels of Cloud Computing
---------------------------------
Cloud computing is typically divided into three levels of service offerings:
Software as a Service(SaaS),
Platform as a Service (PaaS), and
Infrastructure as a service (IaaS).
These levels support
virtualization and management of differing levels of the solution stack.

Software as a Service
---------------------
A SaaS provider typically hosts and manages a given application in their own data center and makes it available to multiple tenants and users over the Web. Some SaaS providers run on another cloud provider’s PaaS or IaaS service offerings. Oracle CRM On Demand,Salesforce.com, and Netsuite are some of the well known SaaS examples.

Platform as a Service
---------------------
Platform as a Service (PaaS) is an application development and deployment platform delivered as a service to developers over the Web. It facilitates development and deployment of applications without the cost and complexity of buying and managing the underlying infrastructure, providing all of the facilities required to support the complete life cycle of building and delivering web applications
and services entirely available from the Internet. This platform consists of infrastructure software, and typically includes a database, middleware and development tools. A virtualized and clustered grid computing architecture is often the basis for this infrastructure software. Some PaaS offerings have a specific programming language or API. For example,Google AppEngine is a PaaS offering where developers write in Python or Java. EngineYard is Ruby on Rails. And sometimes PaaS providers have proprietary languages like force.com from Salesforce.com and Coghead, now owned by SAP.

Infrastructure as a Service
---------------------------
Infrastructure as a Service (IaaS) is the delivery of hardware (server, storage and network), and associated software (operating systems virtualization technology, file system), as a service. It is an evolution of traditional hosting that does not require any long term commitment and allows users to provision resources on demand. Unlike PaaS services, the IaaS provider does very little management other than keep the data center operational and users must deploy and manage the software services
themselves – just the way they would in their own data center. Amazon Web Services Elastic Compute Cloud (EC2) and Secure Storage Service (S3) are examples of IaaS offerings.

TDMA & CDMA

TDMA
----
According to TDMA in each signaling station Bandwidth is used in different time slots.In TDMA technology When a particular signaling station is using a certain timeslot say T1 it cannot be used by another signalling station T1 can be only used by the latter after first station is used.In satellite technology and For GSM mobiles mainlt TDMA technology is used .

CDMA
-----
For CDMa signalling station (mobile tower) there is no limitation for timeslot and bandwidth.It can transmit signals at any time at any frequency.For each station it have its own unique chip-code sequnce with binary logic 0 and 1 .For each clock chipcode will change .Chipcode sequence of paricular station will not be repeated for another station.Signals are secure in this technology.This is also known as Spread spectrum Multiple acess.For CDMA main parts are CDMA decoder & encoder .In CDMA logic 1 is respresented as +1 and logic 0 is represented as -1.

Tuesday, August 25, 2009

Visual c++

Mouse Programming

Handler functions are mainly used for handling messages .Messages are of two types Client and non-client messages .When double clciking ,draging from windows title bar Non Client message is generated.

Client message
---------------
Message Handler Sent When
-------------------------------------------------------------
WM_LBUTTONDOWN OnLButtonDown Left button is pressed
WM_LBUTTONUP OnLButtonUp Left button is released
WM_LBUTTONDBCLCICK OnLButtonDblClk Left button double clicked

WM_MBUTTONDOWN OnMButtonDown Middle button is pressed
WM_MBUTTONUP OnMButtonUp Middle button is released
WM_MBUTTONDBCLICK OnMButtonDblClk Middle button double clicked

WM_RBUTTONDOWN OnRButtonDown Right button is pressed
WM_RBUTTONUP OnRButtonUp Right button is released
WM_RBUTTONDBCLCICK OnRButtonDblClk Right button double clicked

WM_MUSEMOVE OnMouseMove Mouse is Moved Over Window's client area


Non-Client message
---------------
Message Handler Sent When
-------------------------------------------------------------
WM_NCLBUTTONDOWN OnNcLButtonDown Left button is pressed
WM_NCLBUTTONUP OnNcLButtonUp Left button is released
WM_NCLBUTTONDBCLCICK OnNcLButtonDblClk Left button double clicked

WM_NCMBUTTONDOWN OnNcMButtonDown Middle button is pressed
WM_NCMBUTTONUP OnNcMButtonUp Middle button is released
WM_NCMBUTTONDBCLICK OnNcMButtonDblClk Middle button double clicked

WM_NCRBUTTONDOWN OnNcRButtonDown Right button is pressed
WM_NCRBUTTONUP OnNcRButtonUp Right button is released
WM_NCRBUTTONDBCLCICK OnNcRButtonDblClk Right button double clicked

WM_NCMUSEMOVE OnNcMouseMove Mouse is Moved Over Window's client area


Code to check wether mouse is present or not ,if present display the count of buttons.


#include
class mousestatus:public CFrameWnd
{
public:
mousestatus()
{
Create (0,"Mouse status");
}
void checkmouse()
{
int status,count;
char message;
status=::GetSystemMetric(SM_MOUSEPRESENT);
if (status==1)
{
MessageBox("Mouse present","User");
Count=::GetSystemMetric(SM_CMMOUSEBUTTONS);
Sprintf(Message,"%d",Count);
MessageBox(message,"Number of buttons");
}
else
{
MessageBox("Mouse absent","User");
}
}//end of checkmouse
};

class MS : public CWinApp
{
public:
int InitInstance()
{
mousestatus *ptrms =new mousestatus ( );
ptrms -> ShowWindow(1);
ptrms -> checkmouse();
m_pMainWnd =ptrms;
return(1);
}
};
MS myobject;


Program to swap mouse buttons


#include
class Swapmouse:public CFrameWnd
{
public:
Swapmouse()
{
Create (0,"Swapping Mouse button");
}
void swap()
{
int status;
status=::GetSystemMetric(SM_SWAPBUTTON);
if (status==1)
{
MessageBox("Mouse Buttons are swapped","User");
}
else
{
MessageBox("Mouse Not Swapped","User");
}
}//end of checkmouse
};

class Swpms : public CWinApp
{
public:
int InitInstance()
{
Swpms *ptrms =new swpms ( );
ptrms -> ShowWindow(1);
ptrms -> Swap();
m_pMainWnd =ptrswpms;
return(1);
}
};
Swpms myobject;


File Programming
-----------------
Storing of application data into computer drives is called Serialisation and viceversa is known as deserialisation.

For serialisation there are two MFC class CArchive and CFile


CArchive is given in Serialize named function as argument .In CArchive class there are two functions for read and write ; IsLoading and IsStoring.

Eg : Void CFileDemo :: Serialize ( CArchive &obj)

For object Serialization what all steps are followed
----------------------------------------------------
Macro statements like DECLARE_SERIAL and IMPLEMENT_SERAIL are to be defined in class declaration and class implementation.In DECLARE_SERAIL macro one argument should be passed ;the agrument is the name of the class for which serialization should be attained.
In IMPLEMENT_SERAIL macro three arguments should be passed ,first one is same we used in DECLARE_SERAIL macro second one is super base class of our class and third one is version number of our file.

//Class declaration


class CFileClass::public CObject
{
DECLARE_SERIAL(CFileclass)
public :
Virtual void Serialize (CArchive obj);
CFileClass();
virtual `CFileClass();
};

// class implementation

#include "stdafx.h"
#include "FileClass.h"
#ifdef_DEBUG
#undef THIS_FILE
static char THIS_FILE[]=FILE_;
#define new DEBUG_NEW
#end if;
IMPLEMENT_SERAIL(CFileClass,CObject,1)


// Construction

CFileClass:: CFileClass()
{

//add code
}

// distruction

CFileClass::`CFileClass()
{
//add code
}

Visual Basic

Shell function to call executable files from your application.In this function two arguments are accepted one is program name and other is window state of program (1- for normal mode ie: VbNormal ; VbMaximized,VbMinimized)

Private Sub Form_Load( )
Dim r as variant
r =Shell ("Calc.exe,1);
End Sub


AppActivate Statement


Send Keys

Values to submitted in sendkeys

Shift ------ +
Control ----- ^
Alt ------ %
Backspace ---- {BACKSPACE}
Break ---- {BREAK}
Caps ---- {CAPSLOCK}
Clear -------- {CLEAR}
Del --------- {DELETE}
DownArrow ---- {DOWN}
End ---- {END}
Enter -------- {ENTER}
Esc ---------- {ESCAPE}
Help --------- {HELP}
etc.................................

Five arguments for MessageBox

MessageBox(Message,style,heading,helpfile,helpcontextid);

C Sharp

Web.cs
--------
using System;
class webclass
{ public static void Main ()
{
Console.WriteLine("Content_Type :text/html|\n");
Console.WriteLine("First web program ");
}
}

After compiling this web.exe file will be generated .Copy this file into apache\cgi-bin named folder.


Then create a html file

web1.html
----------






<html>
<form action =http://127.0.0.1/cgi-bin/web.exe>
<input type=submit value=Display>
</form>
</html>


then after starting apache

cmd>apache (command to start apache web server)

Then in browser type this hht://127.0.0.1/web1.html and press enter your first C# program got executed.


Thread synchronization
----------------------

Thread synchronization is attained by lock .In common language Runtime (CLR) there are three different types Thread synchronization .

Inter Lock class, Monitor class, Lock statement

In Inter lock class there are there are two threads Increment and Decrement

Interlocked.Increment( )

Thursday, July 9, 2009

WINDOWS Shortcut Key

• Windows: Display the Start menu
• Windows + D: Minimize or restore all windows
• Windows + E: Display Windows Explorer
• Windows + F: Display Search for files
• Windows + Ctrl + F: Display Search for computer
• Windows + F1: Display Help and Support Center
• Windows + R: Display Run dialog box
• Windows + break: Display System Properties dialog box
• Windows + shift + M: Undo minimize all windows
• Windows + U: Open Utility Manager

Monday, July 6, 2009

Registry

Registry is a database which stores the s/w and hardware information of a computer.This resides(contains) in the file user.dat and system.dat from windows 95 version onwards ; before that there was no concept of registry apart from this all informations are stored in the following files Config.sys,autoexec.bat,system.ini,control.ini,win.ini. For editing the registry files windows supplies 'Regedit' named tool .Registry details can be exported and imported .Exported registry files with be .reg extension ;its a text based file.

REGEDIT4
[HKEY_LOCAL_MACHINE\SYSTEM\Setup]
"setup type"=dword.00000000
"cmdline"=setup_new setup
"System Perfix"=hex:c5,0b,00,00,40,36,02

In registry the hyphone symbol '-' is used for commenting.

Based upon the information registry is divided into 6 sections.

HKEY_CLASSES_ROOT
--------------------
This section contains the information of different type of file extensions,OLE related details,Drag & drop features ,Windows shortcut ,User interface etc.


HKEY_CURRENT_USER
-----------------
Contains the information of login user detials and their desktop and start menu settings.

HKEY_LOCAL_MACHINE
-------------------
This stores information about hardware and s/w details .There are many subkeys in this section

Config :
--------
Contains information about assemblence of different hardwares .

Enum :
------
It contains all details about device drivers in the PC.

Hardware :
---------
It contains information about Serial Port ,Processors,Floating Point Processers etc

Network :
--------
Network related details .

Software :
---------
Information about What all Softwares installed in the PC.

System :
--------
It deals with information about the device drivers which is uesd in the Pcand its assembly details.

HKEY_USERS
----------
Contains the information of all user detials and their desktop and start menu settings.


HKEY_CURRENT_CONFIG

-------------------
Details about Hardware Configuration.

HKEY_DYN_DATA
--------------


In registry there are 5 different datatypes

1) REG_BINARY : This datatypes are used for mainly storing hardware related informations .Its value is shhown in hexadecimal format.
2) REG_DWORD : This is 4 byte in length ,consist of boolean data 0 and 1 .Its value can be seen in hexadecimal or in decimal format .
3) REG_SZ : String datatype.
4) REG_EXPAND_SZ :
5) REG_MULTI_SZ :

Some Books for Career Enhancement

Strengthen your writing
By V.R NarayanaSwami Page --- 170
Pub : Orient Long Man

English pronouncing Dictionary
By John Daniel Page --- 559

English Vocabulary in Use
By Michal Mccarthy & Felicity O'Dell
Page --296
Pub : DC Books , Current Books

The Creative Problem Solvers Tool Box
Pub : Orient Longman
Page -- 344


Tough Talking how to handle awkward solutions
Pub : University Press

Business English
Pub : Orient Longman

Speak Better Write Better English

Word Power Made Easy
By Norman Lewis
Pub : DC Books

Facing the interview board
By AK Mani
Pub : Dream Tech Press ,NewDelhi

First Steps in number theory
By Shailesh Shirali
Pub : University Press

How to Face Interview
By S.K TharaFadker
Pub : Dc Books

Friday, March 13, 2009

A College Song (only for Keralites)

Keralam Keralam Keralam Manoharam
Keralam Keralam Keralam Mahattaram
Padavalangha Kalluketti Valavuteertha Keralam
Keralam Keralam Keralam Manoharam
Arikuzhachu Podi varuthu puttu chutta Keralam
Keralam Keralam Keralam Manoharam
Uzhunnarachu Vadayundakki tulakalitta Keralam
Keralam Keralam Keralam Manoharam
Anakettulla PowerKattulla Vedikettulla Keralam
Keralam Keralam Keralam Manoharam
Pillayulla Maniyulla Chandiyulla Keralam
Keralam Keralam Keralam Manoharam
Keralam Keralam Keralam Mahattaram


Shyama varna roopini, kadora bashini priye prema lekhanam ninaku njan tharunnu sharike
Vattamulla pottu venamennu ne paranjathum muttalathu vittathum pottu vaangi thannathum
Shyama varna roopini, kadora bashini priye prema lekhanam ninaku njan tharunnu sharike,
Pulliyulla blouse venamennu ne paranjthum' mundu oori vittathum,
Blouse vaangi thannathum shyama varna roopini,
Kadora bashini priye prema lekhanam ninaku njan tharunnu sharike,
Class cut cheythathum, mattinikum poyathum, ninde sir kandthum puli vadi odichathum.
Vellaram kunnileri vagamel erinjathum, unnam theti kallu randum nettiyil pathichathum,
Pokkamulla mathilu chadi ninde veetyl vannathum, ninde thantha kandathu pulide kombodichathum,
Njondana ninde chettan, vandi kondidichathum mandiyaya ninde thalla...chirava kondadichathum fittayi mathilu chadi Ninde veetyl vannthum, ninde achan kandathum, enna thalli konnathum enkilum en sharike ne, ende badra thanne de,
Ninne ketti kondu povan,enda janmam poyadi....

Wednesday, March 4, 2009

Start menu delay

Hkey_current_user\control Panel\desktop locate

Menushowdelay change value from 400 to 15

To hide drives

HKEY_LOCALMACHINE\Software\Microsoft\Windows\
CurrentVersion\Policies\Explorer - this changes the settings for all users on the machine.
You may have to create the key folder "Explorer" manually.

3. In the Explorer key folder, create a new DWORD value by right-clicking Explorer, then
choosing New DWORD value. Name the value "NoDrives" (without the quotes). This value defines
local and network drive visibility for each logical drive on the computer. All drives will be
visible as long as this value's data is set to 0.

4. Following the table below, enter the decimal number corresponding to the drive(s) you want
to hide as NoDrives value data. When you right-click on NoDrives and choose Modify, make
sure you select Decimal base, not Hexadecimal.And restart windows

Drive Number to hide
A: 1
B: 2
C: 4
D: 8
E: 16
F: 32
G: 64
H: 128
I: 256
J: 512
K: 1024
L: 2048
M: 4096
N: 8192
O: 16384
P: 32768
Q: 65536
R: 131072
S: 262144
T: 524288
U: 1048576
V: 2097152
W: 4194304
X: 8388608
Y: 16777216
Z: 33554432
All drives 67108863

Change Win Pswd

Have you ever forgotten your windows password and never been able to
Retrieve those files you longed?

Well heres how to change your password without knowing the old one.

1)when the computer boots keep pressing F8 until you get to a boot screen.
2)Select boot in DOS.
3)Get yourself into the windows folder by typing "cd windows" (without the "")
4)next type "dir *.pwl". This will display the login password files.
5)after you found out the one that’s yours (or ne1 else’s you want to get into) type del
Username.pwl
6)Reboot the computer
7)When you have to login, put in the username you deleted, and enter ne password you like.
8)The computer will say something like "No password. Would you like to use this one? Confirm?
9)Put your password in
10) sit back and watch all the noobs try and open their windows boxes with the wrong password