PGI User Forum
 SearchSearch   MemberlistMemberlist     RegisterRegister   ProfileProfile    Log inLog in 

Free OpenACC Webinar

Hang when license in use

 
Post new topic   Reply to topic    PGI User Forum Forum Index -> Programming and Compiling
View previous topic :: View next topic  
Author Message
vlarson



Joined: 18 Aug 2004
Posts: 3

PostPosted: Fri Sep 06, 2013 11:02 am    Post subject: Hang when license in use Reply with quote

Hello all,
I'm not sure if this should go here or in licensing/installation.

I have an issue where every night, we run an automated compiller test of our code (runs through multiple compilers). It's run serially from a simple shell script.
The problem is that, when it reaches the PGI compiller, if we forgot to close pgdbg, the pgfortran line simply hangs with the 'license in use' error message instead of exiting with an error code, and waits for user interaction. This freezes the entire nightly build script.
Ifort, however, uses the same license manager and does not freeze when its license is in use.

I'm curious if there is some sort of a compiler flag to allow pgfortran to exit with an error code (where we can use some exception handling to email us that there was an issue) if the license is in use rather than simply hanging and leaving the script partially finished (for several days if this happens over the weekend).

Thank you all for your help.
Back to top
View user's profile
mkcolg



Joined: 30 Jun 2004
Posts: 6218
Location: The Portland Group Inc.

PostPosted: Fri Sep 06, 2013 1:39 pm    Post subject: Reply with quote

Hi vlarson,

That's not the expected behavior. The compilers should retry 3 times to check out the license with ~1 second between tries and then abort.

Could something else in your script be causing it to hang? Do you see the hang when pgfortran is executed outside the script?

- Mat
Back to top
View user's profile
vlarson



Joined: 18 Aug 2004
Posts: 3

PostPosted: Wed Sep 11, 2013 12:19 pm    Post subject: Reply with quote

Hi Mat,

Well, I tested it just by starting 'pgdebug' (which is what tends to cause the issue, if someone leaves that running) first, then running a pgf95 command.
It will hang with the following message
Code:
pgi-f95-lin64: LICENSE MANAGER PROBLEM: Licensed number of users already reached.
Feature:       pgi-f95-lin64
License path:  /opt/pgi/license.dat:
FLEXnet Licensing error:-4,132
For further information, refer to the FLEXnet Licensing documentation,
available at "www.acresso.com".

Unless I physically end the process (control-c, kill command, etc), it just sits there forever.

For now I have, in the script, a few 'sudo killall' commands for each pgi compiler task name, but even that will fail now and then if a user launches the debugger after the kill command goes through, which then causes the script to hang once more.

-Jon (Sysadmin for vlarson)
Back to top
View user's profile
jtull



Joined: 30 Jun 2004
Posts: 445

PostPosted: Thu Sep 12, 2013 3:54 pm    Post subject: Single seat licenses work this way. Reply with quote

I don't see the problem. These are single seat licenses - if you are running pgdbg, there are no more seats, and flexlm queues up the requests.
If we were to timeout compiles, the users with long compilations would timeout as well.

The person using pgdbg CAN run the compilers, btw, since he has the seat. When you are using pgdbg, you will want to also run the compilers,
obviously.

So either open pgdbg
before you run your jobs (inwhich case you will always have the compilers),
or set the permissions on pgdbg (and pgprof) to not allow people to use it while running your jobs so that other users can share the seat.

Or get a multi-seat floating license.
Back to top
View user's profile
vlarson



Joined: 18 Aug 2004
Posts: 3

PostPosted: Tue Sep 17, 2013 12:42 pm    Post subject: Reply with quote

Oh, I understand the reasons for the way it's works like this. I was curious as to whether there is a way to set a timeout for waiting for a license rather than simply stalling, perhaps with a compiler flag (set within our nightly script).

We have several single seat licenses. Due to the hassle we've experienced with flexLM in the past, we're trying to avoid switching to a floating license.
Back to top
View user's profile
Display posts from previous:   
Post new topic   Reply to topic    PGI User Forum Forum Index -> Programming and Compiling All times are GMT - 7 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © phpBB Group