J is a network drive. STAFProc in not a window service, it is started from a
command prompt.
No luck even try specifying the SHELL option.
"STAF local FS LIST DIRECTORY "D:/Temp/Silk/Apps/Harmony" failed. By the way,
when I use xcopy from STAF to copy files to a destination, does the destination
have to exist?
Thanks,
Cindy
From: Sharon Lucas [mailto:luc...@us.ibm.com]
Sent: April-13-11 4:49 PM
To: Cindy Zhu
Subject: Re: FW: [staf-users] Delete a folder with subfolders and read-only
files
Try specifying the SHELL option on the PROCESS START request.
Is J: a network drive not a local drive?
Does the following fail as well? STAF local FS LIST DIRECTORY
"D:/Temp/Silk/Apps/Harmony"
How are you starting STAFProc? If you're starting STAFProc as a Windows
service then STAFProc may not be able to access files on network drives. So,
try shutting down STAF and restarting it from a command prompt and retry the
PROCESS START request to see if that resolves the problem.
--------------------------------------------------------------
Sharon Lucas
IBM Austin, luc...@us.ibm.com
(512) 286-7313 or Tieline 363-7313
From: Cindy Zhu <c...@fekete.com>
To: Sharon Lucas/Austin/IBM@IBMUS
Date: 04/13/2011 05:31 PM
Subject: FW: [staf-users] Delete a folder with subfolders and read-only
files
________________________________
Sorry, there is a mistake in my previous email.
I know this DOS command "xcopy J:\Automation\Silk\Apps\Harmony\*.*
D:\Temp\Silk\Apps\Harmony\*.* /e /h" can remove the read-only attribute while
copying files on windows. I tried it and it worked for me.
But when I use STAF command "STAF local PROCESS START COMMAND "xcopy
J:\Automation\Silk\Apps\Harmony\*.* D:\Temp\Silk\Apps\Harmony\*.* /e /h"
RETURNSTDOUT STDERRTOSTDOUT WAIT", nothing was copied over and I got this error:
Response
------------
{
Return Code: 0
Key: <None>
Files: [
{
Return Code: 0
Data:0
}
]
}
Please help.
Thanks,
Cindy
From: Cindy Zhu
Sent: April-13-11 4:24 PM
To: 'Sharon Lucas'
Subject: RE: [staf-users] Delete a folder with subfolders and read-only files
I know this DOS command "xcopy J:\Automation\Silk\Apps\Harmony\*.*
D:\Temp\Silk\Apps\Harmony\*.* /e /h" can remove the read-only attribute while
copying files on windows. I tried it and it worked for me.
But when I use STAF command "STAF local PROCESS COMMAND "xcopy
J:\Automation\Silk\Apps\Harmony\*.* D:\Temp\Silk\Apps\Harmony\*.* /e /h"
RETURNSTDOUT STDERRTOSTDOUT WAIT", nothing was copied over and I got this error:
Response
------------
{
Return Code: 0
Key: <None>
Files: [
{
Return Code: 0
Data:0
}
]
}
Please help.
Thanks,
Cindy
From: Sharon Lucas [mailto:luc...@us.ibm.com]
Sent: April-13-11 2:48 PM
To: Cindy Zhu
Subject: RE: [staf-users] Delete a folder with subfolders and read-only files
An absolute path.
--------------------------------------------------------------
Sharon Lucas
IBM Austin, luc...@us.ibm.com
(512) 286-7313 or Tieline 363-7313
From: Cindy Zhu <c...@fekete.com>
To: Sharon Lucas/Austin/IBM@IBMUS
Date: 04/13/2011 03:47 PM
Subject: RE: [staf-users] Delete a folder with subfolders and read-only
files
________________________________
Hi Sharon,
"/tmp/myfiles" is relative path or absolute path?
Thanks,
Cindy
From: Sharon Lucas [mailto:luc...@us.ibm.com]
Sent: April-13-11 1:50 PM
To: Cindy Zhu
Cc: staf-users@lists.sourceforge.net
Subject: Re: [staf-users] Delete a folder with subfolders and read-only files
To delete a folder and all of its contents including subdirectories, you can
use the STAF FS service's DELETE ENTRY request with the RECURSE option. For
example:
STAF machine FS DELETE ENTRY /tmp/myfiles RECURSE CONFIRM
However, this won't delete any read-only files.
So, you could either change the permissions of any read-only files contained
within the directory so that they are not read only (e.g. using a STAF PROCESS
START request to run an OS command like chmod, etc) before using the STAF FS
DELETE request.
Or, you could run an OS command that allows you to delete read-only files. For
example, on Unix machines like Linux, you could use the "rm -Rf" command with
the Recursive and Force options to remove a directory and all of its contents
including subdirectories and read-only files. For example:
STAF machine PROCESS START SHELL COMMAND "rm -Rf /tmp/myfiles" RETURNSTDOUT
STDERRTOSTDOUT WAIT
--------------------------------------------------------------
Sharon Lucas
IBM Austin, luc...@us.ibm.com
(512) 286-7313 or Tieline 363-7313
From: Cindy Zhu <c...@fekete.com>
To: "staf-users@lists.sourceforge.net" <staf-users@lists.sourceforge.net>
Date: 04/13/2011 02:32 PM
Subject: [staf-users] Delete a folder with subfolders and read-only files
________________________________
Hi,
How to delete a folder with subfolders and read-only files from STAF command?
Thanks,
Cindy
------------------------------------------------------------------------------
Benefiting from Server Virtualization: Beyond Initial Workload
Consolidation -- Increasing the use of server virtualization is a top
priority.Virtualization can reduce costs, simplify management, and improve
application availability and disaster protection. Learn more about boosting
the value of server virtualization.
http://p.sf.net/sfu/vmware-sfdev2dev_______________________________________________
staf-users mailing list
staf-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/staf-users
------------------------------------------------------------------------------
Benefiting from Server Virtualization: Beyond Initial Workload
Consolidation -- Increasing the use of server virtualization is a top
priority.Virtualization can reduce costs, simplify management, and improve
application availability and disaster protection. Learn more about boosting
the value of server virtualization. http://p.sf.net/sfu/vmware-sfdev2dev
_______________________________________________
staf-users mailing list
staf-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/staf-users