Process keep running on Linux server after running scripts with "b-pro"

Borowsky2

New Member
Hi !

First, sorry for my english... :biggrin:

We have Progress databases on Linux Server.

At night we run 4 ".sh" with the cron table with 30min between each ".sh". These .sh contain many "b-pro" which run ".r"

To connect to the databases, a process (mprosrv) is run per database (8 for me).

The problem is when the 1st .sh is finished processes keep running, they are not killed. So 30min after the 2nd .sh re-create 8 process to connect to the databases.

In the morning, we have 4*8 = 32 processes which are not used and which use resources for nothing.
It causes problem like "OE Broker fails to find a server available for connecting".

How can we do to have less processes used or to the 2nd .sh use processes (connections) of the 1st .sh ?

Thank you for your reply. :)
 
The problem is when the 1st .sh is finished processes keep running .. that would mean your not exiting your program clean. Put some messages after each of your b-pro lines and you will know which ones are not exiting. You dont want to have run-away processes if thats what they are.

HTH
 
Ok. More information : The .sh which is run look like :

export DLC=/progress10/dlc
export PATH=$PATH:.:/usr/java/jdk1.6.0_17/bin:/progress10/dlc/bin:/usr/sbin:/sbin:/home/progress/bin
TERM="xterm"; export TERM;
bpro -pf MyFile.pf -p MyProcedure1 > MyLog
bpro -pf MyFile.pf -p MyProcedure2 > MyLog
bpro -pf MyFile.pf -p MyProcedure3 > MyLog
...
In my .pf file, there are connexions of the 8 databases that my procedures need. For each database connexion, there is a process "mprosrv". So when my first .sh is finished, I've got 8 processes which are not killed and which aren't usefull anymore... Is it the normal working ?

As vinod_home says, maybe there is a command that I have to put in my procedure (.p) to close the connexion and to free process ?
Or Maybe it's a problem with the end of my .sh script ? Do we tell Progress to kill processes ?

Thank you.
 
If you are worried that the _mprosrv processes are running you should not be. This is normal.

Those are started as needed by the database to allow remote connections. If there are no sessions connected to them then they are idle. If a new connection needs one it is already running and ready.

However -- if you are running the batch processes on the same physical server as the database (and you generally should be) then you should not be running them as remote clients. Which is to say that you should not be using the -H and -S parameters. If you omit those parameters the clients will connect using shared memory rather than through a TCP/IP socket. Shared memory is much, much faster than socket communications and a shared memory connection will never start an _mprosrv.
 
Ok Thanks for your reply.

If I omit -S and -H parameters in my .pf file, I have to omit the -N parameter too ? I will try this because my batch processes are running on the same physical server as the database.

What I don't understand is why the second .sh doesn't use mprosrv that the 1st .sh has created to connect to databases...

And an other question, does each "b-pro" command need a remote connection ?

Sorry for my blindness :)

EDIT : I tried without the -H, -S and -N parameter but i have an error : The database /MyDatabaseFile is in use in multi-user mode. (276)
 
Use "mbpro" (multi-user database connection batch process).

bpro is used for single user, which is what the remote connection (-H -S -N) was used for.. i.e. single user remote connection in batch.
 
Yeahh ! It works !!

Thank you very much for your replies ! I want to say that I love you but it's maybe a little too much ! :)

Thanks
 
Back
Top