03-03-2017
substitution of particular char
Thanks.
But the file is big one having 5000 records. I want to change only 154 th
char where the file is having 306 chars.
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
well i have this file here:
<XML>
<pregate xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<system_c>HPREGATE</system_c>
<trans_c>HSPG</trans_c>
<trans_dt>20060105161333</trans_dt>
<user_id_m></user_id_m>
<func_c>C</func_c>
</pregate>
</XML>
i want to... (2 Replies)
Discussion started by: forevercalz
2 Replies
2. Shell Programming and Scripting
Hi all
I am in a small problem pl help me out.
I am having a directory having ZIP files with name starting as :
01.xyz
02.pqr
and so on
I want to run the script-
cat myfile | awk '{print $1, $2}' | while read var1 var2
do
zcat $var2* | grep "^000$var1" >> my_output
done
Where the... (22 Replies)
Discussion started by: vanand420
22 Replies
3. Shell Programming and Scripting
i have an file ,i want to substitute line
003 M 33 22 22 00
WITH NEW
003 M 24 26 28 00
how can i do it (2 Replies)
Discussion started by: RahulJoshi
2 Replies
4. UNIX for Dummies Questions & Answers
correct file names are:
*_0.txt
*_1.txt
incorrect file names are:
*_12.txt
*_0123.txt
*_04321.txt
all files that are incorrect need to replace the ending with *_1.txt
therefore need to create a loop to find the wrong files in a dir ->that dont end in _1.txt or _0.txt and then... (3 Replies)
Discussion started by: sigh2010
3 Replies
5. Shell Programming and Scripting
Hi,
I am new to this forum and my script skills are very weak.
I have this file (file 1) that contains 3 columns (tab delimited):
kyle start stop
john start stop
joe start stop
And I want to replace name (column 1) from another file. This other file has two columns, one is the... (4 Replies)
Discussion started by: kylle345
4 Replies
6. Shell Programming and Scripting
I have a large .gz file where i wish to replace the occurrence of a particular word with another word.. Can anyone help?I prefer a short script..
Can sed work with gz files? (5 Replies)
Discussion started by: maximus8886
5 Replies
7. Programming
Compiling xpp (The X Printing Panel) on SL6 (RHEL6 essentially):
xpp.cxx: In constructor ‘printFiles::printFiles(int, char**, int&)’:
xpp.cxx:200: error: invalid conversion from ‘const char*’ to ‘char*’
The same error with all c++ constructors - gcc 4.4.4.
If anyone can throw any light on... (8 Replies)
Discussion started by: GSO
8 Replies
8. UNIX for Dummies Questions & Answers
I have the below 2 files:
1) Third field from file1.txt should be compared to the first field of lookup.txt.
2) If match found then third field, file1.txt should be substituted with the second field from lookup.txt.
3)Else just print the line from file1.txt.
File1.txt:... (4 Replies)
Discussion started by: venalla_shine
4 Replies
9. Shell Programming and Scripting
Hi experts :)
I need to replace special characters into a file , in the followiing way :
" --> ""
' --> ''
_--> \_
I tried with the sed command but I'm getting and error ksh: $: not found.
ksh: $: not found.
sed: Function s/\/\/ cannot be parsed.
Any idea ?
Thanks ,
KOLAS... (2 Replies)
Discussion started by: Kolas79
2 Replies
10. Shell Programming and Scripting
Team,
I want to change below parameter in all the files in a directory,
Check for HOSTNAME=`hostname`
Change to HOSTNAME=localhost
And I tried below but, its not working ☹
find /tmp -type f -exec sed 's/"HOSTNAME\=\`hostname\`"/"HOSTNAME\=localhost/g'"
Help me if I am missing... (6 Replies)
Discussion started by: natraj005
6 Replies
LEARN ABOUT DEBIAN
queue-repair
queue-repair(8) System Manager's Manual queue-repair(8)
NAME
queue-repair - deal with the qmail queue directory structure
SYNOPSIS
queue-repair [ -htrcbn ] [ -n split ] [ conf-qmail ]
DESCRIPTION
queue-repair deals with the qmail queue structure; it can create a new queue, move and properly rename a queue, dynamically change the
conf-split value, convert big-todo queues to non-big-todo and vice versa, and repair a corrupted queue.
conf-qmail defaults to /var/lib/qmail/ on Debian.
OPTIONS
-h|--help
Display usage information and built-in defaults, then exit.
-t|--test
Run in test-only mode. queue-repair will attempt to report all problems that it finds, without correcting them. This is the
default.
-r|--repair
Run in repair mode. queue-repair will attempt to correct all problems that it finds, except if the basic queue directories (queue,
queue/mess, queue/info, etc) are not found.
-c|--create
Run in create-and-repair mode. queue-repair will attempt to correct all problems that it finds, including creation of a new queue
structure from scratch.
-s|--split split
Specify split as the value of conf-split. This is the number of split subdirectories for those queue directories which are hashed.
The default for qmail is 23. Appropriate values depend on the volume of mail handled, OS filesystem efficiency, and other factors,
but this should always be a prime number.
If you do not specify conf-split, queue-repair will attempt to determine the current value from the existing queue. This option can
be used, however, to change the conf-split value of an existing queue (qmail will still have to be recompiled with the new value).
When creating a new queue, this option must always be specified.
-b|--bigtoto
Use big-todo. queue-repair should be able to automatically determine if you're using qmail patched with the big-todo patch. This
option can be used, however, to convert a non-big-todo queue to a big-todo queue (qmail will still have to be recompiled with the
big-todo patch).
If neither this option nor --no-bigtodo is used, queue-repair will attempt to determine this automatically. When creating a new
queue, either this option or --no-bigtodo must always be specified.
-n|--no-bigtodo
Do not use big-todo. queue-repair should be able to automatically determine if you're using qmail patched with the big-todo patch.
This option can be used, however, to convert a big-todo queue to a non big-todo queue (qmail will still have to be recompiled with-
out the big-todo patch).
If neither this option nor --bigtodo is used, queue-repair will attempt to determine this automatically. When creating a new queue,
either this option or --bigtodo must always be specified.
--i-want-a-broken-conf-split
Force the use of a non-prime value for conf-split.
SEE ALSO
qmail(7)
queue-repair(8)