Search Results

Search: Posts Made By: reddyr
3,216
Posted By reddyr
Yep, I tried -n after posting here and it worked....
Yep, I tried -n after posting here and it worked.

Thanks again for all the help & guidance!
3,216
Posted By reddyr
Thanks neutronscott for the solution &...
Thanks neutronscott for the solution & explanation :b: It worked.

As read exists 2 times it displays alternate lines & remaining lines were inputted as "press any keys". It's clear now :)

On a...
3,216
Posted By reddyr
Problem with while loop reading every line of a text file
Hello,

I'm using RHEL 5.1 with bash. How to handle "read" inside while loop reading every line? Please see below:

# cat /tmp/passwd_sample
CARRJ12:qVSn4ja4mFA72,..:20021:125:JULIAN...
1,597
Posted By reddyr
How to rename multiple files at one go?
Hi,

I have hundreds of files with XXX in their file name and I want to rename all of them with YYY in place of XXX.

for ex:
$ ls -1
123XXX789
345XXX678


Output
$ ls -1
123YYY789...
15,335
Posted By reddyr
How to view the control characters in a file?
Hello,

How can I view control and special characters of a text file?. For example, space, tabs, new line chars etc.

Can I use hexdump for it?

Thanks
2,027
Posted By reddyr
Thanks, that worked.
Thanks, that worked.
2,027
Posted By reddyr
Apologies... Though the values same but there're...
Apologies... Though the values same but there're spaces in 2nd row which I failed to notice because I opened in excel.

,,Price,Price,Price,Price,Price,Price,Price,Price,Price,Qty
Date,Time,%AAA, ...
2,027
Posted By reddyr
Thank you SriniShoo, As Don Cragun correctly...
Thank you SriniShoo,

As Don Cragun correctly pointed out, unfortunately few CSVs contain % in those fields and the solution did not work. It works fine for the CSVs without special characters in...
2,027
Posted By reddyr
Conditional replacement in CSV files
Hello,

I have many CSV files with variable number of rows and columns.

Sample of few problematic CSV files.
,,Price,Price,Price,Price,Price,Price,Price,Price,Price,Qty...
Forum: AIX 07-31-2014
2,969
Posted By reddyr
Ssh problem on AIX 5.3
Hello,
I have a weird ssh problem from host A to host B. Both hosts A and B running AIX 5.3.

if host-A has no ~/.ssh/id_rsa.pub & ~/.ssh/id_rsa then it works fine. If I connect from host-A to...
2,746
Posted By reddyr
Thanks all and there're too many solutions. ...
Thanks all and there're too many solutions.

Sorry for the confusion, Let me clarify again -

1. I need to copy a directory to another location
2. Must keep the same hierarchy and structure...
2,746
Posted By reddyr
Thanks bakunin and RudiC for your replies. ...
Thanks bakunin and RudiC for your replies.

Your solutions are correct as per the requirement i mentioned in my post. My bad, I missed to mention that the directory has sub-directories (and further...
2,746
Posted By reddyr
How to copy a directory without specific files?
Hi

I need to copy a huge directory with thousands of files onto another directory but without *.WMV files (and without *.wmv - perhaps we need to use *.[wW][mM][vV]).

Pls advise how can I do...
1,733
Posted By reddyr
How to grep and print the next and previous N lines after the hit
Hello,

I know that gnu grep has option of -A and -B to extra previous and next lines.

But I'm using HP UX and its grep does not support these options.

BID="0/0/6/1/1.145.17.255.0.0.0"

I...
1,025
Posted By reddyr
Thanks Chubler_XL and RudiC It is NOT...
Thanks Chubler_XL and RudiC

It is NOT coincidence but the order of appearance (as shown in my sample output).

Chubler_XL's all 3 solutions worked for me. I'm using standard awk of HP UX. I...
1,025
Posted By reddyr
Brilliant, worked great. Thanks a million.
Brilliant, worked great. Thanks a million.
1,025
Posted By reddyr
How to match in 2 files and generate 3rd file?
Hello,

I have 2 tables (first file with colon separated, second file comma separated) like below:

Please note that the matching number (kind of primary key) is a number and is NOT unique. It is...
Forum: AIX 07-07-2014
2,134
Posted By reddyr
Thanks MadeInGermany and zaxxon for the replies. ...
Thanks MadeInGermany and zaxxon for the replies.

@zaxxon - Initially i considered nmon but It didn't provide me all I needed and also we needed output in a specific CSV format only (even though...
Forum: AIX 07-07-2014
2,134
Posted By reddyr
Performance stats from AIX 6
Hi,
I'm supposed to capture many performance stats on AIX 6 and stuck up with below:

Priority queue
Disk cache hit%
Page out rate
Swap out rate
Memory queue

I see vmstatis helpful for...
1,793
Posted By reddyr
Thanks Yoda and Scrutinizer. @Yoda - Sorry...
Thanks Yoda and Scrutinizer.

@Yoda - Sorry your solution NOT working. It just prints System Information

# awk -v S="System Information" '
{
if ( $0 !~ /^ / )
...
1,793
Posted By reddyr
How to extract entire para instead of just line?
Hello,

I have a file with multiple paragraphs/sections each starting with word "Handle" and if I grep for a pattern, I should get contents of entire section/para (not just line). Please advise,...
1,508
Posted By reddyr
Thanks RudiC and Don Cragun. @Don Cragun -...
Thanks RudiC and Don Cragun.

@Don Cragun - You are right. RudiC's solution did not work. I'm running on AIX 6 ksh.

Your solution worked great. In your solution, the one within () would remain...
1,508
Posted By reddyr
Change the seconds value in date column
Hello,

I have a file with below contents and need to set seconds value to 00 (as you can see few time stamps are with 01 seconds)
18:16:00 8192 7301 89 11
18:21:00 8192 ...
1,006
Posted By reddyr
Need to pick max values of the columns
Hi,

I have sar disk reports like below sample:

01:01:00 hdisk24 0 0.0 0 0 0.0 0.0
hdisk15 0 0.0 0 3 0.0 5.5
...
2,995
Posted By reddyr
Multiple double quotes
hi

Need to run below command on remote server:

cmd -a "1 2" -b 3

If i run below, there's clash matching double quotes and fail.

ssh $server "cmd -a "1 2" -b 3"

I have few ideas which...
Showing results 1 to 25 of 40

 
All times are GMT -4. The time now is 01:58 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy