- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - OpenVMS
- >
- Re: Adding to DCL$PATH in PERL
Operating System - OpenVMS
1753626
Members
5445
Online
108797
Solutions
Forums
Categories
Company
Local Language
юдл
back
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Forums
Discussions
юдл
back
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Blogs
Information
Community
Resources
Community Language
Language
Forums
Blogs
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-02-2009 09:51 AM
тАО11-02-2009 09:51 AM
Re: Adding to DCL$PATH in PERL
As folks have figured out, you can't create search list logicals using %ENV within Perl. There is a syntax for *reading* search list logicals, but not creating them.
The reason for that is that in order to get past the 255-byte limitation on equivalence names, all of the elements of a search list are treated as one big long string so you effectively have 255 * 127 bytes for your value. In other words, if you assign a value to %ENV longer than 255 bytes, the pieces will be broken into chunks and stored as elements of the search list, then transparently pasted back together on l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ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ
ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ
ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ
ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ
ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ
$
The exception is the special PERL5LIB logical that tells Perl where to look for libraries: that one is always treated as a genuine search list.
The problem at hand is probably best solved by VMS::Logical. FWIW, Perl 5.10.1 is current.
The reason for that is that in order to get past the 255-byte limitation on equivalence names, all of the elements of a search list are treated as one big long string so you effectively have 255 * 127 bytes for your value. In other words, if you assign a value to %ENV longer than 255 bytes, the pieces will be broken into chunks and stored as elements of the search list, then transparently pasted back together on lookup;
$ perl -e "$ENV{FOO} = 'Z' x (255 * 3);"
$ sho log foo
"FOO" = "ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ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ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ
ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ
ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ
ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ
$
The exception is the special PERL5LIB logical that tells Perl where to look for libraries: that one is always treated as a genuine search list.
The problem at hand is probably best solved by VMS::Logical. FWIW, Perl 5.10.1 is current.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-02-2009 12:20 PM
тАО11-02-2009 12:20 PM
Re: Adding to DCL$PATH in PERL
>Running Perl does not spawn a sub process
> and thus a JOB logical is not required.
but what access mode does Perl use to define logical names? If they're in the process table at user mode, they will vaporise on image exit.
Use SHOW LOGICAL/FULL to include access mode, and add a wildcard to the end of the name to display the name at all access modes.
You might be able to SPAWN (ie Perl "system()") a SHOW LOGICAL/FULL command to see your user mode definition. Although you'll be looking at the process table of the subprocess, it should be a clone of the parent's table.
> and thus a JOB logical is not required.
but what access mode does Perl use to define logical names? If they're in the process table at user mode, they will vaporise on image exit.
Use SHOW LOGICAL/FULL to include access mode, and add a wildcard to the end of the name to display the name at all access modes.
You might be able to SPAWN (ie Perl "system()") a SHOW LOGICAL/FULL command to see your user mode definition. Although you'll be looking at the process table of the subprocess, it should be a clone of the parent's table.
A crucible of informative mistakes
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-02-2009 01:29 PM
тАО11-02-2009 01:29 PM
Re: Adding to DCL$PATH in PERL
When Perl is storing the environment array in logical names (not the only option) it sets those logicals in supervisor mode. This is handy when mixing and matching Perl with native VMS utilities and helps make Perl a viable DCL replacement in some circumstances. It causes trouble when scripts ported from Unix assume that the contents of the environment array disappear at program exit.
I've sometimes wondered whether we should implement a mode option so that people who want the logicals to go away at image run-down would have the ability to do so.
I've sometimes wondered whether we should implement a mode option so that people who want the logicals to go away at image run-down would have the ability to do so.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-30-2009 05:49 PM
тАО11-30-2009 05:49 PM
Re: Adding to DCL$PATH in PERL
Isn't that USER mode?
- « Previous
-
- 1
- 2
- Next »
The opinions expressed above are the personal opinions of the authors, not of Hewlett Packard Enterprise. By using this site, you accept the Terms of Use and Rules of Participation.
News and Events
Support
© Copyright 2024 Hewlett Packard Enterprise Development LP