In this post you will learn about some commonly day to day Netezza basic commands. There are lot of Netezza basic commands available along with Netezza commonly used utilities that are used but here are listed some commonly used commands.
Read:
nzrev Command
Check the Netezza build version
[nz@netezza01 ~]$ nzrev Release 7.2.1.0 [Build 46322] [nz@netezza01 ~]$
nzstats Command
Provide the statistics about the Netezza appliance
[nz@netezza01 ~]$ nzstats Field Name Value -------------------- -------------------------------------------- Name netezza 01 Description <sys description> Contact <contact name> Location <sys location> IP Addr 127.0.0.1 Up Time 34640 secs Up Time Text 9 hrs, 37 mins, 20 secs Date 21-Oct-16, 00:53:47 EDT State 8 State Text Online Model IBM Netezza 100-1 Serial Num <serial #> Num SFIs 0 Num SPAs 1 Num SPUs 1 Num Data Slices 8 Num Hardware Issues 0 Num Dataslice Issues 0 [nz@netezza01 ~]$
nzhw Command
You can verify the Netezza hardware and check the issues if any
[nz@netezza01 ~]$ nzhw Description HW ID Location Role State Security ----------- ----- ---------- ------ ------ -------- Rack 1001 rack1 Active Ok N/A SPA 1002 spa1 Active Ok N/A SPU 1003 spa1.spu1 Active Online N/A Disk 1004 spa1.disk1 Active Ok Disabled Disk 1005 spa1.disk2 Active Ok Disabled Disk 1006 spa1.disk3 Active Ok Disabled [nz@netezza01 ~]$
nzstate Command
You can verify the status of the Netezza system with help of this command
[nz@netezza01 ~]$ nzstate System state is 'Online'
nzsql Command
nzsql is Netezza command line interface. You can use those command to connect to Netezza data warehouse system.
Read: nzsql command and its usage
[nz@netezza01 ~]$ nzsql -u username -pw password -db training Welcome to nzsql, the IBM Netezza SQL interactive terminal. Type: \h for help with SQL commands \? for help on internal slash commands \g or terminate with semicolon to execute query \q to quit TRAINING.ADMIN(ADMIN)=>
nzload Command
This command is used to get data into the Netezza data warehouse system.
[nz@netezza01 ~]$ nzload -h Usage: nzload [-h|-rev] [<options>]
nzsession Command
This command is used to maage the Netezza sessions.
[nz@netezza ~]$ nzsession
ID Type User Start Time PID Database Schema State Priority Name Client IP Client PID Command
—– —- —– ———————– —– ——– —— —— ————- ——— ———- ————————
16634 sql ADMIN 21-Oct-16, 01:03:48 EDT 16113 SYSTEM ADMIN active normal 127.0.0.1 16112 SELECT session_id, clien
nzpassword Command
Encrypt the password with help of nzpassword command.
nzbackup and nzrestore Commands
With help of these command you can backup your Netezza data warehouse and restore whenever you want it back.
groom table command
You can use this command to reclaim the Netezza space.
- Read: Netezza Groom Command
TRAINING.ADMIN(ADMIN)=> groom table STUDENTS; NOTICE: Groom will not purge records deleted by transactions that started after 2016-10-21 01:22:05. NOTICE: Groom processed 2 pages; purged 0 records; scan size unchanged; table size unchanged. GROOM RECORDS ALL TRAINING.ADMIN(ADMIN)=>