Unix/Linux Go Back    


Shell Programming and Scripting Unix shell scripting - KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and shell scripts and shell scripting languages here.

nawk command

Shell Programming and Scripting


Closed Linux or Unix Question    
 
Thread Tools Search this Thread Display Modes
    #1  
Old Unix and Linux 05-18-2009
djehres djehres is offline
Registered User
 
Join Date: Sep 2007
Last Activity: 18 April 2012, 10:46 AM EDT
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
nawk command

what is this nawk doing?

This is for solaris 10 with trusted extensions.

Level=$(plabel | nawk 'BEGIN {FS='[\\]\[]*"} {PRINT $2}' )

it is supposed to return UNCLASSIFIED or whatever the zone label is.

I understant $() execute this stuff, FS is field separator, print the 2nd field.

Can somebody explain to me what it does and maybe a way to make it easier?


thanks.
Sponsored Links
    #2  
Old Unix and Linux 05-19-2009
devtakh devtakh is offline Forum Advisor  
Unix Enthusiatic
 
Join Date: Oct 2007
Last Activity: 21 August 2013, 5:20 AM EDT
Location: Bangalore
Posts: 738
Thanks: 0
Thanked 7 Times in 7 Posts
Looks like the field seperator is \][
and zero or many of them.

How does ur inp file look like?
Sponsored Links
Closed Linux or Unix Question

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Linux More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
using cp command inside nawk piscean_n Shell Programming and Scripting 1 04-08-2009 08:31 AM
case command inside awk/nawk abdulaziz Shell Programming and Scripting 9 03-09-2009 09:15 PM
if within nawk command kshelluser UNIX for Dummies Questions & Answers 1 11-30-2006 06:02 AM
nawk command not found 12yearold Shell Programming and Scripting 5 07-07-2006 02:40 PM
nawk command clarification Tux_Raju Shell Programming and Scripting 2 07-28-2005 09:28 AM



All times are GMT -4. The time now is 12:30 AM.