Solved

Problem calling exec after program has been started using rexec

Posted on 2004-04-20
1
306 Views
Last Modified: 2013-12-27
OS Solaris 2.8.
Language C/C++
Lets say I have an executable xxx which perfoms certain things like forking a child, which becomes a demon. After that, demon forks another child, which becomes group leader( of new group ) and after that it tries to call 'execvp' to start another executable( aaa ).
Everything works perfectly.

Problem arises when I start xxx from another program using 'rexec'.
While debugging xxx, it behaves correctly till the call execvp happens.
Here is what I see in workshop:
dbx: process 6733 about to exec("/export/home/izh1/its/bin/aaa")
dbx: warning: LO "/export/home/izh1/its/src/-" destroyed while there are references to it
Reading aaa

>>loading
>>reading additional symbolic information

execution completed, exit code is 795441768
(dbx)

Now I will show you successfull case.
In case I am starting xxx from command line than in the same place (in workshop) I would get:
dbx: process 6733 about to exec("/export/home/izh1/its/bin/aaa")
dbx: warning: LO "/export/home/izh1/its/src/-" destroyed while there are references to it
Reading aaa
Reading libbla1.so
Reading libbla2.so
Reading libbla3.so
(dbx)
And worshop ends up in the aaa process.

Can anyone help me out to understand what is the problem?  Why program which works perfectly stops working properly after it has been started using rexec?
Any inputs are appreciated.

0
Comment
Question by:igor1026
1 Comment
 
LVL 4

Accepted Solution

by:
Otetelisanu earned 500 total points
ID: 10876950
If you start with rexec must
the environemet variable in the
script same as to the rserver.

0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

A metadevice consists of one or more devices (slices). It can be expanded by adding slices. Then, it can be grown to fill a larger space while the file system is in use. However, not all UNIX file systems (UFS) can be expanded this way. The conca…
I have been running these systems for a few years now and I am just very happy with them.   I just wanted to share the manual that I have created for upgrades and other things.  Oooh yes! FreeBSD makes me happy (as a server), no maintenance and I al…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
In a previous video, we went over how to export a DynamoDB table into Amazon S3.  In this video, we show how to load the export from S3 into a DynamoDB table.

746 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now