How to Remove Volume Group and Physical Volume on LVM

icon-redhatlinuxBasically, adding and removing LVM will always involves these three logical “layers” which are Physical volumes (pv), Volume groups (vg) and Logical volumes (lv). This post assumed that the Logical volumes haven’t created. In certain situation, linux administrators are required to remove the existing Physical Volume or Volume Group only. It is possible to perform the required task if that system administrator has the right skill on linux. The steps as below :

1. Display the physical volumes and Volume Group using pvdisplay command :

[root@centos63 ~]# pvdisplay
  --- Physical volume ---
  PV Name               /dev/sdb1
  VG Name               vg_data
  PV Size               4.99 GiB / not usable 2.41 MiB
  Allocatable           yes
  PE Size               4.00 MiB
  Total PE              1278
  Free PE               1278
  Allocated PE          0
  PV UUID               qTmTeq-8qoL-xxEk-Dj5V-zOjl-vEag-P6Jl7L

2. Remove the Volume Group using vgremove command :

[root@centos63 ~]# vgremove vg_data
  Volume group "vg_data" successfully removed

3. Remove Physical Volume using pvremove command :

[root@centos63 ~]# pvremove /dev/sdb1
  Labels on physical volume "/dev/sdb1" successfully wiped

Additional Note :
How to Remove a Logical Volume on CentOS 6.3/RHEL6

Prerequisites Checking Before Install Zimbra Collaboration Suite 8 on CentOS 6.3

zimbraBefore you start installing Zimbra Collaboration Suite (ZCS) 8.0.1 or 8.0.2, there are a few prerequisites checking have to be performed. This is to ensure that the installation running smoothly without any interruption while saving your time to troubleshoot. I have installed Zimbra Collaboration Suite 8.0.1 and 8.0.2 on many CentOS 6.3 and i would like to share my experiences.

1. Make sure your target mail domain (e.g ehowstuff.local) has mx record on your DNS server.

[root@mail ~]# host -t mx ehowstuff.local
ehowstuff.local mail is handled by 0 ehowstuff.local.

2. Stop and disabled the following services :

[root@mail ~]# service iptables stop
[root@mail ~]# service ip6tables stop
[root@mail ~]# service sendmail stop
[root@mail ~]# service postfix stop

3. Disabled auto start the following services :

[root@mail ~]# chkconfig ip6tables off
[root@mail ~]# chkconfig iptables off
[root@mail ~]# chkconfig sendmail off
[root@mail ~]# chkconfig postfix off

4. Disabled Selinux :

[root@mail ~]# setenforce 0
[root@mail ~]# vi /etc/selinux/config

# This file controls the state of SELinux on the system.
# SELINUX= can take one of these three values:
#     enforcing - SELinux security policy is enforced.
#     permissive - SELinux prints warnings instead of enforcing.
#     disabled - No SELinux policy is loaded.
SELINUX=disabled
# SELINUXTYPE= can take one of these two values:
#     targeted - Targeted processes are protected,
#     mls - Multi Level Security protection.
SELINUXTYPE=targeted

5. Make sure the following dependencies software has been installed :

[root@mail ~]# yum install perl nc sudo sysstat -y

How to Upgrade Zimbra Collaboration Suite 8.0.1 to 8.0.2 on CentOS 6.3 x86_64

zimbraIn previous post, i had shared the steps to setup Zimbra Collaboration Suite (ZCS) 8.0.1 Mail Server open source edition on CentOS 6.3 server. At the time this document was written, ZCS 8.0.2 is available. This document shows the upgrading of ZCS from version 8.0.1_GA_5438 to 8.0.2_GA_5569. Before perform the upgrading steps, it is recommended to backup the users mailbox and zimbra configurations.

Major Issues Fixed for 8.0.2

-Task list view fields now are updated after they are edited.
-Fixed issues that caused Contact lists to not sync correctly.
-ZCS cluster zimlet was trying to access httpOnly cookie which is no longer available after release 7.2.0. This resulted in a session expired on the admin console. The Cluster zimlet has been fixed to pass the correct parameters.
-Calendar. Issues in Calendar localized version around Reminder timer and saving appointments has been fixed.
-Install and Upgrade. The MTA restarts correctly after upgrade or install.
-PST migration. PST migration now only imports new and incremental data when Ignore previously imported items option is selected.
-When upgrading to ZCS 8.0, upgrade disables in all of the COSs Zimlets that are not in the certified core Zimlet list. If non-certified Zimlets are enabled at the account level they remain enabled after the upgrade. To disable these Zimlets, the administrator must manually disable these Zimlets on all affected accounts.
-Tags now are migrated when moving a mailbox from 7.x to 8.0.2 directly using zmmboxmove. For mailboxes that moved from 7.x to an earlier version of 8.0, the utility provided in bug 78487 can be used. But if users added new tags to messages or re-tagged messages after the mailbox was moved, when this utility is run these tags are removed.
-For new installs a, a settings was changed in the default mailboxd_java_options in localconfig key because the maximum PermGen size might be too low, leading to java.lang.OutOfMemoryError. This setting is specified in the mailboxd_java_options local config key. After upgrade, the value should be increased to 350m. See http://bugzilla.zimbra.com/show_bug.cgi?id=78661#c16 for a detailed example.
-Account migration undoes any benefit of message deduplication of data on a server. Once all migrations are complete a new tool zmdedup can be used to reduce disk usage caused by this.

Upgrading steps :

1. Show current zimbra version :

[zimbra@host1 ~]$ zmcontrol -v
Release 8.0.1_GA_5438.RHEL6_64_20121105164412 CentOS6_64 FOSS edition.

2. Stop Zimbra services :

[zimbra@host1 ~]$ zmcontrol stop
Host host1.zimbra.local
        Stopping vmware-ha...Done.
        Stopping zmconfigd...Done.
        Stopping stats...Done.
        Stopping mta...Done.
        Stopping spell...Done.
        Stopping snmp...Done.
        Stopping cbpolicyd...Done.
        Stopping archiving...Done.
        Stopping antivirus...Done.
        Stopping antispam...Done.
        Stopping proxy...Done.
        Stopping memcached...Done.
        Stopping mailbox...Done.
        Stopping logger...Done.
        Stopping ldap...Done.

3. Download ZCS 8.0.2 :

[root@host1 ~]# wget http://files2.zimbra.com/downloads/8.0.2_GA/zcs-8.0.2_GA_5569.RHEL6_64.20121210115059.tgz

4. Untar the Downloaded package :

[root@host1 ~]# tar xzvf zcs-8.0.2_GA_5569.RHEL6_64.20121210115059.tgz

5. The upgrading steps almost similar with installation steps. You can refer to this official released notes from zimbra. Run the following command to upgrade :

[root@host1 zcs-8.0.2_GA_5569.RHEL6_64.20121210115059]# ./install.sh --platform-override

Operations logged to /tmp/install.log.28037
Checking for existing installation...
    zimbra-ldap...FOUND zimbra-ldap-8.0.1_GA_5438
    zimbra-logger...FOUND zimbra-logger-8.0.1_GA_5438
    zimbra-mta...FOUND zimbra-mta-8.0.1_GA_5438
    zimbra-snmp...FOUND zimbra-snmp-8.0.1_GA_5438
    zimbra-store...FOUND zimbra-store-8.0.1_GA_5438
    zimbra-apache...FOUND zimbra-apache-8.0.1_GA_5438
    zimbra-spell...FOUND zimbra-spell-8.0.1_GA_5438
    zimbra-convertd...NOT FOUND
    zimbra-memcached...FOUND zimbra-memcached-8.0.1_GA_5438
    zimbra-proxy...FOUND zimbra-proxy-8.0.1_GA_5438
    zimbra-archiving...NOT FOUND
    zimbra-cluster...NOT FOUND
    zimbra-core...FOUND zimbra-core-8.0.1_GA_5438
ZCS upgrade from 8.0.1 to 8.0.2 will be performed.

Saving existing configuration file to /opt/zimbra/.saveconfig


PLEASE READ THIS AGREEMENT CAREFULLY BEFORE USING THE SOFTWARE.
ZIMBRA, INC. ("ZIMBRA") WILL ONLY LICENSE THIS SOFTWARE TO YOU IF YOU
FIRST ACCEPT THE TERMS OF THIS AGREEMENT. BY DOWNLOADING OR INSTALLING
THE SOFTWARE, OR USING THE PRODUCT, YOU ARE CONSENTING TO BE BOUND BY
THIS AGREEMENT. IF YOU DO NOT AGREE TO ALL OF THE TERMS OF THIS
AGREEMENT, THEN DO NOT DOWNLOAD, INSTALL OR USE THE PRODUCT.

License Terms for the Zimbra Collaboration Suite:
  http://www.zimbra.com/license/zimbra_public_eula_2.1.html



Do you agree with the terms of the software license agreement? [N] y




Oracle Binary Code License Agreement for the Java SE Platform Products

ORACLE  AMERICA, INC. ("ORACLE"), FOR AND ON BEHALF OF ITSELF AND ITS SUBSIDIARIES AND AFFILIATES UNDER COMMON CONTROL, IS WILLING TO  LICENSE  THE SOFTWARE
 TO YOU ONLY UPON THE CONDITION THAT YOU ACCEPT ALL OF THE TERMS  CONTAINED IN THIS BINARY CODE LICENSE AGREEMENT AND SUPPLEMENTAL  LICENSE TERMS (COLLECTIVE
LY "AGREEMENT").  PLEASE READ THE AGREEMENT  CAREFULLY.  BY SELECTING THE "ACCEPT LICENSE AGREEMENT" (OR THE EQUIVALENT) BUTTON AND/OR BY USING THE SOFTWARE
YOU ACKNOWLEDGE THAT YOU HAVE READ THE TERMS AND AGREE TO THEM.  IF YOU ARE AGREEING TO THESE TERMS ON BEHALF OF A  COMPANY OR OTHER LEGAL ENTITY, YOU REPRES
ENT THAT YOU HAVE THE LEGAL  AUTHORITY TO BIND THE LEGAL ENTITY TO THESE TERMS.  IF YOU DO NOT HAVE SUCH  AUTHORITY, OR IF YOU DO NOT WISH TO BE BOUND BY THE
 TERMS, THEN SELECT THE "DECLINE LICENSE AGREEMENT" (OR THE EQUIVALENT) BUTTON AND YOU MUST NOT USE THE SOFTWARE ON THIS SITE OR ANY OTHER MEDIA ON WHICH THE
 SOFTWARE IS CONTAINED.

1.  DEFINITIONS.  "Software" means the Java SE Platform Products in binary form that you selected for download, install or use from Oracle or its authorized
licensees, any other machine readable materials (including, but not limited to,  libraries,  source  files,  header  files, and data  files), any updates or
error corrections provided by Oracle, and any user manuals, programming guides and other documentation provided to you by Oracle under this Agreement.  "Gene
ral Purpose Desktop Computers and Servers" means computers,  including desktop and laptop computers, or servers, used for general  computing functions under
end user control (such as but not specifically  limited to email, general purpose Internet browsing, and office suite  productivity tools).  The use of Softw
are in systems and solutions that provide dedicated functionality (other than as mentioned above) or designed  for use in embedded or function-specific softw
are applications, for example but not limited to: Software embedded in or bundled with industrial control systems, wireless mobile telephones, wireless handh
eld devices, netbooks, kiosks, TV/STB, Blu-ray Disc devices, telematics and network control switching equipment, printers and storage management systems, and
 other related systems are excluded from this definition and not licensed under this  Agreement.  "Programs" means Java technology applets and applications
intended to run on the Java Platform, Standard Edition platform on Java-enabled General Purpose Desktop Computers and Servers.  ?Commercial Features? means t
hose features identified in Table 1-1 (Commercial Features In Java SE Product Editions) of the Software documentation accessible at  http://www.oracle.com/te
chnetwork/java/javase/documentation/index.html.  ?README File? means the README file for the Software accessible at http://www.oracle.com/technetwork/java/ja
vase/terms/readme/index.html.

2.  LICENSE TO USE.  Subject to the terms and conditions of this Agreement   including, but not limited to, the Java Technology Restrictions of the  Suppleme
ntal License Terms, Oracle grants you a non-exclusive, non-transferable, limited license without license fees to reproduce and use internally the Software co
mplete and unmodified for the sole purpose of  running Programs.  THE LICENSE SET FORTH IN THIS SECTION 2 DOES NOT EXTEND TO THE COMMERCIAL FEATURES.  YOUR R
IGHTS AND OBLIGATIONS RELATED TO THE COMMERCIAL FEATURES ARE AS SET FORTH IN THE SUPPLEMENTAL TERMS ALONG WITH ADDITIONAL LICENSES FOR DEVELOPERS AND PUBLISH
ERS.

3.  RESTRICTIONS.  Software is copyrighted.  Title to Software and all associated intellectual property rights is retained by Oracle and/or its licensors.  U
nless enforcement is prohibited by applicable law, you may not modify, decompile, or reverse engineer Software.  You acknowledge that the Software is develop
ed for general use in a variety of information management applications; it is not developed or intended for use in any inherently dangerous applications, inc
luding applications that may create a risk of personal injury. If you use the Software in dangerous applications, then you shall be responsible to take all a
ppropriate fail-safe, backup, redundancy, and other measures to ensure its safe use.  Oracle disclaims any express or implied warranty of fitness for such us
es.  No right, title or interest in or to any trademark,  service mark, logo or trade name of Oracle or its licensors is granted under this  Agreement.  Addi
tional restrictions for developers and/or publishers licenses are set forth in the Supplemental License Terms.

4.  DISCLAIMER OF WARRANTY.  THE SOFTWARE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND.  ORACLE FURTHER DISCLAIMS ALL WARRANTIES, EXPRESS AND IMPLIED, IN
CLUDING WITHOUT LIMITATION, ANY IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE OR NONINFRINGEMENT.

5.  LIMITATION OF LIABILITY.  IN NO EVENT SHALL ORACLE BE LIABLE FOR ANY INDIRECT, INCIDENTAL, SPECIAL, PUNITIVE OR CONSEQUENTIAL DAMAGES, OR DAMAGES FOR LOS
S OF PROFITS, REVENUE, DATA OR DATA USE, INCURRED BY YOU OR ANY THIRD PARTY, WHETHER IN AN ACTION IN CONTRACT OR TORT, EVEN IF ORACLE HAS BEEN ADVISED OF THE
 POSSIBILITY OF SUCH DAMAGES. ORACLE'S ENTIRE LIABILITY FOR DAMAGES HEREUNDER SHALL IN NO EVENT EXCEED ONE THOUSAND DOLLARS (U.S. $1,000).

6.  TERMINATION.  This Agreement is effective until terminated.  You may terminate this Agreement at any time by destroying all copies of Software.  This Agr
eement will terminate immediately without notice from Oracle if you  fail to comply with any provision of this Agreement.  Either party may  terminate this A
greement immediately should any Software become, or in either party's opinion be likely to become, the subject of a claim of infringement  of any intellectua
l property  right.  Upon termination, you must destroy all copies of Software.

7.  EXPORT  REGULATIONS.  You agree that U.S. export control laws and other applicable export and import laws govern your use of the Software, including tech
nical data; additional information can be found on Oracle's Global Trade Compliance web site (http://www.oracle.com/products/export). You agree that neither
the Software nor any direct product thereof will be exported, directly, or indirectly, in violation of these laws, or will be used for any purpose prohibited
 by these laws including, without limitation, nuclear, chemical, or biological weapons proliferation.

8.  TRADEMARKS AND LOGOS.  You acknowledge and agree as between you
and Oracle that Oracle owns the ORACLE and JAVA trademarks and all ORACLE- and JAVA-related trademarks, service marks, logos and other brand
designations ("Oracle Marks"), and you agree to comply with the Third
Party Usage Guidelines for Oracle Trademarks currently located at
http://www.oracle.com/us/legal/third-party-trademarks/index.html.  Any use you make of the Oracle Marks inures to Oracle's benefit.

9.  U.S.  GOVERNMENT LICENSE RIGHTS.  If Software is being acquired by or on  behalf of the U.S. Government or by a U.S. Government prime contractor or  subc
ontractor (at any tier), then the Government's rights in Software and accompanying documentation shall be only those set forth in this Agreement.

10.  GOVERNING  LAW.  This agreement is governed by the substantive and procedural laws of California. You and Oracle agree to submit to the exclusive jurisd
iction of, and venue in, the courts of San Francisco, or Santa Clara counties in California in any dispute arising out of or relating to this agreement.

11.  SEVERABILITY.  If any  provision of this  Agreement is held to be unenforceable, this Agreement will remain in effect with the provision omitted, unless
 omission would frustrate the intent of the parties, in which case this Agreement will immediately terminate.

12.  INTEGRATION.  This Agreement is the entire agreement  between you and Oracle relating to its subject matter.  It supersedes all prior or contemporaneous
 oral or written communications, proposals, representations  and warranties and prevails over any  conflicting  or additional  terms  of  any  quote, order,
acknowledgment, or other communication between the parties  relating to its subject matter during the term of this Agreement.  No modification of this Agreem
ent will be  binding,  unless  in  writing  and  signed  by an  authorized representative of each party.

SUPPLEMENTAL LICENSE TERMS

These  Supplemental  License  Terms add to or modify  the terms of the Binary Code License Agreement.  Capitalized terms not defined in these Supplemental  T
erms shall have the same meanings ascribed to them in the Binary Code License Agreement.  These Supplemental Terms shall supersede any  inconsistent or confl
icting terms in the Binary Code License Agreement, or in any license contained within the Software.

A.  COMMERCIAL FEATURES.  You may not use the Commercial Features for running Programs, Java applets or applications in your internal business operations or
for any commercial or production  purpose, or for any purpose other than as set forth in Sections B, C, D and E of these Supplemental Terms.  If You want to
use the Commercial Features for any purpose other than as permitted in this Agreement, You must obtain a separate license from Oracle.

B.  SOFTWARE INTERNAL USE FOR DEVELOPMENT LICENSE GRANT.  Subject to the terms and conditions of this Agreement and restrictions and exceptions set forth in
the README File incorporated herein by reference,  including, but not limited to the Java Technology Restrictions of these  Supplemental Terms, Oracle grants
 you a non-exclusive, non-transferable,  limited license without fees to reproduce internally and use internally the Software complete and unmodified for the
 purpose of designing, developing, and testing your Programs.

C.  LICENSE TO DISTRIBUTE SOFTWARE.  Subject to the terms and conditions of this Agreement and restrictions and exceptions set forth in the   README File, in
cluding, but not limited to the Java Technology Restrictions of these Supplemental Terms, Oracle grants you a non-exclusive, non-transferable, limited licens
e without fees to reproduce and distribute the  Software, provided that (i) you distribute the Software complete and  unmodified and only bundled as part of,
 and for the sole purpose of running, your Programs, (ii) the Programs add significant and primary functionality  to the Software, (iii) you do not distribut
e additional  software intended to replace any component(s) of the Software, (iv) you do not remove or alter any proprietary legends or notices contained in
the Software, (v) you only distribute the Software subject to a license agreement that: (a) is a complete, unmodified reproduction of this Agreement; or (b)
protects Oracle's  interests consistent with the terms contained in this Agreement and that includes the notice set forth in Section G, and (vi) you agree to
 defend and indemnify Oracle and its licensors from and against any damages, costs, liabilities, settlement amounts and/or expenses (including  attorneys' fe
es)  incurred in connection  with any claim, lawsuit or action by any third party that arises or results from the use or distribution of any and all Programs
 and/or Software.

D.  LICENSE TO DISTRIBUTE REDISTRIBUTABLES.  Subject to the terms and conditions of this Agreement and restrictions and exceptions set forth in the README  F
ile, including but not limited to the Java Technology Restrictions of these Supplemental Terms, Oracle grants you a non-exclusive,  non-transferable, limited
 license without fees to reproduce and distribute  those files specifically identified as redistributable in the   README File ("Redistributables") provided
that: (i) you distribute the  Redistributables complete and unmodified, and only bundled as part of Programs, (ii) the Programs add significant and primary f
unctionality to the  Redistributables, (iii) you do not distribute additional software intended to supersede any component(s) of the Redistributables (unless
 otherwise specified in the applicable README File), (iv) you do not remove or alter any proprietary legends or notices contained in or on the Redistributabl
es, (v)  you only distribute the Redistributables pursuant to a license agreement  that: (a) is a complete, unmodified reproduction of this Agreement; or (b)
 protects Oracle's interests consistent with the terms contained in the Agreement and includes the notice set forth in Section G, (vi) you agree to defend an
d indemnify Oracle and its licensors from and against any damages,  costs, liabilities, settlement amounts and/or expenses (including  attorneys'  fees) incu
rred in connection with any claim, lawsuit or action by any third  party that arises or results from the use or distribution of any and all Programs and/or S
oftware.

E.  DISTRIBUTION BY PUBLISHERS.  This section pertains to your distribution  of the JavaTM SE Development Kit Software with your printed book or magazine (as
 those terms are commonly used in the industry) relating to Java technology ("Publication").  Subject to and conditioned upon your compliance  with the restr
ictions and obligations contained in the Agreement, Oracle hereby grants to you a non-exclusive, nontransferable limited right to reproduce complete and unmo
dified copies of the Software on electronic  media (the "Media") for the sole purpose of inclusion and distribution with your Publication(s), subject to the
following terms: (i) You may not distribute  the Software on a stand-alone basis; it must be distributed with your Publication(s); (ii) You are responsible f
or downloading the Software from the applicable Oracle web site; (iii) You must refer to the Software as JavaTM SE Development Kit; (iv) The Software must be
 reproduced in its entirety and without any modification whatsoever (including with respect to all proprietary notices) and distributed with your Publication
 subject to a license agreement that is a complete, unmodified reproduction of this Agreement; (v) The Media label shall include the following information:
Copyright 2011, Oracle America, Inc.  All rights reserved.  Use is subject to license terms.  ORACLE and JAVA trademarks and all ORACLE- and JAVA-related tra
demarks, service marks, logos and other brand
designations are trademarks or registered  trademarks of Oracle in the U.S. and other countries.  This information must be placed on the Media  label in such
 a manner as to only apply to the Oracle  Software;  (vi) You must clearly identify the Software as Oracle's product on the Media  holder or Media label, and
 you may not state or imply that Oracle is responsible for any third-party software contained on the Media; (vii) You may not include any third  party softwa
re on the Media which is intended to be a  replacement or substitute for the Software; (viii) You agree to defend and indemnify Oracle and its licensors from
 and against any damages, costs, liabilities, settlement amounts and/or expenses (including  attorneys'  fees) incurred in connection with any claim, lawsuit
 or action by any third party that arises or results from the use or distribution of the Software and/or the Publication; ; and (ix) You shall provide Oracle
 with a written notice for each Publication; such notice shall include the following information: (1) title of Publication, (2) author(s), (3) date of Public
ation,  and (4)  ISBN or ISSN  numbers.  Such notice shall be sent to  Oracle America, Inc.,  500 Oracle  Parkway, Redwood Shores,  California  94065 U.S.A ,
 Attention:  General Counsel.

F.  JAVA TECHNOLOGY RESTRICTIONS.  You may not create, modify, or change the behavior of, or authorize your licensees to create, modify, or change the behavi
or of, classes, interfaces, or subpackages that are in any way  identified  as  "java", "javax", "sun", ?oracle? or similar convention as   specified by Orac
le in any naming convention designation.

G.  COMMERCIAL FEATURES NOTICE.  For purpose of complying with Supplemental Term Section  C.(v)(b) and D.(v)(b), your license agreement shall include the fol
lowing notice, where the notice is displayed in a manner that anyone using the Software will see the notice:

Use of the Commercial Features for any commercial or production purpose requires a separate license from Oracle.  ?Commercial Features? means those features
identified Table 1-1 (Commercial Features In Java SE Product Editions) of the Software documentation accessible at http://www.oracle.com/technetwork/java/jav
ase/documentation/index.html

H.  SOURCE CODE.  Software may contain source code that, unless expressly   licensed for other purposes, is provided solely for reference purposes  pursuant
to the terms of this Agreement.  Source code may not be redistributed  unless  expressly  provided for in this Agreement.

I.  THIRD PARTY CODE.  Additional copyright notices and license terms applicable to portions of the Software are set forth in the THIRDPARTYLICENSEREADME fil
e accessible at http://www.oracle.com/technetwork/java/javase/documentation/index.html.  In addition to any terms and conditions of any third party opensourc
e/freeware license identified in the  THIRDPARTYLICENSEREADME file, the disclaimer of warranty and limitation of liability  provisions in  paragraphs 4 and 5
 of the Binary Code License Agreement shall apply to all Software in this distribution.

J.  TERMINATION FOR INFRINGEMENT.  Either party may terminate this Agreement immediately should any Software become, or in either party's opinion be likely t
o become, the subject of a claim of infringement of any intellectual property right.

K.  INSTALLATION AND AUTO-UPDATE.  The Software's installation and auto-update processes transmit a limited amount of data to Oracle (or its service  provide
r) about those specific processes to help Oracle understand and optimize them.  Oracle does not associate the data with personally  identifiable  information
.  You can find more  information about the data Oracle collects as a result of your Software download at http://www.oracle.com/technetwork/java/javase/docum
entation/index.html.

For inquiries please contact:  Oracle America, Inc., 500 Oracle Parkway,
Redwood Shores, California 94065, USA.

Last updated May 17, 2011




Do you agree with the terms of the software license agreement? [N] y

Checking for prerequisites...
     FOUND: NPTL
     FOUND: nc-1.84-22
     FOUND: sudo-1.7.4p5-13
     FOUND: libidn-1.18-2
     FOUND: gmp-4.3.1-7
     FOUND: /usr/lib64/libstdc++.so.6

Checking for suggested prerequisites...
     FOUND: perl-5.10.1
     FOUND: sysstat
     FOUND: sqlite
Prerequisite check complete.
Checking current number of databases...

Do you want to verify message store database integrity? [Y] y
Verifying integrity of message store databases.  This may take a while.
Starting mysqld...done.
mysqld is alive
No errors found
mysqld is alive
Stopping mysqld... done.

Checking for installable packages

Found zimbra-core
Found zimbra-ldap
Found zimbra-logger
Found zimbra-mta
Found zimbra-snmp
Found zimbra-store
Found zimbra-apache
Found zimbra-spell
Found zimbra-memcached
Found zimbra-proxy


The Zimbra Collaboration Server appears already to be installed.
It can be upgraded with no effect on existing accounts,
or the current installation can be completely removed prior
to installation for a clean install.

Do you wish to upgrade? [Y] y

Select the packages to install
    Upgrading zimbra-core
    Upgrading zimbra-ldap
    Upgrading zimbra-logger
    Upgrading zimbra-mta
    Upgrading zimbra-snmp
    Upgrading zimbra-store
    Upgrading zimbra-apache
    Upgrading zimbra-spell
    Upgrading zimbra-memcached
    Upgrading zimbra-proxy
Checking required space for zimbra-core
Checking space for zimbra-store

Installing:
    zimbra-core
    zimbra-ldap
    zimbra-logger
    zimbra-mta
    zimbra-snmp
    zimbra-store
    zimbra-apache
    zimbra-spell
    zimbra-memcached
    zimbra-proxy

You appear to be installing packages on a platform different
than the platform for which they were built.

This platform is CentOS6_64
Packages found: RHEL6_64
This may or may not work.

Using packages for a platform in which they were not designed for
may result in an installation that is NOT usable. Your support
options may be limited if you choose to continue.


Install anyway? [N] y

The system will be modified.  Continue? [N] y

Shutting down zimbra mail

Backing up the ldap database...done.

Removing existing packages

   zimbra-ldap...done
   zimbra-logger...done
   zimbra-mta...done
   zimbra-snmp...done
   zimbra-store...done
   zimbra-spell...done
   zimbra-memcached...done
   zimbra-proxy...done
   zimbra-apache...done
   zimbra-core...done

Removing deployed webapp directories
Installing packages

    zimbra-core......zimbra-core-8.0.2_GA_5569.RHEL6_64-20121210115059.x86_64.rpm...done
    zimbra-ldap......zimbra-ldap-8.0.2_GA_5569.RHEL6_64-20121210115059.x86_64.rpm...done
    zimbra-logger......zimbra-logger-8.0.2_GA_5569.RHEL6_64-20121210115059.x86_64.rpm...done
    zimbra-mta......zimbra-mta-8.0.2_GA_5569.RHEL6_64-20121210115059.x86_64.rpm...done
    zimbra-snmp......zimbra-snmp-8.0.2_GA_5569.RHEL6_64-20121210115059.x86_64.rpm...done
    zimbra-store......zimbra-store-8.0.2_GA_5569.RHEL6_64-20121210115059.x86_64.rpm...done
    zimbra-apache......zimbra-apache-8.0.2_GA_5569.RHEL6_64-20121210115059.x86_64.rpm...done
    zimbra-spell......zimbra-spell-8.0.2_GA_5569.RHEL6_64-20121210115059.x86_64.rpm...done
    zimbra-memcached......zimbra-memcached-8.0.2_GA_5569.RHEL6_64-20121210115059.x86_64.rpm...done
    zimbra-proxy......zimbra-proxy-8.0.2_GA_5569.RHEL6_64-20121210115059.x86_64.rpm...done

Setting defaults from saved config in /opt/zimbra/.saveconfig/config.save
   HOSTNAME=host1.zimbra.local
   LDAPHOST=host1.zimbra.local
   LDAPPORT=389
   SNMPTRAPHOST=host1.zimbra.local
   SMTPSOURCE=admin@zimbra.local
   SMTPDEST=admin@zimbra.local
   SNMPNOTIFY=yes
   SMTPNOTIFY=yes
   LDAPROOTPW=A3e1onaU
   LDAPZIMBRAPW=A3e1onaU
   LDAPPOSTPW=A3e1onaU
   LDAPREPPW=A3e1onaU
   LDAPAMAVISPW=A3e1onaU
   LDAPNGINXPW=A3e1onaU
Restoring existing configuration file from /opt/zimbra/.saveconfig/localconfig.xml...done
Operations logged to /tmp/zmsetup.12252012-011606.log
Upgrading from 8.0.1_GA_5438 to 8.0.2_GA_5569
Stopping zimbra services...done.
Starting mysql...done.
This appears to be 8.0.1_GA
Checking ldap status...not running.
Running zmldapapplyldif...done.
Checking ldap status...not running.
Starting ldap...done.
Schema upgrade required from version 91 to 92.
Running /opt/zimbra/libexec/scripts/migrate20121009-VolumeBlobs.pl
Tue Dec 25 01:16:50 2012: Verified schema version 91.
Tue Dec 25 01:16:52 2012: Verified schema version 91.
Tue Dec 25 01:16:52 2012: Updating DB schema version from 91 to 92.
Stopping mysql...done.
Updating from 8.0.2_GA
Updating global config and COS's with attributes introduced after 8.0.1_GA...done.
Stopping ldap...done.
Upgrade complete.

Running zmldapapplyldif...done.
Checking ldap status....not running.
Starting ldap...done.
Setting defaults...done.
Setting defaults from existing config...done.
Checking for port conflicts
Setting defaults from ldap...done.
Saving config in /opt/zimbra/config.8837...done.
Operations logged to /tmp/zmsetup.12252012-011606.log
Setting local config values...done.
Initializing core config...Setting up CA...done.
Deploying CA to /opt/zimbra/conf/ca ...done.
Setting replication password...done.
Setting Postfix password...done.
Setting amavis password...done.
Setting nginx password...done.
Creating server entry for host1.zimbra.local...already exists.
Setting Zimbra IP Mode...done.
Saving CA in ldap ...done.
Saving SSL Certificate in ldap ...done.
Setting spell check URL...done.
Setting service ports on host1.zimbra.local...done.
Adding host1.zimbra.local to zimbraMailHostPool in default COS...done.
Setting Keyboard Shortcut Preferences...done.
Setting zimbraFeatureTasksEnabled=TRUE...done.
Setting zimbraFeatureBriefcasesEnabled=FALSE...done.
Setting MTA auth host...done.
Setting TimeZone Preference...done.
Initializing mta config...done.
Setting services on host1.zimbra.local...done.
Creating user spam.o9zobzifr@zimbra.local...already exists.
Creating user ham.dkytx2z3@zimbra.local...already exists.
Creating user virus-quarantine.xbqagircz@zimbra.local...already exists.
Setting spam training and Anti-virus quarantine accounts...done.
Configuring SNMP...done.
Setting up syslog.conf...done.
Starting servers...done.
Checking for deprecated zimlets...done.
Checking for network zimlets in LDAP...done.
Removing network zimlets...
Finished removing network zimlets.
Installing common zimlets...
        com_zimbra_date...done.
        com_zimbra_email...done.
        com_zimbra_tooltip...done.
        com_zimbra_cert_manager...done.
        com_zimbra_url...done.
        com_zimbra_attachmail...done.
        com_zimbra_phone...done.
        com_zimbra_proxy_config...done.
        com_zimbra_clientuploader...done.
        com_zimbra_ymemoticons...done.
        com_zimbra_srchhighlighter...done.
        com_zimbra_webex...done.
        com_zimbra_attachcontacts...done.
        com_zimbra_bulkprovision...done.
        com_zimbra_viewmail...done.
        com_zimbra_adminversioncheck...done.
Finished installing common zimlets.
Getting list of all zimlets...done.
Updating non-standard zimlets...
Finished updating non-standard zimlets.
Restarting mailboxd...done.
Skipping creation of default domain GAL sync account - existing install detected.

You have the option of notifying Zimbra of your installation.
This helps us to track the uptake of the Zimbra Collaboration Server.
The only information that will be transmitted is:
        The VERSION of zcs installed (8.0.2_GA_5569_CentOS6_64)
        The ADMIN EMAIL ADDRESS created (admin@zimbra.local)

Notify Zimbra of your installation? [Yes] no
Notification skipped
Setting up zimbra crontab...done.


Moving /tmp/zmsetup.12252012-011606.log to /opt/zimbra/log


Configuration complete - press return to exit

6. Make sure zimbra services are running :

[root@host1 zcs-8.0.2_GA_5569.RHEL6_64.20121210115059]# su - zimbra
[zimbra@host1 ~]$ zmcontrol status
Host host1.zimbra.local
        antispam                Running
        antivirus               Running
        ldap                    Running
        logger                  Running
        mailbox                 Running
        memcached               Running
        mta                     Running
        proxy                   Running
        snmp                    Running
        spell                   Running
        stats                   Running
        zmconfigd               Running

7. Check the updated version of the ZCS :

[zimbra@host1 ~]$ zmcontrol -v
Release 8.0.2_GA_5569.RHEL6_64_20121210115059 CentOS6_64 FOSS edition.

How to Upgrade from CentOS 6.2 to CentOS 6.3

linux centos 6.3CentOS 6.3 had released on 2012-07-09 with the kernel version 2.6.32-279. CentOS is an Enterprise-class Linux Distribution derived from sources freely provided to the public by our Upstream OS Provider (UOP).
For version CentOS-4.x and CentOS-5.x, it is recommend to reinstall rather than attempt an inplace upgrade from CentOS-4 or CentOS-5 to CentOS 6.3. Direct upgrade from CentOS 6.x to CentOS-6.3 for i386 and x86_64 Architectures is highly recommendeded. The ‘yum update’ should move your machine seamlessly from any previous CentOS-6.x release to CentOS-6.3, unless you have edited your yum configs. Follow this steps to upgrade the CentOS-6.x to CentOS6.3

Check older version :

[root@host1 ~]# cat /etc/redhat-release
CentOS release 6.2 (Final)
or
[root@host1 ~]# cat /etc/issue
CentOS release 6.2 (Final)
Kernel \r on an \m

Official way to do upgrade:

[root@host1 ~]# yum clean all
[root@host1 ~]# yum update -y
[root@host1 ~]# reboot

Check latest version :

[root@host1 ~]# cat /etc/redhat-release
CentOS release 6.3 (Final)

or

[root@host1 ~]# cat /etc/issue
CentOS release 6.3 (Final)
Kernel \r on an \m

How to Setup Zimbra Collaboration Suite 8.0.1 OSE on CentOS 6.3

Setup Zimbra Collaboration Suite 8.0.1Zimbra trusted by over 500 million users worldwide to increase productivity with a full set of collaboration tools while maintaining total control over the security and privacy of email. In this post, i will share the steps to setup Zimbra Collaboration Suite 8.0.1 (ZCS)  Mail Server open source edition on CentOS 6.3 64 bit.  ZCS 8.0.1 only released the 64 bit version for Redhat Linux Enteprise 6 (RHEL6) or CentOS 6 operating system. Before you start installing ZCS software, please make sure that all the prerequisites has been configured and install.

Setup Zimbra Collaboration Suite 8.0.1

1. Download Zimbra Collaboration Suite 8.0.1 from zimbra official website :

[root@host1 ~]# wget files2.zimbra.com/downloads/8.0.1_GA/zcs-8.0.1_GA_5438.RHEL6_64.20121105164412.tgz

2. Extract Zimbra Collaboration Suite 8.0.1 :

[root@host1 ~]# tar xzvf zcs-8.0.1_GA_5438.RHEL6_64.20121105164412.tgz

3. Start the Zimbra Collaboration Suite 8.0.1 installation :

[root@host1 ~]# cd zcs-8.0.1_GA_5438.RHEL6_64.20121105164412
[root@host1 zcs-8.0.1_GA_5438.RHEL6_64.20121105164412]# ./install.sh --platform-override

Operations logged to /tmp/install.log.1247
Checking for existing installation...
    zimbra-ldap...NOT FOUND
    zimbra-logger...NOT FOUND
    zimbra-mta...NOT FOUND
    zimbra-snmp...NOT FOUND
    zimbra-store...NOT FOUND
    zimbra-apache...NOT FOUND
    zimbra-spell...NOT FOUND
    zimbra-convertd...NOT FOUND
    zimbra-memcached...NOT FOUND
    zimbra-proxy...NOT FOUND
    zimbra-archiving...NOT FOUND
    zimbra-cluster...NOT FOUND
    zimbra-core...NOT FOUND

PLEASE READ THIS AGREEMENT CAREFULLY BEFORE USING THE SOFTWARE.
ZIMBRA, INC. ("ZIMBRA") WILL ONLY LICENSE THIS SOFTWARE TO YOU IF YOU
FIRST ACCEPT THE TERMS OF THIS AGREEMENT. BY DOWNLOADING OR INSTALLING
THE SOFTWARE, OR USING THE PRODUCT, YOU ARE CONSENTING TO BE BOUND BY
THIS AGREEMENT. IF YOU DO NOT AGREE TO ALL OF THE TERMS OF THIS
AGREEMENT, THEN DO NOT DOWNLOAD, INSTALL OR USE THE PRODUCT.

License Terms for the Zimbra Collaboration Suite:
  http://www.zimbra.com/license/zimbra_public_eula_2.1.html

Do you agree with the terms of the software license agreement? [N] y

Oracle Binary Code License Agreement for the Java SE Platform Products

ORACLE  AMERICA, INC. ("ORACLE"), FOR AND ON BEHALF OF ITSELF AND ITS SUBSIDIARIES AND AFFILIATES UNDER COMMON CONTROL, IS WILLING TO  LICENSE  THE SOFTWARE
 TO YOU ONLY UPON THE CONDITION THAT YOU ACCEPT ALL OF THE TERMS  CONTAINED IN THIS BINARY CODE LICENSE AGREEMENT AND SUPPLEMENTAL  LICENSE TERMS (COLLECTIVE
LY "AGREEMENT").  PLEASE READ THE AGREEMENT  CAREFULLY.  BY SELECTING THE "ACCEPT LICENSE AGREEMENT" (OR THE EQUIVALENT) BUTTON AND/OR BY USING THE SOFTWARE
YOU ACKNOWLEDGE THAT YOU HAVE READ THE TERMS AND AGREE TO THEM.  IF YOU ARE AGREEING TO THESE TERMS ON BEHALF OF A  COMPANY OR OTHER LEGAL ENTITY, YOU REPRES
ENT THAT YOU HAVE THE LEGAL  AUTHORITY TO BIND THE LEGAL ENTITY TO THESE TERMS.  IF YOU DO NOT HAVE SUCH  AUTHORITY, OR IF YOU DO NOT WISH TO BE BOUND BY THE
 TERMS, THEN SELECT THE "DECLINE LICENSE AGREEMENT" (OR THE EQUIVALENT) BUTTON AND YOU MUST NOT USE THE SOFTWARE ON THIS SITE OR ANY OTHER MEDIA ON WHICH THE
 SOFTWARE IS CONTAINED.

1.  DEFINITIONS.  "Software" means the Java SE Platform Products in binary form that you selected for download, install or use from Oracle or its authorized
licensees, any other machine readable materials (including, but not limited to,  libraries,  source  files,  header  files, and data  files), any updates or
error corrections provided by Oracle, and any user manuals, programming guides and other documentation provided to you by Oracle under this Agreement.  "Gene
ral Purpose Desktop Computers and Servers" means computers,  including desktop and laptop computers, or servers, used for general  computing functions under
end user control (such as but not specifically  limited to email, general purpose Internet browsing, and office suite  productivity tools).  The use of Softw
are in systems and solutions that provide dedicated functionality (other than as mentioned above) or designed  for use in embedded or function-specific softw
are applications, for example but not limited to: Software embedded in or bundled with industrial control systems, wireless mobile telephones, wireless handh
eld devices, netbooks, kiosks, TV/STB, Blu-ray Disc devices, telematics and network control switching equipment, printers and storage management systems, and
 other related systems are excluded from this definition and not licensed under this  Agreement.  "Programs" means Java technology applets and applications
intended to run on the Java Platform, Standard Edition platform on Java-enabled General Purpose Desktop Computers and Servers.  ?Commercial Features? means t
hose features identified in Table 1-1 (Commercial Features In Java SE Product Editions) of the Software documentation accessible at  http://www.oracle.com/te
chnetwork/java/javase/documentation/index.html.  ?README File? means the README file for the Software accessible at http://www.oracle.com/technetwork/java/ja
vase/terms/readme/index.html.

2.  LICENSE TO USE.  Subject to the terms and conditions of this Agreement   including, but not limited to, the Java Technology Restrictions of the  Suppleme
ntal License Terms, Oracle grants you a non-exclusive, non-transferable, limited license without license fees to reproduce and use internally the Software co
mplete and unmodified for the sole purpose of  running Programs.  THE LICENSE SET FORTH IN THIS SECTION 2 DOES NOT EXTEND TO THE COMMERCIAL FEATURES.  YOUR R
IGHTS AND OBLIGATIONS RELATED TO THE COMMERCIAL FEATURES ARE AS SET FORTH IN THE SUPPLEMENTAL TERMS ALONG WITH ADDITIONAL LICENSES FOR DEVELOPERS AND PUBLISH
ERS.

3.  RESTRICTIONS.  Software is copyrighted.  Title to Software and all associated intellectual property rights is retained by Oracle and/or its licensors.  U
nless enforcement is prohibited by applicable law, you may not modify, decompile, or reverse engineer Software.  You acknowledge that the Software is develop
ed for general use in a variety of information management applications; it is not developed or intended for use in any inherently dangerous applications, inc
luding applications that may create a risk of personal injury. If you use the Software in dangerous applications, then you shall be responsible to take all a
ppropriate fail-safe, backup, redundancy, and other measures to ensure its safe use.  Oracle disclaims any express or implied warranty of fitness for such us
es.  No right, title or interest in or to any trademark,  service mark, logo or trade name of Oracle or its licensors is granted under this  Agreement.  Addi
tional restrictions for developers and/or publishers licenses are set forth in the Supplemental License Terms.

4.  DISCLAIMER OF WARRANTY.  THE SOFTWARE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND.  ORACLE FURTHER DISCLAIMS ALL WARRANTIES, EXPRESS AND IMPLIED, IN
CLUDING WITHOUT LIMITATION, ANY IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE OR NONINFRINGEMENT.

5.  LIMITATION OF LIABILITY.  IN NO EVENT SHALL ORACLE BE LIABLE FOR ANY INDIRECT, INCIDENTAL, SPECIAL, PUNITIVE OR CONSEQUENTIAL DAMAGES, OR DAMAGES FOR LOS
S OF PROFITS, REVENUE, DATA OR DATA USE, INCURRED BY YOU OR ANY THIRD PARTY, WHETHER IN AN ACTION IN CONTRACT OR TORT, EVEN IF ORACLE HAS BEEN ADVISED OF THE
 POSSIBILITY OF SUCH DAMAGES. ORACLE'S ENTIRE LIABILITY FOR DAMAGES HEREUNDER SHALL IN NO EVENT EXCEED ONE THOUSAND DOLLARS (U.S. $1,000).

6.  TERMINATION.  This Agreement is effective until terminated.  You may terminate this Agreement at any time by destroying all copies of Software.  This Agr
eement will terminate immediately without notice from Oracle if you  fail to comply with any provision of this Agreement.  Either party may  terminate this A
greement immediately should any Software become, or in either party's opinion be likely to become, the subject of a claim of infringement  of any intellectua
l property  right.  Upon termination, you must destroy all copies of Software.

7.  EXPORT  REGULATIONS.  You agree that U.S. export control laws and other applicable export and import laws govern your use of the Software, including tech
nical data; additional information can be found on Oracle's Global Trade Compliance web site (http://www.oracle.com/products/export). You agree that neither
the Software nor any direct product thereof will be exported, directly, or indirectly, in violation of these laws, or will be used for any purpose prohibited
 by these laws including, without limitation, nuclear, chemical, or biological weapons proliferation.

8.  TRADEMARKS AND LOGOS.  You acknowledge and agree as between you
and Oracle that Oracle owns the ORACLE and JAVA trademarks and all ORACLE- and JAVA-related trademarks, service marks, logos and other brand
designations ("Oracle Marks"), and you agree to comply with the Third
Party Usage Guidelines for Oracle Trademarks currently located at
http://www.oracle.com/us/legal/third-party-trademarks/index.html.  Any use you make of the Oracle Marks inures to Oracle's benefit.

9.  U.S.  GOVERNMENT LICENSE RIGHTS.  If Software is being acquired by or on  behalf of the U.S. Government or by a U.S. Government prime contractor or  subc
ontractor (at any tier), then the Government's rights in Software and accompanying documentation shall be only those set forth in this Agreement.

10.  GOVERNING  LAW.  This agreement is governed by the substantive and procedural laws of California. You and Oracle agree to submit to the exclusive jurisd
iction of, and venue in, the courts of San Francisco, or Santa Clara counties in California in any dispute arising out of or relating to this agreement.

11.  SEVERABILITY.  If any  provision of this  Agreement is held to be unenforceable, this Agreement will remain in effect with the provision omitted, unless
 omission would frustrate the intent of the parties, in which case this Agreement will immediately terminate.

12.  INTEGRATION.  This Agreement is the entire agreement  between you and Oracle relating to its subject matter.  It supersedes all prior or contemporaneous
 oral or written communications, proposals, representations  and warranties and prevails over any  conflicting  or additional  terms  of  any  quote, order,
acknowledgment, or other communication between the parties  relating to its subject matter during the term of this Agreement.  No modification of this Agreem
ent will be  binding,  unless  in  writing  and  signed  by an  authorized representative of each party.

SUPPLEMENTAL LICENSE TERMS

These  Supplemental  License  Terms add to or modify  the terms of the Binary Code License Agreement.  Capitalized terms not defined in these Supplemental  T
erms shall have the same meanings ascribed to them in the Binary Code License Agreement.  These Supplemental Terms shall supersede any  inconsistent or confl
icting terms in the Binary Code License Agreement, or in any license contained within the Software.

A.  COMMERCIAL FEATURES.  You may not use the Commercial Features for running Programs, Java applets or applications in your internal business operations or
for any commercial or production  purpose, or for any purpose other than as set forth in Sections B, C, D and E of these Supplemental Terms.  If You want to
use the Commercial Features for any purpose other than as permitted in this Agreement, You must obtain a separate license from Oracle.

B.  SOFTWARE INTERNAL USE FOR DEVELOPMENT LICENSE GRANT.  Subject to the terms and conditions of this Agreement and restrictions and exceptions set forth in
the README File incorporated herein by reference,  including, but not limited to the Java Technology Restrictions of these  Supplemental Terms, Oracle grants
 you a non-exclusive, non-transferable,  limited license without fees to reproduce internally and use internally the Software complete and unmodified for the
 purpose of designing, developing, and testing your Programs.

C.  LICENSE TO DISTRIBUTE SOFTWARE.  Subject to the terms and conditions of this Agreement and restrictions and exceptions set forth in the   README File, in
cluding, but not limited to the Java Technology Restrictions of these Supplemental Terms, Oracle grants you a non-exclusive, non-transferable, limited licens
e without fees to reproduce and distribute the  Software, provided that (i) you distribute the Software complete and  unmodified and only bundled as part of,
 and for the sole purpose of running, your Programs, (ii) the Programs add significant and primary functionality  to the Software, (iii) you do not distribut
e additional  software intended to replace any component(s) of the Software, (iv) you do not remove or alter any proprietary legends or notices contained in
the Software, (v) you only distribute the Software subject to a license agreement that: (a) is a complete, unmodified reproduction of this Agreement; or (b)
protects Oracle's  interests consistent with the terms contained in this Agreement and that includes the notice set forth in Section G, and (vi) you agree to
 defend and indemnify Oracle and its licensors from and against any damages, costs, liabilities, settlement amounts and/or expenses (including  attorneys' fe
es)  incurred in connection  with any claim, lawsuit or action by any third party that arises or results from the use or distribution of any and all Programs
 and/or Software.

D.  LICENSE TO DISTRIBUTE REDISTRIBUTABLES.  Subject to the terms and conditions of this Agreement and restrictions and exceptions set forth in the README  F
ile, including but not limited to the Java Technology Restrictions of these Supplemental Terms, Oracle grants you a non-exclusive,  non-transferable, limited
 license without fees to reproduce and distribute  those files specifically identified as redistributable in the   README File ("Redistributables") provided
that: (i) you distribute the  Redistributables complete and unmodified, and only bundled as part of Programs, (ii) the Programs add significant and primary f
unctionality to the  Redistributables, (iii) you do not distribute additional software intended to supersede any component(s) of the Redistributables (unless
 otherwise specified in the applicable README File), (iv) you do not remove or alter any proprietary legends or notices contained in or on the Redistributabl
es, (v)  you only distribute the Redistributables pursuant to a license agreement  that: (a) is a complete, unmodified reproduction of this Agreement; or (b)
 protects Oracle's interests consistent with the terms contained in the Agreement and includes the notice set forth in Section G, (vi) you agree to defend an
d indemnify Oracle and its licensors from and against any damages,  costs, liabilities, settlement amounts and/or expenses (including  attorneys'  fees) incu
rred in connection with any claim, lawsuit or action by any third  party that arises or results from the use or distribution of any and all Programs and/or S
oftware.

E.  DISTRIBUTION BY PUBLISHERS.  This section pertains to your distribution  of the JavaTM SE Development Kit Software with your printed book or magazine (as
 those terms are commonly used in the industry) relating to Java technology ("Publication").  Subject to and conditioned upon your compliance  with the restr
ictions and obligations contained in the Agreement, Oracle hereby grants to you a non-exclusive, nontransferable limited right to reproduce complete and unmo
dified copies of the Software on electronic  media (the "Media") for the sole purpose of inclusion and distribution with your Publication(s), subject to the
following terms: (i) You may not distribute  the Software on a stand-alone basis; it must be distributed with your Publication(s); (ii) You are responsible f
or downloading the Software from the applicable Oracle web site; (iii) You must refer to the Software as JavaTM SE Development Kit; (iv) The Software must be
 reproduced in its entirety and without any modification whatsoever (including with respect to all proprietary notices) and distributed with your Publication
 subject to a license agreement that is a complete, unmodified reproduction of this Agreement; (v) The Media label shall include the following information:
Copyright 2011, Oracle America, Inc.  All rights reserved.  Use is subject to license terms.  ORACLE and JAVA trademarks and all ORACLE- and JAVA-related tra
demarks, service marks, logos and other brand
designations are trademarks or registered  trademarks of Oracle in the U.S. and other countries.  This information must be placed on the Media  label in such
 a manner as to only apply to the Oracle  Software;  (vi) You must clearly identify the Software as Oracle's product on the Media  holder or Media label, and
 you may not state or imply that Oracle is responsible for any third-party software contained on the Media; (vii) You may not include any third  party softwa
re on the Media which is intended to be a  replacement or substitute for the Software; (viii) You agree to defend and indemnify Oracle and its licensors from
 and against any damages, costs, liabilities, settlement amounts and/or expenses (including  attorneys'  fees) incurred in connection with any claim, lawsuit
 or action by any third party that arises or results from the use or distribution of the Software and/or the Publication; ; and (ix) You shall provide Oracle
 with a written notice for each Publication; such notice shall include the following information: (1) title of Publication, (2) author(s), (3) date of Public
ation,  and (4)  ISBN or ISSN  numbers.  Such notice shall be sent to  Oracle America, Inc.,  500 Oracle  Parkway, Redwood Shores,  California  94065 U.S.A ,
 Attention:  General Counsel.

F.  JAVA TECHNOLOGY RESTRICTIONS.  You may not create, modify, or change the behavior of, or authorize your licensees to create, modify, or change the behavi
or of, classes, interfaces, or subpackages that are in any way  identified  as  "java", "javax", "sun", ?oracle? or similar convention as   specified by Orac
le in any naming convention designation.

G.  COMMERCIAL FEATURES NOTICE.  For purpose of complying with Supplemental Term Section  C.(v)(b) and D.(v)(b), your license agreement shall include the fol
lowing notice, where the notice is displayed in a manner that anyone using the Software will see the notice:

Use of the Commercial Features for any commercial or production purpose requires a separate license from Oracle.  ?Commercial Features? means those features
identified Table 1-1 (Commercial Features In Java SE Product Editions) of the Software documentation accessible at http://www.oracle.com/technetwork/java/jav
ase/documentation/index.html

H.  SOURCE CODE.  Software may contain source code that, unless expressly   licensed for other purposes, is provided solely for reference purposes  pursuant
to the terms of this Agreement.  Source code may not be redistributed  unless  expressly  provided for in this Agreement.

I.  THIRD PARTY CODE.  Additional copyright notices and license terms applicable to portions of the Software are set forth in the THIRDPARTYLICENSEREADME fil
e accessible at http://www.oracle.com/technetwork/java/javase/documentation/index.html.  In addition to any terms and conditions of any third party opensourc
e/freeware license identified in the  THIRDPARTYLICENSEREADME file, the disclaimer of warranty and limitation of liability  provisions in  paragraphs 4 and 5
 of the Binary Code License Agreement shall apply to all Software in this distribution.

J.  TERMINATION FOR INFRINGEMENT.  Either party may terminate this Agreement immediately should any Software become, or in either party's opinion be likely t
o become, the subject of a claim of infringement of any intellectual property right.

K.  INSTALLATION AND AUTO-UPDATE.  The Software's installation and auto-update processes transmit a limited amount of data to Oracle (or its service  provide
r) about those specific processes to help Oracle understand and optimize them.  Oracle does not associate the data with personally  identifiable  information
.  You can find more  information about the data Oracle collects as a result of your Software download at http://www.oracle.com/technetwork/java/javase/docum
entation/index.html.

For inquiries please contact:  Oracle America, Inc., 500 Oracle Parkway,
Redwood Shores, California 94065, USA.

Last updated May 17, 2011

Do you agree with the terms of the software license agreement? [N] y

Checking for prerequisites...
     FOUND: NPTL
     FOUND: nc-1.84-22
     FOUND: sudo-1.7.4p5-13
     FOUND: libidn-1.18-2
     FOUND: gmp-4.3.1-7
     FOUND: /usr/lib64/libstdc++.so.6

Checking for suggested prerequisites...
     FOUND: perl-5.10.1
     FOUND: sysstat
     FOUND: sqlite
Prerequisite check complete.

Checking for installable packages

Found zimbra-core
Found zimbra-ldap
Found zimbra-logger
Found zimbra-mta
Found zimbra-snmp
Found zimbra-store
Found zimbra-apache
Found zimbra-spell
Found zimbra-memcached
Found zimbra-proxy

Select the packages to install

Install zimbra-ldap [Y]

Install zimbra-logger [Y]

Install zimbra-mta [Y]

Install zimbra-snmp [Y]

Install zimbra-store [Y]

Install zimbra-apache [Y]

Install zimbra-spell [Y]

Install zimbra-memcached [N] y

Install zimbra-proxy [N] y
Checking required space for zimbra-core
Checking space for zimbra-store

Installing:
    zimbra-core
    zimbra-ldap
    zimbra-logger
    zimbra-mta
    zimbra-snmp
    zimbra-store
    zimbra-apache
    zimbra-spell
    zimbra-memcached
    zimbra-proxy

You appear to be installing packages on a platform different
than the platform for which they were built.

This platform is CentOS6_64
Packages found: RHEL6_64
This may or may not work.

Using packages for a platform in which they were not designed for
may result in an installation that is NOT usable. Your support
options may be limited if you choose to continue.

Install anyway? [N] y

The system will be modified.  Continue? [N] y

Removing /opt/zimbra
Removing zimbra crontab entry...done.
Cleaning up zimbra init scripts...done.
Cleaning up /etc/ld.so.conf...done.
Cleaning up /etc/security/limits.conf...done.

Finished removing Zimbra Collaboration Server.

Installing packages

    zimbra-core......zimbra-core-8.0.1_GA_5438.RHEL6_64-20121105164412.x86_64.rpm...done
    zimbra-ldap......zimbra-ldap-8.0.1_GA_5438.RHEL6_64-20121105164412.x86_64.rpm...done
    zimbra-logger......zimbra-logger-8.0.1_GA_5438.RHEL6_64-20121105164412.x86_64.rpm...done
    zimbra-mta......zimbra-mta-8.0.1_GA_5438.RHEL6_64-20121105164412.x86_64.rpm...done
    zimbra-snmp......zimbra-snmp-8.0.1_GA_5438.RHEL6_64-20121105164412.x86_64.rpm...done
    zimbra-store......zimbra-store-8.0.1_GA_5438.RHEL6_64-20121105164412.x86_64.rpm...done
    zimbra-apache......zimbra-apache-8.0.1_GA_5438.RHEL6_64-20121105164412.x86_64.rpm...done
    zimbra-spell......zimbra-spell-8.0.1_GA_5438.RHEL6_64-20121105164412.x86_64.rpm...done
    zimbra-memcached......zimbra-memcached-8.0.1_GA_5438.RHEL6_64-20121105164412.x86_64.rpm...done
    zimbra-proxy......zimbra-proxy-8.0.1_GA_5438.RHEL6_64-20121105164412.x86_64.rpm...done
Operations logged to /tmp/zmsetup.12192012-054322.log
Installing LDAP configuration database...done.
Setting defaults...No results returned for A lookup of host1.zimbra.local
Checked nameservers:
        192.168.1.44
No results returned for AAAA lookup of host1.zimbra.local
Checked nameservers:
        192.168.1.44

DNS ERROR resolving host1.zimbra.local
It is suggested that the hostname be resolvable via DNS
Change hostname [Yes] no

DNS ERROR resolving MX for host1.zimbra.local
It is suggested that the domain name have an MX record configured in DNS
Change domain name? [Yes] yes
Create domain: [host1.zimbra.local] zimbra.local
        MX: mail.zimbra.local (192.168.1.43)

        Interface: 192.168.1.43
        Interface: 127.0.0.1
        Interface: ::1
done.
Checking for port conflicts

Main menu

   1) Common Configuration:
   2) zimbra-ldap:                             Enabled
   3) zimbra-store:                            Enabled
        +Create Admin User:                    yes
        +Admin user to create:                 admin@zimbra.local
******* +Admin Password                        UNSET
        +Anti-virus quarantine user:           virus-quarantine.xbqagircz@zimbra.local
        +Enable automated spam training:       yes
        +Spam training user:                   spam.o9zobzifr@zimbra.local
        +Non-spam(Ham) training user:          ham.dkytx2z3@zimbra.local
        +SMTP host:                            host1.zimbra.local
        +Web server HTTP port:                 80
        +Web server HTTPS port:                443
        +Web server mode:                      https
        +IMAP server port:                     7143
        +IMAP server SSL port:                 7993
        +POP server port:                      7110
        +POP server SSL port:                  7995
        +Use spell check server:               yes
        +Spell server URL:                     http://host1.zimbra.local:7780/aspell.php
        +Enable version update checks:         TRUE
        +Enable version update notifications:  TRUE
        +Version update notification email:    admin@zimbra.local
        +Version update source email:          admin@zimbra.local

   4) zimbra-mta:                              Enabled
   5) zimbra-snmp:                             Enabled
   6) zimbra-logger:                           Enabled
   7) zimbra-spell:                            Enabled
   8) zimbra-proxy:                            Enabled
   9) Enable VMware HA:                        no
  10) Default Class of Service Configuration:
   r) Start servers after configuration        yes
   s) Save config to file
   x) Expand menu
   q) Quit

Address unconfigured (**) items  (? - help) 3

Store configuration

   1) Status:                                  Enabled
   2) Create Admin User:                       yes
   3) Admin user to create:                    admin@zimbra.local
** 4) Admin Password                           UNSET
   5) Anti-virus quarantine user:              virus-quarantine.xbqagircz@zimbra.local
   6) Enable automated spam training:          yes
   7) Spam training user:                      spam.o9zobzifr@zimbra.local
   8) Non-spam(Ham) training user:             ham.dkytx2z3@zimbra.local
   9) SMTP host:                               host1.zimbra.local
  10) Web server HTTP port:                    80
  11) Web server HTTPS port:                   443
  12) Web server mode:                         https
  13) IMAP server port:                        7143
  14) IMAP server SSL port:                    7993
  15) POP server port:                         7110
  16) POP server SSL port:                     7995
  17) Use spell check server:                  yes
  18) Spell server URL:                        http://host1.zimbra.local:7780/aspell.php
  19) Enable version update checks:            TRUE
  20) Enable version update notifications:     TRUE
  21) Version update notification email:       admin@zimbra.local
  22) Version update source email:             admin@zimbra.local

Select, or 'r' for previous menu [r] 4

Password for admin@zimbra.local (min 6 characters): [NqEX9TSRjj] password

Store configuration

   1) Status:                                  Enabled
   2) Create Admin User:                       yes
   3) Admin user to create:                    admin@zimbra.local
   4) Admin Password                           set
   5) Anti-virus quarantine user:              virus-quarantine.xbqagircz@zimbra.local
   6) Enable automated spam training:          yes
   7) Spam training user:                      spam.o9zobzifr@zimbra.local
   8) Non-spam(Ham) training user:             ham.dkytx2z3@zimbra.local
   9) SMTP host:                               host1.zimbra.local
  10) Web server HTTP port:                    80
  11) Web server HTTPS port:                   443
  12) Web server mode:                         https
  13) IMAP server port:                        7143
  14) IMAP server SSL port:                    7993
  15) POP server port:                         7110
  16) POP server SSL port:                     7995
  17) Use spell check server:                  yes
  18) Spell server URL:                        http://host1.zimbra.local:7780/aspell.php
  19) Enable version update checks:            TRUE
  20) Enable version update notifications:     TRUE
  21) Version update notification email:       admin@zimbra.local
  22) Version update source email:             admin@zimbra.local

Select, or 'r' for previous menu [r] r

Main menu

   1) Common Configuration:
   2) zimbra-ldap:                             Enabled
   3) zimbra-store:                            Enabled
   4) zimbra-mta:                              Enabled
   5) zimbra-snmp:                             Enabled
   6) zimbra-logger:                           Enabled
   7) zimbra-spell:                            Enabled
   8) zimbra-proxy:                            Enabled
   9) Enable VMware HA:                        no
  10) Default Class of Service Configuration:
   r) Start servers after configuration        yes
   s) Save config to file
   x) Expand menu
   q) Quit

*** CONFIGURATION COMPLETE - press 'a' to apply
Select from menu, or press 'a' to apply config (? - help) x

Main menu

   1) Common Configuration:
        +Hostname:                             host1.zimbra.local
        +Ldap master host:                     host1.zimbra.local
        +Ldap port:                            389
        +Ldap Admin password:                  set
        +Secure interprocess communications:   yes
        +TimeZone:                             Australia/Brisbane
        +IP Mode:                              ipv4

   2) zimbra-ldap:                             Enabled
        +Create Domain:                        yes
        +Domain to create:                     zimbra.local
        +Ldap root password:                   set
        +Ldap replication password:            set
        +Ldap postfix password:                set
        +Ldap amavis password:                 set
        +Ldap nginx password:                  set
        +Ldap Bes Searcher password:           set

   3) zimbra-store:                            Enabled
        +Create Admin User:                    yes
        +Admin user to create:                 admin@zimbra.local
        +Admin Password                        set
        +Anti-virus quarantine user:           virus-quarantine.xbqagircz@zimbra.local
        +Enable automated spam training:       yes
        +Spam training user:                   spam.o9zobzifr@zimbra.local
        +Non-spam(Ham) training user:          ham.dkytx2z3@zimbra.local
        +SMTP host:                            host1.zimbra.local
        +Web server HTTP port:                 80
        +Web server HTTPS port:                443
        +Web server mode:                      https
        +IMAP server port:                     7143
        +IMAP server SSL port:                 7993
        +POP server port:                      7110
        +POP server SSL port:                  7995
        +Use spell check server:               yes
        +Spell server URL:                     http://host1.zimbra.local:7780/aspell.php
        +Enable version update checks:         TRUE
        +Enable version update notifications:  TRUE
        +Version update notification email:    admin@zimbra.local
        +Version update source email:          admin@zimbra.local

   4) zimbra-mta:                              Enabled
        +MTA Auth host:                        host1.zimbra.local
        +Enable Spamassassin:                  yes
        +Enable Clam AV:                       yes
        +Notification address for AV alerts:   admin@zimbra.local
        +Bind password for postfix ldap user:  set
        +Bind password for amavis ldap user:   set

   5) zimbra-snmp:                             Enabled
        +Enable SNMP notifications:            yes
        +SNMP Trap hostname:                   host1.zimbra.local
        +Enable SMTP notifications:            yes
        +SMTP Source email address:            admin@zimbra.local
        +SMTP Destination email address:       admin@zimbra.local

   6) zimbra-logger:                           Enabled
   7) zimbra-spell:                            Enabled
   8) zimbra-proxy:                            Enabled
        +Enable POP/IMAP Proxy:                TRUE
        +IMAP proxy port:                      143
        +IMAP SSL proxy port:                  993
        +POP proxy port:                       110
        +POP SSL proxy port:                   995
        +Bind password for nginx ldap user:    set
        +Enable HTTP[S] Proxy:                 FALSE

   9) Enable VMware HA:                        no
  10) Default Class of Service Configuration:
        +Enable Tasks Feature:                 Enabled

   c) Collapse menu
   r) Start servers after configuration        yes
   s) Save config to file
   q) Quit

*** CONFIGURATION COMPLETE - press 'a' to apply
Select from menu, or press 'a' to apply config (? - help) a
Save configuration data to a file? [Yes]
Save config in file: [/opt/zimbra/config.9166]
Saving config in /opt/zimbra/config.9166...done.
The system will be modified - continue? [No] yes
Operations logged to /tmp/zmsetup.12192012-054322.log
Setting local config values...done.
Initializing core config...Setting up CA...done.
Deploying CA to /opt/zimbra/conf/ca ...done.
Creating SSL zimbra-store certificate...done.
Creating new zimbra-ldap SSL certificate...done.
Creating new zimbra-mta SSL certificate...done.
Creating new zimbra-proxy SSL certificate...done.
Installing mailboxd SSL certificates...done.
Installing MTA SSL certificates...done.
Installing LDAP SSL certificate...done.
Installing Proxy SSL certificate...done.
Initializing ldap...done.
Setting replication password...done.
Setting Postfix password...done.
Setting amavis password...done.
Setting nginx password...done.
Creating server entry for host1.zimbra.local...done.
Setting Zimbra IP Mode...done.
Saving CA in ldap ...done.
Saving SSL Certificate in ldap ...done.
Setting spell check URL...done.
Setting service ports on host1.zimbra.local...done.
Adding host1.zimbra.local to zimbraMailHostPool in default COS...done.
Setting zimbraFeatureTasksEnabled=TRUE...done.
Setting zimbraFeatureBriefcasesEnabled=FALSE...done.
Setting MTA auth host...done.
Setting TimeZone Preference...done.
Initializing mta config...done.
Setting services on host1.zimbra.local...done.
Creating domain zimbra.local...done.
Setting default domain name...done.
Creating domain zimbra.local...already exists.
Creating admin account admin@zimbra.local...done.
Creating root alias...done.
Creating postmaster alias...done.
Creating user spam.o9zobzifr@zimbra.local...done.
Creating user ham.dkytx2z3@zimbra.local...done.
Creating user virus-quarantine.xbqagircz@zimbra.local...done.
Setting spam training and Anti-virus quarantine accounts...done.
Initializing store sql database...done.
Setting zimbraSmtpHostname for host1.zimbra.local...done.
Configuring SNMP...done.
Setting up syslog.conf...done.
Starting servers...done.
Installing common zimlets...
        com_zimbra_date...done.
        com_zimbra_email...done.
        com_zimbra_tooltip...done.
        com_zimbra_cert_manager...done.
        com_zimbra_url...done.
        com_zimbra_attachmail...done.
        com_zimbra_phone...done.
        com_zimbra_proxy_config...done.
        com_zimbra_clientuploader...done.
        com_zimbra_ymemoticons...done.
        com_zimbra_srchhighlighter...done.
        com_zimbra_webex...done.
        com_zimbra_attachcontacts...done.
        com_zimbra_bulkprovision...done.
        com_zimbra_adminversioncheck...done.
Finished installing common zimlets.
Restarting mailboxd...done.
Creating galsync account for default domain...done.

You have the option of notifying Zimbra of your installation.
This helps us to track the uptake of the Zimbra Collaboration Server.
The only information that will be transmitted is:
        The VERSION of zcs installed (8.0.1_GA_5438_CentOS6_64)
        The ADMIN EMAIL ADDRESS created (admin@zimbra.local)

Notify Zimbra of your installation? [Yes] no
Notification skipped
Setting up zimbra crontab...done.

Moving /tmp/zmsetup.12192012-054322.log to /opt/zimbra/log

Configuration complete - press return to exit

4. Check Status, restart, start and stop zimbra server :

[root@host1 ~]# su - zimbra
[zimbra@host1 ~]$ zmcontrol status
[zimbra@host1 ~]$ zmcontrol restart
[zimbra@host1 ~]$ zmcontrol start
[zimbra@host1 ~]$ zmcontrol stop

How to Mount a Windows Shared Folder in Linux CentOS 6.3

In this post, i will share on how to mount windows share folder on linux CentOS 6.3 server. Assumed that windows share folder has been configured properly with administrator privileged. This uses Common Internet File System (CIFS) protocol. CIFS can lets you access to shared folder and files that are remotely on the server and can do read and write to them.

Windows Share: //192.168.2.51/Files
Windows Credentials : username=administrator,password=mypassword

1. Execute the following command to mount Windows share folder :

[root@centos63 /]# mount -t cifs -o username=administrator,password=mypassword //192.168.2.51/Files /mnt

2. Verify that Windows share folder already mounted to /mnt :

[root@centos63 /]# df -k
Filesystem           1K-blocks      Used Available Use% Mounted on
/dev/mapper/vg_centos63-lv_root
                       5716804   2451228   2975172  46% /
tmpfs                   515400         0    515400   0% /dev/shm
/dev/sda1               495844     66280    403964  15% /boot
//192.168.2.51/Files 476403708 343375460 133028248  73% /mnt

3. Add that Windows share folder into /etc/fstab file, so that it will auto mount once rebooted :

[root@centos63 ~]# vi /etc/fstab

Add the final line as below :

#
# /etc/fstab
# Created by anaconda on Sun Jul 15 20:17:38 2012
#
# Accessible filesystems, by reference, are maintained under '/dev/disk'
# See man pages fstab(5), findfs(8), mount(8) and/or blkid(8) for more info
#
/dev/mapper/vg_centos63-lv_root /                       ext4    defaults        1 1
UUID=2217c7b1-4467-4c81-8596-c3ee7758e2cc /boot                   ext4    defaults        1 2
/dev/mapper/vg_centos63-lv_swap swap                    swap    defaults        0 0
tmpfs                   /dev/shm                tmpfs   defaults        0 0
devpts                  /dev/pts                devpts  gid=5,mode=620  0 0
sysfs                   /sys                    sysfs   defaults        0 0
proc                    /proc                   proc    defaults        0 0
//192.168.2.51/Files    /mnt                    cifs    username=administrator,password=mypassword 0 0

How to Enable mod_perl on Linux CentOS 6.3

The default apache configuration installed without mod_perl. This can be a good idea in order to minimize the number of things that can go wrong. This post will covers the steps to enable mod_perl on linux CentOS 6.3. This will make Perl script be fast and increase the performance.

Prerequisites:
How to Install Httpd on CentOS 6.3

1. To Enable mod_perl, simply run the following command :

[root@centos63 ~]# yum install mod_perl -y
Loaded plugins: fastestmirror, presto, priorities
Loading mirror speeds from cached hostfile
 * base: centos.ipserverone.com
 * extras: centos.ipserverone.com
 * updates: centos.ipserverone.com
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package mod_perl.i686 0:2.0.4-10.el6 will be installed
--> Processing Dependency: perl(BSD::Resource) for package: mod_perl-2.0.4-10.el6.i686
--> Running transaction check
---> Package perl-BSD-Resource.i686 0:1.29.03-3.el6 will be installed
--> Finished Dependency Resolution

Dependencies Resolved

====================================================================================================
 Package                       Arch             Version                      Repository        Size
====================================================================================================
Installing:
 mod_perl                      i686             2.0.4-10.el6                 base             3.2 M
Installing for dependencies:
 perl-BSD-Resource             i686             1.29.03-3.el6                base              35 k

Transaction Summary
====================================================================================================
Install       2 Package(s)

Total download size: 3.2 M
Installed size: 6.0 M
Downloading Packages:
Setting up and reading Presto delta metadata
Processing delta metadata
Package(s) data still to download: 3.2 M
(1/2): mod_perl-2.0.4-10.el6.i686.rpm                                        | 3.2 MB     00:27
(2/2): perl-BSD-Resource-1.29.03-3.el6.i686.rpm                              |  35 kB     00:00
----------------------------------------------------------------------------------------------------
Total                                                               117 kB/s | 3.2 MB     00:27
Running rpm_check_debug
Running Transaction Test
Transaction Test Succeeded
Running Transaction
  Installing : perl-BSD-Resource-1.29.03-3.el6.i686                                             1/2
  Installing : mod_perl-2.0.4-10.el6.i686                                                       2/2
  Verifying  : mod_perl-2.0.4-10.el6.i686                                                       1/2
  Verifying  : perl-BSD-Resource-1.29.03-3.el6.i686                                             2/2

Installed:
  mod_perl.i686 0:2.0.4-10.el6

Dependency Installed:
  perl-BSD-Resource.i686 0:1.29.03-3.el6

Complete!

2. Configure PerlRun mode :

[root@centos63 ~]# vi /etc/httpd/conf.d/perl.conf

a) Original :

#PerlSwitches -w

Uncomment or change to :

PerlSwitches -w

b) Original :

#PerlSwitches -T

Uncomment or change to :

PerlSwitches -T

c) Original :

#Alias /perl /var/www/perl
#<Directory /var/www/perl>
#    SetHandler perl-script
#    PerlResponseHandler ModPerl::Registry
#    PerlOptions +ParseHeaders
#    Options +ExecCGI
#</Directory>

Uncomment or change to :

Alias /perl /var/www/perl
<Directory /var/www/perl>
    SetHandler perl-script
#   AddHandler perl-script .cgi
#   PerlResponseHandler ModPerl::Registry
    PerlResponseHandler ModPerl::PerlRun
    PerlOptions +ParseHeaders
    Options +ExecCGI
</Directory>

d) Original :

#<Location /perl-status>
#    SetHandler perl-script
#    PerlResponseHandler Apache2::Status
#    Order deny,allow
#    Deny from all
#    Allow from .example.com
#</Location>

Uncomment or change to :

<Location /perl-status>
    SetHandler perl-script
    PerlResponseHandler Apache2::Status
    Order deny,allow
    Deny from all
    Allow from 192.168.2.0/24
</Location>

3. Restart Apache :

[root@centos63 ~]# /etc/rc.d/init.d/httpd restart
Stopping httpd:                                            [  OK  ]
Starting httpd:                                            [  OK  ]

4. Make sure if it works normally :

Browse to http://192.168.2.54/perl-status

mod_perl

5. Configure Registry mode :

Alias /perl /var/www/perl
<Directory /var/www/perl>
    SetHandler perl-script
# AddHandler perl-script .cgi
    PerlResponseHandler ModPerl::Registry
#  PerlResponseHandler ModPerl::PerlRun
    PerlOptions +ParseHeaders
    Options +ExecCGI
</Directory>

6. Restart Apache :

[root@centos63 ~]# /etc/rc.d/init.d/httpd restart
Stopping httpd:                                            [  OK  ]
Starting httpd:                                            [  OK  ]

How to Secure OpenSSH (SSHD) on Linux

OpenSSH is a open source alternative to the proprietary Secure Shell software. It is also the SSH connectivity tools that allows you to remotely login, transfer remote file via scp or sftp. It was created as an open source alternative to the proprietary Secure Shell software. OpenSSH options are controlled through the /etc/ssh/sshd_config file. In order to improve OpenSSH server security, certain default sshd setting need to be change. This post will show you three example to Secure OpenSSH (SSHD) on Linux. This steps has been tested on CentOS 6.3 and may working on CentOS 6.2, CentOS 5.x and Redhat Enterprise Linux 5 (RHEL 5) and Redhat Enterprise Linux 6 (RHEL 6).

1.Change SSH Default Port :

By default ssh runs on port 22. Hacker would need to know the SSH port number in order to access your system. One of the method to improve security is to change the default port to a non-standard port. That would helps to stop brute force attacks.

#Port 22

Uncomment and change to :

Port 2202

2. Disable Root Login (PermitRootLogin) :

Add the following entry to sshd_config to disable root to login to the server directly.

#PermitRootLogin yes

Uncomment and change to :

PermitRootLogin no

3. Listen Specific IP only :

By default ssh will listen on all of the above ip-addresses. If you want users to login only using ip-address 192.168.1.200 and 192.168.1.202, do the following in your sshd_config :

ListenAddress 192.168.1.200
ListenAddress 192.168.1.202

How to Find Default Gateway IP address on Linux

A default gateway is the node (a router) or network point on the computer network that serves as an access point and entrance to another network. It passes traffic between different subnets and networks. Computers running on the network using IP, a default gateway address is needed to reach all computers that are not on the same local IP subnet. This post will show you how to Find default gateway IP address on linux operating system. This command has been tested on CentOS 6.3.

1. Print default gateway using route command :

[root@centos63 ~]# route

Output :

Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
192.168.1.0     *               255.255.255.0   U     0      0        0 eth0
link-local      *               255.255.0.0     U     1002   0        0 eth0
default         192.168.1.1     0.0.0.0         UG    0      0        0 eth0

2. Print default gateway using netstat command :

[root@centos63 ~]# netstat -rn

Output :

Kernel IP routing table
Destination     Gateway         Genmask         Flags   MSS Window  irtt Iface
192.168.1.0     0.0.0.0         255.255.255.0   U         0 0          0 eth0
169.254.0.0     0.0.0.0         255.255.0.0     U         0 0          0 eth0
0.0.0.0         192.168.1.1     0.0.0.0         UG        0 0          0 eth0

Note : The flag U indicates that route is up and G indicates that it is gateway.

How to Check Disk Read Write Speed in Linux

hard diskMeasuring sequential disk performance is easy in linux as every modern Linux distribution comes with a command line utility called hdparm. Hdparm is a free tool to measure sequential disk performance which is primarily used to tune and optimize disk parameters. It is important to read hdparm man page and perform full backup before using hdparm command line utility. The popular option for hdparm command line utility are -t and -T.

-t is to perform buffered disk read which is the data transfer rate directly from the disk to memory.

-T is to perform timing cached read which is the data transfer rate from a memory buffer without reading the hard drive.

If hdparm is not installed then follow this steps to install hdparm on CentOS 6.3.

Type hdparm without option to get full hard disk parameters as a reference.

[root@centos63 ~]# hdparm

hdparm - get/set hard disk parameters - version v9.16

Usage:  hdparm  [options] [device] ..

Options:
 -a   get/set fs readahead
 -A   get/set the drive look-ahead flag (0/1)
 -b   get/set bus state (0 == off, 1 == on, 2 == tristate)
 -B   set Advanced Power Management setting (1-255)
 -c   get/set IDE 32-bit IO setting
 -C   check drive power mode status
 -d   get/set using_dma flag
 -D   enable/disable drive defect management
 -E   set cd/dvd drive speed
 -f   flush buffer cache for device on exit
 -F   flush drive write cache
 -g   display drive geometry
 -h   display terse usage information
 -H   read temperature from drive (Hitachi only)
 -i   display drive identification
 -I   detailed/current information directly from drive
 -k   get/set keep_settings_over_reset flag (0/1)
 -K   set drive keep_features_over_reset flag (0/1)
 -L   set drive doorlock (0/1) (removable harddisks only)
 -M   get/set acoustic management (0-254, 128: quiet, 254: fast)
 -m   get/set multiple sector count
 -N   get/set max visible number of sectors (HPA) (VERY DANGEROUS)
 -n   get/set ignore-write-errors flag (0/1)
 -p   set PIO mode on IDE interface chipset (0,1,2,3,4,...)
 -P   set drive prefetch count
 -q   change next setting quietly
 -Q   get/set DMA queue_depth (if supported)
 -r   get/set device  readonly flag (DANGEROUS to set)
 -R   obsolete
 -s   set power-up in standby flag (0/1) (DANGEROUS)
 -S   set standby (spindown) timeout
 -t   perform device read timings
 -T   perform cache read timings
 -u   get/set unmaskirq flag (0/1)
 -U   obsolete
 -v   defaults; same as -acdgkmur for IDE drives
 -V   display program version and exit immediately
 -w   perform device reset (DANGEROUS)
 -W   get/set drive write-caching flag (0/1)
 -x   obsolete
 -X   set IDE xfer mode (DANGEROUS)
 -y   put drive in standby mode
 -Y   put drive to sleep
 -Z   disable Seagate auto-powersaving mode
 -z   re-read partition table
 --dco-freeze      freeze/lock current device configuration until next power cycle
 --dco-identify    read/dump device configuration identify data
 --dco-restore     reset device configuration back to factory defaults
 --direct          use O_DIRECT to bypass page cache for timings
 --drq-hsm-error   crash system with a "stuck DRQ" error (VERY DANGEROUS)
 --fibmap          show device extents (and fragmentation) for a file
 --fibmap-sector   show absolute LBA of a specfic sector of a file
 --fwdownload            Download firmware file to drive (EXTREMELY DANGEROUS)
 --fwdownload-mode3      Download firmware using min-size segments (EXTREMELY DANGEROUS)
 --fwdownload-mode3-max  Download firmware using max-size segments (EXTREMELY DANGEROUS)
 --fwdownload-mode7      Download firmware using a single segment (EXTREMELY DANGEROUS)
 --idle-immediate  idle drive immediately
 --idle-unload     idle immediately and unload heads
 --Istdin          read identify data from stdin as ASCII hex
 --Istdout         write identify data to stdout as ASCII hex
 --make-bad-sector deliberately corrupt a sector directly on the media (VERY DANGEROUS)
 --prefer-ata12    use 12-byte (instead of 16-byte) SAT commands when possible
 --read-sector     read and dump (in hex) a sector directly from the media
 --security-help   display help for ATA security commands
 --trim-sectors    tell SSD firmware to discard unneeded data sectors (lba and count)
 --verbose         display extra diagnostics from some commands
 --write-sector    repair/overwrite a (possibly bad) sector directly on the media (VERY DANGEROUS)

Note : Substitute /dev/sda with the name of the disk device.

Example on how to check disk Disk Read Write Speed for /dev/sda on CentOS6.3 :

[root@centos63 ~]# hdparm -tT /dev/sda

/dev/sda:
 Timing cached reads:   4128 MB in  2.00 seconds = 2065.62 MB/sec
 Timing buffered disk reads:  276 MB in  3.06 seconds =  90.30 MB/sec

Example on how to check disk Disk Read Write Speed for /dev/sdb on CentOS6.3 :

[root@centos63 ~]# hdparm -tT /dev/sdb

/dev/sdb:
 Timing cached reads:   3410 MB in  2.00 seconds = 1705.84 MB/sec
 Timing buffered disk reads:  364 MB in  3.00 seconds = 121.29 MB/sec

How to Fix “-bash: hdparm: command not found” on Linux CentOS 6.3

hard diskQuestion:
When i try to run hdparm command to check to check the hard drive read and writing speed, the following error has been returned. Hdparm is a command line utility to measure sequential disk performance which is primarily used to tune and optimize disk parameters. Hdparm is free software under the BSD license.

[root@centos63 ~]# hdparm -t /dev/sda
-bash: hdparm: command not found

To Fix this, install hdparm command line utility on CentOS 6.3 using two method :

Method 1: Install hdparm using yum command :

[root@centos63 ~]# yum install hdparm -y

Example :

[root@centos63 ~]# yum install hdparm -y
Loaded plugins: fastestmirror, presto, priorities
Loading mirror speeds from cached hostfile
 * base: mirrors.sin3.sg.voxel.net
 * extras: mirrors.sin3.sg.voxel.net
 * updates: mirror.issp.co.th
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package hdparm.i686 0:9.16-3.4.el6 will be installed
--> Finished Dependency Resolution

Dependencies Resolved

====================================================================================================
 Package               Arch                Version                        Repository           Size
====================================================================================================
Installing:
 hdparm                i686                9.16-3.4.el6                   base                 72 k

Transaction Summary
====================================================================================================
Install       1 Package(s)

Total download size: 72 k
Installed size: 134 k
Downloading Packages:
Setting up and reading Presto delta metadata
Processing delta metadata
Package(s) data still to download: 72 k
hdparm-9.16-3.4.el6.i686.rpm                                                 |  72 kB     00:00
Running rpm_check_debug
Running Transaction Test
Transaction Test Succeeded
Running Transaction
  Installing : hdparm-9.16-3.4.el6.i686                                                         1/1
  Verifying  : hdparm-9.16-3.4.el6.i686                                                         1/1

Installed:
  hdparm.i686 0:9.16-3.4.el6

Complete!

Method 2 : Install hdparm using RPM packages as per OS and bit :

For 32 Bit :

[root@centos63 ~]# rpm -Uvh http://mirrors.hostemo.com/CentOS/6.3/os/i386/Packages/hdparm-9.16-3.4.el6.i686.rpm

For 64 Bit :

[root@centos63 ~]# rpm -Uvh http://mirrors.hostemo.com/CentOS/6.3/os/x86_64/Packages/hdparm-9.16-3.4.el6.x86_64.rpm

Verify if the hdparm RPM is installed or not by using the following command :

[root@centos63 ~]# rpm -qa | grep hdparm
hdparm-9.16-3.4.el6.i686

How to Remove a Logical Volume on CentOS 6.3/RHEL6

In previous post, i have cover the steps to create additional Logical volume manager (LVM). In certain situation, linux administrator is required to remove the existing logical volume. It is possible to perform the required task if that system administrator has the right skill on linux. Otherwise, they will put themselves and the organization in the disaster or risk as this working with the system’s data. This post assumed centos63_vol has been created and will be remove later. In summary, removing a logical volume (centos63_vol) will involve the following processes:

a) Unmount the LV
b) Remove the LV
c) Update /etc/fstab

1. Begin by listing all the logical volumes on the system :

[root@centos63 ~]# lvs
  LV           VG          Attr     LSize Pool Origin Data%  Move Log Copy%  Convert
  lv_root      vg_centos63 -wi-ao-- 5.54g
  lv_swap      vg_centos63 -wi-ao-- 1.97g
  centos63_vol vg_data     -wi-ao-- 4.99g

2. Check current disk layout and find where centos63_vol is mounted :

[root@centos63 ~]# df -lh
Filesystem            Size  Used Avail Use% Mounted on
/dev/mapper/vg_centos63-lv_root
                      5.5G  2.2G  3.1G  41% /
tmpfs                 504M     0  504M   0% /dev/shm
/dev/sda1             485M   65M  395M  15% /boot
/dev/mapper/vg_data-centos63_vol
                      5.0G  139M  4.6G   3% /mydata

3. View current /etc/fstab value :

[root@centos63 ~]# cat /etc/fstab

#
# /etc/fstab
# Created by anaconda on Sun Jul 15 20:17:38 2012
#
# Accessible filesystems, by reference, are maintained under '/dev/disk'
# See man pages fstab(5), findfs(8), mount(8) and/or blkid(8) for more info
#
/dev/mapper/vg_centos63-lv_root /                       ext4    defaults        1 1
UUID=2217c7b1-4467-4c81-8596-c3ee7758e2cc /boot                   ext4    defaults        1 2
/dev/mapper/vg_centos63-lv_swap swap                    swap    defaults        0 0
tmpfs                   /dev/shm                tmpfs   defaults        0 0
devpts                  /dev/pts                devpts  gid=5,mode=620  0 0
sysfs                   /sys                    sysfs   defaults        0 0
proc                    /proc                   proc    defaults        0 0
/dev/vg_data/centos63_vol /mydata                       ext4    defaults        1 1

4. Unmount centos63_vol (mounted at /mydata) :

[root@centos63 ~]# umount /mydata

5. Verify that centos63_vol has unmounted :

[root@centos63 ~]# df -lh
Filesystem            Size  Used Avail Use% Mounted on
/dev/mapper/vg_centos63-lv_root
                      5.5G  2.2G  3.1G  41% /
tmpfs                 504M     0  504M   0% /dev/shm
/dev/sda1             485M   65M  395M  15% /boot

6. Remove the logical volume /dev/mapper/vg_data-centos63_vol :

[root@centos63 ~]# lvremove /dev/mapper/vg_data-centos63_vol
Do you really want to remove active logical volume centos63_vol? [y/n]: y
  Logical volume "centos63_vol" successfully removed

7. Verify the logical volume has been removed :

[root@centos63 ~]# lvs
  LV      VG          Attr     LSize Pool Origin Data%  Move Log Copy%  Convert
  lv_root vg_centos63 -wi-ao-- 5.54g
  lv_swap vg_centos63 -wi-ao-- 1.97g
[root@centos63 ~]#

8. Update /etc/fstab to reflect the removal of the file system :

[root@centos63 ~]# vi /etc/fstab
#
# /etc/fstab
# Created by anaconda on Sun Jul 15 20:17:38 2012
#
# Accessible filesystems, by reference, are maintained under '/dev/disk'
# See man pages fstab(5), findfs(8), mount(8) and/or blkid(8) for more info
#
/dev/mapper/vg_centos63-lv_root /                       ext4    defaults        1 1
UUID=2217c7b1-4467-4c81-8596-c3ee7758e2cc /boot                   ext4    defaults        1 2
/dev/mapper/vg_centos63-lv_swap swap                    swap    defaults        0 0
tmpfs                   /dev/shm                tmpfs   defaults        0 0
devpts                  /dev/pts                devpts  gid=5,mode=620  0 0
sysfs                   /sys                    sysfs   defaults        0 0
proc                    /proc                   proc    defaults        0 0