02-28-2007
Quote:
Originally Posted by happyv
i am not sure...is it my file is xml format, the sed command not work.
sed 's;F0</Number>;F</Number>;g' file
if I used below, it work
sed 's; <Number>11 20 03 22 23 21 91 00 0F</Number>; <Number>11 20 03 22 23 21 91 00 F</Number>;g' file
Anyway, my file with more than 10,000 line and it waste time to manual to put the <number> information into the script.
any idea?
Based on the sample file posted, command was posted.
Could you please post the exact command you ran and the output that you got?
I had tested and then only posted, sure the command should work
8 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hello experts,
I know line number of the word I want to replace. Can "sed" substitute word on a specific line?
As well, can sed substitute words inside a specific patten.
ex. <word>lalala</word> #replace anything between <word> and </word>
minifish (2 Replies)
Discussion started by: minifish
2 Replies
2. Shell Programming and Scripting
I have been lurking on this forum for some time now and appreciate Everyone's help. I need to find a way to get the SystemID from this XML file. The file is much larger than just this one line but I can grep and get this line Printed. But really just need the "systemid".
<test123: prefintem... (9 Replies)
Discussion started by: elbombillo
9 Replies
3. Shell Programming and Scripting
hi All,
cat file_name | awk /^~/'{print $1","$2","$3","$4}' | sed -e 's/~//g'
Can this be done by using sed or awk alone (4 Replies)
Discussion started by: harshakusam
4 Replies
4. Shell Programming and Scripting
Hi Guys,
Req your help in searching and replacing the word that comes after equals(=) symbol
I would like to replace the sting in bold with a string in variable.
d=ABCDF8C44C22
# grep -i NIM_MASTERID ${_NIMINFO}
export NIM_MASTERID=00CDF8C44C00
I'm looking to replace any word that... (4 Replies)
Discussion started by: ajilesh
4 Replies
5. Shell Programming and Scripting
Hi,
I have line in input file as below:
3G_CENTRAL;INDONESIA_(M)_TELKOMSEL;SPECIAL_WORLD_GRP_7_FA_2_TELKOMSEL
My expected output for line in the file must be :
"1-Radon1-cMOC_deg"|"LDIndex"|"3G_CENTRAL|INDONESIA_(M)_TELKOMSEL"|LAST|"SPECIAL_WORLD_GRP_7_FA_2_TELKOMSEL"
Can someone... (7 Replies)
Discussion started by: shis100
7 Replies
6. Shell Programming and Scripting
logs:
"/home/abc/public_html/index.php"
"/home/abc/public_html/index.php"
"/home/xyz/public_html/index.php"
"/home/xyz/public_html/index.php"
"/home/xyz/public_html/index.php"
how to use "cut" or "awk" or "sed" to get the following result:
abc
abc
xyz
xyz
xyz (8 Replies)
Discussion started by: timmywong
8 Replies
7. Shell Programming and Scripting
echo {mbr_key,grp_key,dep_key,abc,xyz,aaa,ccc} |
awk 'gsub(/^|abc,|$/,"") {print}'
Required output
{grp_key,xyz,aaa,ccc} (5 Replies)
Discussion started by: 100bees
5 Replies
8. Shell Programming and Scripting
SUSE linux
bash shell
this works
test -d /tmpp && echo "directory exists" || echo "directory doesn't exists" |sed -e "s/^/prefix /"
prefix directory doesn't exists
but why doesn't this work?
test -d /tmp && echo "directory exists" || echo "directory doesn't exists" |sed -e... (3 Replies)
Discussion started by: snoman1
3 Replies
LEARN ABOUT DEBIAN
rdma_post_recv
RDMA_POST_RECV(3) Librdmacm Programmer's Manual RDMA_POST_RECV(3)
NAME
rdma_post_recv - post a work request to receive an incoming message.
SYNOPSIS
#include <rdma/rdma_verbs.h>
int rdma_post_recv (struct rdma_cm_id *id, void *context, void *addr, size_t length, struct ibv_mr *mr);
ARGUMENTS
id A reference to a communication identifier where the message buffer will be posted.
context User-defined context associated with the request.
addr The address of the memory buffer to post.
length The length of the memory buffer.
mr A registered memory region associated with the posted buffer.
DESCRIPTION
Posts a work request to the receive queue of the queue pair associated with the rdma_cm_id. The posted buffer will be queued to receive an
incoming message sent by the remote peer.
RETURN VALUE
Returns 0 on success, or -1 on error. If an error occurs, errno will be set to indicate the failure reason.
NOTES
The user is responsible for ensuring that a receive buffer is posted and large enough to contain all sent data before the peer posts the
corresponding send message. The message buffer must have been registered before being posted, with the mr parameter referencing the regis-
tration. The buffer must remain registered until the receive completes.
Messages may be posted to an rdma_cm_id only after a queue pair has been associated with it. A queue pair is bound to an rdma_cm_id after
calling rdma_create_ep or rdma_create_qp, if the rdma_cm_id is allocated using rdma_create_id.
The user-defined context associated with the receive request will be returned to the user through the work completion wr_id, work request
identifier, field.
SEE ALSO
rdma_cm(7), rdma_create_id(3), rdma_create_ep(3), rdma_create_qp(3), rdma_reg_read(3), ibv_reg_mr(3), ibv_dereg_mr(3), rdma_post_recvv(3),
rdma_post_send(3)
librdmacm 2010-07-19 RDMA_POST_RECV(3)