comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » get_lun & free_lun
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
get_lun & free_lun [message #89332] Tue, 19 August 2014 05:02 Go to next message
markb77 is currently offline  markb77
Messages: 217
Registered: July 2006
Senior Member
I just noticed that get_lun and free_lun are limited to unit numbers 100-128. That means an IDL application could have access to (at maximum) 29 files simultaneously.

Is there any way around this, other than hard-coding logical unit numbers into your code?

thanks
Mark
Re: get_lun & free_lun [message #89334 is a reply to message #89332] Tue, 19 August 2014 08:32 Go to previous messageGo to next message
Russell Ryan is currently offline  Russell Ryan
Messages: 122
Registered: May 2012
Senior Member
Not that I am aware of. Also, the problem is more sinister... You *ONLY* have access to 29 files, period. You can't open any LUN larger than 128, try it:

openw,150,'tmp.tmp'


At least, that gives me an error...

Russell
IDL> help,!version
** Structure !VERSION, 8 tags, length=104, data length=100:
ARCH STRING 'x86_64'
OS STRING 'darwin'
OS_FAMILY STRING 'unix'
OS_NAME STRING 'Mac OS X'
RELEASE STRING '8.2.3'
BUILD_DATE STRING 'May 2 2013'
MEMORY_BITS INT 64
FILE_OFFSET_BITS
INT 64
I
Re: get_lun & free_lun [message #89335 is a reply to message #89332] Tue, 19 August 2014 09:13 Go to previous messageGo to next message
Yngvar Larsen is currently offline  Yngvar Larsen
Messages: 134
Registered: January 2010
Senior Member
On Tuesday, 19 August 2014 14:02:05 UTC+2, superchromix wrote:
> I just noticed that get_lun and free_lun are limited to unit numbers 100-128. That means an IDL application could have access to (at maximum) 29 files simultaneously.
>
>
>
> Is there any way around this, other than hard-coding logical unit numbers into your code?


1) Use idl_idlbridge. The new idl "child processes" get their own separate set of LUNs (but possibly limited by your OS: see eg "ulimit -n" and "sysctl -n kernel.maxfiles" on a linux system)

or

2) Close your files as soon as possible after you finish reading/writing what you need. (In what scenario do you need to keep more than 29 files open at the same time?)

--
Yngvar
Re: get_lun & free_lun [message #89337 is a reply to message #89335] Tue, 19 August 2014 10:24 Go to previous message
markb77 is currently offline  markb77
Messages: 217
Registered: July 2006
Senior Member
On Tuesday, August 19, 2014 6:13:17 PM UTC+2, Yngvar Larsen wrote:
> On Tuesday, 19 August 2014 14:02:05 UTC+2, superchromix wrote:
>
>> I just noticed that get_lun and free_lun are limited to unit numbers 100-128. That means an IDL application could have access to (at maximum) 29 files simultaneously.
>
>>
>
>>
>
>>
>
>> Is there any way around this, other than hard-coding logical unit numbers into your code?
>
>
>
>
>
> 1) Use idl_idlbridge. The new idl "child processes" get their own separate set of LUNs (but possibly limited by your OS: see eg "ulimit -n" and "sysctl -n kernel.maxfiles" on a linux system)
>
>
>
> or
>
>
>
> 2) Close your files as soon as possible after you finish reading/writing what you need. (In what scenario do you need to keep more than 29 files open at the same time?)
>
>
>
> --
>
> Yngvar

Thanks for the tip about the IDL_IDLBridge - I'm glad that's the case. I was thinking of a scenario where 5 instances of an application are running simultaneously.. it wouldn't be unreasonable for each of those applications to have 5 files open...
Mark
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Generating N random numbers that add to a TOTAL
Next Topic: Customising ENVI water depths tool with IDL

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 13:43:25 PDT 2025

Total time taken to generate the page: 0.00576 seconds