Search Results

Search: Posts Made By: k_manimuthu
20,296
Posted By k_manimuthu
Yes, i need to save the file content as well exit...
Yes, i need to save the file content as well exit from current vi screen.



Considered the below sample codes did same as the real environment.
In real script i didn't have permission to...
20,296
Posted By k_manimuthu
Thanks nezabudka. Actually a primary script open...
Thanks nezabudka. Actually a primary script open a text file from vi command. But end user need close the file manually, than only the primary script resumes execute the next flows. Above command...
20,296
Posted By k_manimuthu
Hi Neo, "vi" option used in that...
Hi Neo, "vi" option used in that script.
20,296
Posted By k_manimuthu
Send keys in shell script
Hi All,

Consider we have script Linux server . But we don't have permission to edit that file.
When run the script, it opens a file as "/tmp/xxx0000 .txt" with few contents. Most of the time...
2,236
Posted By k_manimuthu
Your code regex part doesn't have reference for...
Your code regex part doesn't have reference for GT:PL value and need to modify the regex part.
Try the below code and you can add more regex based on your needs.


perl -plane ' BEGIN{ %h =...
2,412
Posted By k_manimuthu
Try the below codes and integrate into your...
Try the below codes and integrate into your script.
#!/bin/sh
#By default array string tokenizer considered as space, But we need entire line.
# So whitespace replaced as _SPACE_
F1=( `cat...
2,225
Posted By k_manimuthu
Get first column value uniq
Hi All,

I have a directory and sub-directory that having ‘n' number of .log file in nearly 1GB.
The file is comma separated file. I need to recursively grep and uniq first column values only. ...
3,830
Posted By k_manimuthu
Got it. I added the below command and I got the...
Got it. I added the below command and I got the first word of the output.


cut -d ' ' -f1
3,830
Posted By k_manimuthu
Get first word only starting of a line
Hi,

I am trying to get longest line in a .gz file without extract the file.
I am using the below command to get the longest line.


zcat /a/b/c/file.gz |awk '{print length, $0}'|sort -nr|head...
18,374
Posted By k_manimuthu
Thanks, Here what is the mean for "%5dn<...
Thanks, Here what is the mean for "%5dn< %L"?
18,374
Posted By k_manimuthu
Diff option to get line number
Hi,

I am using the below command to get the diff output of two files.
Here in the output file, I wish to add line number in front of each line starting position.
Please suggest the diff...
1,680
Posted By k_manimuthu
File comparsion tool
Hi All, Please suggest some file comparison tool in Linux.
The tool have the provision for command line option for file comparison and the output will be stored in to html file. Thanks in advance
2,465
Posted By k_manimuthu
Find missing .ibd files
Hi,

I have mysql file that extension is .frm and .ibd file.
I am trying the to get command line utility to get missing .ibd file.

for example:
Input :

$ ls -al
-rw-rw---- 1 mysql mysql ...
1,644
Posted By k_manimuthu
Thanks, I am using redhat linux and i know when...
Thanks, I am using redhat linux and i know when the 'core' file was created. Is there any way to check to generic log file, then pls let me know the path.
1,644
Posted By k_manimuthu
I have a core file and i am trying to analyze...
I have a core file and i am trying to analyze with GDB.

I got the below output and want to know about which command used for the PID's

(gdb) core /opt/lampp/var/mysql/core.mysqld.9765
BFD:...
1,644
Posted By k_manimuthu
How to find the corresponding command for a existing PID?
Hi All,

A process completed already and I have the PID. I want to know the which command used for this PID. 'ps' command and '/proc' folder having the list current process only. Is there a way to...
1,489
Posted By k_manimuthu
for SDIR in $(eval $CMD); do echo ....; done ...
for SDIR in $(eval $CMD); do echo ....; done
This syntax working fine in Redhat Linux.
But it not working in Solaris. Any one Please suggest the equal command in Solaris
1,489
Posted By k_manimuthu
Thanks a lot ygemici
Thanks a lot ygemici
1,489
Posted By k_manimuthu
Store a command and execute
Hi All,

I am trying to get latest folders based on some condition. The below sample script working fine for me.

#!/bin/sh
INSTALLDIR=`pwd`
_UPGRADE_=1
CMD="ls -rtp $INSTALLDIR | grep /"...
1,908
Posted By k_manimuthu
I just show the piece of code how to write the...
I just show the piece of code how to write the output to a file. I expect you collate code in the existing example. OK, tried the below code.

#!/usr/bin/perl
use strict;
use warnings;
my...
1,908
Posted By k_manimuthu
Solution already provided there...
Solution already provided there (https://www.unix.com/shell-programming-scripting/168797-looping-through-only-blank-lines-file.html)

The script give the output to console. if you want to save the...
1,973
Posted By k_manimuthu
#!/usr/bin/perl use strict; use warnings; ...
#!/usr/bin/perl
use strict;
use warnings;
my $file1=open_file("file1.txt");
my $file2=open_file("file2.txt");
my @file1 = split(/\n{2,}/, $file1);
my @file2 = split(/\n{2,}/, $file2);
for (my...
8,530
Posted By k_manimuthu
The mentioned code working fine me with out any...
The mentioned code working fine me with out any modification.
1,601
Posted By k_manimuthu
'tar xzvf 20110913.tar.gz' command is enough for...
'tar xzvf 20110913.tar.gz' command is enough for extract the 'tar.gz' format file. If you are not able extract the file by using the 'xzvf' optioin, check your tar utility version and upgrade the...
1,350
Posted By k_manimuthu
perl -ne '/(\d+)/; if ( $1 >= 6 && $1 <= 10...
perl -ne '/(\d+)/; if ( $1 >= 6 && $1 <= 10 ){print}' temp.txt
perl -ne '/(\d+)/; if ( $1 >= 11 && $1 <= 100 ){print}' temp.txt
perl -ne '/(\d+)/; if ( $1 >= 101 ){print}' temp.txt
Showing results 1 to 25 of 106

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