4.6.5 Netezza Getting Started Tips
4.6.5 Netezza Getting Started Tips
Document Number: D20293-11 Rev. 1 Software Release: 4.6 Revised: February 25, 2009
Netezza Corporation Corporate Headquarters 26 Forest St., Marlborough, Massachusetts 01752 tel 508.382.8200 fax 508.382.8300 www.netezza.com
The specifications and information regarding the products described in this manual are subject to change without notice. All statements, information, and recommendations in this manual are believed to be accurate. Netezza makes no representations or warranties of any kind, express or implied, including, without limitation, those of merchantability, fitness for a particular purpose, and noninfringement, regarding this manual or the products' use or performance. In no event will Netezza be liable for indirect, incidental, consequential, special, or economic damages (including lost business profits, business interruption, loss or damage of data, and the like) arising out of the use or inability to use this manual or the products, regardless of the form of action, whether in contract, tort (including negligence), breach of warranty, or otherwise, even if Netezza has been advised of the possibility of such damages. Portions of this publication were derived from PostgreSQL documentation. For those portions of the documentation that were derived originally from PostgreSQL documentation, and only for those portions, the following applies: PostgreSQL is copyright 1996-2001 by the PostgreSQL global development group and is distributed under the terms of the license of the University of California below. Postgres95 is copyright 1994-5 by the Regents of the University of California. Permission to use, copy, modify, and distribute this documentation for any purpose, without fee, and without a written agreement is hereby granted, provided that the above copyright notice and this paragraph and the following two paragraphs appear in all copies. In no event shall the University of California be liable to any party for direct, indirect, special, incidental, or consequential damages, including lost profits, arising out of the use of this documentation, even if the University of California has been advised of the possibility of such damage. The University of California specifically disclaims any warranties, including, but not limited to, the implied warranties of merchantability and fitness for a particular purpose. The documentation provided hereunder is on an "as-is" basis, and the University of California has no obligations to provide maintenance, support, updates, enhancements, or modifications. Netezza, the Netezza logo, NPS, Snippet, Snippet Processing Unit, SPU, Snippet Processing Array, SPA, Performance Server, Netezza Performance Server, Asymmetric Massively Parallel Processing, AMPP, Intelligent Query Streaming, SQL-Blast and other marks are trademarks or registered trademarks of Netezza Corporation in the United States and/or other countries. All rights reserved. The Netezza implementation of the ODBC driver is an adaptation of an open source driver, Copyright 2000, 2001, Great Bridge LLC. The source code for this driver and the object code of any Netezza software that links with it are available upon request to [email protected] Red Hat is a trademark or registered trademark of Red Hat, Inc. in the United States and/or other countries. Linux is a trademark or registered trademark of Linus Torvalds in the United States and/or other countries. D-CC, D-C++, Diab+, FastJ, pSOS+, SingleStep, Tornado, VxWorks, Wind River, and the Wind River logo are trademarks, registered trademarks, or service marks of Wind River Systems, Inc. Tornado patent pending. APC and the APC logo are trademarks or registered trademarks of American Power Conversion Corporation. All document files and software of the above named third-party suppliers are provided "as is" and may contain deficiencies. Netezza and its suppliers disclaim all warranties of any kind, express or implied, including, without limitation, those of merchantability, fitness for a particular purpose, and noninfringement. In no event will Netezza or its suppliers be liable for indirect, incidental, consequential, special, or economic damages (including lost business profits, business interruption, loss or damage of data, and the like), or the use or inability to use the above-named third-party products, even if Netezza or its suppliers have been advised of the possibility of such damages. All other trademarks mentioned in this document are the property of their respective owners. Document Number: 20293-11 Software Release Number: 4.6 and Later Netezza Performance Server Getting Started Tips Copyright 2004-2009 Netezza Corporation. All rights reserved. Regulatory Notices Install the NPS Series in a restricted-access location. Ensure that only those trained to operate or service the equipment have physical access to it. Install each AC power outlet near the NPS rack that plugs into it, and keep it freely accessible. You must provide all disconnect devices and over-current protection devices. Product may be powered by redundant power sources. Disconnect ALL power sources before servicing. FCC Statement This equipment has been tested and found to comply with the limits for a Class A digital device, pursuant to part 15 of the FCC rules. These limits are designed to provide reasonable protection against harmful interference when the equipment is operated in a commercial environment. This equipment generates, uses, and can radiate radio-frequency energy and, if not installed and used in accordance with the instruction manual, may cause harmful interference to radio communications. Operation of this equipment in a residential area is likely to cause harmful interference, in which case users will be required to correct the interference at their own expense. CSA Statement This Class A digital apparatus meets all requirements of the Canadian Interference-Causing Equipment Regulations (ICES-003). Cet appareil numrique de la classe A est conforme la norme NMB-003 du Canada. CE Statement (Europe) This product complies with the European Low Voltage Directive 73/23/EEC and EMC Directive 89/336/EEC as amended by European Directive 93/68/EEC/. Warning: This is a class A product. In a domestic environment this product may cause radio interference in which case the user may be required to take adequate measures.
Contents
1 About the Netezza Performance Server
NPS Hardware. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-1 NPS Host . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-1 Snippet Processing Units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-2 Snippet Processing Arrays . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-2 Storage Arrays . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-2 NPS Software . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-2 NPS Software CDs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-3 Installing Administration and Client Software . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-3 Linux Host Operating System Requirements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-4 Powering Down the NPS System . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-4 Powering Down 10000-Series NPS Systems. . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-5 Powering Down 5200-Series Systems . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-9 Powering Up the NPS System . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-10 Powering Up a 10000-Series NPS System . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-11 Powering Up 5200-Series Systems . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-14 Netezza SPU LED Descriptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-15 Getting Started with Commands and Queries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-16 Default Users and Passwords . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-16 Netezza Common Tasks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-17 Basic Netezza CLI Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-21 Basic Netezza SQL Information. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-24 Choosing a Backup and Restore Method . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-27 Getting Help . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-28 PDF Documentation. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-28 Online Help . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-29 Netezza Support Contact Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-31
iii
iv
List of Tables
Table 1-1: Table 1-2: Table 1-3: Table 1-4: Table 1-5: Table 1-6: Table 1-7: Table 1-8: Table 1-9: Table 1-10: Table 1-11: Table 1-12: Table 1-13: Table 1-14: NPS Release Software CDs. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-3 Rev 7 SPU LED Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-16 Default Users and Passwords . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-16 Netezza Common Tasks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-17 CLI Command Locations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-21 Commonly Used Command Options. . . . . . . . . . . . . . . . . . . . . . . . 1-22 Commonly Used nzload Command Options . . . . . . . . . . . . . . . . . . 1-22 Log files for nzload . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-23 Netezza SQL Commands . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-24 SQL Tips . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-25 Commonly Used Internal Slash Options . . . . . . . . . . . . . . . . . . . . . 1-25 Commonly Used nzsql Command Options . . . . . . . . . . . . . . . . . . . 1-26 Choosing a Backup and Restore Method . . . . . . . . . . . . . . . . . . . . 1-27 Key User Manuals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-28
vi
CHAPTER 1
About the Netezza Performance Server
Whats in this chapter
NPS Hardware NPS Software Linux Host Operating System Requirements Powering Down the NPS System Powering Up the NPS System Getting Started with Commands and Queries Getting Help
This document provides a brief introduction to some background information and getting started tips for the Netezza Performance Server (NPS). If you are a new user of the NPS data warehouse appliance, or you are moving from an older NPS system to the latest release, review this content to familiarize yourself with the basics.
NPS Hardware
A Netezza system consists of multiple hardware and software components working together to provide performance and reliability. The NPS models include configurations with one standalone rack (a standard configuration), or two or more hardware racks clustered in a high-availability (HA) configuration. Within each rack are numerous components that work together to provide the asymmetric massively parallel processing of the NPS architecture. The key hardware components within an NPS include the following: NPS Host Snippet Processing Units Snippet Processing Arrays Storage Arrays
NPS Host
The NPS host, located within the NPS rack, controls and coordinates the activity of the NPS. It performs query optimization; controls table and database operations; consolidates and returns query results; and monitors the NPS system components to detect and report problems.
1-1
The host is a highly redundant, highly available, server with dual power supplies, error-correcting memory, a disk channel controller, and redundant disks (RAID 5). Each NPS rack has a keyboard, video, mouse (KVM) unit to give administrators direct access to the host operating system and commands. In most cases, administrators use remote connect applications to log in to the host over their secure network and run commands.
Storage Arrays
The NPS host system may also include optional internal storage arrays, which you can use for such tasks as backups, load staging, or other user disk space. New 10000-series NPS HA systems contain the Storage Pad array, which offers 5TB of user disk space for each system. The Storage Pad XL option provides 10TB per rack (or 5TB for a half-rack configuration such as the 10050). The NPS model 5200 does not have a Storage Pad option.
NPS Software
The NPS appliance leverages a variety of software applications to perform its day-to-day system tasks as well as to allow users to run administration and data analysis tasks. For example, the NPS host uses the Red Hat Enterprise Linux (RHEL) operating system (described in more detail in Linux Host Operating System Requirements on page 1-4), and it also has software to manage the NPS hardware devices and components, such as firmware, flash, and other applications. These applications are preinstalled when you purchase an NPS system; when the system is installed onsite, Netezza engineers will help you to finalize the configuration and system settings to connect the system into your data center environment.
1-2
D20293-11
Rev.1
NPS Software
Periodically, Netezza issues patches to correct reported problems as well as to improve system performance. Netezza also issues new major and minor software releases to add new features and capabilities. When software updates and new releases are available, Netezza Support will work with you to plan upgrade paths as well as to install the patches and upgrades to your system.
D20293-11
Rev.1
1-3
obtain status for the system. Netezza also provides a Web Admin application that you can install on the NPS host. The Web Admin application allows administrators to access the NPS system using a Web browser to perform various management tasks. To use NzAdmin or the Web Admin applications, you must install the software located on one of the CDs labeled NPS Client CD (for either UNIX or Windows clients). Refer to the client installation instructions in the NPS System Administrators Guide for details. For business intelligence and data integration applications, the Netezza ODBC and/or JDBC driver, or OLE-DB provider, must be installed on the client systems to communicate with the NPS. For a description of the ODBC, JDBC, and OLE DB support and how to install and configure them, refer to the NPS ODBC, JDBC and OLE DB Installation and Configuration Guide.
Netezza provides kernel updates when security updates, patches, or other service packs become available for the operating system. Upgrade kits are also available to upgrade the Linux operating systems. Netezza Support will work with you to upgrade and maintain your NPS host operating systems. Netezza supports client connections from a variety of operating systems such as: HP-UX (11i); Red Hat Linux 7.3, RHEL version 2.1, 3.0, and 4.0; Windows 2000, 2003, XP, and Vista; AIX 5.1, 5.2, 5.3; and Solaris versions 2.7, 2.8, 2.9, or 2.10.
1-4
D20293-11
Rev.1
3. Shut down the Linux operating system using the following command: shutdown -h now The system displays a series of messages as it stops processes and other system activity. When it finishes, it displays the message power down which indicates that it is now safe to turn off the power to the system. 4. Press the power button on the NPS host (located in the front of the NPS cabinet) to power down the host system. 5. Switch off the power to the two PDU units (located in the rear of the NPS cabinet at the bottom) to completely power down the NPS rack. Make sure that you switch off power to both power switches.
D20293-11
Rev.1
1-5
3. Shut down the Linux operating system using the following command: shutdown -h now The system displays a series of messages as it stops processes and other system activity. When it finishes, it displays the message power down which indicates that it is now safe to turn off the power to the system. 4. Press the power button on the NPS host (located in the front of the NPS cabinet) to power down the host system. 5. In the back of the NPS rack, locate the Storage Pad array component and do the following: a. Press and hold the power button for storage processor A (SP A) for a few seconds until the power shuts off. (See Figure 1-1 for the location of the SP A and B power switches.) b. Press and hold the power button for storage processor B(SP B) for a few seconds until the power shuts off.
SP A Power Switch
c. Press the standby power supply (SPS) toggle switch on its left side (the O side) to turn the SPS off (see Figure 1-2).
1-6
D20293-11
Rev.1
SPS Switch Figure 1-2: Storage Pad Standby Power Supply (SPS) Switch 6. Switch off the power to the two PDU units (located in the rear of the NPS cabinet at the bottom) to completely power down the NPS rack. Make sure that you switch off power to both power switches.
3. Log in to host 2 as root, then shut down the Linux operating system using the following command: shutdown -h now The system displays a series of messages as it stops processes and other system activity. When it finishes, it displays the message power down which indicates that it is now safe to turn off the power to the system. 4. Press the power button on host 2 (located in the front of the NPS cabinet) to power down that host. 5. Log in to host 1 as root, then shut down the Linux operating system using the following command: shutdown -h now The system displays a series of messages as it stops processes and other system activity. When it finishes, it displays the message power down which indicates that it is now safe to turn off the power to the system. 6. Press the power button on host 1 (located in the front of the NPS cabinet) to power down the host. 7. Press the power button on the MSA500G2 (located on the bottom right corner of MSA500G2) to power down the device. 8. Switch off the power to the two PDU units (located in the rear of the NPS cabinet at the bottom) to completely power down the NPS rack. Make sure that you switch off power to both power switches, and repeat this step on each rack of your HA system.
D20293-11
Rev.1
1-7
Powering Down an HA NPS System with One or More Storage Pad Arrays
To power down a high-availability (HA) NPS system which has one or more Storage Pad arrays: 1. Log on as root to host 1 using the following command:
su -
3. Log in to host 2 as root, then shut down the Linux operating system using the following command: shutdown -h now The system displays a series of messages as it stops processes and other system activity. When it finishes, it displays the message power down which indicates that it is now safe to turn off the power to the system. 4. Press the power button on host 2 (located in the front of the NPS cabinet) to power down that NPS host. 5. Log in to host 1 as root, then shut down the Linux operating system using the following command: shutdown -h now The system displays a series of messages as it stops processes and other system activity. When it finishes, it displays the message power down which indicates that it is now safe to turn off the power to the system. 6. Press the power button on host 1 (located in the front of the NPS cabinet) to power down the NPS host. 7. In the back of each NPS rack that has a Storage Pad array (usually host 1 for an SL-series system or in each rack for an XL-series system), locate the Storage Pad array component and do the following steps: a. Press and hold the power button for storage processor A (SP A) for a few seconds until the power shuts off. (See Figure 1-1 on page 1-6 for the location of the SP A and B power switches.) b. Press and hold the power button for storage processor B (SP B) for a few seconds until the power shuts off. c. Press the standby power supply (SPS) toggle switch on its left side (the O side) to turn the SPS off. (See Figure 1-2 on page 1-7 for a description of the location of the switch.) d. If you have a 10000XL-series system, repeat these steps to power down each Storage Pad array; there is one in each rack of the NPS system. 8. Switch off the power to the two PDU units (located in the rear of the NPS cabinet at the bottom) to completely power down the NPS rack. Make sure that you switch off power to both power switches, and repeat this step on each rack of your HA system.
1-8
D20293-11
Rev.1
5. Shut down the Linux operating system using the following command: shutdown -h now The system displays a series of messages as it stops processes and other system activity. When it finishes, it displays the message power down which indicates that it is now safe to turn off the power to the system. 6. Press the power button on the NPS host (located in the front of the NPS cabinet) to power down the host system. 7. Disconnect the two power cables that lead from the auto-transfer switch to the main power to completely power down the system. To power down a 5200-OA system: 1. Shut down the NPS system: a. Log on as nz to the NPS system. b. Enter the following command: nzstate c. If the system state is Stopped, continue with step 2.
D20293-11
Rev.1
1-9
d. If the system state is Online, enter the following command: nzstop 2. Log out of nz, then log on as root using the following command:
su -
3. Shut down the Linux operating system using the following command: shutdown -h now The system displays a series of messages as it stops processes and other system activity. When it finishes, it displays the message power down which indicates that it is now safe to turn off the power to the system. 4. Press the power button on the NPS host (located in the front of the NPS cabinet) to power down the host system. 5. Switch off the power to the UPS located in the bottom of the rack to power down the UPS. 6. Disconnect the power cable that leads from the isolation transformer to the main power to completely power down the system. To power down a 5200-DC system: 1. Shut down the NPS system: a. Log on as nz to the NPS system. b. Enter the following command: nzstate c. If the system state is Stopped, continue with step 2. d. If the system state is Online, enter the following command: nzstop 2. Log out of nz and log on as root. 3. Shut down the Linux operating system using the following command: shutdown -h now The system displays a series of messages as it stops processes and other system activity. When it finishes, it displays the message power down which indicates that it is now safe to turn off the power to the system. 4. Press the power button on the NPS host (located in the front of the NPS cabinet) to power down the host system. 5. Disconnect the two power cables that lead from the auto-transfer switch to the main power to completely power down the system.
1-10
D20293-11
Rev.1
SPS Switch Figure 1-3: Storage Pad Standby Power Supply (SPS) Switch
D20293-11
Rev.1
1-11
b. Press the power button for storage processor A (SP A) to power the device (see Figure 1-4). Note that SP B automatically powers up after you power up SP A. Note that SP A may not power up right away if the SPS battery is not charged. Wait a few minutes to allow the battery to charge and then power up SP A again.
SP A Power Switch
Note: Wait five minutes for the Storage Pad array to initialize before proceeding to step 3 to power the host. 3. Press the power button on the NPS host (located in the front of the NPS cabinet) to power up the host system. A series of messages appears as the NPS host system boots. 4. After the host has started, log in as nz to the NPS system. 5. Confirm that the NPS system is online using the following command: nzstate
1-12
D20293-11
Rev.1
4. Wait at least 30 seconds after powering up host 1, then press the power button on host 2 (located in the front of the NPS cabinet) to power up that host. The delay ensures that host 1 completes its start-up operations first, and thus is the primary host for the HA system. 5. After both hosts have completed the power-up sequence, log in to host 1 as root and run the following command to verify that the cluster services have started:
clustat -i 3
Note: When the cluster manager starts and is ready, status appears as follows. (This could take about one minute.)
Member ha1 ha2 Status up up Node ID 0 0 Power Switch good good
7. Verify that the NPS system is online using the following command: nzstate
D20293-11
Rev.1
1-13
4. Wait at least 30 seconds after powering up host 1, then press the power button on host 2 (located in the front of the NPS cabinet) to power up that host. The delay ensures that host 1 completes its start-up operations first, and thus is the primary host for the HA system. 5. After both hosts have completed the power-up sequence, log in to host 1 as root and run the following command to verify that the cluster services have started:
/usr/sbin/crm_mon -i3
The output of the command refreshes at the specified interval rate of 3 seconds (-i3). Review the output and watch for the resource groups to all have a Started status. This usually takes about 2 to 3 minutes, then proceed to step 6. Sample output follows:
============ Last updated: Mon Oct 6 12:48:09 2008 Current DC: nps50230 (6ea6cffe-3b61-4d29-ac92-5f36ea5f4033) 2 Nodes configured. 3 Resources configured. ============ Node: nps50224 (e00c23e5-1b17-4281-8a2d-403f27129e10): online Node: nps50230 (6ea6cffe-3b61-4d29-ac92-5f36ea5f4033): online Resource Group: nps drbd_exphome_device (heartbeat:drbddisk): Started nps50230 drbd_nz_device (heartbeat:drbddisk): Started nps50230 exphome_filesystem (heartbeat::ocf:Filesystem): Started nps50230 nz_filesystem (heartbeat::ocf:Filesystem): Started nps50230 fabric_ip (heartbeat::ocf:IPaddr): Started nps50230 wall_ip (heartbeat::ocf:IPaddr): Started nps50230 nzbootpd (lsb:nzbootpd): Started nps50230 snmptrapd (lsb:snmptrapd): Started nps50230 storagepadinit (lsb:storagepadinit): Started nps50230 nzinit (lsb:nzinit): Started nps50230 fencing_route_to_ha1 (stonith:apcmaster): Started nps50230 fencing_route_to_ha2 (stonith:apcmaster): Started nps50224
Press Control-C to exit the crm_mon command and return to the command prompt. 6. Log on to host 1 as the nz account using the following command:
su - nz
7. Verify that the NPS system is online using the following command: nzstate
1-14
D20293-11
Rev.1
To power up a 5200-BSA system: 1. Confirm that the two power cables that lead from the main power are connected to the auto-transfer switch. 2. Press the power button on the NPS host (located in the front of the NPS cabinet) to power up the host system. A series of messages appears as the NPS host system boots. 3. After the host has started, log in as nz to the NPS system. 4. Start the NPS system using the following command: nzstart 5. Press the power button on the front of the second host (the DL145G3 or the x3550 host) to power up the application server. 6. After the host starts, log in to the second host and follow the procedures to start your business intelligence applications using their standard start-up procedures. To power up a 5200-OA system: 1. Confirm that the power cable that leads from the main power is connected to the isolation transformer. 2. Switch on the power to the UPS located in either the front or the back of the rack at the bottom to power up the UPS. 3. Press the power button on the NPS host (located in the front of the NPS cabinet) to power up the host system. A series of messages appears as the NPS host system boots. 4. After the host has started, log in as nz to the NPS system. 5. Start the NPS system using the following command: nzstart To power up a 5200-DC system: 1. Confirm that the two power cables that lead from the main power are connected to the auto-transfer switch. 2. Press the power button on the NPS host (located in the front of the NPS cabinet) to power up the host system. A series of messages appears as the NPS host system boots. 3. After the host has started, log in as nz to the NPS system. 4. Start the NPS system using the following command: nzstart
D20293-11
Rev.1
1-15
The LEDs indicate activity such as hard disk, LAN, or database activity; when the top or bottom LEDs are amber, they indicate a potential problem situation on the SPU such as a hardware fault or SPU firmware issue. Table 1-2 describes the LEDs. To manage SPUs using the nzspu command or the NzAdmin interface, see the NPS System Administrators Guide. Table 1-2: Rev 7 SPU LED Description LED Top Color Green Amber Middle Green Amber Bottom Green Amber Indication Database activity (such as a query in progress) Auxiliary 1 (indicates a hardware fault or SPU firmware issue) Not used (physical LAN0 activity) Physical LAN 1 link activity Hard disk activity (such as reads or writes, loads, and so on) Auxiliary 0 (indicates a hardware fault or SPU firmware issue)
root
netezza
As the admin database user, you can create other database users and groups to grant and manage access to the objects (such as databases, tables, views, and so on) and administration tasks (such as creating or dropping tables, deleting rows, and creating users). Groups allow you to organize users that have related roles or functions. Groups make it easier to assign the same permissions to all the users by changing the permissions on the group,
1-16
D20293-11
Rev.1
rather than changing each user account. When you assign or revoke permissions to the group, all the users in the group have that change in permission. For details about user and group management, refer to the NPS System Administrators Guide. Note: There is also a default database group called public. All users are automatically assigned as members of the public group. You cannot delete the public group, or remove users from it. This group allows you to grant all users the same privilege in one step.
Table 1-4: Netezza Common Tasks Category Loading data Description Load data Command/Tool nzload
CREATE EXTERNAL TABLE
nzload
CREATE EXTERNAL TABLE
Refer to Chapter 12, Backing Up and Restoring Databases. Refer to Chapter 10, Creating and Maintaining Databases with the CLI. Refer to Chapter 11, Creating and Maintaining Databases with the NzAdmin tool. Refer to Chapter 10, Creating and Maintaining Databases with the CLI.
View session
D20293-11
Rev.1
1-17
Table 1-4: Netezza Common Tasks (continued) Category Queries Description Display query table Command/Tool nzstats Where to Find More Information Refer to Chapter 14, Displaying NPS Statistics. Refer to Chapter 6, Managing the NPS with the NzAdmin Tool. Refer to Chapter 10, Creating and Maintaining Databases with the CLI. Refer to Chapter 14, Displaying NPS Statistics. Refer to Chapter 6, Managing the NPS with the NzAdmin Tool. Refer to Chapter 10, Creating and Maintaining Databases with the CLI. Refer to Chapter 11, Creating and Maintaining Databases with the NzAdmin tool. Refer to Chapter 11, Creating and Maintaining Databases with the NzAdmin tool. Refer to the NPS Database Users Guide, Appendix B. Refer to Chapter 8, Establishing Security and Access Control.
_v_qrystat view
nzstats
_v_qryhist view
Data Distribution
Privileges
Create user
CREATE USER
[Create] User
1-18
D20293-11
Rev.1
Table 1-4: Netezza Common Tasks (continued) Category Privileges (continued) Description Create group Command/Tool NzAdmin or Web Admin tool Where to Find More Information Refer to Chapter 11, Creating and Maintaining Databases with the NzAdmin tool. Refer to the NPS Database Users Guide, Appendix B. Refer to Chapter 8, Establishing Security and Access Control. Refer to Chapter 11, Creating and Maintaining Databases with the NzAdmin tool. Refer to the NPS Database Users Guide, Appendix B. Refer to Chapter 11, Creating and Maintaining Databases with the NzAdmin tool. Refer to the NPS Database Users Guide, Appendix B. Refer to Chapter 11, Creating and Maintaining Databases with the NzAdmin tool. Refer to the NPS Database Users Guide, Appendix B.
CREATE GROUP
[Create] Group
Grant rights
GRANT
Revoke access
REVOKE
Alter access
D20293-11
Rev.1
1-19
Table 1-4: Netezza Common Tasks (continued) Category Monitoring Description Show system state Command/Tool nzstate show Where to Find More Information Refer to Chapter 4, Managing the NPS with the CLI. Refer to Chapter 4, Managing the NPS with the CLI. Refer to Chapter 14, Displaying NPS Statistics. Refer to Chapter 4, Managing the NPS with the CLI. Refer to Chapter 4, Managing the NPS with the CLI. Refer to Chapter 6 or Chapter 7.
View statistics
Notification when the system changes states, a hardware component failed, or when the disk is more than 80 percent full Tables Create a table
NzAdmin tool
Refer to Chapter 10, Creating and Maintaining Databases with the NzAdmin Tool. Refer to the NPS Database Users Guide, Appendix B. Refer to Chapter 11, Creating and Maintaining Databases with the NzAdmin Tool. Refer to the NPS Database Users Guide, Appendix B.
CREATE TABLE
1-20
D20293-11
Rev.1
Running the CLI Commands from a Host, Linux Client, and Windows Client
Table 1-5 lists the NPS commands and the locations where they can be found on the NPS host and on client systems. You can run all of the nz* commands from the NPS host, but certain commands are not available on clients. In the table, a checkmark indicates that the command can be run from that location, while a dash indicates that the command is not available from that location Table 1-5: CLI Command Locations Default Location Platform nzbackup nzhostbackup nzhostrestore nzrestore nzstart nzstop nzcontents nzconvert nzevent nzinventory nzload nzpassword nzreclaim nzrev nzsession nzsfi nzspu nzsql nzstate /nz/kit/bin NPS Server Linux Host Client /usr/local/nz/bin Solaris Client HPUX Client AIX Client C:\Program Files\Netezza\Bin Windows Client
D20293-11
Rev.1
1-21
Table 1-5: CLI Command Locations (continued) Default Location Platform nzstats nzsystem /nz/kit/bin NPS Server Linux Host Client /usr/local/nz/bin Solaris Client HPUX Client AIX Client C:\Program Files\Netezza\Bin Windows Client
-maxErrors <n>
tables when working with the -maxErrors option. It is normal to see a reference to external tables in a related error message. -delim <char> Specifies the separator between successive input fields. (The default is \t.)
1-22
D20293-11
Rev.1
Table 1-7: Commonly Used nzload Command Options (continued) Options -escapeChar <char> Description Specifies an escape character in char or varchar fields. You can specify the escapeChar option to permit any character preceded with a backslash (\) to be interpreted as an escape character. In this way, you could use the zero (byte 0), line feed (byte 10), carriage return (byte 13), or the closing delimiter. Allows an ASCII value 1-31 in char() and varchar() fields. (You must escape NUL, CR, and LF.) Allows unescaped carriage returns (CR) in char and varchar fields. (LF becomes only end of row.) Specifies how to interpret the date format. Styles include Y[2]MD, DMY[2], MDY[2], and MONDY[2]. The default is YMD. Specifies the delimiter (date component separator) to use with the dateStyle option. The default dateDelim option is a dash (-). The -dateDelim value cannot be the same as the -timeDelim value. Specifies the 24 hour or 12 hour time format, such as 24HOUR or 12HOUR. The default is 24HOUR. Specifies the delimiter to use for time formats. The default is a colon (:).
-ctrlChars
-dateDelim <char>
timeStyle <style>
-timeDelim <char>
Table 1-8 lists nzload log files. For more information about the log files and how to use them, refer to the NPS System Administrators Guide. Table 1-8: Log files for nzload File format <table>.<database>.nzlog Description Includes summary report and information about any bad records encountered. (The system appends to the nzlog file each time you load the same table into the same database.) Includes the bad records in their original state. (The system overwrites the nzbad file each time you load the same table into the same database.)
<table>.<database>.nzbad
D20293-11
Rev.1
1-23
SQL Commands
Table 1-9 lists some of the Netezza SQL commands. For more information on particular commands, refer to the NPS Database Users Guide. Table 1-9: Netezza SQL Commands List of SQL Commands ALTER AGGREGATE ALTER DATABASE ALTER FUNCTION ALTER GROUP ALTER SEQUENCE ALTER SESSION ALTER SYNONYM ALTER TABLE ALTER USER ALTER VIEW BEGIN COMMENT COMMIT COPY CREATE AGGREGATE CREATE DATABASE CREATE EXTERNAL TABLE CREATE FUNCTION CREATE GROUP CREATE MATERIALIZED VIEW CREATE OR REPLACE VIEW CREATE SEQUENCE CREATE SYNONYM CREATE TABLE CREATE TABLE AS CREATE USER CREATE VIEW DELETE DROP AGGREGATE DROP DATABASE DROP FUNCTION DROP GROUP DROP SEQUENCE DROP SYNONYM DROP TABLE DROP USER DROP VIEW EXPLAIN EXTRACT GENERATE EXPRESS STATISTICS GENERATE STATISTICS GRANT INSERT RESET REVOKE ROLLBACK SELECT SET SET SESSION SET SYSTEM DEFAULT SET TRANSACTION SHOW SHOW SYSTEM DEFAULT TRUNCATE UPDATE
1-24
D20293-11
Rev.1
Identifiers are case sensitive, but they are treated as uppercase (system default) unless you enclose them in double quotes. Rather than returning an unknown quantity of records, first get a sense as to the size of your result set. Limit the number of records that your application returns. Parse the query, but do not actually run it.
SELECT COUNT AS
D20293-11
Rev.1
1-25
Table 1-11: Commonly Used Internal Slash Options (continued) Command \dSv \d view \echo text \! cmd Description Lists all system views. Describes a view. Writes <text> to stdout. Shell escape or command. (Runs a shell command without leaving the nzsql session.)
Query
Query Response
1-26
D20293-11
Rev.1
D20293-11
Rev.1
1-27
Getting Help
This section describes how to find the Netezza customer user guides and documentation, how to use online help, and how to contact Netezza Support when you have questions or a possible problem.
PDF Documentation
Netezza includes user guides in Adobe PDF format on the NPS Documentation CD. Updated guides are also available on the Netezza FTP site (ntzftp.netezza.com) in the Documentation area. Table 1-14 lists several of the commonly used manuals. Table 1-14: Key User Manuals File Netezza_database_users_guide.pdf Description NPS Database Users Guide describes the Netezza SQL language used for queries to databases on the NPS systems. NPS System Administrators Guide is written for system and database administrators. It describes how to manage the NPS systems and database. Netezza Performance Server Release Notes includes a list of new features and enhancements, known issues, and customer-reported issues that have been fixed in the release. Netezza Performance Server Getting Started Tips (this guide) describes background information and tips for using the NPS system. NPS ODBC, JDBC and OLE DB Installation and Configuration Guide provides information for those who want to install and configure ODBC clients, JDBC clients, or the OLE DB connector to communicate with the NPS.
Netezza_system_admin_guide.pdf
Netezza_release_notes.pdf
Netezza_getting_started_tips.pdf
Netezza_odbc_jdbc_guide.pdf
Note: As of NPS Release 3.0, the user guides are not installed by default to the /nz/kit/doc directory on the NPS host; however, the NPS Software Upgrade Guide describes how to manually copy the PDF files to that location or to any network location if you want to make the guides available across your network to your users.
1-28
D20293-11
Rev.1
Getting Help
Online Help
Netezza documentation includes online help for the administration UIs and commands.
To view context-sensitive help, click the question mark on any page. A sample contextsensitive help screen follows:
D20293-11
Rev.1
1-29
1-30
D20293-11
Rev.1
Getting Help
Netezza CLI commands often include subcommands. In the preceding example of the nzsystem command, the subcommands are listed in a distinct section. You can view help for Netezza CLI subcommands by entering the name of the CLI command, followed by -hc, followed by the name of the subcommand. Sample subcommand online help follows:
> nzsystem -hc stop Usage: nzsystem stop [<subcmd options>] Subcmd Options: -host <name/IP> -timeout <secs> -u <user name> -pw <password> -pw <password> -now -nowAfter <secs> -force host name or IP address [NZ_HOST] time to wait before exiting with a timeout error (default = 300) login using <user name> [NZ_USER] authentication password [NZ_PASSWORD] authentication password [NZ_PASSWORD] do not wait for current work to finish time for work to finish before resorting to '-now' (default = 300) do not prompt for confirmation
D20293-11
Rev.1
1-31
1-32
D20293-11
Rev.1