Search Results

Search: Posts Made By: ramen_noodle
24,445
Posted By ramen_noodle
Vgersh is very good at this type of problem and I...
Vgersh is very good at this type of problem and I don't want to but in, but most cases, in most shells, using an array to store the data and exploding the array is a simple way to form a...
Forum: Programming 10-11-2008
4,170
Posted By ramen_noodle
I'd use flock(). Obtain lock, read n bytes,...
I'd use flock(). Obtain lock, read n bytes, release lock, next child, etc...
Forum: Programming 10-09-2008
17,608
Posted By ramen_noodle
Hello, This is one of the well known...
Hello,



This is one of the well known *nix gotchas.
Most unix systems programmers have gotten used to it.
Not that it's ideal.

"
Read or write not blocking on a resource after select...
Forum: Programming 10-09-2008
3,515
Posted By ramen_noodle
#define PNAME "/fullpath/to/abc" #define ARGS...
#define PNAME "/fullpath/to/abc"
#define ARGS NULL
...
int status;.
if ( (child = fork()) == 0) {
execl(PNAME,basename(PNAME),ARGS);
} else {
waitpid(child,&status,0);
/*test...
Forum: Programming 10-09-2008
17,608
Posted By ramen_noodle
Good luck. You stated that you don't want...
Good luck.

You stated that you don't want to set O_NONBLOCK
which is standard to *nix for alleviating blocking behaviors
and is the basis for fast event interfaces like kqueue and
epoll for...
25,090
Posted By ramen_noodle
Since you are driving the interaction remotely...
Since you are driving the interaction remotely and possibly dealing with multiple logins concurrently the way I'd do this is to use an interact for each spawn_id (after successful setup) with a...
25,090
Posted By ramen_noodle
Ouch. I could probably advise but your outlined...
Ouch. I could probably advise but your outlined procedure is very wrong.
If all in tcl this will require a moderate amount of work and very little expect as
explained.
1,991
Posted By ramen_noodle
An option is expect for windows. Expect for...
An option is expect for windows.
Expect for Windows - Welcome (http://docs.activestate.com/activetcl/8.4/expect4win/welcome.html)
5,702
Posted By ramen_noodle
Using getopts would be a better bet imho. -g...
Using getopts would be a better bet imho.
-g group, -u user -r (optional regexp)...that kind of thing.
Forum: Linux 10-08-2008
14,109
Posted By ramen_noodle
Take a look here. Expect FAQ (Frequently Asked...
Take a look here. Expect FAQ (Frequently Asked Questions) (http://expect.nist.gov/FAQ.html#q21)
1,758
Posted By ramen_noodle
Sure. Here's a quick snippet using regular...
Sure. Here's a quick snippet using regular expressions and builtin error indices.


proc id_pat_match {p} {
send_user "Saw pattern $p\n..continuing"
...
Forum: Programming 10-08-2008
28,797
Posted By ramen_noodle
cpu cores : 2 cpu family : 6 cpuid...
cpu cores : 2
cpu family : 6
cpuid level : 10
cpu MHz : 1200.000
flags : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi...
Forum: Programming 10-06-2008
28,797
Posted By ramen_noodle
Just for contrast on a modern intel SMP processor...
Just for contrast on a modern intel SMP processor running linux 2.6.18 I get more
than a million operations/sec.
On that basis I don't believe this qualifies as a bug..more of a growing pain. ...
Forum: Linux 10-06-2008
6,069
Posted By ramen_noodle
Linux pthreads don't support these functions. I'd...
Linux pthreads don't support these functions. I'd suggest man -k pthread_cond.
These functions can be recreated without too much trouble.
Forum: Programming 09-11-2008
8,049
Posted By ramen_noodle
Not to be a wiseacre but this doesn't seem to...
Not to be a wiseacre but this doesn't seem to have a lot to do with HLP.
Forum: Programming 09-09-2008
21,634
Posted By ramen_noodle
Both ways would work for the op. it seems to me...
Both ways would work for the op. it seems to me one involves creation of a state machine and the other depends on avoiding serialization blocks imposed by pthread_join.
6,798
Posted By ramen_noodle
If you are handling clients on a system that must...
If you are handling clients on a system that must scale you will use neither. Using non-blocking I/O and a fast event mechanism like epoll or kqueue is a better answer.
Forum: Programming 09-08-2008
8,986
Posted By ramen_noodle
man sigprocmask.
man sigprocmask.
Forum: Programming 09-08-2008
21,634
Posted By ramen_noodle
The normal threaded way to do what is suggested...
The normal threaded way to do what is suggested is to create a monitor thread for notification and use pthread_cond primitives for the synchronization.
Example code follows.

#include <stdio.h>...
Forum: Programming 09-05-2008
4,284
Posted By ramen_noodle
Depending on the source of your ldapsearch...
Depending on the source of your ldapsearch utility OpenLDAP may be alternately applicable. OpenLDAP, Software, Man Pages: ldap (http://www.openldap.org/software/man.cgi?query=ldap)
Forum: UNIX and Linux Applications 09-03-2008
20,528
Posted By ramen_noodle
Yep. I worked for the DOC and before audit we...
Yep. I worked for the DOC and before audit we settled on the CIS L1 standard.
It sounds like you guys went way past that.
I feel your pain but admins that have root create huge problems in a...
Forum: Programming 09-03-2008
25,369
Posted By ramen_noodle
poll() and select() aren't the operative...
poll() and select() aren't the operative indicators.

send() to a closed port should error. You need to check the return from this function.
If your client really depends on server response then...
Forum: Programming 09-03-2008
10,666
Posted By ramen_noodle
Allocating memory in 256 byte chunks may seem...
Allocating memory in 256 byte chunks may seem efficient until you move past userspace.
I'm smiling here so please don't be offended.

This is what I was trying to get at earlier. Most 'smart' text...
Forum: UNIX and Linux Applications 09-03-2008
20,528
Posted By ramen_noodle
OK. Re: [ale] automating an ssh script?...
OK.
Re: [ale] automating an ssh script? (http://www.ale.org/archive/ale/ale-2002-07/msg00913.html)
Forum: UNIX and Linux Applications 09-03-2008
20,528
Posted By ramen_noodle
wsiefkas, You can use ssh's pki (keys) to...
wsiefkas,

You can use ssh's pki (keys) to facilitate interaction from a shell script. Simply look at the man pages for : ssh-add, ssh, ssh-agent, ssh-keygen, sshd, etc.. for details. This does ...
Showing results 1 to 25 of 247

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