Sponsored Content
Full Discussion: awk command issue
Top Forums Shell Programming and Scripting awk command issue Post 302841801 by Klashxx on Thursday 8th of August 2013 03:37:53 AM
Old 08-08-2013
Try:
Code:
awk '1' RS=':'  infile

 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

command line arg issue with awk

Hi friends, I am trying to pass input from command line and trying to print that column values. (FYI: I am using ksh) My code goes like this... #!/bin/sh column=$1 awk '{print $'$column'}' I execute using command like this --> ls -l | file_name parameter Hope I am clear with my... (2 Replies)
Discussion started by: divzz
2 Replies

2. Shell Programming and Scripting

awk command in script gives error while same awk command at prompt runs fine: Why?

Hello all, Here is what my bash script does: sums number columns, saves the tot in new column, outputs if tot >= threshold val: > cat getnon0file.sh #!/bin/bash this="getnon0file.sh" USAGE=$this" InFile="xyz.38" Min="0.05" # awk '{sum=0; for(n=2; n<=NF; n++){sum+=$n};... (4 Replies)
Discussion started by: catalys
4 Replies

3. Shell Programming and Scripting

awk command issue

Hi, Please could someone advise the issue i have with my awk command ? my command is : export NUM_SCENARIOS=`awk -F= '!/^#/ && /NUM_SCENARIOS/{print $2}' /home/environment.properties` when I echo $NUM_SCENARIOS this comes back with : 100 10 The issue I have is, there is... (9 Replies)
Discussion started by: venhart
9 Replies

4. Shell Programming and Scripting

awk NR issue

Hi guys, i am trying to analyze a text file using awk and am not able to solve this issue. This is the piece of code that I have written BEGIN { ## Time to count MACs -> 5 seconds. TIME_LIMIT = 5; k = 50000; } ## For every line. { time_in_seconds = $1... (2 Replies)
Discussion started by: jamie_123
2 Replies

5. Shell Programming and Scripting

awk issue

Hi all, i am trying to use below command to see the output of hardware inventory, but i only see 2 first line no output of the command. awk '/Hardware/ {print $0}' XXX_result.txt Hardware inventory: Hardware inventory: any idea how to see whatever is under hardware inventory. i... (11 Replies)
Discussion started by: Jared
11 Replies

6. Shell Programming and Scripting

Variable value substitution issue with awk command issue

Hi All, I am using the below script which has awk command, but it is not returing the expected result. can some pls help me to correct the command. The below script sample.ksh should give the result if the value of last 4 digits in the variable NM matches with the variable value DAT. The... (7 Replies)
Discussion started by: G.K.K
7 Replies

7. Shell Programming and Scripting

For loop, awk command issue

limit.csv data -------------- 5600050 38Nhava 400077 27Bomay rate.txt data ------------- 38NhaVA 27BomaY 27Bomay below is my script: for i in `cat limit.csv` do b=`awk '{print $1}' $i` (4 Replies)
Discussion started by: p_satyambabu
4 Replies

8. UNIX for Beginners Questions & Answers

awk command issue

Hi All, I am trying to perform certain task using awk command but the command is not returning expected output though it is running fine independently but not in for loop. req: 1. I am searching a pattern (say pattern1) in a dated file 2. trying to search the last occurrence of the another... (11 Replies)
Discussion started by: abhii
11 Replies

9. Shell Programming and Scripting

Issue with awk command between Linux and Solaris

Hi, Here is the output using bash profile on Linux uptime 04:59:14 up 16 days, 4:48, 2 users, load average: 1.00, 1.00, 1.20 Here is the output using bash profile on Solaris uptime 4:00am up 84 day(s), 22:21, 3 users, load average: 0.09, 0.10, 0.12 Now,... (4 Replies)
Discussion started by: mohtashims
4 Replies

10. UNIX for Beginners Questions & Answers

Issue with awk command

I am new to unix.I have a requirement to get few fields from the log file as below. Log app9/cc-gr_base.log.2017-07-19.gz: hostname 1500523166993 NA:NA:NA http-nio-8080-exec-56 INFO Points balance from MIS for user with userId: 19651069, first name: DEREK RICHARD and last name: BOUDREAU is... (3 Replies)
Discussion started by: nextStep
3 Replies
MAKE_SOCKDFR(8) 					      System Manager's Manual						   MAKE_SOCKDFR(8)

NAME
make_sockdfr - Generates frozen route file for SOCKS server SYNOPSIS
make_sockdfr [infile [outfile] ] DESCRIPTION
make_sockdfr reads in a plain-text route file for the SOCKS server and produces a frozen route file as the output. Both arguments are optional. The default for infile is /etc/sockd.route; the default for outfile is /etc/sockd.fr. You may specify infile while omitting outfile, but you cannot specify outfile without also speficying infile. The contents of the frozen route file is essentially the memory image of the parsed input file. Using the frozen route file can reduce the start-up delay of the SOCKS server program since it no longer has to parse the file contents. When the SOCKS server starts, it always looks for the frozen route file /etc/sockd.fr first. If that file is not found, it then tries to use the plain-text route file /etc/sockd.route. If you use frozen route file, you must remember to run make_sockdfr every time after you modify the plain-text file or the SOCKS server will continue to use the frozen version of a previous route file. To find out the contents of a frozen route file, use dump_sockdfr. FILES
/etc/sockd.fr, /etc/sockd.route SEE ALSO
dump_sockdfr(8), sockd.fr(5), sockd.route(5) AUTHOR
Ying-Da Lee, yingda@esd.sgi.com or yingda@best.com May 6, 1996 MAKE_SOCKDFR(8)
All times are GMT -4. The time now is 09:49 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy