Sponsored Content
Full Discussion: spawning the same program
Top Forums UNIX for Advanced & Expert Users spawning the same program Post 80678 by laforge on Wednesday 10th of August 2005 04:55:18 PM
Old 08-10-2005
spawning the same program

We have a program (reader) that reads audio files in a real-time continuous stream from a sender program. If the reader gets weird we want the sender to be able to send one command that will stop the current reader and start a new one that will be able to continue reading in the files. The sender cannot access anything other than the reader (ie, it cannot run any commands on the server, etc). The reader runs on UNIX and is written in C++.

I've tried using system() to call a batch file that sleeps for a few second and then starts a new reader. It starts a new reader but the old one stays up. I've also tried exec(), which does replace the old reader with the new one but the new reader doesn't read the audio files; it just seems to sit out there doing nothing.

Is there a way to have a program basically kill itself and start a fresh version of itself that works?

Thank you.
 

10 More Discussions You Might Find Interesting

1. Solaris

spawning new shells using dtterm in Solaris 8

Hi all, First time poster here. Great forum. Im trying to spawn new shells and pass commands to the new shells in a solaris 8 environment utilizing dtterm and its option -e. I can successfully spawn a window utilizing the following code: /usr/dt/bin/dtterm -display <ip.address> & ... (4 Replies)
Discussion started by: Rocketman8541
4 Replies

2. Shell Programming and Scripting

Spawning new shells from the command line in OpenStep 4.2

Hi all, Im trying to figure out what the command would be to launch terminal windows from the command line in Open Step 4.2 . (looking for something similiar like /usr/bin/xterm or /usr/bin/dtterm etc) echo $TERM = vt100 echo $SHELL = /bin/csh Im combing over alot of OpenStep 4.2 and... (3 Replies)
Discussion started by: Rocketman8541
3 Replies

3. Shell Programming and Scripting

Spawning a shell script

Hi there, I have a shell script which I need to run it from two different places on the same server, are there any specific rules I need to apply? What is the best practice to achieve this task. Regards (5 Replies)
Discussion started by: JimJim
5 Replies

4. Programming

spawning multiple processes spread across two files

I want to spawn n child processes but have two different classes..with the foremost one forking/spawning the child process and the latter performing a function w/ the spawned processes. I can do this in one class with an if statement and the simple if((pid=fork())==0) //child process { ... (1 Reply)
Discussion started by: StrengthThaDon
1 Replies

5. Shell Programming and Scripting

Spawning multiple threads in Unix

Hi, I need to spawn mutilpe threads , each invoking a different set of shell scripts, in parallel. What would be the best way to do that. Any sample script would greatly help. I am a novice at Unix so any help is much appreciated. Thanks (5 Replies)
Discussion started by: neeto
5 Replies

6. UNIX for Advanced & Expert Users

Crontab spawning multiple at processes

Hi - I need help. My user crontab is spawning multiple at processes (and multiple mencoder program starts, that exit, then restart, repeatedly), locking up my system. For example I have this entry in my crontab: $ sudo crontab -u victoria -e * * * * * ~/recordings/pvr1 * * * * *... (10 Replies)
Discussion started by: gstuart
10 Replies

7. UNIX for Advanced & Expert Users

Help! imapd is spawning multiple processes, all of a sudden, for no reason!

Hi All, I need some assistance, if possible... Our IMAP server has recently (as of 10:30 GMT today) started spawning multiple processes for no reason! This is causing the mail server's load average to increase continually until the whole machine grinds to a halt. Here is a typical... (0 Replies)
Discussion started by: fishsponge
0 Replies

8. Shell Programming and Scripting

lost the $ prompt - am I spawning shells??

When trying to get the correct syntax to cron a script that creates a file with the date stamp as its output, sometimes I get these results: - from the command line, I may encounter an error that leaves me without the usual $ prompt. Am I in a new shell? I try to exit it with 'exit' or :q! and... (1 Reply)
Discussion started by: landog
1 Replies

9. AIX

Multiple pconsole processes spawning indefinetly

Good night everyone, I've been trying to make AD authentication work with RBAC and I think I messed my test LPAR up. I've manually modified the /etc/security/user.roles file, adding a role to one of my AD users (who is not defined locally) and then runned setkst. It worked fine, but now I found... (3 Replies)
Discussion started by: Janpol
3 Replies

10. Shell Programming and Scripting

Spawning a TTY shell

Hi there, I would like to understand the purpose of spawning a TTY shell? Does it mean that it will help to open up a new Windows on the current interactive shell such that when the session gets lost the other won't Any explanation will be helpful. (3 Replies)
Discussion started by: alvinoo
3 Replies
SVN::Dump::Reader(3)					User Contributed Perl Documentation				      SVN::Dump::Reader(3)

NAME
SVN::Dump::Reader - A Subversion dump reader SYNOPSIS
# !!! You should use SVN::Dump, not SVN::Dump::Reader !!! use SVN::Dump::Reader; my $reader = SVN::Dump::Reader( $fh ); my $record = $reader->read_record(); DESCRIPTION
The "SVN::Dump::Reader" class implements a reader object for Subversion dumps. METHODS
The following methods are available: new( $fh ) Create a new "SVN::Dump::Reader" attached to the $fh filehandle. read_record( ) Read and return a new SVN::Dump::Record object from the dump filehandle. read_header_block( ) Read and return a new SVN::Dump::Headers object from the dump filehandle. read_property_block( ) Read and return a new SVN::Dump::Property object from the dump filehandle. read_text_block( ) Read and return a new SVN::Dump::Text object from the dump filehandle. The "read_..." methods will die horribly if asked to read inconsistent data from a stream. SEE ALSO
SVN::Dump, SVN::Dump::Headers, SVN::Dump::Property, SVN::Dump::Text. COPYRIGHT &; LICENSE Copyright 2006 Philippe 'BooK' Bruhat, All Rights Reserved. This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. perl v5.10.0 2008-06-12 SVN::Dump::Reader(3)
All times are GMT -4. The time now is 12:29 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy