- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - OpenVMS
- >
- File still locked after being closed
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
Forums
Discussions
Discussions
Discussions
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
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-08-2007 05:18 AM
03-08-2007 05:18 AM
"The process cannot access the file because it is being used by another process."
Have any of you run across this, and is there anything that I can do about it? Might it be a VMS problem?
Thanks!
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-08-2007 06:36 AM
03-08-2007 06:36 AM
Re: File still locked after being closed
what does SHOW DEV/FILES show for that device?
Purely Personal Opinion
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-08-2007 06:43 AM
03-08-2007 06:43 AM
Re: File still locked after being closed
By the time I got the notice on my pager and got logged in, the FTP worked. The SHOW DEV/FILES didn't show the file.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-08-2007 09:02 AM
03-08-2007 09:02 AM
Re: File still locked after being closed
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-08-2007 09:09 AM
03-08-2007 09:09 AM
Re: File still locked after being closed
Thanks!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-08-2007 09:26 AM
03-08-2007 09:26 AM
Re: File still locked after being closed
(This is a guess.)
I've seen similar sequences and errors here, and switching over to the COPY/FTP command makes for easier coding, and it removes the reliance on an FTP script-based mechanism.
COPY/FTP was first available in V6.2, with a compliant IP stack.
If this isn't it, can you post the version info for OpenVMS and IP and Rdb, and an example of the particular LOCKED failure, of the command(s) involved, and the related error messages?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-08-2007 09:45 AM
03-08-2007 09:45 AM
Re: File still locked after being closed
1) This is the job that unloads the data and submits the FTP job:
$ wo f$time()
7-MAR-2007 22:43:42.84
$ rmu/unload/virtual_fields/record_definition=-
(file=DISK$DGA207:[DATABASE_UNLOAD]COURSE_DATA,format=delimited_text,-
prefix="",separator="|",suffix="")-
STUDENT_db COURSE_DATA DISK$DGA207:[DATABASE_UNLOAD]COURSE_DATA.unl
%RMU-I-DATRECUNL, 3004445 data records unloaded.
$ wo f$time()
7-MAR-2007 23:02:18.96
$!
$! We don't care about the record description (.RRD) file
$ delete/log DISK$DGA207:[DATABASE_UNLOAD]COURSE_DATA.rrd;*
%DELETE-I-FILDEL, DISK$DGA207:[DATABASE_UNLOAD]COURSE_DATA.RRD;1 deleted (171 blocks)
$!
$ if f$mode() .eqs. "INTERACTIVE"
$ else
$ logfile_name := -
sys$common:[sysmgr]database_unload_ftp.log_COURSE_DATA
$ wait 00:00:05
$ submit-
/log="SYS$COMMON:[SYSMGR]DATABASE_UNLOAD_FTP.LOG_COURSE_DATA"/noprint -
/queue = STUDENT_unload_ftp$batch -
/param=("STUDENT","COURSE_DATA","DISK$DGA207:[DATABASE_UNLOAD]") -
sys$manager:database_unload_ftp
Job DATABASE_UNLOAD_FTP (queue STUDENT_UNLOAD_FTP$BATCH, entry 3627) started on
STUDENT_UNLOAD_FTP$BATCH
$ endif
2) This the FTP job:
.
.
.
$ open/write ftp_commands -
sys$manager:database_unload_ftp.cmd_COURSE_DATA
$ write ftp_commands username
$ write ftp_commands password
$ write ftp_commands "enable log"
$ write ftp_commands "enable reply"
$ write ftp_commands "put DISK$DGA207:[DATABASE_UNLOAD]COURSE_DATA.unl"
$ write ftp_commands "quit"
$ close ftp_commands
$!
$ wo "Starting FTP of STUDENT.COURSE_DATA at 7-MAR-2007 23:02:24.67"
Starting FTP of STUDENT.COURSE_DATA at 7-MAR-2007 23:02:24.67
$ set noon
$ loop_count = 0
$!
$DO_THE_FTP:
$ ftp TAHOE -
/input=sys$manager:database_unload_ftp.cmd_COURSE_DATA
220 tahoe Microsoft FTP Service (Version 5.0).
Connected to TAHOE.
331 Password required for fusr_stu.
230-Sierra College SIS FTP Site
230-Unauthorized Access Prohibited
230 User fusr_stu logged in.
Bell off.
Debugging on (debug=1).
Reply on.
Verbose mode on.
---> PORT 10,10,2,154,206,111
200 PORT command successful.
---> STOR course_data.unl
550 course_data.unl: The process cannot access the file because it is being used
by another process.
---> QUIT
221
$ if ($status .eqs. "%X176499F2") - ! The UNL file is still open
.or. ($status .eqs. "%X17649B42")
$ then
$ save_status = $status
$ loop_count = loop_count + 1
$ if loop_count .gt. 5
$ endif
$ wait 00:00:05
$ goto do_the_ftp
(does this up to 5 times before giving up)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-08-2007 10:52 AM
03-08-2007 10:52 AM
SolutionI'd check the input with a SHOW DEVICE/FILE prior to the COPY/FTP, and I'd take a very careful look to determine if this is an error being returned from the Microsoft FTP server or from the Windows box.
To test for the latter error case, I'd change the RMU export and the COPY/FTP to select a different filename on OpenVMS (and I'd probably also pick a more unique filename), and pass over the name course_data.unl as the target filename.
Something like this:
$ copy/ftp -
rmu_unload_'pid_time_string'.data -
x.y.z"user pass"::course_data.unl
The error resulting from a failure of this FTP command will tell you if the error was from the rmu_unload-whatsit file on the OpenVMS end, or from the course_data.unl file on the Windows end.
Right now, it's not entirely clear (to me) which is triggering this. But I'd tend to guess that it's the Windows box. The 550 class errors from FTP are usually returned from the target; from the remote host. Permission errors. Read-only errors. Etc. I'd not expect an FTP client to return a 550 for a local file access problem.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-08-2007 11:25 AM
03-08-2007 11:25 AM
Re: File still locked after being closed
The reason that I was using FTP/input was to have the Windows password in the command file so it doesn't show up in the .LOG files. (I delete the command file that FTP uses right after the FTP is done.)
Changing the target file name is an interesting idea. I'd have to modify the DTS job on the Windows box to look for the "other" file name. Plus I'm sure there would be other gotchas!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-08-2007 11:26 AM
03-08-2007 11:26 AM
Re: File still locked after being closed
> returned from the target;
All the numbered messages are returned from
the server/target/remote system. The arrows,
"--->", identify what the client is sending
out. The things without arrows are the
server's responses. This is a problem on the
FTP server. The server's message may or may
not accurately describe the problem, but
that's where it is.
COPY /FTP /VERBOSE should show you all that
junk, too, so that's not a good excuse for
avoiding COPY /FTP. A "more unique filename"
(which is to say, a unique file name) sounds
like a good idea to me.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-08-2007 12:12 PM
03-08-2007 12:12 PM
Re: File still locked after being closed
Changing the target file name is an interesting idea. I'd have to modify the DTS job on the Windows box to look for the "other" file name.
<<<
Why? I'd rename the temporary file on the OpenVMS side from the RMU up through the COPY/FTP for testing purposes, and I'd transfer the file over (with an explicit rename operation, since you can pick the target file during COPY/FTP) under the original and classic filename; what the current Windows software expects. You have full control over the OpenVMS side, after all.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-12-2007 05:06 AM
03-12-2007 05:06 AM