Video Screencast Help

Diskpart script not running before deploying Windows 7 via Altiris 7.1

Created: 10 Jan 2013 • Updated: 11 Jan 2013 | 3 comments
This issue has been solved. See solution.

Need a solution as to why diskpart clean is not running via a task.  This prevents us from deploying Windows 7 properly with Altiris 7.1. We are able to successfully deploy Windows 7 via Altiris 6.9 using the same script.  

In altiris 6.9 we are calling on a .txt file named "dpclean.txt".  Here are the contents of the file:

Select disk 0


In Altiris 6.9, the .txt file is located in .\Libarary\dpclean.txt.  This is the command that we run to call on the file:

diskpart /s ".\Library\dpclean.txt"

In Altiris 7.1, we've created the same file and placed it in the same directory our image files are located on a 2008 site server.  The directory is: \\site server\deployment\task handler\image

I've created a run script task with the following command:


diskpart /s "\\site server\deployment\task handler\image\dpclean.txt"


The "PAUSE" command is for troubleshooting purposes and to see what errors appear.  

This is what appears "diskpart was unable to open or read the script file".  

Any ideas or suggestions is appreciated as I'm fairly new to the Altiris 7.1 world.  

Comments 3 CommentsJump to latest comment

andykn101's picture

I think your problem is that the PECTAgent running the diskpart command can't access the \\site server unless you completely relax share and folder permissions on it.

Authorised Symantec Consultant (ASC) with Endpoint Management Limited, an Authorised Symantec Delivery Provider based in the UK.

Connect Etiquette: Please "Mark as Solution" posts that fix your problem.

CBaelum's picture

You could have your Run Task make a local dpclean.txt file.

Make the task contain this:


echo Select Disk 0 > dpclean.txt

echo clean >> dpclean.txt

diskpart /s dpclean.txt


This would make a file called dpclean.txt in the root of the automation partition disk.

This way you could still maintain what is in the dpclean.txt file in one place instead of having to replace files.

mcos1979's picture

Thanks for the replies all!  It looks creating the script locally did the trick.  The permissions were going to be my last resort as we would have had to clear that with our security folks.  Again,  thanks for the help!