Sunday 27 December 2009

Vmware : Vsphere Console Desktop Shortcut

For Vmware infrastructure :
"%PROGRAM_FILES%\VMware\Infrastructure\Virtual Infrastructure Client\4.0\vmware-vmrc.exe" -h 192.168.69.42 -u username -p PASSWORD -d "[datastore1] Ninefingers2/Ninefingers2.vmx"

Add -X for full screen


Monday 30 November 2009

Windows : What is the NTFS cluster size ?

* Run chkdsk on the drive - chkdsk C:
 * Cluster size if third line from bottom eg. 4096 bytes in each allocation unit

Thursday 12 November 2009

Excel : Bullets in a cell

  1. Position the insertion point at the beginning of your text entry.
  2. Type a symbol that you want to use as a bullet. To create the bullet character, press ALT+0149 (type 0149 on the numeric keypad).


Saturday 31 October 2009

ESXI : SSH enable

  1. alt-f1 at console screen - (Note: you will not see your typing on this screen, just trust us, it is there).
  2. unsupported
  3. root pw
  4. vi /etc/inetd.conf
  5. delete the “#” from ssh
  6. services.sh restart

Nb may need to ps aux |grep inetd (getting the PID) and kill -HUP PID

scp works, sftp does not.




Friday 30 October 2009

New squeezebox server

* Centos 5.4

* squeezeboxserver-7.4.0-1.rpm
  wget http://triodeplugins.googlecode.com/files/BBCiPlayer-v0.9f.zip
  manually install BBCiPlayer plugin - would not work auto
  into /var/lib/squeezeboxserver/cache/InstalledPlugins/Plugins/
 
* vi /etc/sysconfig/network-scripts/ifcfg-eth0
DEVICE=eth0
BOOTPROTO=none
ONBOOT=yes
TYPE=Ethernet
NETMASK=255.255.255.0
IPADDR=192.168.69.240
GATEWAY=192.168.69.69

* vi /etc/resolv.conf
nameserver 212.23.3.100
nameserver 212.23.6.100

* Add additional vm disk 150Gb
 fdisk /sdb
 mkfs.ext3 /sdb1
* vi /etc/fstab
/dev/sdb1               /u01                    ext3    defaults        0 0

* Copy all music
  mkdir /local/Music
  mkdir /local/Playlists

* vi /etc/samba/smb.conf
workgroup = WORKGROUP
[Public]
        path = /local/Public
        writeable = yes
        guest ok = yes

[Music]
        path = /local/Music
        writeable = no
        guest ok = yes

[Photo]
        path = /local/Photos
        writeable = no
        guest ok = yes

* chkconfig --level 2345 smb on

* vi /etc/yum.repos.d/dag.repo
[dag]
name=Dag RPM Repository for Red Hat Enterprise Linux
baseurl=http://apt.sw.be/redhat/el$releasever/en/$basearch/dag
gpgcheck=1
enabled=1

* vi /etc/yum.repos.d/rpmforge.repo
[rpmforge]
name = Red Hat Enterprise $releasever - RPMforge.net - dag
mirrorlist = http://apt.sw.be/redhat/el5/en/mirrors-rpmforge
enabled = 1
protect = 0
gpgkey = file:///etc/pki/rpm-gpg/RPM-GPG-KEY-rpmforge-dag
gpgcheck = 1

* tar xvfz VMwareTools-4.0.0-171294.tar.gz
 cd vmware-tools-distrib/
 ./vmware-install.pl

* libtorrent-0.12.0-1.el5.rf - nb. had to downgrade or no connection
  rtorrent-0.8.0-1.el5.rf

* vi /etc/inittab
id:3:initdefault:

* Copy photos to /u01

* Install squid
 Copy squid.conf and allowed-sites

* Install dnsmasq
 Copy dnsmasq.conf
 Update /etc/hosts

* Install lighttpd
 Copy config
 Copy proxy.pac and link to /srv/www/lighttpd
 Link /u01/Photos to /srv/www/lighttpd
 Available at photo.steampig.co.uk/album


Saturday 17 October 2009

Vmware squeezecenter - now includes BBC iplayer

* Vmware workstation machine
* Install Centos 5.3 dvd - Gnome desktop + server heavily cut down - dhcp, no firewall or selinux
* yum install Mysql and mysql server
* Setup vmware share for host resource directory
* rpm install squeezecenter
* Switch to static ip /etc/sysconfig/network - gateway xx.xx.xx.xx /etc/sysconfig/network-scripts/ifcfg-eth0 - BOOTPROTO=static IPADDR=xx.xx.xx.xx NETMASK=255.255.255.0
* Set up static dns /etc/resolv.conf - nameserver xx.xx.xx.xx
* Setup vmware share for host music directory - ln -s from /dev/hgfs directory
* Squeezecenter config - music dir, playlist dir, add iplayer and lazysearch2 plugins, disable unwanted plugins
* Test with softsqueeze
* Re-point squeezeboxes and customise menus - also set alarm
* Increase internet radio buffer to 10 seconds Squeezecenter-Settings-Advanced-Network-Radio Station Buffer Seconds

"F:\Program Files\VMware\VMware Workstation\vmware.exe" -x  "G:\Iggy (Centos 5.3)\Iggy (Centos 5.3).vmx"


Friday 9 October 2009

Oracle : SQL Developer Data Modeller

Pros
  • Full oracle support
  • Also SQL Server (2005?) and DB2
  • Java based so linux too
  • Data model v.similar to Designer
  • Reverse engineer and generate scripts
  • Diff ?
  • No db required - xml files - so portable
  • Repository in the offing
Cons
  • Expensive - $3k list
  • Unable to draw arbitrary lines for unsupported relationships
  • No customisation
  • Process flows - unable to do functional decomoposition (?)



Tuesday 6 October 2009

SQL Server : Non-standard ports

When you connect to a server using a default instance configuration (e.g. "myserver"), the SQL client calls the server on the standard port: 1433.
When you call a server using a named instance but lacking a port (e.g. "myserver\instancename"), the SQL client calls SQL Server's management service on port 1434.
The management service replies with a dynamically assigned port (chosen at sql engine service startup) for the instance and the client connection proceeds using that new port.
If the network firewall doesn't have either the management service port nor the dynamic port(s) open the connections fail.

Using dynamic ports for SQL instances means that the instance names are like a SQL DNS system. They are simply there to help the server resolve a dynamic port. Once the port is resolved, the name is superfluous.
You can use additional, and thus non-standard, ports for the additional SQL instances so as to know the ports so the firewall could be configured to allow them.
Once you have a predefined port assigned to a named instance you no longer need the actual instance name for the connection but can simply connect using the server name (or IP) and port number, for example: "myserver,1432".
Also you no longer need to run the SQL browser service on the server that provides the instance name lookup.

Friday 11 September 2009

Linux : add additonal disk as a logical volume

# Add new disk as a logical volume

# Create partition
fdisk -l

fdisk /dev/sdb
n-1-rtn-rtn

# Create a physical volume
pvcreate /dev/sdb1
pvdisplay

# Create a virtual group VolGroup01
vgcreate VolGroup01 /dev/sdb1

# Get PE size from vgdisplay
vgdisplay
 Total PE              4094


# Create a logical volume
lvcreate -n vol01 -l 4094 VolGroup01
lvdisplay

mkfs.ext3 /dev/VolGroup01/vol01

# Add to fstab
vi /etc/fstab
/dev/VolGroup01/vol01    /u01         ext3    defaults        0 0

mount /u01


Thursday 10 September 2009

BOXI : Restore to point in time with oracle

  • Shut down services on lonmisapp01
  • Restore database to point in time before deletion
    Export ORACLE_SID=MISDB1
  • Identify required sequence number from alert log
    139776 (8:04 am)
  • Disable dataguard
    dgmgrl<br />DGMGRL> connect sys<br />DGMGRL> show configuration<br />DGMGRL> disable configuration<br />
  • Run rman nocatalog
    connect target<br />shutdown immediate<br />startup mount<br /><br />run {<br />	set until sequence 139776;<br />	restore database;<br />	recover database;<br />	}<br /><br />alter database open;<br />
  • Restore file store to point in time before deletion - safe to use last full backup
    cd /u04/oradata/backup/MISDB1/BO-filestore<br />tar xvfz lonmisapp01_BO_FILESTORE_20090910012217_20426.tgz<br /><br />mv /u04/boxi/lonmisapp01/FileStore /u04/boxi/lonmisapp01/FileStore_Old<br />mv ./u04/boxi/lonmisapp01/FileStore /u04/boxi/lonmisapp01/FileStore<br /><br />chown -R root: /u04/boxi/lonmisapp01/FileStore<br />
  • Restart services on lonmisapp01 and test


Oracle : Refresh the dataguard instance and re-enable

  • Disable dataguard on primary
    dgmgrl
    DGMGRL> connect sys
    DGMGRL> show configuration
    DGMGRL> disable configuration
  • Shutdown standby in sqlplus
    alter database recover managed standby database cancel
      shudown immediate
  • Clear out standby data files
    cd /u04/oradata/STANDBYDB/<br />rm *.dbf<br />
  • Create backup of primary control file and then shut down primary in sqlplus
    alter database create standby controlfile as '/tmp/stnd_controlfile.bkp';<br />shutdown immediate;<br />
  • Copy control file to standby and then all data files (NOT archive logs, redo logs, standby logs)
    scp /tmp/stnd_controlfile.bkp oracle@greoemdb01:/u04/oradata/MISDG1<br />cd /u04/oradata/PRIMARYDB/<br />scp * oracle@greoemdb01:/u04/oradata/STABDBYDB<br />
  • Startup standby in sqlplus
    startup mount<br />alter database recover managed standby database disconnect;<br />
  • Startup primary in sqlplus
    startup <br />
  • Re-enable dataguard configuration in dgmgrl
    dgmgrl<br />DGMGRL> connect sys<br />DGMGRL> show configuration<br />DGMGRL> enable configuration<br />
  • Check db logs on both sides!

Note
  • did not need to create standby logs as they already exist on the primary (and so are referenced in the control file (possibly) ) 
  • did not need to rename any files on the standby as the DB_FILE_NAME_CONVERT and LOG_FILE_NAME_CONVERT params are both set correctly


Wednesday 9 September 2009

Oracle : 11GR2 - File Watchers

Trigger scheduler jobs when a glob-matched file is created in a directory

BEGIN
DBMS_SCHEDULER.CREATE_FILE_WATCHER(
FILE_WATCHER_NAME => 'EOD_FILE_WATCHER',
DIRECTORY_PATH => '?/eod_reports',
FILE_NAME => 'eod*.txt',
CREDENTIAL_NAME => 'WATCH_CREDENTIAL',
DESTINATION => NULL,
ENABLED => FALSE);
END;
/

SELECT file_watcher_name, destination, directory_path, file_name, credential_name
FROM dba_scheduler_file_watchers;

<a href="http://download.oracle.com/docs/cd/E11882_01/server.112/e10595/scheduse005.htm#CIABIEJA">Ref</a>


Oracle : 11GR2 - IGNORE_ROW_ON_DUPKEY_INDEX Hint

Silently ignore new rows that violate a single unique index. 
  • The IGNORE_ROW_ON_DUPKEY_INDEX hint applies only to single-table INSERT operations. It is not supported for UPDATE, DELETE, MERGE, or multitable insert operations.
  • IGNORE_ROW_ON_DUPKEY_INDEX causes the statement to ignore a unique key violation for a specified set of columns or for a SINGLE specified index.
  • When a unique key violation is encountered, a row-level rollback occurs and execution resumes with the next input row.
  • As with all hints, a syntax error in the hint causes it to be silently ignored. The result will be that ORA-00001 will be caused, just as if no hint were used.
Ref

Bulk operations?
Multiple rows with same UK being inserted - which get in - arbitrary ?

Oracle : 11GR2 - Recursive subqueries for hierarchy traversal

Recursive Subquery Example
===========================
WITH
  reports_to_101 (eid, emp_last, mgr_id, reportLevel) AS
  (
     SELECT employee_id, last_name, manager_id, 0 reportLevel
     FROM employees
     WHERE employee_id = 101
   UNION ALL
     SELECT e.employee_id, e.last_name, e.manager_id, reportLevel+1
     FROM reports_to_101 r /* MAGIC IS HERE */
         ,employees e
     WHERE r.eid = e.manager_id
  )
SELECT eid, emp_last, mgr_id, reportLevel
FROM reports_to_101
ORDER BY reportLevel, eid;

       EID EMP_LAST                      MGR_ID REPORTLEVEL
---------- ------------------------- ---------- -----------
       101 Kochhar                          100           0
       108 Greenberg                        101           1
       200 Whalen                           101           1
       203 Mavris                           101           1
       204 Baer                             101           1
       205 Higgins                          101           1
       109 Faviet                           108           2
       110 Chen                             108           2
       111 Sciarra                          108           2
       112 Urman                            108           2
       113 Popp                             108           2
       206 Gietz                            205           2

Ref


Oracle : 11GR2 - LISTAGG - the long missing string concatentation built-in

Finally

LISTAGG Example
===============
SELECT department_id "Dept.",
  LISTAGG(last_name, '; ')
   WITHIN GROUP (ORDER BY hire_date) "Employees"
   FROM employees
   GROUP BY department_id;

Dept. Employees
------ ------------------------------------------------------------
    10 Whalen
    20 Hartstein; Fay
    30 Raphaely; Khoo; Tobias; Baida; Himuro; Colmenares
    40 Mavris
    50 Kaufling; Ladwig; Rajs; Sarchand; Bell; Mallin; Weiss; Davie
       s; Marlow; Bull; Everett; Fripp; Chung; Nayer; Dilly; Bissot
       ; Vollman; Stiles; Atkinson; Taylor; Seo; Fleaur; Matos; Pat
       el; Walsh; Feeney; Dellinger; McCain; Vargas; Gates; Rogers;
        Mikkilineni; Landry; Cabrio; Jones; Olson; OConnell; Sulliv
       an; Mourgos; Gee; Perkins; Grant; Geoni; Philtanker; Markle
    60 Austin; Pataballa; Lorentz; Ernst; Hunold
    70 Baer

  • Throws a ORA-01489: result of string concatenation is too long is > 4000 chars ! -
  • No way to suppress (?) so need to avoid
with base_data as (
select
table_name,
sum(length(table_name)) over (order by table_name)
  + row_number () over (order by table_name)        tot_length
from dba_tables
where 1=1
and owner = 'SYS'
order by table_name
)
select
listagg(table_name,';') within group (order by table_name)
from base_data b
where tot_length < 4000

Ref



Oracle : 11GR2 - Selected new features

Drawn from the 11GR2 New features doc

Definitely Interesting
1.2.2.4 IGNORE_ROW_ON_DUPKEY_INDEX Hint for INSERT Statement
1.3.1.1 Analytic Functions 2.0
1.3.1.2 Recursive WITH Clause
1.3.2.2 Preprocessing Data for ORACLE_LOADER Access Driver in External Tables
1.5.2.1 E-mail Notification
1.5.2.2 File Watcher
1.5.2.4 Remote Database Jobs
1.5.3.1 Data Pump Legacy Mode

Possibly Interesting
1.2.3.2 Configurable Real-Time Query Apply Lag Limit
1.9.2.3 Automatic Patching of Time Stamp With Time Zone Data
1.3.4.2 Minimal Effort Parallel Execution - Auto Degree of Parallelism (DOP) and Queuing
1.9.2.10 Enable Sampling for Active Data Guard
1.9.2.12 Global Oracle RAC ASH Report + ADDM Backwards Compatibility

RAC - Possibly Interesting
1.4.1.6 Grid Plug and Play (GPnP)
1.4.1.7 Oracle Restart
1.4.1.10 Role-Separated Management
1.4.1.13 Enterprise Manager-Based Clusterware Resource Management
1.4.1.14 Enterprise Manager Provisioning for Oracle Clusterware and Oracle Real Application Clusters
1.4.1.17 Configuration Assistant Support for Removing Oracle RAC Installations
1.4.1.18 Oracle Universal Installer Support for Removing Oracle RAC Installations
1.4.1.22 Out-of-Place Oracle Clusterware Upgrade
1.4.1.26 SRVCTL Support for Single-Instance Database in a Cluster

Definitely Interesting

1.2.2.4 IGNORE_ROW_ON_DUPKEY_INDEX Hint for INSERT Statement
With INSERT INTO TARGET...SELECT...FROM SOURCE, a unique key for some to-be-inserted rows may collide with existing rows. The IGNORE_ROW_ON_DUPKEY_INDEX allows the collisions to be silently ignored and the non-colliding rows to be inserted. A PL/SQL program could achieve the same effect by first selecting the source rows and by then inserting them one-by-one into the target in a block that has a null handler for the DUP_VAL_ON_INDEX exception. However, the PL/SQL approach would take effort to program and is much slower than the single SQL statement that this hint allows.
This hint improves performance and ease-of-programming when implementing an online application upgrade script using edition-based redefinition.

1.3.1.1 Analytic Functions 2.0
New and enhanced analytical functions are introduced in this release. A new ordered aggregate, LISTAGG, concatenates the values of the measure column. The new analytic window function NTH_VALUE (a generalization of existing FIRST_VALUE and LAST_VALUE functions) gives users the functionality of retrieving an arbitrary (or nth) record in a window.
The LAG and LEAD functions are enhanced with the IGNORE NULLS option.
The new and enhanced SQL analytical functions allow more complex analysis in the database, using (simpler) SQL specification and providing better performance.
See Also:
Oracle Database Data Warehousing Guide for details

1.3.1.2 Recursive WITH Clause
The SQL WITH clause has been extended to enable formulation of recursive queries.
Recursive WITH clause complies with the American National Standards Institute (ANSI) standard. This makes Oracle ANSI-compatible for recursive queries.
See Also:
Oracle Database SQL Language Reference for details

1.3.2.2 Preprocessing Data for ORACLE_LOADER Access Driver in External Tables
The syntax for the ORACLE_LOADER access driver is extended in this release to allow specification of a program to preprocess the data files that are read for the external table. The access parameters can specify the name of a directory object and the name of an executable file in that directory object. When the access driver needs to read data from a file, it creates a process that runs the specified program, passing in the name of the data file. The output from the program is passed into the access driver which parses the data into records and columns.
The initial use of this feature is by a customer who needs to load data that is stored in compressed files. The user specifies the name of the program used to decompress the file as part of the access parameters. The access driver reads the output of the decompression program.
Large customers want to load data from compressed files which requires less disk space and uses the I/O bandwidth between the disk and memory more efficiently.

1.5.2.1 E-mail Notification
Oracle Database 11g Release 2 (11.2) users can now get e-mail notifications on any job activity.
This feature improves efficiency by enabling users to be notified of any job activity that is of interest to them without having to constantly monitor the job.

1.5.2.2 File Watcher
File watcher enables jobs to be triggered when a file arrives on a given machine.
This feature improves efficiency and ease-of-use. Jobs with file dependencies are automatically triggered when the specified file is received instead of constantly monitoring for the file.

1.5.2.4 Remote Database Jobs
This feature enables users to run PL/SQL blocks or stored procedures that reside in a remote database as a job.
This is a key feature for Enterprise Manager scheduling. It improves efficiency and ease-of-use by enabling job scheduling in a distributed environment to be managed centrally.

1.5.3.1 Data Pump Legacy Mode
Data Pump Legacy Mode provides backward compatibility for scripts and parameter files used for original Export and Import scripts.
This feature enables users to continue using original Export and Import scripts with Data Pump Export and Import. Development time is reduced as new scripts do not have to be created.

Possibly Interesting

1.2.3.2 Configurable Real-Time Query Apply Lag Limit
A physical standby database can be open for read-only access while redo apply is active only if the Oracle Active Data Guard option is enabled. This capability is known as real-time query.
The new STANDBY_MAX_DATA_DELAY session parameter can be used to specify a session-specific apply lag tolerance, measured in seconds, for queries issued by non-administrative users to a physical standby database that is in real-time query mode.
This capability allows queries to be safely offloaded from the primary database to a physical standby database, because it is possible to detect if the standby database has become unacceptably stale.

1.9.2.3 Automatic Patching of Time Stamp With Time Zone Data
Time stamp with time zone data could become stale in the database tables when the time zone version file is updated. Today, users have to manually fix the affected data. This feature updates the system and user data transparently with minimal downtime and provides automatic and transparent patching of time stamp with time zone data whenever a time zone file is updated.
Also, when a server time zone version is patched, all of the clients that communicate with the server need to be patched as well. With this feature, OCI, JDBC, Pro*C, and SQL*Plus clients can now continue to work with the server without having to update their client-side files.
This new feature provides automatic and transparent patching of time stamp with time zone data whenever a time zone file is updated.

1.3.4.2 Minimal Effort Parallel Execution - Auto Degree of Parallelism (DOP) and Queuing
When activated, Oracle determines the optimal degree of parallelism (DOP) for any given SQL operation based on the size of the objects, the complexity of a statement, and the existing hardware resources.

1.9.2.10 Enable Sampling for Active Data Guard
Active Session History (ASH) is now available on standby systems.
Having ASH data available on standby systems for Data Guard environments allows customers to troubleshoot performance problems specific to their standby environments.

1.9.2.12 Global Oracle RAC ASH Report + ADDM Backwards Compatibility
The Active Session History (ASH) report now includes cluster-wide information, greatly enhancing it's utility in identifying and troubleshooting performance issues that span nodes for a cluster database.

RAC - Possibly Interesting

1.4.1.6 Grid Plug and Play (GPnP)
Grid Plug and Play (GPnP) eliminates per-node configuration data and the need for explicit add and delete nodes steps. This allows a system administrator to take a template system image and run it on a new node with no further configuration. This removes many manual operations, reduces the opportunity for errors, and encourages configurations that can be changed easily. Removal of the per-node configuration makes the nodes easier to replace, because they do not need to contain individually-managed state.
Grid Plug and Play reduces the cost of installing, configuring, and managing database nodes by making their per-node state disposable. It allows nodes to be easily replaced with regenerated state.

1.4.1.7 Oracle Restart
Oracle Restart improves the availability of your single-instance Oracle database. Oracle Restart automatically restarts the database instance, the Automatic Storage Management (ASM) instance, the listener, and other components after a hardware or software failure or whenever your database host computer restarts. Server Control (SRVCTL) is the command line interface to manage Oracle processes that are managed by Oracle Restart on a standalone server.
This feature provides improved reliability and automated management of a single-instance Oracle database and the management of any process or application running on the database server.

1.4.1.10 Role-Separated Management
Role-separated management for Oracle Clusterware allows certain administrative tasks to be delegated to different people, representing different roles in the company. It is based on the idea of a clusterware administrator. The administrator may grant administrative tasks on a per resource basis. For example, if two databases are placed into the same cluster, the clusterware administrator can manage both databases in the cluster. But, the clusterware administrator may decide to grant different administrative privileges to each DBA responsible for one of those databases.
Role-separated management allows multiple applications and databases to share the same cluster and hardware resources, but ensures that different administration groups do not interfere with each other

1.4.1.13 Enterprise Manager-Based Clusterware Resource Management
New in this release is an Enterprise Manager graphical user interface (GUI) to manage various Oracle Clusterware resources with full lifecycle support. In addition to allowing the creation and configuration of resources within Oracle Clusterware, it also helps to monitor and manage resources once deployed in the cluster.
Using Oracle Enterprise Manager as a GUI to monitor and manage various Oracle Clusterware resources eases the daily management in high availability environments.

1.4.1.14 Enterprise Manager Provisioning for Oracle Clusterware and Oracle Real Application Clusters
Enterprise Manager provisioning introduces procedures to easily scale up or scale down Oracle Clusterware and Oracle Real Application Clusters.
Ease-of-implementation and management for a clustered database environment can be achieved through utilizing the terprise Manager provisioning framework.

1.4.1.17 Configuration Assistant Support for Removing Oracle RAC Installations
Database Configuration Assistant (DBCA), Database Upgrade Assistant (DBUA), and Net Configuration Assistant (NETCA) have been updated to support the complete deinstallation and deconfiguration of Oracle RAC databases and listeners.
This support improves the manageability of an Oracle RAC environment through automation of deinstallation and deconfiguration of Oracle RAC databases.

1.4.1.18 Oracle Universal Installer Support for Removing Oracle RAC Installations
The installer can clean up a failed Oracle Clusterware installation or upgrade of an environment prior to reattempting the operation. This ensures that the reattempted operation is done over a clean environment, thereby eliminating the chances of errors related to environmental inconsistencies.
Easily cleaning up an environment provides improved Oracle RAC manageability and deployment.

1.4.1.22 Out-of-Place Oracle Clusterware Upgrade
A new version of Oracle Clusterware is now installed into a separate home from the current installation. This reduces the downtime required to upgrade a node in the cluster and facilitate the provisioning of clusters within an enterprise.
The benefit is a reduction in planned outage time required for cluster upgrades which assists in meeting availability service levels. This also makes it easier to provide a standard installation across the enterprise.

1.4.1.26 SRVCTL Support for Single-Instance Database in a Cluster
Using SRVCTL, you can register a single-instance database to be managed by Oracle Clusterware. Once registered, Oracle Clusterware starts, stops, monitors, and restarts the database instance.
This feature provides an improved management interface which makes it easy to provide higher availability for single-instance databases that are running on a server that is part of a cluster.

Fini



Thursday 3 September 2009

Oracle: Exporting Grid Control Repository Database

Resolve EXP-00079 EXP-00056 (exp) and ORA-28112 (expdp) Errors when Exporting Grid Control Repository Database using Traditional Export or Datapump Export (1oG+)

grant exempt access policy to EXPORTING_USER;




Oracle : Archivelog mode 2

# For RAC bring down other instances
srvctl stop instance -d NTPDB1 -i NTPDB12

# On remaining instance
alter system set log_archive_dest_1='location=/u02/volntpdblogs01/oradata/NTPDB1/archive' scope=spfile
alter system set log_archive_format='%t_%s_%r.dbf' scope=spfile
shutdown immediate;
startup mount;
alter database archivelog;
alter database open;
ALTER SYSTEM SWITCH LOGFILE;

# For RAC bring back other instances
srvctl start instance -d NTPDB1 -i NTPDB12


Tuesday 1 September 2009

Oracle : Drop corrupt AQ tables

alter session set events '10851 trace name context forever, level 2';

This disables ORA-24005 message then table can be dropped using conventional SQL DROP


Friday 21 August 2009

Windows : Count files

From command line - not excludes hidden files
dir "C:\" /b/s |find /v /c "::"

Tuesday 4 August 2009

Linux : Renew dhcp lease

sudo dhclient -r

(windows = ipconfig \r)

Vmware Server : Port redirection for NAT network access to guest SSH+RDP

* Add lines to the NAT config to redirect the host ports to the required guest ports
vi /etc/vmware/vmnet8/nat/nat.conf

# SSH
#      ssh -p 8889 root@localhost
8822 = 192.168.84.129:22

# RDP
8889 = 192.168.84.128:3389

* Restart the vm network services
/usr/lib/vmware/net-services.sh restart


Thursday 30 July 2009

Friday 24 July 2009

Windows Server 2003: Install DNS and Active Directory

http://www.petri.co.il/how_to_install_active_directory_on_windows_2003.htm



Wednesday 22 July 2009

OEM : Netapps custom reports

1. Grant additional perms
Need following perms on OEM repos as query is reliant on base tables not oem application views - could rework later perhaps
grant select on MGMT_METRICS_RAW to mgmt_view;
grant select on MGMT_METRICS to mgmt_view;
grant select on MGMT_TARGETS to mgmt_view;
2. Create first Report
2.1 Create Report
Navigate to Reports->Create
Title : NTAP001 - Netapps Raw IO-Rate
Category : Custom Reports (may have to add)
Subcategory : Development (may have to add)
Target : Target Type=Network Appliance Filer
Time Period : This reoport has a time period = ticked. Time Period = This Year, Allow the report viewer... = ticked

2.2 Create chart element
Navigate to tab Elements->Add
Select     Chart from SQL
Navigate to Set Parameters
Header : Io Rate
Statment :
    select
    mt.TARGET_NAME,
    mrw.COLLECTION_TIMESTAMP,
    --mm.column_label,
    mrw.VALUE
    /*-- DEBUG
    ,mm.COLUMN_LABEL_NLSID
    ,'MRW->'
    ,mrw.*
    ,',MT->'
    ,mt.*
    ,'MM->'
    ,mm.*
    */
    from
    MGMT_METRICS_RAW mrw,
    MGMT_METRICS mm,
    MGMT_TARGETS mt
    where 1=1
    and mrw.metric_guid    = mm.metric_guid
    and mrw.TARGET_GUID    = mt.TARGET_GUID
    and mt.TARGET_TYPE     = mm.TARGET_TYPE
    and mt.type_meta_ver   = mm.type_meta_ver
    and (mt.TARGET_TYPE = 'netapp_filer' )
    AND mrw.collection_timestamp >=      ??EMIP_BIND_START_DATE??
    and mrw.collection_timestamp <=       ??EMIP_BIND_END_DATE??
    and mt.TARGET_GUID          = ??EMIP_BIND_TARGET_GUID??
    and column_label_nlsid in (
     'netapp_filer_total_disk_io_rate'
    --,'netapp_filer_pct_busy'
    --,'netapp_filer_nfs_calls_rate'
    --,'netapp_filer_total_network_io_rate'
    )
    ORDER BY
    mt.TARGET_NAME,
    mrw.COLLECTION_TIMESTAMP,
    mm.column_label
Statement type : SQL
Legent Position : Right
Width : 1000
Height : 400

2.3 Create Table element
Navigate to tab Elements->Add
Select     Table from SQL
Repeat settings for Chart from SQL element above

3. Clone to create other reports
Repeat altering Sql in each case for
    NTAP001 - Netapps Raw IO-Rate = netapp_filer_total_disk_io_rate
    NTAP002 - Netapps Raw CPU %Busy = netapp_filer_pct_busy
    NTAP003 - Netapps Raw NFS Call Rate = netapp_filer_nfs_calls_rate
    NTAP004 - Netapps Raw Network IO Rate = netapp_filer_total_network_io_rate


OEM : Add ability to run queries on target dbs for OEM report elements

  • Login as sys on the Grid Repository and execute :
    insert into sysman.mgmt_ip_report_elem_def values('target_user_table_from_sql','database_target_type',
    'target_user_table_from_sql',
    'oracle.sysman.db.util.reports.TableTargetRenderController',0,NULL,'EM',NULL,
    '10.2.0.1.0');

    Insert into SYSMAN.MGMT_IP_ELEM_PARAM_CLASSES
    (ELEMENT_NAME_NLSID, ELEMENT_TYPE_NLSID, ELEMENT_PARAM_CLASS, DISPLAY_ORDER)
    Values ('target_user_table_from_sql', 'database_target_type','oracle.sysman.eml.ip.render.elem.HeaderParamController',
    1);

    Insert into SYSMAN.MGMT_IP_ELEM_PARAM_CLASSES
    (ELEMENT_NAME_NLSID, ELEMENT_TYPE_NLSID, ELEMENT_PARAM_CLASS, DISPLAY_ORDER)
    Values ('target_user_table_from_sql', 'database_target_type', 'oracle.sysman.eml.ip.render.elem.SQLStatementParamController', 2);
    Commit;
  • In GC there is now an element type on the Report page called "target_user_table_from_sql" which allows scripts to run against a Target database.


OEM : UDMs and Custom reports

1. Create user defined metric on LIVE1, ESTDB2 (has to be a db), DBQLIVE1
  • Navigate to Targets->Databases->Selected Database->User-Defined Metrics->Create
  • Metric Name    :    ODL_NEW_CLIENT_APPS_THISMONTH
  • Metric Type :    NUMBER       
  • SQL Query Output : Single Value
  • SQL Query :   
               select count(9) ct from
               (select program_name
                      ,min(least(nvl(first_allow_time,sysdate+1),nvl(first_deny_time,sysdate+1))) min_first_time 
                from odl_dbadmin_dbo.client_app_login
                where 1=1
                group by program_name
                order by 2 desc)
            where min_first_time >= sysdate-30
  • Db Credentials : User/Password
  • Comparison Operator : >
  • Warning : 0
  • Alert Message : ODL_NEW_CLIENT_APPS_THISMONTH: %value% new applications detected
  • Schedule
  • Enabled : On
  • Start : Immediately
  • Repeat every : 24 hours
2. Add custom report to show all UDMs
2.1  Create Report
  • Navigate to Reports->Create
  • Title : ODL010 - ODL User-defined Metric (UDM) Current Values
  • Category : Custom Reports (may have to add)
  • Subcategory : Development (may have to add)
  • Target : Use specified target = EMREP2.ODL (OEM repos)
  • Privileges : Run report usign target privs = ticked
  • Time Period : This reoport has a time period = ticked  Last 24 hours
2.2 Add query as a new element
  • Navigate to tab Elements->Add
  • Select     target_user_table_from_sql
  • Navigate to Set Parameters
  • Header : Latest UDM values
  • Statment :
           SELECT DISTINCT
            key_value "Metric Name", 
            UPPER(target_name) "Target Name",             
            TO_CHAR(collection_timestamp, 'MM-DD-YYYY HH24:MI') "Last Collected" 
            ,nvl(to_char(data_value_int),string_value) "Metric Value"
            --,M.*
            FROM sysman.em$current_metrics m 
            WHERE 1=1
            AND METRIC_NAME = 'SQLUDM'
            AND key_value like 'ODL%'
            ORDER BY 1, 2
  • Statement type : SQL
  • Rows to display : 100

2.3 Set a preferred credentials against the OEM repos target for the report running user
  • Navigate to Preferences->Preferred Credentials
  • Select Database Instance->Set Credentials
  • Fill in valid user/password for OEM Report


Friday 17 July 2009

Oracle : Tracing the session behind an ORA-54 resource busy message

select    oracle_username || ' (' || s.osuser || ')' username
,    s.sid || ',' || s.serial# sess_id
,    owner || '.' ||    object_name object
,    object_type
,    decode(    l.block
    ,    0, 'Not Blocking'
    ,    1, 'Blocking'
    ,    2, 'Global') status
,    decode(v.locked_mode
    ,    0, 'None'
    ,    1, 'Null'
    ,    2, 'Row-S (SS)'
    ,    3, 'Row-X (SX)'
    ,    4, 'Share'
    ,    5, 'S/Row-X (SSX)'
    ,    6, 'Exclusive', TO_CHAR(lmode)) mode_held
from    v$locked_object v
,    dba_objects d
,    v$lock l
,    v$session s
where     v.object_id = d.object_id
and     v.object_id = l.id1
and     v.session_id = s.sid
order by oracle_username
,    session_id

ALTER SYSTEM KILL SESSION '109,27585'; --sess_id

Saturday 11 July 2009

Firefox 3.5 startup speedup

Remove files from the following directories which are scanned for security:

C:\Documents and Settings\*user*\Local Settings\History
C:\Documents and Settings\*user*\Local Settings\Temporary Internet Files
C:\Documents and Settings\*user*\My Recent Documents
C:\Documents and Settings\*user*\Temp\

Thursday 25 June 2009

Windows : Remote desktop - terminal server has exceeded the maximum ...

Getting a RC console session
  • Console option for mstsc is removed from Pre vista sp1, xp sp3, server 2008
  • For connecting from older machines to older machines - mstsc -v:servername /f -console
  • For connecting from new machines to older machines there is a different switch - mstsc -v:servername /f /admin
  • For connecting from to new machines this way - cannot be done
From the command line
  • If you can get an admin connection - net use /user:[username] \\servername\share
  • Then can query/kill sessions remote (below)
Killing other non-console sessions
  • From the command line - query session /server:servername
  • Then reset session [ID] /server:servername



Tuesday 23 June 2009

Windows : RunDll links

Sharepoint - Map subsite to a drive

Mapping the sharepoint wiki as a mapped drive

  • From explorer (NOT internet explorer) choose Tools->Map Network Drive
  • Select a free Drive: letter (e.g. Z:)
  • In the Folder: field type the url http://sharepoint/Wiki
  • Check reconnect at login as required
  • Press
  • Nb. Only sharepoint subsites can be mapped this way

Adding sharepoint as a Network Place

  • Run the add network place wizard - rundll32 netplwiz.dll,AddNetPlaceRunDll
  • Click Next and Select “Choose another network location” click “Next”.
  • Type the address of SharePoint site/sub site. (e.g. http://p2-Testsite/Testsubsite/)
  • Type in the username and password.
  • Navigate to the Document library/list and create a Shortcut.


<b><b>
</b></b>
http://www.phase2.com/blog/?p=96


Sharepoint : Embed excel in the wiki

To add an excel spreadsheet for viewing in sharepoint

  • Save spreadsheet to Sharepoint by selection sharepoint3/wiki/Wiki Pages/Oracle-docs/<spreadheet_name>.xlsx
  • Choose "Site Actions" (blue lozenge top right hand side) and Edit Page
  • Select Yellow "Add a Web Part" bar
  • Tick All Web Parts->Business Data->Excel Web Access
  • Select edit->Modify Shared Web Part
  • Select Workbook field using <...> button (/wiki/Wiki Pages/Oracle-docs/<spreadheet_name>.xlsx)
  • Amend display properties as required
  • Nb. Autogenerate Title will override entered title
  • Press <OK>
  • Press Exit Edit Mode
To update an excel spreadsheet stored/ussed in sharepoint
  • Navigate to required spreadsheet in sharepoint and select Open->In Excel
  • Select Open->In Excel
  • Edit spreadsheet as required
  • Overwrite using "Save As" to the original sharepoint location in (e.g. sharepoint3/wiki/Wiki Pages/Oracle-docs/<spreadheet_name>.xlsx)
  • On the wiki page choose Update->Reload Workbook to check changes


Thursday 18 June 2009

SourceSafe : Get a release based on a label

To check out the labelled release from VSS using the GUI
  • Open VSS repository \\lonnasc0601\Database VSS
  • In the tree navigate and select the node $/schema/ODL_DBSERVICES
  • Right click and select Working Folder - select a local foler to check out to and press
  • Back on the selected tree node right click again and select Show History
  • In the Project History Options dialog click 'Include Labels' and press
  • In the history table select the line where the Action is Labeled 'ZPFL_20090618_ORACLE-172' and press
  • In the Get Dialog click 'Recursive' and then 'Build Tree' and press
  • If prompted to create a folder press
To check out the labelled release from VSS using the command line
  • Setup env
set PATH=%PATH%;C:\Program Files\Microsoft Visual SourceSafe
set SSDIR=\\lonnasc0601\Database VSS
mkdir "C:\VSS\Database VSS7"
  • Run get command for a label
REM ss.exe get -V
To label projects (directories) in GUI
  • Select required project, right click and select Label
  • Enter  required label (eg. ZPFL_20090618_ORACLE-132)
  • Label will be applied to project and recursively to all sub-projects and file
To label a file in GUI
  • Select required file, select label icon on toolbar (=clock and postit note)
  • Enter label text (eg. ZPFL_20090618_ORACLE-132)
  • NOTE that a new file version if created for each label entered on a distinct file

To view labels in GUI
  • Select project or file, right click and choose SHow History
  • Check the 'Include Lables' check box
  • Labels are included in the Action column




Wednesday 20 May 2009

USB Mass Storage

First is to ensure that the HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\USBSTOR­ start value is 3.

If you are an administrator on the machine, ensure C:\windows\system32\drivers have SYSTEM user access especially USBSTOR.SYS.

If you don't have usbstor.inf in that directory or anywhere in c:\windows, go download from the web.

Go to Device Manager an uninstall the " ? " which was a result of the failed driver installation.

Plug-in the device, then when asked where to search, point to c:\windows\system32\drivers...

Wednesday 1 April 2009

RAC : Disable CRS

Disabled the three lines that keep the demons running in /etc/inittab
#h1:35:respawn:/etc/init.d/init.evmd run >/dev/null 2>&1 </dev/null
#h2:35:respawn:/etc/init.d/init.cssd fatal >/dev/null 2>&1 </dev/null
#h3:35:respawn:/etc/init.d/init.crsd run >/dev/null 2>&1 </dev/null

Marked crs as disabled in the file that controls its behaviour at start up
/etc/oracle/scls_scr/lontestdb01/root/crsstart

Check logs in /var/log/messsages and  CRS_HOME/log/<hostname>/*

Fini

Tuesday 31 March 2009

Oracle : Empty listener log

http://boomslaang.wordpress.com/2007/11/07/ooops/

Temporarily stop logging
  • lsnrctl
  • set current_listener <ListenerName>
  • set log_status=off
Move and recreate log file
  • mv <logfile> <logfile>.old
  • touch <logfile>
Restart logging
  • lsnrctl
  • set current_listener <ListenerName>
  • set log_status=on

Check entries re-appearing in logfile

Fini

Oracle : Stop listener logging

http://lc.leidenuniv.nl/awcourse/oracle/network.920/a96581/listener.htm

add following to listener.ora
  • LOGGING_<ListenerName>=OFF

Check with
  • lsnrctl reload <ListenerName>

Confirm via
  • lsnrctl
  • set current_listener <ListenerName>
  • show log_status

Fini  

Wednesday 25 March 2009

11g : Errors using exp as it is de-supported

Got some errors running exp on an 11G cluster due to missing perms

Met*link stated that exp/imp are actually desupported in 11G in favour of data pump

Work around fix was to grant the following directly to the exp-orting user

GRANT EXECUTE ON SYS.DBMS_DEFER_IMPORT_INTERNAL TO <user_name>;
GRANT EXECUTE ON SYS.DBMS_EXPORT_EXTENSION TO <user_name>;

Fini


Thursday 5 March 2009

identifying trace files in 11g (RAC)

SELECT pid, program, tracefile
FROM gv$process
where pid in (37,84)

Friday 27 February 2009

Perl one-liner to summarize file sizes

ls -l /u02/volestlivelogs01/oradata/ESTDB/archive/*.dbf | sed -e "s/:/ /g" -e "s/  / /g" | perl -lane 'BEGIN {%hash=();} $hash{"$F[5]$F[6]-$F[7]:00"}+= $F[4]; END {foreach $k (sort keys %hash) {print "$k " . int($hash{$k}/(1024*1024)) . " Mb"; } }'

Total size of an arbitrary list of files

ls -lrt | grep "Feb 17" | awk '{tot += $5;ct +=1; print $9 " " $5/(1024*1024) "Mb"} END {printf(" Files : %s TOTAL SIZE %4.2f Gb\n",ct,tot/(1024*1024*1024))}'

Remove files

ls -lrt | grep "Feb 19" | cut -d":" -f2 | cut -d" " -f2 | xargs rm -rf


Wednesday 18 February 2009

Total size of an arbitrary list of files

ls -lrt | grep "Feb 17" | awk '{tot += $5;ct +=1; print $9 " " $5/(1024*1024) "Mb"} END {printf(" Files : %s TOTAL SIZE %4.2f Gb\n",ct,tot/(1024*1024*1024))}'

Friday 30 January 2009

Oracle : Display refcursor content in SqlPlus or Toad

Proc to xml-ify the refcursor

create or replace procedure refcursor_print (p_refcursor in sys_refcursor,
                 p_null_handling in number := 0)
as
  l_xml      xmltype;
  l_context  dbms_xmlgen.ctxhandle;
  l_clob     clob;

  l_null_self_argument_exc exception;
  pragma exception_init (l_null_self_argument_exc, -30625);
 
  procedure print (p_msg in varchar2)
  as
    l_text varchar2(32000) := p_msg;
  begin
    loop
      exit when l_text is null;
      dbms_output.put_line(substr(l_text,1,250));
      l_text:=substr(l_text, 251);
    end loop;
  end print;
begin
  /*
  Purpose:    print debug information (ref cursor)
  Remarks:    outputs weakly typed cursor as XML
  */

  /* get a handle on the ref cursor */
  l_context:=dbms_xmlgen.newcontext (p_refcursor);
  /*
  # DROP_NULLS CONSTANT NUMBER:= 0; (Default) Leaves out the tag for NULL elements.
  # NULL_ATTR CONSTANT NUMBER:= 1; Sets xsi:nil="true".
  # EMPTY_TAG CONSTANT NUMBER:= 2; Sets, for example, <foo/>.
  */
  /* how to handle null values */
  dbms_xmlgen.setnullhandling (l_context, p_null_handling);
  /* create XML from ref cursor */
  l_xml:=dbms_xmlgen.getxmltype (l_context, dbms_xmlgen.none);

  print('Number of rows in ref cursor: ' || dbms_xmlgen.getnumrowsprocessed (l_context));
 
  begin
    l_clob:=l_xml.getclobval();
    print('Size of XML document (anything over 32K will be truncated): ' || length(l_clob));
    print(substr(l_clob,1,32000));
  exception
    when l_null_self_argument_exc then
       print('Empty dataset.');
  end;
end ;

Call like this
Nb returns a refcursor into c1
Output via dbms_output

c1 sys_refcursor;

begin
   get_refcursor_with_some_params('X1001',TO_DATE('12/02/2008','DD/MM/YYYY'),c1);
  refcursor_print(c1);
end;


Wednesday 28 January 2009

Rdesktop under linux into a Cisco VPN

  • Using Centos 5.2 - need to add additional repos to find a copy of kvpnc (?)
  • Correct version of packages (vpnc-0.3.3-1.2.el5.rf, kvpnc-0.8.8-1.el5.rf)
  • Need kde
  • Watch out for later version of vpnc (0.5+) being incompatible with syntax used by kvpnc - downgraded to get them to match 
  • Run kpvnc and import .pcf file to set up a new connection definition
  • Had some problems with Perfect Foward Secrecy being passed as a parameter to vpnc and vpnc not understanding - can be turned off via Profile->General->Advanced->PFS
  • Edit /etc/vpnc.conf to be something like
### This is the gateway configuration
IPSec gateway
IPSec ID
IPSec secret

### Put your username here
Xauth username
Xauth password

  • Install rdesktop
  • Use a command like "rdesktop  -u \\ -p -f -a 16 -k en-uk MACHINE
  • -f is fullscreen mode - use Ctrl-Alt-Enter to get out
  • On vmware this would be Ctrl-Alt-(Space-then-Enter) holding down Ctrl-Alt the whole time

Misc
Putty - selection cursor shows up black on black - change the mouse pointer on the remote machine to something more usable (Control panel -> Mouse->Pointers Tab->Text Selection)


Friday 23 January 2009

Conficker related links


Stopping Autorun
http://nick.brown.free.fr/blog/2007/10/memory-stick-worms.html

How to disable the use of USBs (MS)
http://support.microsoft.com/kb/823732


Monday 19 January 2009

Windows: Remote query for installed patches

wmic /user:Administrator /password:,password> /node:"spread-00811" qfe | find /N "KB958644"

Windows : Remote registry query/changes

reg query \\SPREAD-01058\HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced\Folder\Hidden\SHOWALL /s

Windows: Admin command window via Runas

runas /user:odl\administrator cmd

Thursday 15 January 2009

Oracle: DBCA template reverse engineering problem solved


Silent create template
dbca -createTemplateFromDB -sourceDB lontestdb02:1521:NEWDEV4 -templateName ZPFL1 -sysDBAUserName sys -sysDBAPassword password -maintainFileLocations false -silent


Problem
When using the DBCA to create a RAC database when selecting next on the node selection screen are
receiving the following error:

java.security.AccessControlException: access denied (java.sql.SQLPermission setLog)
at
java.security.AccessControlContext.checkPermission(AccessControlContext.java:270)
at
java.security.AccessController.checkPermission(AccessController.java:401)
at java.lang.SecurityManager.checkPermission(SecurityManager.java:542)
at java.sql.DriverManager.setLogStream(DriverManager.java:392)

Cause

The problem is that the user (oracle user) which use the DBCA does not have the permission to use the java packages for the RAC environment across the nodes. To create a file which set the permissions it will be checked and used to perform the action needed to be able to create the instances across the nodes

Fix

Create the file:

.java.policy on each node in the Oracle Users Home directory.

containing the following code.

grant {
permission java.security.AllPermission;
};

When done, changed the permission to 770 for the .java.policy file for the files/nodes
Start the DBCA again.

Template created in $ORACLE_HOME/dbca

Tuesday 6 January 2009

Oracle 10.2 RAC reboottime tweakables


http://mengmark.spaces.live.com/blog/cns!9BA8E9209B123692!179.entry


Oracle Database 10g Release 2 CSS (Cluster Synchronization Service) parameters:

 

With
different patch-sets of Oracle Database 10g Release 2; there exist
different timeout parameters which are used by CSS while accessing
storage data. In this document we will cover following Oracle Database
10g Release 2 patch-set versions:

1. Oracle Database 10.2.0.1

2. Oracle Database 10.2.0.1 + Patch for Bug 4896338

3. Oracle Database 10.2.0.2

4. Oracle Database 10.2.0.3

 

1. Oracle Database 10.2.0.1

 

There
is only one CSS parameter available in this version of Oracle and it is
called misscount which represents the maximum time in seconds that, a
heartbeat can be missed before entering into cluster reconfiguration to
evict the node, and the maximum time allowed for a voting file I/O to
complete.

The default value for misscount is 60 seconds.

 

2. Oracle Database 10.2.0.1 + Patch 4896338 and Oracle Database 10.2.0.2

There
is bug 4896338 with Oracle Database 10.2.0.1 which is a placeholder bug
for PCW 10.2.0.1 merge for very low brownout. Please refer
www.metalink.oracle.com for more details.

Oracle Database 10.2.0.2 has a fix for this bug.

There are three CSS parameters available in 10.2.0.2 and 10.2.0.1 + patch for bug 4896338; they are as follows:

 

a)
misscount - It represents maximum time in seconds that, a heartbeat can
be missed before entering into a cluster reconfiguration to evict the
node.

 

b)
disktimeout - It is the maximum amount of time allowed for a voting
file I/O to complete; if this time is exceeded the voting disk will be
marked as offline.

 

c) reboottime - It is the amount of time allowed for a node to complete a reboot after the CSS daemon has been evicted.

 

Default values for these parameters are as follows:

misscount = 60 seconds

disktimeout = 200 seconds

reboottime = 3 seconds

Using
"crsctl get css disktimeout / reboottime" will not show parameter value
unless you modify it explicitly. You can check the parameter's values
using ocssd.log under $CRS_HOME directory. 8

CRS internally calculates two parameters namely diskshorttimeout and disklongtimeout (can be checked in ocssd.log), where

 

a)
diskshorttimeout = misscount - reboottime : This value is used during
reconfiguration and initial cluster formation as a timeout for voting
file I/O to complete.

 

b)
disklongtimeout = disktimeout : This value is used during normal
operation of RAC as a timeout for voting file I/O to complete.

 

3. Oracle Database 10.2.0.3

 

This
version also has same parameters as that of Oracle Database 10.2.0.2;
also the default values are same as Oracle Database 10.2.0.2. There is
slight difference in the internal calculation of there parameter
values; If disktimeout is less than the misscount value then during
cluster formation and throughout cluster operation misscount -
reboottime is considered as disktimeout and the modified parameter
disktimeout is ignored.

That is in Oracle Database 10.2.0.3 diskshorttimeout = disklongtimeout if css disktimeout parameter is less than css misscount.

 

4. Recommendations for Oracle Database 10g Release 2 CSS parameter values to be used with NetApp storage:

 

As
diskshorttimeout = misscount - reboottime; and if misscount &
reboottime are kept as default values i.e. 60 seconds & 3 seconds
respectively; the time for accessing voting file will be considered as
57 seconds by CSS, so If the reconfiguration happens during the NetApp
Storage takeover or giveback process there are chances of CRS reboot
taking place; hence following are the recommended values for CSS
timeout parameters for Oracle Database 10g Release 2 RAC to work
smoothly during NetApp Storage takeover and giveback process.

1. Oracle Database 10.2.0.1

misscount = 120 seconds (default is 60 seconds)

2. Oracle Database 10.2.0.1 + Patch for Bug 4896338

misscount = 120 seconds (default is 60 seconds)

disktimeout = 200 seconds (default)

reboottime = 3 seconds (default)

3. Oracle Database 10.2.0.2

misscount = 120 seconds (default is 60 seconds)

disktimeout = 200 seconds (default)

reboottime = 3 seconds (default)

4. Oracle Database 10.2.0.3

misscount = 120 seconds (default is 60 seconds)

disktimeout = 200 seconds (default)

reboottime = 3 seconds (default)

All the above recommendations are for Linux Operating system.

Note:
The stock version of Oracle database 10g Release 2 lower than 10.2.0.2
do not provide all the configurable CSS parameters; hence it is
advisable to upgrade Oracle Database to 10.2.0.2 or higher.

 

Appendix

Commands to check / modify CSS parameters:

1. crsctl get css misscount ---------- to check misscount value

2. crsctl get css disktimeout --------- to check disktimeout value

3. crsctl get css reboottime ---------- to check reboottime value

4. crsctl set css misscount 120 --------- to set misscount to 120 seconds

5. crsctl set css disktimeout 200 ------- to set disktimeout to 200 seconds

6. crsctl set css reboottime 3 ----------- to set reboottime to 3 seconds 


http://el-caro.blogspot.com/2006/10/case-study-on-how-to-diagnose-node.html


There have been a couple of additional CSS related parameters introduced in the
10.2.0.2 patchset to address long I/O requirements of storage vendors such as
EMC and NetApp.

• reboottime: (default 3 seconds)
The amount of time
allowed for a node to complete a reboot after the CSS daemon has been
evicted.
This parameter can be set via the command
crsctl set css
reboottime R [-force] (R is seconds)

• disktimeout (default 200 seconds)

The maximum amount of time allowed for a voting file I/O to complete; if
this time is exceeded the voting disk will be marked as unavailable
This
parameter can be set via the command
crsctl set css disktimeout D [-force] (D
is seconds)

These commands must be run as root on a node where the CRSD
is up, unless
'-force' is specified, in which case the the CRS stack should
not be up on any other node.
After the commands are run all CSS daemons must
be restarted for the settings to take effect on all nodes asap.
You can
verify the settings by doing an ocrdump and checking the values in the
OCRDUMPFILE

 

Office : Outlook Rule limits

http://corinnalo.blogspot.com/2008/10/exchange-outlook-rules-32k-limit.html

There is a Microsoft KB that talks about some workarounds on the
Exchange 32K rules storage limit problem. Basically, rename your rules
to shorter names, merge some of your rules, change your local folders
to shorter names, move your Outlook data files to another location on
the file system that has a shorter path, etc.