- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - OpenVMS
- >
- File size of Open File..
Categories
Company
Local Language
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
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
Community
Resources
Forums
Blogs
- 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
тАО03-19-2007 12:49 AM
тАО03-19-2007 12:49 AM
I am using the f$file_attributes to find the file size of an open file using f$file_attributes. This fails.
a = F$FILE_ATTRIBUTES("SMSC_DAT1:[SMH00]smh00_own_file.dat", "eof")
%SYSTEM-W-ACCONFLICT, file access conflict
\SMSC_DAT1:[SMH00]smh00_own_file.dat\
This file is opened in a global section.
$ install list/global
Group Global Sections
SMH00_OWN_FILE.DAT
(00000000) WRT DZRO TMP GRP =000100 Pgltcnt/Refcnt=360944/22559
If I do it for a normal file it works..
Is there a way around it. Or an other way
gr,
Robert Verkerk
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-19-2007 01:26 AM
тАО03-19-2007 01:26 AM
Re: File size of Open File..
F$FILE always use RMS SYS$OPEN to have it load details into FAB's and XAB's.
For the open to succeed, the sharing conditions must be correct.
DIR/FULL on the other hand oly uses RMS for remote (DECNET) files. For local files is uses a QIO to get the Attributes.
So you can either parse DIR/FULL output, or write a (not to hard!) program to do that QIO yourself and return the data in any way you like (dcl symbols probably).
IMHO F$FILE should use QIO and blow through sharing... it is not about to share data it only want meta data! And/or RMS should get a 'Display Only' option. Like a SYS$DISPLAY call without a prior open, or an other flag.
RMS also needs the ability to use the SYSLCK option to be able to code up IGNORE=INTERLOCK like BACKUP.
Met vriendelijke groetjes,
Hein van den Heuvel
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-19-2007 01:34 AM
тАО03-19-2007 01:34 AM
Re: File size of Open File..
Than we will just use some very crude commands:
$ PIPE DIRECTORY -
SMSC_DAT1:[SMH00]smh00_own_file.dat -
/SIZE /GRAND_TOTAL | -
SEARCH SYS$INPUT "Grand total" /NUM /NOHIGHLIGHT | -
(READ SYS$INPUT TMPI ; -
TMPI = F$ELEMENT(12," ",TMPI) ; -
DEFINE/JOB/NOLOG TMP_RESULT &TMPI -
)
$ sho log TMP_RESULT
gr,
Robert
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-19-2007 01:59 AM
тАО03-19-2007 01:59 AM
Re: File size of Open File..
be carefull!
In case you have more than one version of your file, you will get the total size of all versions of this file.
You may change the Directory Command to
DIRECTORY -
SMSC_DAT1:[SMH00]smh00_own_file.dat; -
/SIZE/GRAND
(file.ext; or file.ext;0)
Regards
Heinz
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-19-2007 02:10 AM
тАО03-19-2007 02:10 AM
Re: File size of Open File..
Hmmm,
Why not use:
dir/size=allo/nohead/notrai/wid=file=200 xxx
The you do not need the SEARH.
Just pick up element 2 from a compressed string with space seperator
Oh... be sure to ask for the last version only.
$ PIPE DIRECTORY /size=allo/nohead/notrai/wid=file=100 X.X. | (READ SYS$INPUT X ; X=F$ELE(1," ",F$EDI(X,"COMPRESS")) ; DEF/JO XX &X)
Hein.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-19-2007 06:52 AM
тАО03-19-2007 06:52 AM
Re: File size of Open File..
Another (massively brute force, unsupported, subject to change without notice) approach would involve capturing and parsing the output of INSTALL.
What might you be up to here?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-19-2007 07:27 PM
тАО03-19-2007 07:27 PM
Re: File size of Open File..
Thanks for the reply's. The task at hand is as follows. We know this particular file can be very big. We want to know before we make a backup if the file will fit on a specific volume. But we want to know the size before the backup. While the file is still live, The file does not grow. Once it is created it has a fixed format.
That's why we try to do this.
gr,
Robert Verkerk.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-19-2007 10:54 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-19-2007 11:13 PM
тАО03-19-2007 11:13 PM
Re: File size of Open File..
Hein.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-20-2007 03:58 AM
тАО03-20-2007 03:58 AM
Re: File size of Open File..
Or consider compression. There are various tools that can compress data, including BACKUP and its latent compression. Most section files I've encountered would compress very nicely.
Or you can exclude this file from the operation, and potentially create a tool which maps to the section and extracts its data into a file that BACKUP can then process.