06-27-2014
What function are you using (if any), and are you passing it the whole file or 1 line at a time?
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi,
I have file 1.txt with following entries as shown:
0152364|134444|10.20.30.40|015236433
0233654|122555|10.20.30.50|023365433
**
**
**
In file 2.txt I have the following entries as shown:
0152364|134444|10.20.30.40|015236433
0233654|122555|10.20.30.50|023365433... (4 Replies)
Discussion started by: imas
4 Replies
2. Shell Programming and Scripting
Hi all,
I'm looking for some help. I have a file (very long) that is organized like below:
>Cluster 0
0 283nt, >01_FRYJ6ZM12HMXZS... at +/99%
1 279nt, >01_FRYJ6ZM12HN12A... at +/99%
2 281nt, >01_FRYJ6ZM12HM4TS... at +/99%
3 283nt, >01_FRYJ6ZM12HM946... at +/99%
4 279nt,... (4 Replies)
Discussion started by: d.chauliac
4 Replies
3. Shell Programming and Scripting
Hi,
file -> temp.txt
cat temp.txt
/home/pradeep/123/a_asp.html
/home/pradeep/123/a_asp1.html
/home/pradeep/435/a_asp2.html
/home/pradeep/arun/abc/a_dfr.html
/home/pradeep/arun/123/a_kir.html
/home/pradeep/123/arun/a_dir.html
....
....
..
i need to get a_*.html(bolded strings... (4 Replies)
Discussion started by: pradebban
4 Replies
4. Shell Programming and Scripting
I have a file a file having entries are like
@ram@sham@sita
@krishan@kumar
@deep@kumar@hello@sham
in this file all line are having different no of pattern-@.
need to fetch the substring after the last pattern.
like
sita
kumar
sham
thanks in advance (3 Replies)
Discussion started by: saluja.deepak
3 Replies
5. UNIX for Dummies Questions & Answers
Hi,
I have a string looks like the following:
USERS 32767.9844 UNDOTBS1 32767.9844 SYSAUX 32767.9844 SYSTEM 32767.9844 EMS 8192 EMS 8192 EMS_INDEXES 4096 EMS_INDEXES 4096 8 rows selected.
How do I extract a sub-string to get the expected output as following:
EMS 8192
EMS_INDEXES 4096
... (3 Replies)
Discussion started by: NetBear
3 Replies
6. Shell Programming and Scripting
Fairly straightforward, but I'm having an awful time getting what I thought was a simple regex to work. I'll give the command I was playing with, and I'm aware why this one doesn't work (the 1,3 is off the A-Z, not the whole expression), I just don't know what the fix is:
Actual Output(s):
$... (5 Replies)
Discussion started by: Vryali
5 Replies
7. Shell Programming and Scripting
Hi All,
I have the following output file created as a result of one script called pattern_daily.log
$ cat pattern_daily.log
Approved|2|Wed, Oct 24, 2012 11:21:09 AM
Declined|1|Wed, Oct 24, 2012 11:21:15 AM
Approved|2|Wed, Oct 24, 2012 11:24:08 AM
Declined|1|Wed, Oct 24, 2012 11:24:18 AM... (4 Replies)
Discussion started by: Gem_In_I
4 Replies
8. Shell Programming and Scripting
'Hi
I'm using the following code to extract the lines(and redirect them to a txt file) after the pattern match. But the output is inclusive of the line with pattern match.
Which option is to be used to exclude the line containing the pattern?
sed -n '/Conn.*User/,$p' > consumers.txt (11 Replies)
Discussion started by: essem
11 Replies
9. UNIX for Dummies Questions & Answers
I am not an expert with linux, but following various posts on this forum, I have been trying to write a script to match pattern of charters occurring together in a file.
My file has approximately 200 million characters (upper and lower case), with about 50 characters per line. I have merged all... (5 Replies)
Discussion started by: biowizz
5 Replies
10. Shell Programming and Scripting
Hi,
I know how to replace a string with another in a file.
But, i wish to replace the below string pattern
EncryptedPassword="{gafgfa}]\asffafsf312a" i.e EncryptedPassword="<any random string>"
To
EncryptedPassword=""
i.e remove the random password to a empty string.
Can you... (3 Replies)
Discussion started by: mohtashims
3 Replies
LEARN ABOUT DEBIAN
misc_conv
MISC_CONV(3) Linux-PAM Manual MISC_CONV(3)
NAME
misc_conv - text based conversation function
SYNOPSIS
#include <security/pam_misc.h>
void misc_conv(int num_msg, const struct pam_message **msgm, struct pam_response **response, void *appdata_ptr);
DESCRIPTION
The misc_conv function is part of libpam_misc and not of the standard libpam library. This function will prompt the user with the
appropriate comments and obtain the appropriate inputs as directed by authentication modules.
In addition to simply slotting into the appropriate pam_conv(3), this function provides some time-out facilities. The function exports five
variables that can be used by an application programmer to limit the amount of time this conversation function will spend waiting for the
user to type something. The five variabls are as follows:
time_t pam_misc_conv_warn_time;
This variable contains the time (as returned by time(2)) that the user should be first warned that the clock is ticking. By default it
has the value 0, which indicates that no such warning will be given. The application may set its value to sometime in the future, but
this should be done prior to passing control to the Linux-PAM library.
const char *pam_misc_conv_warn_line;
Used in conjuction with pam_misc_conv_warn_time, this variable is a pointer to the string that will be displayed when it becomes time
to warn the user that the timeout is approaching. Its default value is a translated version of "...Time is running out...", but this
can be changed by the application prior to passing control to Linux-PAM.
time_t pam_misc_conv_die_time;
This variable contains the time (as returned by time(2)) that the will time out. By default it has the value 0, which indicates that
the conversation function will not timeout. The application may set its value to sometime in the future, but this should be done prior
to passing control to the Linux-PAM library.
const char *pam_misc_conv_die_line;
Used in conjuction with pam_misc_conv_die_time, this variable is a pointer to the string that will be displayed when the conversation
times out. Its default value is a translated version of "...Sorry, your time is up!", but this can be changed by the application prior
to passing control to Linux-PAM.
int pam_misc_conv_died;
Following a return from the Linux-PAM libraray, the value of this variable indicates whether the conversation has timed out. A value of
1 indicates the time-out occurred.
The following two function pointers are available for supporting binary prompts in the conversation function. They are optimized for the
current incarnation of the libpamc library and are subject to change.
int (*pam_binary_handler_fn)(void *appdata, pamc_bp_t *prompt_p);
This function pointer is initialized to NULL but can be filled with a function that provides machine-machine (hidden) message exchange.
It is intended for use with hidden authentication protocols such as RSA or Diffie-Hellman key exchanges. (This is still under
development.)
int (*pam_binary_handler_free)(void *appdata, pamc_bp_t *delete_me);
This function pointer is initialized to PAM_BP_RENEW(delete_me, 0, 0), but can be redefined as desired by the application.
SEE ALSO
pam_conv(3), pam(7)
STANDARDS
The misc_conv function is part of the libpam_misc Library and not defined in any standard.
Linux-PAM Manual 06/04/2011 MISC_CONV(3)