无忧启动论坛
标题:
请大侠指点下,为什么我这一键制作WIM的bat制作出来的蓝屏?
[打印本页]
作者:
2012yangyf
时间:
2012-12-27 23:38
标题:
请大侠指点下,为什么我这一键制作WIM的bat制作出来的蓝屏?
请大侠指点下,为什么我这一键制作WIM的bat制作出来的,加载完进度条后,出项win2003启动画面之前,蓝屏?
一键WIM制作包百度网盘地址:
http://pan.baidu.com/share/link?shareid=162124&uk=1308952287
原意是想做个IMG用VDM加载后,直接转化为WIM的BAT.系统是冷风的Win2003EE版,WIM小于300MB.
麻烦各位高手下载下来帮我看下,感激不尽!
3.开始转换.bat
@ECHO OFF
set var=A
set var2=D
ECHO ┌─────────────────────────────────┐
ECHO │首先,需要把原系统文件复制到新目录下,方便制作。 │
ECHO └─────────────────────────────────┘
set /p var=请输入从哪个盘复制文件 C/D/E/F...(默认A盘):
set /p var2=请输入复制文件到哪个盘 C/D/E/F...(默认D盘):
ECHO ┌─────────────────────────────────┐
ECHO │您选择的是从%var%盘复制到%var2%盘BOOT目录下,请确认后按任意键继续 │
ECHO └─────────────────────────────────┘
pause >nul
robocopy.exe "%var%:\WINDOWS" "%var2%:\BOOT\WINDOWS" /E /ZB /COPYALL /R:5 /W:10 /xf *.tmp *.bak *.log *.jpg *.png *.pnf *.gif *.txt *.html *.ico IconCache.db *.PF *.bmp *.gid *.old *.chm *.htm *.mp3 *.EVT
robocopy.exe "%var%:\Program Files" "%var2%:\BOOT\Program Files" /E /ZB /COPYALL /R:5 /W:10 /xf *.tmp *.bak *.log *.jpg *.ico *.pnf *.gif *.txt *.html IconCache.db *.PF *.bmp *.gid *.old *.chm *.htm *.mp3 *.EVT
robocopy.exe "%var%:\Documents and Settings" "%var2%:\BOOT\Documents and Settings" /E /ZB /COPYALL /R:5 /W:10 /xf *.tmp *.bak *.log *.jpg *.png *.pnf *.gif *.txt *.html *.ico IconCache.db *.PF *.bmp *.gid *.old *.chm *.htm *.mp3 *.EVT
xcopy %var%:\SsRd????.cif %var2%:\BOOT /H /R /K /Y 2>nul
ECHO ┌─────────────────────────────────┐
ECHO │复制完成。查看上面汇总结果的"FAILED"列表数是否为0 │
ECHO │若无大量文件复制失败,则按任意键继续优化清理... │
ECHO └─────────────────────────────────┘
pause >nul
ECHO ┌─────────────────────────────────┐
ECHO │清除文件夹 │
ECHO └─────────────────────────────────┘
rd /s /q %var2%:\BOOT\windows\ADAM 2>nul
rd /s /q %var2%:\BOOT\windows\addins 2>nul
rd /s /q %var2%:\BOOT\windows\ADFS 2>nul
rd /s /q %var2%:\BOOT\windows\Cursors 2>nul
rd /s /q %var2%:\BOOT\windows\Debug 2>nul
rd /s /q %var2%:\BOOT\windows\Help 2>nul
rd /s /q %var2%:\BOOT\windows\ime 2>nul
rd /s /q %var2%:\BOOT\windows\Installer 2>nul
rd /s /q %var2%:\BOOT\windows\java 2>nul
rd /s /q %var2%:\BOOT\windows\LastGood 2>nul
rd /s /q %var2%:\BOOT\windows\LastGood.Tmp 2>nul
rd /s /q %var2%:\BOOT\windows\Logs 2>nul
rd /s /q %var2%:\BOOT\windows\Media 2>nul
rd /s /q %var2%:\BOOT\windows\msapps 2>nul
rd /s /q %var2%:\BOOT\windows\mui 2>nul
rd /s /q "%var2%:\BOOT\windows\Offline Web Pages" 2>nul
rd /s /q "%var2%:\BOOT\windows\Downloaded Installations" 2>nul
rd /s /q %var2%:\BOOT\windows\RegisteredPackages 2>nul
rd /s /q %var2%:\BOOT\windows\WinSxS\InstallTemp 2>nul
rd /s /q %var2%:\BOOT\windows\prefetch 2>nul
rd /s /q %var2%:\BOOT\windows\repair 2>nul
rd /s /q %var2%:\BOOT\windows\security 2>nul
rd /s /q %var2%:\BOOT\windows\Web 2>nul
rd /s /q %var2%:\BOOT\windows\temp 2>nul
rd /s /q %var2%:\BOOT\windows\system32\1025 2>nul
rd /s /q %var2%:\BOOT\windows\system32\1028 2>nul
rd /s /q %var2%:\BOOT\windows\system32\1031 2>nul
rd /s /q %var2%:\BOOT\windows\system32\1033 2>nul
rd /s /q %var2%:\BOOT\windows\system32\1037 2>nul
rd /s /q %var2%:\BOOT\windows\system32\1041 2>nul
rd /s /q %var2%:\BOOT\windows\system32\1042 2>nul
rd /s /q %var2%:\BOOT\windows\system32\1054 2>nul
rd /s /q %var2%:\BOOT\windows\system32\2052 2>nul
rd /s /q %var2%:\BOOT\windows\system32\3076 2>nul
rd /s /q %var2%:\BOOT\windows\system32\3com_dmi 2>nul
rd /s /q %var2%:\BOOT\windows\system32\administration 2>nul
rd /s /q %var2%:\BOOT\windows\system32\dllcache 2>nul
rd /s /q %var2%:\BOOT\windows\system32\dhcp 2>nul
rd /s /q %var2%:\BOOT\windows\system32\export 2>nul
rd /s /q %var2%:\BOOT\windows\system32\lls 2>nul
rd /s /q %var2%:\BOOT\windows\system32\LogFiles 2>nul
rd /s /q %var2%:\BOOT\windows\system32\ReinstallBackups 2>nul
rd /s /q %var2%:\BOOT\windows\system32\ShellExt 2>nul
rd /s /q %var2%:\BOOT\windows\system32\Setup 2>nul
rd /s /q %var2%:\BOOT\windows\system32\spool\drivers\w32x86 2>nul
rd /s /q %var2%:\BOOT\windows\system32\spool\PRINTERS 2>nul
rd /s /q %var2%:\BOOT\windows\system32\spool\prtprocs 2>nul
rd /s /q %var2%:\BOOT\windows\system32\wins 2>nul
rd /s /q %var2%:\BOOT\windows\system32\config\systemprofile 2>nul
ECHO ┌─────────────────────────────────┐
ECHO │清除文件 │
ECHO └─────────────────────────────────┘
del /f /s /q %var2%:\BOOT\windows\*.bak 2>nul
del /f /s /q %var2%:\BOOT\windows\*.log 2>nul
del /f /s /q %var2%:\BOOT\windows\*.old 2>nul
del /f /s /q %var2%:\BOOT\windows\*.tmp 2>nul
del /f /s /q %var2%:\BOOT\windows\*.txt 2>nul
del /f /s /q %var2%:\BOOT\windows\*.lnk 2>nul
del /f /s /q %var2%:\BOOT\windows\_default.pif 2>nul
del /f /s /q %var2%:\BOOT\windows\desktop.ini 2>nul
del /f /s /q %var2%:\BOOT\windows\system.ini 2>nul
del /f /s /q %var2%:\BOOT\windows\win.ini 2>nul
del /f /s /q %var2%:\BOOT\windows\inf\*.PNF 2>nul
del /f /s /q %var2%:\BOOT\windows\control.ini 2>nul
del /f /s /q %var2%:\BOOT\windows\inf\mdm*.* 2>nul
del /f /s /q %var2%:\BOOT\windows\system32\config\*.Evt 2>nul
del /f /s /q %var2%:\BOOT\windows\system32\config\*.sav 2>nul
del /f /s /q %var2%:\BOOT\windows\system32\config\*.LOG 2>nul
del /f /s /q %var2%:\BOOT\windows\system32\config\*.DEL 2>nul
del /f /s /q %var2%:\BOOT\windows\system32\KBDFR.DLL 2>nul
del /f /s /q %var2%:\BOOT\windows\system32\KBDGR.DLL 2>nul
del /f /s /q %var2%:\BOOT\windows\system32\KBDIT.DLL 2>nul
del /f /s /q %var2%:\BOOT\windows\system32\winntbbu.dll 2>nul
del /f /s /q %var2%:\BOOT\windows\system32\tp4.hlp 2>nul
del /f /s /q "%var2%:\BOOT\Documents and Settings\Administrator\Recent\*.*" 2>nul
del /f /s /q "%var2%:\BOOT\Documents and Settings\Administrator\Local Settings\History\*.*" 2>nul
del /f /s /q "%var2%:\BOOT\Documents and Settings\Administrator\recent\*.*" 2>nul
ECHO ┌─────────────────────────────────┐
ECHO │复制驱动文件 │
ECHO └─────────────────────────────────┘
attrib -a -h -r -s %var2%:\BOOT\WINDOWS\system32\drivers\wimfsf.sys >nul
attrib -a -h -r -s %var2%:\BOOT\WINDOWS\system32\drivers\wimfltr.sys >nul
attrib -a -h -r -s %var2%:\BOOT\WINDOWS\system32\drivers\ramdisk.sys >nul
attrib -a -h -r -s %var2%:\BOOT\WINDOWS\system32\drivers\fbwf.sys >nul
attrib -a -h -r -s %var2%:\BOOT\WINDOWS\system32\halmacpi.dll >nul
attrib -a -h -r -s %var2%:\BOOT\WINDOWS\system32\winload.exe >nul
attrib -a -h -r -s %var2%:\BOOT\WINDOWS\system32\ntkrnlpa.exe >nul
attrib -a -h -r -s %var2%:\BOOT\WINDOWS\inf\wimfltr.inf >nul
attrib -a -h -r -s %var2%:\BOOT\WINDOWS\inf\ramdisk.inf >nul
attrib -a -h -r -s %var2%:\BOOT\fbwf.cfg >nul
copy .\WIMboot\wimfsf.sys %var2%:\BOOT\WINDOWS\system32\drivers\ /y
copy .\WIMboot\wimfltr.sys %var2%:\BOOT\WINDOWS\system32\drivers\ /y
copy .\WIMboot\ramdisk.sys %var2%:\BOOT\WINDOWS\system32\drivers\ /y
copy .\WIMboot\fbwf.sys %var2%:\BOOT\WINDOWS\system32\drivers\ /y
copy .\WIMboot\halmacpi.dll %var2%:\BOOT\WINDOWS\system32\ /y
copy .\WIMboot\winload.exe %var2%:\BOOT\WINDOWS\system32\ /y
copy .\WIMboot\ntkrnlpa.exe %var2%:\BOOT\WINDOWS\system32\ /y
copy .\WIMboot\wimfltr.inf %var2%:\BOOT\WINDOWS\inf\ /y
copy .\WIMboot\ramdisk.inf %var2%:\BOOT\WINDOWS\inf\ /y
copy .\WIMboot\fbwf.cfg %var2%:\BOOT\ /y
ECHO ┌─────────────────────────────────┐
ECHO │加载注册表 │
ECHO └─────────────────────────────────┘
reg load HKLM\sys %var2%:\BOOT\windows\system32\config\system
IF ERRORLEVEL 1 echo 加载注册表失败,按任意键退出。 &pause>nul &exit
ECHO ┌─────────────────────────────────┐
ECHO │导入wim驱动 │
ECHO └─────────────────────────────────┘
regedit /s .\WIMboot\wimboot.reg
ECHO ┌─────────────────────────────────┐
ECHO │删除X盘符 │
ECHO └─────────────────────────────────┘
reg delete hklm\SYS\MountedDevices /v \DosDevices\x: /f
ECHO ┌─────────────────────────────────┐
ECHO │卸载注册表 │
ECHO └─────────────────────────────────┘
reg unload HKLM\sys
IF ERRORLEVEL 1 echo 卸载注册表失败,按任意键退出。 &pause>nul &exit
ECHO ┌─────────────────────────────────┐
ECHO │开始打包%var2%:\BOOT下文件为 %var2%:\RAMOS.wim 按任意键继续... │
ECHO └─────────────────────────────────┘
pause >nul
del %var2%:\RAMOS.wim
imagex /capture %var2%:\BOOT %var2%:\RAMOS.wim "RAMOS" /boot /compress maximum
copy %var2%:\RAMOS.wim C:\boot\
ECHO ┌─────────────────────────────────┐
ECHO │打包完毕,已自动复制到C盘。请仔细查看CMD窗口有无出错提示! │
ECHO └─────────────────────────────────┘
pause >nul
复制代码
[
本帖最后由 2012yangyf 于 2012-12-28 13:38 编辑
]
作者:
2012yangyf
时间:
2012-12-28 13:31
这是原bat,这制作的可以成功,我就是照这改的:
@echo off
color 70
ECHO 说 明
ECHO ---------------------------------------------------------
ECHO.
ECHO 移植已经安装好的 WINXP、2K3 系统为 WIM 的 RAMOS 。
ECHO.
ECHO 系统 默认为administrator登录,系统 默认为“X盘”系统(系统安装方法请百度)
ECHO.
ECHO.
ECHO. 本处理参考菜鸟论坛Q大教程,制作过程得到菜鸟论坛:鑫源,路飞,dummy等各位大神指导,在此一并感谢
ECHO. 归零 (QQ群:112102870;245855821) 2012.12.22
ECHO -------------------------------------------------------------------------------
PAUSE
echo 完成等待。
cls
@echo. 选择您需要做系统的window所在盘(D/E/F/G/H..如果复制过文件请按M)
ECHO.
ECHO. 若启动wim后发现新硬件安装完新硬件后导出注册表system配置单元
ECHO.
ECHO. 拷贝至E:\BOOT\WINDOWS\SYSTEM32\CONFIG 目录替换后按M重新打包wim
ECHO -------------------------------------------------------------------------------
set shut=""
set /p shut="请输入 【 <D> 或 <E> 或 <F> 或 <G> 或 <H> 或 <I>或 <J> 或 <X> 或 <q>退出】 并按回车键 :"
IF NOT "%shut%"=="" (
if %shut% NEQ "" SET shut=%shut:~0,1%
) else (
set shut="")
if /i %shut%==c goto RAM1
if /i %shut%==d goto RAM2
if /i %shut%==e goto RAM3
if /i %shut%==f goto RAM4
if /i %shut%==g goto RAM5
if /i %shut%==h goto RAM6
if /i %shut%==i goto RAM7
if /i %shut%==j goto RAM8
if /i %shut%==x goto RAM9
if /i %shut%==m goto RAM0
if /i %shut%==q exit
:RAM1
@echo.
@echo 您选择的是E:\sys\gbak盘,任意键继续。。。
pause
echo 请等待》》》》》》》
robocopy.exe >nul "E:\sys\gbak\WINDOWS" "e:\boot\WINDOWS" /E /ZB /COPYALL /R:5 /W:10 /xf *.tmp *.bak *.log *.jpg *.png *.pnf *.gif *.txt *.html *.ico IconCache.db *.PF *.bmp *.gid *.old *.chm *.htm *.mp3 *.EVT
robocopy.exe >nul "E:\sys\gbak\Program Files" "e:\boot\Program Files" /E /ZB /COPYALL /R:5 /W:10 /xf *.tmp *.bak *.log *.jpg *.ico *.pnf *.gif *.txt *.html IconCache.db *.PF *.bmp *.gid *.old *.chm *.htm *.mp3 *.EVT
robocopy.exe >nul "E:\sys\gbak\Documents and Settings" "e:\boot\Documents and Settings" /E /ZB /COPYALL /R:5 /W:10 /xf *.tmp *.bak *.log *.jpg *.png *.pnf *.gif *.txt *.html *.ico IconCache.db *.PF *.bmp *.gid *.old *.chm *.htm *.mp3 *.EVT
sleep.exe 9000
echo 完成等待。
goto RAM0
:RAM2
@echo.
@echo 您选择的是D盘,任意键继续。。。
pause
echo 请等待》》》》》》》
robocopy.exe >nul "D:\WINDOWS" "E:\BOOT\WINDOWS" /E /ZB /COPYALL /R:5 /W:10 /xf *.tmp *.bak *.log *.jpg *.png *.pnf *.gif *.txt *.html *.ico IconCache.db *.PF *.bmp *.gid *.old *.chm *.htm *.mp3 *.EVT
robocopy.exe >nul "D:\Program Files" "E:\BOOT\Program Files" /E /ZB /COPYALL /R:5 /W:10 /xf *.tmp *.bak *.log *.jpg *.ico *.pnf *.gif *.txt *.html IconCache.db *.PF *.bmp *.gid *.old *.chm *.htm *.mp3 *.EVT
robocopy.exe >nul "D:\Documents and Settings" "E:\BOOT\Documents and Settings" /E /ZB /COPYALL /R:5 /W:10 /xf *.tmp *.bak *.log *.jpg *.png *.pnf *.gif *.txt *.html *.ico IconCache.db *.PF *.bmp *.gid *.old *.chm *.htm *.mp3 *.EVT
sleep.exe 9000
echo 完成等待。
goto RAM0
:RAM3
@echo.
@echo 您选择的是E盘,任意键继续。。。
pause
echo 请等待》》》》》》》
robocopy.exe >nul "E:\WINDOWS" "E:\BOOT\WINDOWS" /E /ZB /COPYALL /R:5 /W:10 /xf *.tmp *.bak *.log *.jpg *.png *.pnf *.gif *.txt *.html *.ico IconCache.db *.PF *.bmp *.gid *.old *.chm *.htm *.mp3 *.EVT
robocopy.exe >nul "E:\Program Files" "E:\BOOT\Program Files" /E /ZB /COPYALL /R:5 /W:10 /xf *.tmp *.bak *.log *.jpg *.ico *.pnf *.gif *.txt *.html IconCache.db *.PF *.bmp *.gid *.old *.chm *.htm *.mp3 *.EVT
robocopy.exe >nul "E:\Documents and Settings" "E:\BOOT\Documents and Settings" /E /ZB /COPYALL /R:5 /W:10 /xf *.tmp *.bak *.log *.jpg *.png *.pnf *.gif *.txt *.html *.ico IconCache.db *.PF *.bmp *.gid *.old *.chm *.htm *.mp3 *.EVT
sleep.exe 9000
echo 完成等待。
goto RAM0
:RAM4
@echo.
@echo 您选择的是F盘,任意键继续。。。
pause
echo 请等待》》》》》》》
robocopy.exe >nul "F:\WINDOWS" "E:\BOOT\WINDOWS" /E /ZB /COPYALL /R:5 /W:10 /xf *.tmp *.bak *.log *.jpg *.png *.pnf *.gif *.txt *.html *.ico IconCache.db *.PF *.bmp *.gid *.old *.chm *.htm *.mp3 *.EVT
robocopy.exe >nul "F:\Program Files" "E:\BOOT\Program Files" /E /ZB /COPYALL /R:5 /W:10 /xf *.tmp *.bak *.log *.jpg *.ico *.pnf *.gif *.txt *.html IconCache.db *.PF *.bmp *.gid *.old *.chm *.htm *.mp3 *.EVT
robocopy.exe >nul "F:\Documents and Settings" "E:\BOOT\Documents and Settings" /E /ZB /COPYALL /R:5 /W:10 /xf *.tmp *.bak *.log *.jpg *.png *.pnf *.gif *.txt *.html *.ico IconCache.db *.PF *.bmp *.gid *.old *.chm *.htm *.mp3 *.EVT
sleep.exe 9000
echo 完成等待。
goto RAM0
:RAM5
@echo.
@echo 您选择的是G盘,任意键继续。。。
pause
echo 请等待》》》》》》》
robocopy.exe >nul "G:\WINDOWS" "E:\BOOT\WINDOWS" /E /ZB /COPYALL /R:5 /W:10 /xf *.tmp *.bak *.log *.jpg *.png *.pnf *.gif *.txt *.html *.ico IconCache.db *.PF *.bmp *.gid *.old *.chm *.htm *.mp3 *.EVT
robocopy.exe >nul "G:\Program Files" "E:\BOOT\Program Files" /E /ZB /COPYALL /R:5 /W:10 /xf *.tmp *.bak *.log *.jpg *.ico *.pnf *.gif *.txt *.html IconCache.db *.PF *.bmp *.gid *.old *.chm *.htm *.mp3 *.EVT
robocopy.exe >nul "G:\Documents and Settings" "E:\BOOT\Documents and Settings" /E /ZB /COPYALL /R:5 /W:10 /xf *.tmp *.bak *.log *.jpg *.png *.pnf *.gif *.txt *.html *.ico IconCache.db *.PF *.bmp *.gid *.old *.chm *.htm *.mp3 *.EVT
sleep.exe 9000
echo 完成等待。
goto RAM0
:RAM6
@echo.
@echo 您选择的是H盘,任意键继续。。。
pause
echo 请等待》》》》》》》
robocopy.exe >nul "H:\WINDOWS" "E:\BOOT\WINDOWS" /E /ZB /COPYALL /R:5 /W:10 /xf *.tmp *.bak *.log *.jpg *.png *.pnf *.gif *.txt *.html *.ico IconCache.db *.PF *.bmp *.gid *.old *.chm *.htm *.mp3 *.EVT
robocopy.exe >nul "H:\Program Files" "E:\BOOT\Program Files" /E /ZB /COPYALL /R:5 /W:10 /xf *.tmp *.bak *.log *.jpg *.ico *.pnf *.gif *.txt *.html IconCache.db *.PF *.bmp *.gid *.old *.chm *.htm *.mp3 *.EVT
robocopy.exe >nul "H:\Documents and Settings" "E:\BOOT\Documents and Settings" /E /ZB /COPYALL /R:5 /W:10 /xf *.tmp *.bak *.log *.jpg *.png *.pnf *.gif *.txt *.html *.ico IconCache.db *.PF *.bmp *.gid *.old *.chm *.htm *.mp3 *.EVT
sleep.exe 9000
echo 完成等待。
goto RAM0
:RAM7
@echo.
@echo 您选择的是I盘,任意键继续。。。
pause
echo 请等待》》》》》》》
robocopy.exe >nul "I:\WINDOWS" "E:\BOOT\WINDOWS" /E /ZB /COPYALL /R:5 /W:10 /xf *.tmp *.bak *.log *.jpg *.png *.pnf *.gif *.txt *.html *.ico IconCache.db *.PF *.bmp *.gid *.old *.chm *.htm *.mp3 *.EVT
robocopy.exe >nul "I:\Program Files" "E:\BOOT\Program Files" /E /ZB /COPYALL /R:5 /W:10 /xf *.tmp *.bak *.log *.jpg *.ico *.pnf *.gif *.txt *.html IconCache.db *.PF *.bmp *.gid *.old *.chm *.htm *.mp3 *.EVT
robocopy.exe >nul "I:\Documents and Settings" "E:\BOOT\Documents and Settings" /E /ZB /COPYALL /R:5 /W:10 /xf *.tmp *.bak *.log *.jpg *.png *.pnf *.gif *.txt *.html *.ico IconCache.db *.PF *.bmp *.gid *.old *.chm *.htm *.mp3 *.EVT
sleep.exe 9000
echo 完成等待。
goto RAM0
:RAM8
@echo.
@echo 您选择的是J盘,任意键继续。。。
pause
echo 请等待》》》》》》》
robocopy.exe >nul "J:\WINDOWS" "E:\BOOT\WINDOWS" /E /ZB /COPYALL /R:5 /W:10 /xf *.tmp *.bak *.log *.jpg *.png *.pnf *.gif *.txt *.html *.ico IconCache.db *.PF *.bmp *.gid *.old *.chm *.htm *.mp3 *.EVT
robocopy.exe >nul "J:\Program Files" "E:\BOOT\Program Files" /E /ZB /COPYALL /R:5 /W:10 /xf *.tmp *.bak *.log *.jpg *.ico *.pnf *.gif *.txt *.html IconCache.db *.PF *.bmp *.gid *.old *.chm *.htm *.mp3 *.EVT
robocopy.exe >nul "J:\Documents and Settings" "E:\BOOT\Documents and Settings" /E /ZB /COPYALL /R:5 /W:10 /xf *.tmp *.bak *.log *.jpg *.png *.pnf *.gif *.txt *.html *.ico IconCache.db *.PF *.bmp *.gid *.old *.chm *.htm *.mp3 *.EVT
sleep.exe 9000
echo 完成等待。
goto RAM0
:RAM9
@echo.
@echo 您选择的是K盘,任意键继续。。。
pause
echo 请等待》》》》》》》
robocopy.exe >nul "K:\WINDOWS" "E:\BOOT\WINDOWS" /E /ZB /COPYALL /R:5 /W:10 /xf *.tmp *.bak *.log *.jpg *.png *.pnf *.gif *.txt *.html *.ico IconCache.db *.PF *.bmp *.gid *.old *.chm *.htm *.mp3 *.EVT
robocopy.exe >nul "K:\Program Files" "E:\BOOT\Program Files" /E /ZB /COPYALL /R:5 /W:10 /xf *.tmp *.bak *.log *.jpg *.ico *.pnf *.gif *.txt *.html IconCache.db *.PF *.bmp *.gid *.old *.chm *.htm *.mp3 *.EVT
robocopy.exe >nul "K:\Documents and Settings" "E:\BOOT\Documents and Settings" /E /ZB /COPYALL /R:5 /W:10 /xf *.tmp *.bak *.log *.jpg *.png *.pnf *.gif *.txt *.html *.ico IconCache.db *.PF *.bmp *.gid *.old *.chm *.htm *.mp3 *.EVT
sleep.exe 9000
echo 完成等待。
goto RAM0
:RAM0
echo 清除文件夹
rd /s /q E:\BOOT\windows\ADAM
rd /s /q E:\BOOT\windows\addins
rd /s /q E:\BOOT\windows\ADFS
rd /s /q E:\BOOT\windows\Cursors
rd /s /q E:\BOOT\windows\Debug
rd /s /q E:\BOOT\windows\Help
rd /s /q E:\BOOT\windows\ime
rd /s /q E:\BOOT\windows\Installer
rd /s /q E:\BOOT\windows\java
rd /s /q E:\BOOT\windows\LastGood
rd /s /q E:\BOOT\windows\LastGood.Tmp
rd /s /q E:\BOOT\windows\Logs
rd /s /q E:\BOOT\windows\Media
rd /s /q E:\BOOT\windows\msapps
rd /s /q E:\BOOT\windows\mui
rd /s /q "E:\BOOT\windows\Offline Web Pages"
rd /s /q "E:\BOOT\windows\Downloaded Installations"
rd /s /q E:\BOOT\windows\RegisteredPackages
rd /s /q E:\BOOT\windows\WinSxS\InstallTemp
rd /s /q E:\BOOT\windows\prefetch
rd /s /q E:\BOOT\windows\repair
rd /s /q E:\BOOT\windows\security
rd /s /q E:\BOOT\windows\Web
rd /s /q E:\BOOT\windows\temp
rd /s /q E:\BOOT\windows\system32\1025
rd /s /q E:\BOOT\windows\system32\1028
rd /s /q E:\BOOT\windows\system32\1031
rd /s /q E:\BOOT\windows\system32\1033
rd /s /q E:\BOOT\windows\system32\1037
rd /s /q E:\BOOT\windows\system32\1041
rd /s /q E:\BOOT\windows\system32\1042
rd /s /q E:\BOOT\windows\system32\1054
rd /s /q E:\BOOT\windows\system32\2052
rd /s /q E:\BOOT\windows\system32\3076
rd /s /q E:\BOOT\windows\system32\3com_dmi
rd /s /q E:\BOOT\windows\system32\administration
rd /s /q E:\BOOT\windows\system32\dllcache
rd /s /q E:\BOOT\windows\system32\dhcp
rd /s /q E:\BOOT\windows\system32\export
rd /s /q E:\BOOT\windows\system32\lls
rd /s /q E:\BOOT\windows\system32\LogFiles
rd /s /q E:\BOOT\windows\system32\ReinstallBackups
rd /s /q E:\BOOT\windows\system32\ShellExt
rd /s /q E:\BOOT\windows\system32\Setup
rd /s /q E:\BOOT\windows\system32\spool\drivers\w32x86
rd /s /q E:\BOOT\windows\system32\spool\PRINTERS
rd /s /q E:\BOOT\windows\system32\spool\prtprocs
rd /s /q E:\BOOT\windows\system32\wins
rd /s /q E:\BOOT\windows\system32\config\systemprofile
echo 清除文件
del /f /s /q E:\BOOT\windows\*.bak
del /f /s /q E:\BOOT\windows\*.log
del /f /s /q E:\BOOT\windows\*.old
del /f /s /q E:\BOOT\windows\*.tmp
del /f /s /q E:\BOOT\windows\*.txt
del /f /s /q E:\BOOT\windows\*.lnk
del /f /s /q E:\BOOT\windows\_default.pif
del /f /s /q E:\BOOT\windows\desktop.ini
del /f /s /q E:\BOOT\windows\system.ini
del /f /s /q E:\BOOT\windows\win.ini
del /f /s /q E:\BOOT\windows\inf\*.PNF
del /f /s /q E:\BOOT\windows\control.ini
del /f /s /q E:\BOOT\windows\inf\mdm*.*
del /f /s /q E:\BOOT\windows\system32\config\*.Evt
del /f /s /q E:\BOOT\windows\system32\config\*.sav
del /f /s /q E:\BOOT\windows\system32\config\*.LOG
del /f /s /q E:\BOOT\windows\system32\config\*.DEL
del /f /s /q E:\BOOT\windows\system32\KBDFR.DLL
del /f /s /q E:\BOOT\windows\system32\KBDGR.DLL
del /f /s /q E:\BOOT\windows\system32\KBDIT.DLL
del /f /s /q E:\BOOT\windows\system32\winntbbu.dll
del /f /s /q E:\BOOT\windows\system32\tp4.hlp
del /f /s /q "E:\BOOT\Documents and Settings\Administrator\Recent\*.*"
del /f /s /q "E:\BOOT\Documents and Settings\Administrator\Local Settings\History\*.*"
del /f /s /q "E:\BOOT\Documents and Settings\Administrator\recent\*.*"
ECHO ---------------------------------------------------------
echo 备份A盘注册表
echo 复制相关文件
echo.
ECHO ---------------------------------------------------------
copy E:\BOOT\windows\system32\config\system . /y >nul
copy .\WIMboot\*.sys E:\BOOT\WINDOWS\system32\drivers\ /y >nul
Rem copy .\WIMboot\*.dll E:\BOOT\WINDOWS\system32\ /y >nul
copy .\WIMboot\*.exe E:\BOOT\WINDOWS\system32\ /y >nul
copy .\WIMboot\halmacpi.dll E:\BOOT\WINDOWS\system32\ /y >nul
copy .\WIMboot\*.inf E:\BOOT\WINDOWS\inf\ /y >nul
copy .\WIMboot\fbwf.cfg E:\BOOT\ /y >nul
echo 加载注册表
echo.
reg load HKLM\sys E:\BOOT\windows\system32\config\system >nul 2>nul
if errorlevel 1 (
echo 注册表加载出错
goto fail
)
echo 设置Enum注册表可操作权限
setacl -on "hklm\SYS\ControlSet001\Enum" -ot reg -actn ace -ace "n:everyone;p:full;m:grant;w:dacl" -actn setprot -op "dacl:p_nc" >nul
echo 导入wim驱动
regedit /s .\WIMboot\wimboot.reg
echo 删除 X 盘符 wim驱动
rem reg delete HKEY_LOCAL_MACHINE\SYSTEM\MountedDevices /v \DosDevices\x: /f
reg delete hklm\SYS\MountedDevices /v \DosDevices\x: /f rem check to see if x drier has been deleted.*********important this value should be delete before make wim
echo.
reg unload HKLM\sys >nul 2>nul
if errorlevel 1 (
echo 注册表断开出错
goto fail
)
echo 注册表修改完成。
echo.
echo 请等待》》》》》》》
sleep.exe 9000
echo 完成等待。
@ ECHO.
ECHO ---------------------------------------------------------
ECHO.
ECHO 自动打包 %wimpath%\ 下文件为 C:\boot\boota.wim ...
ECHO.
ECHO ---------------------------------------------------------
pause
del C:\boot\boota.wim >nul
imagex /capture E:\BOOT C:\boot\boota.wim "boota" /boot /compress maximum
ECHO ---------------------------------------------------------
echo 请等待》》》》》》》
sleep.exe 9000
echo 完成等待。
echo 打包完毕。重启后,体验 RAMOS 的魅力吧!
pause
复制代码
文件内容:
[一键win2003,xpWIM]
database.mdb
imagex.exe
REGEDT.EXE
robocopy.exe
sleep.exe
启动项管理.cfg
启动项管理.exe
使用方法.txt
一键WIMRAMOS.bat
注册表垃圾清理器.exe
文件总数 = 10
-------------------------------
[boot]
bcd
bcd.LOG
bcd16384
bcd26384
bcdokbackup
bcdokversion
boot.sdi
BOOTICE.EXE
bootmgr.exe
pxeboot.n12
文件总数 = 10
----------------------------
[WIMboot]
fbwf.cfg
fbwf.sys
halmacpi.dll
ntkrnlpa.exe
ramdisk.inf
ramdisk.sys
wimboot.reg
wimfltr.inf
wimfltr.sys
wimfsf.sys
winload.exe
复件 wimboota.reg
文件总数 = 12
作者:
buypro
时间:
2013-1-1 14:48
你不都已经制作成功了吗
能成功一次,就应该具有了可重复行。除非你硬件环境有了改变。 bat改了后出现蓝屏。只能说明bat 有问题
建议你排除法再查查
作者:
buypro
时间:
2013-1-1 14:52
建议成功后用wimtool打包。wim会小点。
建议删除administrator 用新的账号。wim也会小不少。
作者:
buypro
时间:
2013-1-1 14:55
还有如果你用了我的bcd.
如果是pxe启动的话。只适合千兆网卡。百兆可能会卡住。
请自行修改bcd中有关blockzise的参数。
欢迎光临 无忧启动论坛 (http://bbs.wuyou.net/)
Powered by Discuz! X3.3