Operating System - OpenVMS
1753521 Members
5426 Online
108795 Solutions
New Discussion юеВ

Re: Logical Names nesting

 
SOLVED
Go to solution
jordi sueiro
Occasional Advisor

Logical Names nesting

Hello,

* I have this system:
OpenVMS V7.3-2 on node SEGRI2 5-JUN-2008 13:24:09.71 Uptime 295 22:36:57

* with (among others) this disk:
$ sh dev DISK$USER_D
Device Device Error Volume Free Trans Mnt
Name Status Count Label Blocks Count Cnt
$1$DGA422: (XXXXXX) Mounted 0 USER_D 22077916 1 1

* and its associated logical name:
$ sh log/ful DISK$USER_D
"DISK$USER_D" [exec] = "$1$DGA422:" [concealed,terminal] (LNM$SYSTEM_TABLE)

* Now, I try to do this (define nested logicals):
$ def/exec/tra DK$1 DISK$USER_D:[USER26.]
$ def/exec/tra DK$2 DK$1:[cep.]

* That's the way they are:
$ sh log dk$%/ful
"DK$1" [exec] = "DISK$USER_D:[USER26.]"
"DK$2" [exec] = "DK$1:[CEP.]"

* But if I try using them, I get errors!:
$ dir DK$2:[000000]
%DIRECT-E-OPENIN, error opening DK$2:[000000] as input
-RMS-F-DIR, error in directory name

* unless I try the first-level nested one:
$ dir DK$1:[000000]

Directory DISK$USER_D:[USER26.][000000]

CEP.DIR;1 PACBD.DIR;1 SD_AXP.DIR;1

Total of 3 files.
-------------------------------------------------------------
* Let's try concealing:
$ def/exec/tra=(concealed) DK$1 DISK$USER_D:[USER26.]
$ def/exec/tra=(concealed) DK$2 DK$1:[cep.]

* That's the way they are:
$ sh log dk$%/ful
"DISK$1" [exec] = "DISK$USER_D:[USER26.]" [concealed]
"DISK$2" [exec] = "DISK$1:[CEP.]" [concealed]

* And just the same results:
$ dir DK$2:[000000]
%DIRECT-E-OPENIN, error opening DK$2:[000000] as input
-RMS-F-DEV, error in device name or inappropriate device type for operation
$ dir DK$1:[000000]

Directory DK$1:[000000]

CEP.DIR;1 PACBD.DIR;1 SD_AXP.DIR;1

Total of 3 files.
-------------------------------------------------------------

Can anyone help me? Thanks in advance!
12 REPLIES 12
Jan van den Ende
Honored Contributor
Solution

Re: Logical Names nesting

Jordi,

According to the documentation, _CONCEALED DEVICE_ logicals cannot be nested.

In practice, it is (just a little) less strict:

$ Define/trans=conc DISK1 $1$DGA422:
$ Define/trans=conc rooted disk1:[root.]

(assume ROOT.DIR does exist)
$ Dir rooted:[000000]

Directory ROOTED
(etc)

But the definition of the device part of a concealed device can NOT itself contain, directly nor indirectly, a DIRECTORY part.

(much as I have regretted this myself in the past!)

hth

Proost.

Have one on me.

jpe
Don't rust yours pelled jacker to fine doll missed aches.
labadie_1
Honored Contributor

Re: Logical Names nesting

Hello

When you define a concealed, you have a string .][ in your device definition.

You can have this string only once in a device definition.

So you can't do a concealed of concealed.

If you search on ITRC, you will find a good number of posts on that subject.
Hoff
Honored Contributor

Re: Logical Names nesting

John Gillings
Honored Contributor

Re: Logical Names nesting


>(much as I have regretted this myself in
>the past!)

Allowing nesting of logical names concealed devices might seem attractive, but it results in an explosion of complexity (consider multiple nestings). Were concealed devices implemented differently, it might have been feasible, but we're stuck with the historical separation of device and directory, which makes nesting a somewhat intractable problem. (the unix file specification model, where there is no distinction between device, directory and file is much more flexible and often easier to deal with, but we're stuck with what we've got)

What makes things worse is, there are some circumstances where nesting apparently "works", but, as documented, it's not guaranteed.

The attachment is a command procedure to define a concealed logical name to a specified directory which resolves all logical names and file specification peculiarities.

Example:

$ @DEFINE_CONCEALED MYLOGIN SYS$LOGIN /JOB

A crucible of informative mistakes
jordi sueiro
Occasional Advisor

Re: Logical Names nesting

Hello,

First of all: thanks to everyone for their answers.
Second, surely I was not good enough at explaining my needs, maybe -sure!- there's something I don't -still- understand in the "Logical Names World". It was my fault, and I apologize. So I'll try again:
I would like to get something like that (don't mind about the "Directory DISK$U..." header; all I want is the files list!):
$ dir DISK$USER_D:[USER26.CEP]

Directory DISK$USER_D:[USER26.CEP]

USUARI.DIR;1

Total of 1 file.
when I issue:
$ dir DK$2:[000000]
%DIRECT-E-OPENIN, error opening DK$2:[000000] as input
-RMS-F-DIR, error in directory name

That's why I've been trying with concealing and not concealing the logical names involved. I don't care if I get something like:
$ dir DK$2:[000000]

Directory $1$DGA422:[USER26.CEP]

USUARI.DIR;1

Total of 1 file.

My question is: is there a way to get the above result (other than assigning disk$2 to the "full" path)? Please note that I'm trying to use logical names to it's "maximum" extent (I'm moving my old system to a new one, trying to minimize the changes in disk assigning; my new system has bigger disks, so I put a few old ones in just one new -a directory for each old disk).

I hope this clarifies my "problem". Please feel free to ask any further data you may need.
Thank you again
P.S. I've tried also this (DEconcealing physical device logical name):
$ sh log dk$%,DISK$USER_D/ful

(LNM$PROCESS_TABLE) [kernel]
[no protection information]

(LNM$JOB_816601C0) [kernel] [shareable] [Quota=(14232,15000)]
[Protection=(RWCD,RWCD,,)] [Owner=[SYSMGR,SYSTEM]]

(LNM$GROUP_000001) [kernel] [shareable,group]
[Protection=(RWCD,R,R,)] [Owner=[SYSMGR,*]]

(LNM$SYSTEM_TABLE) [kernel] [shareable,system]
[Protection=(RWC,RWC,R,R)] [Owner=[SYSMGR,SYSTEM]]

"DISK$USER_D" [exec] = "$1$DGA422:" [terminal]
"DK$1" [exec] = "DISK$USER_D:[USER26.]"
"DK$2" [exec] = "DK$1:[CEP.]"

(LNM$SYSCLUSTER_TABLE) [kernel] [shareable,system]
[Protection=(RWC,RWC,R,R)] [Owner=[SYSMGR,SYSTEM]]

(DECW$LOGICAL_NAMES) [exec] [shareable]
[Protection=(RWCD,RWCD,R,R)] [Owner=[SYSMGR,SYSTEM]]
SEGRI2> dir DK$2:[000000]
%DIRECT-E-OPENIN, error opening DK$2:[000000] as input
-RMS-F-DIR, error in directory name
Karl Rohwedder
Honored Contributor

Re: Logical Names nesting

It looks like the definition of DK$2 is missing the concealed attribute:

$ define dk$2 /exec/Sys/translation=concea DISK$USER_D:[USER26.CEP.]

You can't defined concealed logical names using concealed logical names (that's why John provides his DCL routine).

regards Kalle
Jan van den Ende
Honored Contributor

Re: Logical Names nesting

Jordi,

>>>
Please note that I'm trying to use logical names to it's "maximum" extent
<<<

VERY good! More people should do that!

>>>
is there a way to get the above result (other than assigning disk$2 to the "full" path)?
<<<

The way _I_ would tackle this:

In the ONE procedure clusterwide that defines fysical devices, like disks, tapes, ,,,

$ DEFINE /SYSTEM/EXEC DISKnn $1$DGA422: /trans=conc

In the ONE procedure clusterwide that defines all (real & potential) concealed devices

$ DEFINE /system/exec CEP_ROOT DISKnn:[USER26.CEP.]/trans=conc

Note: after these two bootstrap procedures (MOUNT step in between) have been run, _NO_ procedure should EVER reference Fysical devices, NOR disks anymore (BACKUP excepted).

In the initialisition procedure for application CEP:

$ define [/table] [/mode] USUARI CEP_ROOT:[USUARI]

ANY references now should be through either CEP_ROOT or USUARI.

$ DIR CEP_ROOT:[000000]

USUARI.DIR;1

$ DIR USUARI:

CEP_ROOT:[USUARI]



--- Many ways leading to Rome, but this schema has helped me/us tremendously for over 20 years now. It has been deployed in dozens of sites, expecially in the timeframe that I was involved in rolling out turn-key applications.
It also was the basis for our 11-year-uptime cluster.

Success!

Proost.

Have one on me.

jpe
Don't rust yours pelled jacker to fine doll missed aches.
jordi sueiro
Occasional Advisor

Re: Logical Names nesting

Thanks Kalle, but I (think, maybe I'm wrong) don't need concealed logical names. Please tell me if I'm wrong with this: All I need is a three LN's chain...
jordi sueiro
Occasional Advisor

Re: Logical Names nesting

Thanks Jan, but I think this is not what I'm asking for. I want three (or more) nested logicals; is this possible with Open VMS?
P.S. The schema you pointed out is the same (good one) we've been using for 19 years, but I don't want the easy way... although maybe that's the only one...