Jump to content











Photo
* * * * * 1 votes

"Panther" XP/2003 (deployment system)


  • Please log in to reply
58 replies to this topic

#1 thunn

thunn

    Silver Member

  • .script developer
  • 531 posts
  • Location:Brooklyn, New York
  • Interests:computers<br />mechanics<br />distortion<br /><br />
  •  
    United States

Posted 22 May 2008 - 06:05 AM

Posted Image

CPU independent Windows XP using WDS Beta from Longhorn

http://pantherxp.net

:thumbup:;)

Hello all...
For awhile now I've been working on a system to utilize the early (WIM based) Panther engine as a means of deploying WinXP and other NTLDR based Windows NT systems to hardware with different CPU types. After only a gahzillion test cycles... It's finally done. :thumbup:

Discovering the system HAL type (when the wrong HAL is installed) was the main issue at hand. Most system builders have, to date, used data stored in the registry to determine the system HAL type for similar image based deployments. This is not always a reliable means of checking the number of physical CPU cores though. If the wrong HAL is installed or used in a preinstallation environment, the registry will reflect the incorrect HAL type when queried. For this reason a small 3rd party tool was was discovered for the task of checking the number of CPU cores reliably (A huge thanks to Galapo for pointing me to Crystal Dew World). With this task performed correctly, sysprep may install a new HAL on request if needed.
:thumbup:

For those curious, scripted (autoit3) HAL swaps were also successfully tested, but sysprep works fine if the CPU type is reported accurately.

With the HAL detection issue overcome, I'm now updating some supporting web documents.

If this sounds like something interesting to you, a demo client image has been tested and uploaded. (please pm)

attached is a preliminary readme.

more details will follow.

--------------------
-edit-
attached readme is from an early release
the current client image readme is online here.
---------------------

-thuun

Attached Files



#2 TheHive

TheHive

    Platinum Member

  • .script developer
  • 4198 posts

Posted 22 May 2008 - 06:26 AM

Sounds like a great project.

#3 felix

felix

    Member

  • Members
  • 55 posts
  • Location:In the BOOT
  • Interests:Sports
  •  
    Italy

Posted 28 May 2008 - 12:21 PM

Long time no see my friend.
So you did it..Nice
;)

#4 thunn

thunn

    Silver Member

  • .script developer
  • 531 posts
  • Location:Brooklyn, New York
  • Interests:computers<br />mechanics<br />distortion<br /><br />
  •  
    United States

Posted 29 May 2008 - 10:01 AM

these are the cpu detect and cmdlines scripts...

&#58;&#58; ..............................................................

&#58;&#58;  ************************************************************

&#58;&#58;   &#34;Panther&#34; XP/2003 Postrest.cmd

&#58;&#58;   Copyright &#40;C&#41;2008 thuunderboy

&#58;&#58;

&#58;&#58;   CrystalCPUID &#40;C&#41;2008 hiyohiyo

&#58;&#58;   SpDrvScn &#40;C&#41;2006 Joseph Dowden

&#58;&#58;   7za &#40;C&#41;2007 Igor Pavlov

&#58;&#58;  ............................................................

&#58;&#58; **************************************************************



@echo off

setlocal



for %%d in &#40;C D E F G H I J K L M N O P Q R S T U V W X Y Z&#41; do if exist %%d&#58;\SOURCES\sysprep.inf &#40;

set dist_root=%%d&#58;

&#41;



set srcdir=%dist_root%\SOURCES\DIST

set oemdir=%srcdir%\$OEM$



cd %systemdrive%\sysprep || exit



&#58;&#58;

&#58;&#58; Get sysprep.inf from Dvd\SOURCES and add InstallFilesPath entry

&#58;&#58;

for %%a in &#40;sysprep.inf unattend.txt&#41; do if exist %dist_root%\SOURCES\%%a copy /y %dist_root%\SOURCES\%%a %~dp0

inimod.exe /F&#58;&#34;%systemdrive%\sysprep\sysprep.inf&#34; /AC /S&#58;&#34;Unattended&#34; /K&#58;&#34;InstallFilesPath&#34; /V&#58;&#34;%srcdir%\&#34;



&#58;&#58;

&#58;&#58; Detect CPU type and update HAL if multi processor

&#58;&#58;

start /wait CrystalCPUID.exe /s /e

if %errorlevel% neq 0 ver >nul

findstr /c&#58;&#34;Physical Core &#58; 1&#34; temp.txt

if %errorlevel% equ 0 &#40;

start presetup.exe -splash_uni

&#41; else if %errorlevel% equ 1 &#40;

inimod.exe /F&#58;&#34;%systemdrive%\sysprep\sysprep.inf&#34; /AC /S&#58;&#34;Unattended&#34; /K&#58;&#34;UpdateHAL&#34; /V&#58;&#34;ACPIAPIC_MP,%WINDIR%\Inf\Hal.inf&#34;

start presetup.exe -splash_multi

&#41;

ren temp.txt CrystalCPUID_%PROCESSOR_ARCHITECTURE%.log

for %%l in &#40;*.log&#41; do xcopy /y %%l %systemroot%\debug\



&#58;&#58;

&#58;&#58; Copy and expand OEM files to the install drive

&#58;&#58;

if exist %oemdir%\$$ xcopy /y /e %oemdir%\$$ %systemroot%\

if exist %oemdir%\$1 xcopy /y /e %oemdir%\$1 %systemdrive%\

if exist %oemdir%\$docs xcopy /y /e %oemdir%\$docs %systemdrive%\DOCUME~1\

if exist %oemdir%\$progs xcopy /y /e %oemdir%\$progs %systemdrive%\PROGRA~1\



for %%A in &#40;7z cab rar zip&#41; do &#40;

for %%F in &#40;%oemdir%\$$.%%A&#41; do 7za.exe x %%F -y -o%systemroot%

for %%F in &#40;%oemdir%\$1.%%A&#41; do 7za.exe x %%F -y -o%systemdrive%

for %%F in &#40;%oemdir%\$docs.%%A&#41; do 7za.exe x %%F -y -o%systemdrive%\DOCUME~1

for %%F in &#40;%oemdir%\$progs.%%A&#41; do 7za.exe x %%F -y -o%systemdrive%\PROGRA~1

&#41;



&#58;&#58;

&#58;&#58; Expand compressed drivers to the install drive

&#58;&#58;

start presetup.exe -splash_instdrvs

for /r &#34;%oemdir%\drivers\&#34; %%C in &#40;*.7z *.cab *.rar *.zip&#41; do &#40;

for %%D in &#40;%systemdrive%\sysprep\drivers\%%~nC&#41; do &#40;

7za.exe x &#34;%%C&#34; -y -o&#34;%%D&#34;

&#41;

&#41;



&#58;&#58;

&#58;&#58; Add driver folders to DevicePath key for Setup

&#58;&#58;

for %%d in &#40;

%oemdir%\drivers

%systemdrive%\sysprep\drivers

&#41; do if exist %%d &#40;

start /wait spdrvscn.exe /p %%~fd /e inf /i /f /a /s /q

&#41;



endlocal

exit


&#58;&#58; ..............................................................

&#58;&#58;  ************************************************************

&#58;&#58;   &#34;Panther&#34; XP/2003 pxpinst.cmd

&#58;&#58;   MiniSetup Cmdlines.txt script

&#58;&#58;   Copyright &#40;C&#41;2008 thuunderboy

&#58;&#58;  ............................................................

&#58;&#58; **************************************************************



@echo off

setlocal enableextensions



set srcdir=%~d0\SOURCES\DIST

set oemdir=%srcdir%\$oem$



set boot_text=XP Professional

set boot_args=/NOEXECUTE=ALWAYSOFF



set msi_args=/qn /norestart ALLUSERS=1

set type1_args=/q /n /o /z

set type2_args=/Q



set inst_drivers=no

set drivers_path=%oemdir%\drivers



set add_reboot=no

set add_shutdown=no



if &#34;%1&#34;==&#34;-c&#34; goto _clnup

if &#34;%1&#34;==&#34;-r&#34; goto _reboot

if &#34;%1&#34;==&#34;-s&#34; goto _shutdown



cd %oemdir% || goto _end



if %inst_drivers% equ yes &#40;

for /r &#34;%~d0\&#34; %%i in &#40;dpinst*.exe&#41; do &#40;

for %%d in &#40;%drivers_path%&#41; do if exist %%d start &#34;%%~ni&#34; /wait /min cmd /c %%i /Q /LM /SA /SE /SW /C /PATH %%d

&#41;

&#41;

for %%B in &#40;C D E F G H I J K L M N O P Q R S T U V W X Y Z&#41; do if exist %%B&#58;\boot.ini if exist %%B&#58;\ntldr &#40;

attrib -s -r -h %%B&#58;\boot.ini

findstr /c&#58;&#34;Longhorn&#34; %%B&#58;\boot.ini && replace.vbs %%B&#58;\boot.ini &#34;Longhorn&#34; &#34;%boot_text%&#34;

findstr /c&#58;&#34;/DETECTHAL&#34; %%B&#58;\boot.ini && replace.vbs %%B&#58;\boot.ini &#34;/DETECTHAL&#34; &#34;%boot_args%&#34;

for %%V in &#40;30 3 0&#41; do &#40;findstr /c&#58;&#34;timeout=%%V&#34; %%B&#58;\boot.ini && replace.vbs %%B&#58;\boot.ini &#34;timeout=%%V&#34; &#34;timeout=10&#34;&#41;

attrib +r +s +h %%B&#58;\boot.ini

if exist %%B&#58;\boot.bak &#40;

attrib -s -r -h %%B&#58;\boot.bak

move /y %%B&#58;\boot.bak %systemroot%\debug

&#41;

&#41;

move /y %systemdrive%\$WINDOWS.~BT\sources\Panther %systemroot%\debug

for %%D in &#40;BT LS&#41; do rd /s/q %systemdrive%\$WINDOWS.~%%D



start /wait %systemdrive%\sysprep\sysprep.exe -clean



reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce /v z_spSrcPath /d &#34;hidec /w reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Setup /v ServicePackSourcePath /d %srcdir%\ /f&#34; /f

reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce /v z_srcPath /d &#34;hidec /w reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Setup /v SourcePath /d %srcdir%\ /f&#34; /f

for %%R in &#40;&#34;HKLM\Software\Microsoft\Windows NT\CurrentVersion&#34; HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Setup&#41; do reg add %%R /v SourcePath /d %srcdir%\ /f

for %%V in &#40;&#34;Installation Sources&#34; ServicePackSourcePath&#41; do reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Setup /v %%V /d %srcdir%\ /f



for %%D in &#40;hotfixes updates&#41; do if exist %oemdir%\%%D set udpdir=%%D

for %%D in &#40;kbtype1 kb_type1 kb-type1 type1&#41; do if exist %oemdir%\%udpdir%\%%D set kb1dir=%%D

for %%D in &#40;kbtype2 kb_type2 kb-type2 type2&#41; do if exist %oemdir%\%udpdir%\%%D set kb2dir=%%D



for /r &#34;%oemdir%\%udpdir%\%kb1dir%\svcpack\&#34; %%K in &#40;*.exe&#41; do start &#34;%%~nK&#34; /wait /min cmd /c &#34;%%K&#34; %type1_args%

for /r &#34;%oemdir%\%udpdir%\%kb2dir%\svcpack\&#34; %%K in &#40;*.exe&#41; do start &#34;%%~nK&#34; /wait /min cmd /c &#34;%%K&#34; %type2_args%



if exist %oemdir%\%udpdir%\%kb1dir%\runonceex &#40;

for /r &#34;%oemdir%\%udpdir%\%kb1dir%\runonceex\&#34; %%K in &#40;*.exe&#41; do &#40;

reg add &#34;HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnceEx\%%~nK&#34; /ve /d &#34;%%~nK&#34; /f

reg add &#34;HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnceEx\%%~nK&#34; /v &#34;%%~nK&#34; /d &#34;&#34;&#34;&#34;%%K&#34;&#34;&#34; %type1_args%&#34; /f

&#41;

rundll32 iernonce.dll,RunOnceExProcess

&#41;



if exist %oemdir%\%udpdir%\%kb2dir%\runonceex &#40;

for /r &#34;%oemdir%\%udpdir%\%kb2dir%\runonceex\&#34; %%K in &#40;*.exe&#41; do &#40;

reg add &#34;HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnceEx\%%~nK&#34; /ve /d &#34;%%~nK&#34; /f

reg add &#34;HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnceEx\%%~nK&#34; /v &#34;%%~nK&#34; /d &#34;&#34;&#34;&#34;%%K&#34;&#34;&#34; %type2_args%&#34; /f

&#41;

rundll32 iernonce.dll,RunOnceExProcess

&#41;



if exist %oemdir%\runonceex &#40;

for /r &#34;%oemdir%\runonceex\&#34; %%I in &#40;*.exe&#41; do &#40;

reg add &#34;HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnceEx\%%~nI&#34; /ve /d &#34;%%~nI&#34; /f

reg add &#34;HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnceEx\%%~nI&#34; /v &#34;%%~nI&#34; /d &#34;&#34;&#34;&#34;%%I&#34;&#34;&#34;&#34; /f

&#41;

rundll32 iernonce.dll,RunOnceExProcess

&#41;



for /r &#34;%oemdir%\svcpack\&#34; %%R in &#40;*.reg&#41; do regedit /s &#34;%%R&#34;

for /r &#34;%oemdir%\svcpack\&#34; %%I in &#40;*.inf&#41; do rundll32 setupapi,InstallHinfSection DefaultInstall 132 &#34;%%I&#34;

for /r &#34;%oemdir%\svcpack\&#34; %%D in &#40;*.dll *.ocx *.ax&#41; do copy /y %%D %systemroot%\system32 && regsvr32 /s &#34;%systemroot%\system32\%%~nxD&#34;

for /r &#34;%oemdir%\svcpack\&#34; %%I in &#40;*.msi&#41; do start &#34;%%~nI&#34; /wait /min cmd /c msiexec /i &#34;%%I&#34; %msi_args%

for /r &#34;%oemdir%\svcpack\&#34; %%I in &#40;*.exe *.vbs *.bat *.cmd&#41; do start &#34;%%~nI&#34; /wait /min cmd /c &#34;%%I&#34;



for /r &#34;%oemdir%\%udpdir%\%kb1dir%\runonce\&#34; %%K in &#40;*.exe&#41; do reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce /v &#34;%%~nK&#34; /d &#34;&#34;&#34;&#34;%%K&#34;&#34;&#34; %type1_args%&#34; /f

for /r &#34;%oemdir%\%udpdir%\%kb2dir%\runonce\&#34; %%K in &#40;*.exe&#41; do reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce /v &#34;%%~nK&#34; /d &#34;&#34;&#34;&#34;%%K&#34;&#34;&#34; %type2_args%&#34; /f



for /r &#34;%oemdir%\runonce\&#34; %%R in &#40;*.reg&#41; do reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce /v &#34;z_%%~nR&#34; /d &#34;regedit /s &#34;&#34;&#34;%%R&#34;&#34;&#34;&#34; /f

for /r &#34;%oemdir%\runonce\&#34; %%I in &#40;*.inf&#41; do reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce /v &#34;z_%%~nI&#34; /d &#34;rundll32 setupapi,InstallHinfSection DefaultInstall 132 &#34;&#34;&#34;%%I&#34;&#34;&#34;&#34; /f

for /r &#34;%oemdir%\runonce\&#34; %%D in &#40;*.dll *.ocx *.ax&#41; do reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce /v &#34;z_%%~nD&#34; /d &#34;hidec /w cmd /c copy /y &#34;&#34;&#34;%%D&#34;&#34;&#34; %systemroot%\system32 && regsvr32 /s &#34;&#34;&#34;%systemroot%\system32\%%~nxD&#34;&#34;&#34;&#34; /f

for /r &#34;%oemdir%\runonce\&#34; %%I in &#40;*.msi&#41; do reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce /v &#34;z_%%~nI&#34; /d &#34;hidec /w cmd /c start &#34;&#34;&#34;%%~nI&#34;&#34;&#34; /wait /min msiexec /i &#34;&#34;&#34;%%I&#34;&#34;&#34; %msi_args%&#34; /f

for /r &#34;%oemdir%\runonce\&#34; %%I in &#40;*.exe *.vbs *.bat *.cmd&#41; do reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce /v &#34;z_%%~nI&#34; /d &#34;hidec /w cmd /c start &#34;&#34;&#34;%%~nI&#34;&#34;&#34; /wait /min &#34;&#34;&#34;%%I&#34;&#34;&#34;&#34; /f



reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce /v _cfg_hkcu /d &#34;rundll32 advpack.dll,LaunchINFSection %~d0\SOURCES\pxpinst.inf,PCL,PCU&#34; /f

reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce /v z_cleanup /d &#34;hidec /w %~f0 -c&#34; /f

rundll32 advpack.dll,LaunchINFSection %~d0\SOURCES\pxpinst.inf,DefaultInstall



if %add_shutdown% equ yes reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce /v zzz_shutdown /d &#34;hidec /w %~f0 -s&#34; /f &goto _end

if %add_reboot% equ yes reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce /v zzz_reboot /d &#34;hidec /w %~f0 -r&#34; /f

goto _end



&#58;_clnup

for %%D in &#40;&#34;%tmp%&#34; %systemroot%\Temp&#41; do &#40;

attrib -r -s -h /s /d %%D

rd /q/s %%D

if exist %%D &#40;

reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce /v &#91;%%D_zap&#93; /d &#34;hidec /w cmd /c rd /q/s %%D && md %%D&#34; /f

&#41; else md %%D

&#41;

for %%D in &#40;%systemroot%\$hf_mig$&#41; do rd /q/s %%D && md %%D && attrib +h /s /d %%D

for %%F in &#40;*.old *.tmp&#41; do del /q /s %systemroot%\%%F

move /y %systemroot%\*log.txt %systemroot%\debug

goto _end



&#58;_reboot

hidec /w shutdown -r -f -t 90 -c &#34;Rebooting momentarily, please wait...&#34;

goto _end



&#58;_shutdown

psshutdown -f -k -t 300



&#58;_end

endlocal

goto &#58;eof


......

#5 kickarse

kickarse

    Member

  • Members
  • 67 posts
  • Location:USA
  •  
    United States

Posted 13 June 2008 - 05:26 PM

Sounds great... but you still need to boot into PE after laying down an image in order to do this, no??

#6 Galapo

Galapo

    Platinum Member

  • .script developer
  • 3841 posts
  •  
    Australia

Posted 13 June 2008 - 09:09 PM

No need to boot into PE.

Regards,
Galapo.

#7 kickarse

kickarse

    Member

  • Members
  • 67 posts
  • Location:USA
  •  
    United States

Posted 13 June 2008 - 09:16 PM

Well if you need a beta tester just let me know. I've been doing the whole driverpacks/sysprep/hal thing for a while now. I'm also on the msfn.org forums (I wrote AutoWifi, UpdateHammer and DriverForge, USBeSafe).

Oh and do you think that it could be used for something like Acronis or Ghost imaging solutions?

#8 thunn

thunn

    Silver Member

  • .script developer
  • 531 posts
  • Location:Brooklyn, New York
  • Interests:computers<br />mechanics<br />distortion<br /><br />
  •  
    United States

Posted 20 June 2008 - 05:13 AM

Galapo has seen the project image,

You might think of Panther XP as an alternative to 'universal restore' by Acronis.
It uses the longhornpe, but does not have to. (These deployment systems all use sysprep, *just updated by MS)

Panther XP requires 1 reboot to go from PE to WinXP MiniSetup plus one more to finish and load the desktop. Thats.. err, um, ... 2.

:)

Please PM me and I'll provide a link for the client image.
...

I'm now creating a set of support tools to mount the beta wim image(s) and inject new files... :)

here's a peek ...

&#58;&#58; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

&#58;&#58;  &#34;Panther&#34; XP/2003 WinPE WIM Beta 1 Mount

&#58;&#58;  Copyright &#40;C&#41;2008 thuunderboy

&#58;&#58; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~



@echo off

title %~0



set safety=on



set wim_image=WinPE



set wim_index=1



set build_root=..\..\..



cd %build_root%



set build_root=%cd%



set svc_dir=%build_root%\support\service\svcres



if not exist %svc_dir%\%~n0%~x0 goto &#58;eof



call %svc_dir%\_set_env.cmd -def



set pthrxpdir=%workdrive%\PantherXP



set linkd_dir=%pthrxpdir%\%wim_image%



for %%i in &#40;C D E F G H I J K L M N O P Q R S T U V W X Y Z&#41; do if not exist %%i&#58; &#40;

set tmpdrv=%%i

&#41;



echo.&echo.&echo  &#34;Panther&#34; XP/2003 %~n0%~x0 &echo.

echo _______________________________________________________ &echo.



if exist %build_root%\sources\%wim_image%.wim &#40;

if %safety% neq off echo.&echo Ready to mount %wim_image%.WIM to Drive&#58; &#91;%tmpdrv%&#58;&#93; &echo.&echo. &pause &echo.

for %%L in &#40;%linkd_dir%&#41; do &#40;

if exist %%L_bak rd /s/q %%L_bak

if exist %%L ren %%L %%~nL_bak

md %%L

&#41;

echo.&echo VDCmd &#91;Version 1.0.0.3&#93; Copyright 2005 Kana Solution

%svc_dir%\vdcmd.exe -d=%tmpdrv% -p=&#34;%linkd_dir%&#34;

&#41; else echo.&echo %wim_image%.WIM file missing! &echo.



if exist %tmpdrv%&#58; &#40;

echo.&echo Virtual Drive&#58; &#91;%tmpdrv%&#58;&#93; mapped to&#58; &#91;%linkd_dir%&#93; &echo.

echo.&echo xImage &#91;Version 6.0.4059.0&#93; Copyright 2003 Microsoft Corporation

echo.&echo Applying&#58; &#91;%build_root%\sources\%wim_image%.wim {Index %wim_index%}&#93;

echo.&echo To Drive&#58; &#91;%tmpdrv%&#58;&#93;

%svc_dir%\ximage.exe /apply %build_root%\sources\%wim_image%.wim %tmpdrv%&#58; %wim_index%

&#41; else if exist %build_root%\sources\%wim_image%.wim &#40;

echo.&echo A drive letter must be made available to continue.

echo.&echo Ready to exit. &echo. 

&#41;



if &#34;%1&#34; neq &#34;-q&#34; pause

exit

--and no. 2 ...

&#58;&#58; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

&#58;&#58;  &#34;Panther&#34; XP/2003 WinPE Mass Storage Driver Injector

&#58;&#58;  Copyright &#40;C&#41;2008 thuunderboy

&#58;&#58; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~



@echo off

title %~0



set build_root=..\..\..



cd %build_root%



set build_root=%cd%



set svc_dir=%build_root%\support\service\svcres



if not exist %svc_dir%\%~n0%~x0 goto &#58;eof



call %svc_dir%\_set_env.cmd -def



set pthrxpdir=%workdrive%\PantherXP



set drvrep=%build_root%\sources\dist\$oem$\drivers\boot



set drvarc=%build_root%\support\service\driver_arc



set sys32_rep=%build_root%\sources\dist\$oem$\$$\system32



set pebld_tag=boot\system32\drivers\wimfsf.sys



for %%I in &#40;C D E F G H I J K L M N O P Q R S T U V W X Y Z&#41; do if exist %%I&#58;\%pebld_tag% &#40;

set pebld_root=%%I&#58;

&#41;



echo.&echo.&echo  &#34;Panther&#34; XP/2003 %~n0%~x0 &echo.

echo _______________________________________________________ &echo.



if exist %pebld_root%\%bld_tag% &#40;

echo.&echo Install target located at Drive&#58; &#91;%pebld_root%&#93;

&#41; else echo.&echo Install target not found. &echo.&pause &exit



for /r &#34;%drvarc%\&#34; %%C in &#40;*.7z *.cab *.rar *.zip&#41; do &#40;

for %%D in &#40;%drvrep%\%%~nC&#41; do &#40;

%sys32_rep%\7za.exe x &#34;%%C&#34; -y -o&#34;%%D&#34; >nul

echo.&echo Extracting %%~nC%%~xC to&#58;

echo %%D

&#41;

&#41;



echo.&echo Preparing to install driver packages . . .&echo.

for /r &#34;%drvrep%\&#34; /d %%D in &#40;*&#41; do &#40;

if exist %%D\*.inf cd %%D && for %%B in &#40;*.inf&#41; do &#40;

echo %%~nB

set drvsfound=true

&#41;

&#41;

if &#34;%drvsfound%&#34; neq &#34;true&#34; &#40;

echo. 

echo No drivers found. &echo.

echo Please place drivers into subfolders of&#58; &echo.&echo &#91;%drvrep%&#93;

echo.

pause

goto &#58;eof

&#41;

echo.

pause



ren &#34;%pebld_root%\boot&#34; &#34;Windows&#34;

ren %pebld_root%\Windows\system32\setupreg.hiv SYSTEM

move %pebld_root%\Windows\system32\SYSTEM %pebld_root%\Windows\system32\config\

md %pebld_root%\Users &#34;%pebld_root%\Program Files&#34;



for /r &#34;%drvrep%\&#34; %%M IN &#40;*.inf&#41; do &#40;

%svc_dir%\peimg.exe %pebld_root%\Windows /inf=&#34;%%M&#34;

echo. 

&#41;



ren &#34;%pebld_root%\Windows&#34; &#34;boot&#34;

ren %pebld_root%\boot\system32\config\SYSTEM setupreg.hiv

move %pebld_root%\boot\system32\config\setupreg.hiv %pebld_root%\boot\system32\

rd /s/q %pebld_root%\Users &#34;%pebld_root%\Program Files&#34;

rd /s/q %pebld_root%\boot\system32\DriverStore



set winpeoem_sif=%pebld_root%\boot\system32\winpeoem.sif

echo.&echo.&echo Updating &#34;%winpeoem_sif%&#34;. . . &echo.



if not exist %winpeoem_sif% &#40;

echo &#91;Version&#93;> %winpeoem_sif%

echo signature=&#34;$Windows NT$&#34;>> %winpeoem_sif% &echo.>> %winpeoem_sif%

&#41; else echo.>> %winpeoem_sif%



for /r &#34;%drvrep%\&#34; /d %%D in &#40;*&#41; do &#40;

if exist %%D\*.sys &#40;

cd %%D

for %%B in &#40;*.sys&#41; do %svc_dir%\inimod.exe /F&#58;&#34;%winpeoem_sif%&#34; /AC /S&#58;&#34;massstoragedrivers.append&#34; /K&#58;&#34;MassStorageDriver_%%~nB&#34; /V&#58;&#34;%%B&#34; >nul

&#41;

&#41;

type %winpeoem_sif% &echo.



if %errorlevel% neq 0 echo Exit code %errorlevel%.



echo.&echo Done.&echo.

if &#34;%1&#34; neq &#34;-q&#34; pause

exit

and unmount ...

&#58;&#58; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

&#58;&#58;  &#34;Panther&#34; XP/2003 WIM Beta 1 Unmount

&#58;&#58;  Copyright &#40;C&#41;2008 thuunderboy

&#58;&#58; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~



@echo off

title %~0



call %~dp0\_set_env.cmd -def



set pthrxpdir=%workdrive%\PantherXP



set tagfile_1=boot\system32\drivers\wimfsf.sys



set tagfile_2=sysprep\setact.exe



set unmount=all



set tmpdrv=



echo.&echo.&echo  &#34;Panther&#34; XP/2003 %~n0%~x0 &echo.

echo _______________________________________________________ &echo.



if not exist %pthrxpdir% md %pthrxpdir% &set pxpdir=removed

if not exist %pthrxpdir%\winpe md %pthrxpdir%\winpe &set pedir=removed

if not exist %pthrxpdir%\install md %pthrxpdir%\install &set instdir=removed



&#58;_unmount

for %%I in &#40;C D E F G H I J K L M N O P Q R S T U V W X Y Z&#41; do &#40;

if exist %%I&#58;\%tagfile_1% set tmpdrv=%%I

if exist %%I&#58;\%tagfile_2% set tmpdrv=%%I

&#41;



if not exist %tmpdrv%&#58; set tmpdrv=Z

if not exist %tmpdrv%&#58; set tmpdrv=Y

if not exist %tmpdrv%&#58; set tmpdrv=X

if not exist %tmpdrv%&#58; set tmpdrv=W

if not exist %tmpdrv%&#58; set tmpdrv=V

if not exist %tmpdrv%&#58; set tmpdrv=U

if not exist %tmpdrv%&#58; set tmpdrv=T

if not exist %tmpdrv%&#58; set tmpdrv=S

if not exist %tmpdrv%&#58; set tmpdrv=R

if not exist %tmpdrv%&#58; set tmpdrv=Q

if not exist %tmpdrv%&#58; set tmpdrv=P

if not exist %tmpdrv%&#58; set tmpdrv=O

if not exist %tmpdrv%&#58; set tmpdrv=N

if not exist %tmpdrv%&#58; set tmpdrv=M

if not exist %tmpdrv%&#58; set tmpdrv=L

if not exist %tmpdrv%&#58; set tmpdrv=K

if not exist %tmpdrv%&#58; set tmpdrv=J

if not exist %tmpdrv%&#58; set tmpdrv=I

if not exist %tmpdrv%&#58; set tmpdrv=H

if not exist %tmpdrv%&#58; set tmpdrv=G

if not exist %tmpdrv%&#58; set tmpdrv=F

if not exist %tmpdrv%&#58; set tmpdrv=E

if not exist %tmpdrv%&#58; set tmpdrv=D

if not exist %tmpdrv%&#58; set tmpdrv=C



start /wait /min subst /d %tmpdrv%&#58;



if not exist %tmpdrv%&#58; &#40;

goto _result

&#41; else set tmpdrv=Z

if not exist %tmpdrv%&#58; set tmpdrv=Y

if not exist %tmpdrv%&#58; set tmpdrv=X

if not exist %tmpdrv%&#58; set tmpdrv=W

if not exist %tmpdrv%&#58; set tmpdrv=V

if not exist %tmpdrv%&#58; set tmpdrv=U

if not exist %tmpdrv%&#58; set tmpdrv=T

if not exist %tmpdrv%&#58; set tmpdrv=S

if not exist %tmpdrv%&#58; set tmpdrv=R

if not exist %tmpdrv%&#58; set tmpdrv=Q

if not exist %tmpdrv%&#58; set tmpdrv=P

if not exist %tmpdrv%&#58; set tmpdrv=O

if not exist %tmpdrv%&#58; set tmpdrv=N

if not exist %tmpdrv%&#58; set tmpdrv=M

if not exist %tmpdrv%&#58; set tmpdrv=L

if not exist %tmpdrv%&#58; set tmpdrv=K

if not exist %tmpdrv%&#58; set tmpdrv=J

if not exist %tmpdrv%&#58; set tmpdrv=I

if not exist %tmpdrv%&#58; set tmpdrv=H

if not exist %tmpdrv%&#58; set tmpdrv=G

if not exist %tmpdrv%&#58; set tmpdrv=F

if not exist %tmpdrv%&#58; set tmpdrv=E

if not exist %tmpdrv%&#58; set tmpdrv=D

if not exist %tmpdrv%&#58; set tmpdrv=C



start /wait /min subst /d %tmpdrv%&#58;



&#58;_result

if not exist %tmpdrv%&#58; &#40;

echo.&echo Virtual Drive &#91;%tmpdrv%&#58;&#93; unmounted.

if %unmount% equ all goto _unmount

&#41; else if %unmount% equ all &#40;

echo.&echo All Virtual Drives unmounted.

&#41; else echo.&echo Done.

echo.&echo.



if &#34;%pedir%&#34;==&#34;removed&#34; rd /q/s %pthrxpdir%\winpe

if &#34;%instdir%&#34;==&#34;removed&#34; rd /q/s %pthrxpdir%\install

if &#34;%pxpdir%&#34;==&#34;removed&#34; rd /q/s %pthrxpdir%



if &#34;%1&#34; neq &#34;-q&#34; pause

exit

--there are now over a dozen servicing commands in all, plus new docs.

Once everything is finalized it will be made available for widespread use.
So far it's going good and is quite fun to work on, so it'll be done soon and something posted here.

...
btw...

* The new xp.5512 sp3 opk update is now out
It has a new sysprep (v 5512) which adds an update cycle to my project.
what the hell.

:)

-t

#9 Galapo

Galapo

    Platinum Member

  • .script developer
  • 3841 posts
  •  
    Australia

Posted 20 June 2008 - 06:14 AM

Your project continues to impress me! Seems a good idea to me to automate mounting and injection so as to prevent mistakes people might make. A side effect is that such automated commands help to document the process and what is carried out without actually writing a help file per se (I personally hate writing documentation!).

Regards,
Galapo.

#10 kickarse

kickarse

    Member

  • Members
  • 67 posts
  • Location:USA
  •  
    United States

Posted 17 July 2008 - 12:12 AM

Any updates??

I'm looking forward to trying this, but I'm not familiar with deploying WIM images. Could this work with ghost or acronis??

#11 was_jaclaz

was_jaclaz

    Finder

  • Advanced user
  • 7101 posts
  • Location:Gone in the mist
  •  
    Italy

Posted 17 July 2008 - 07:51 AM

Any updates??

I'm looking forward to trying this, but I'm not familiar with deploying WIM images. Could this work with ghost or acronis??


Updates about what? :cheers:

A bit of advice, if I may:
before attempting modifying a method, always try it EXACTLY as it is, get the hang of it, try understanding how it works, then, and only then you can try starting to modify it to suit your expectations.

jaclaz

#12 kickarse

kickarse

    Member

  • Members
  • 67 posts
  • Location:USA
  •  
    United States

Posted 17 July 2008 - 02:48 PM

Updates about what? :cheers:

A bit of advice, if I may:
before attempting modifying a method, always try it EXACTLY as it is, get the hang of it, try understanding how it works, then, and only then you can try starting to modify it to suit your expectations.

jaclaz


I completely agree and understand that. I feel the same way. The questions was just that, a question to find out if it'll work with ghost. That's all.

I was just curious if WIM was the only way this would work. But it seems that that's the only method he's working on or will be working on.

#13 was_jaclaz

was_jaclaz

    Finder

  • Advanced user
  • 7101 posts
  • Location:Gone in the mist
  •  
    Italy

Posted 17 July 2008 - 06:08 PM

I completely agree and understand that. I feel the same way. The questions was just that, a question to find out if it'll work with ghost. That's all.

I was just curious if WIM was the only way this would work. But it seems that that's the only method he's working on or will be working on.


As I see it, but I may be completely and utterly wrong, of course :cheers:, the same approach could work with .img (RAW images) or .sdi images, that can be read through RAMDISK or through filedisk, IMDISK or VDK.

AFAIK both Ghost and Acronis use proprietary format images, for which I cannot say if a "filedisk like" driver capable of mounting those images exists (or is given together with the respective Commercial product).

FYI, this "Panther XP" project has some points in common with a project born on MSFN:
http://www.boot-land...?showtopic=3549

jaclaz

#14 thunn

thunn

    Silver Member

  • .script developer
  • 531 posts
  • Location:Brooklyn, New York
  • Interests:computers<br />mechanics<br />distortion<br /><br />
  •  
    United States

Posted 08 September 2008 - 02:56 AM

I know this project present confusion to some. Please understand this is somewhat intented.

Currently a project webpage is in progress to answer a few common question Ive received.

http://thuun.boot-land.net/PantherXP

#15 Galapo

Galapo

    Platinum Member

  • .script developer
  • 3841 posts
  •  
    Australia

Posted 08 September 2008 - 04:46 AM

Looks like it's coming together nicely! As always, good work.

Regards,
Galapo.

#16 Siginet

Siginet

    Frequent Member

  • .script developer
  • 173 posts
  •  
    United States

Posted 09 September 2008 - 11:25 PM

Hey thunn... long time no see. :huh: My username over at 911cd.net was L3th4l I used to be a big time user of the bart disk and used many of your plugins. :huh: So I am sure this project is a great one as well. :)

This may be a little off topic but it is a question I have wondered for a while...

Is it possible to change the HAL info on a hard drive that is allready installed without having to re-image the drive and re-deploying it to the system? Currently I use Acronis True Image with the Universal Restore option when I need to transfer a drive from one machine into a new system. But I think it would be great if there was a simple way for me to rip out the HAL info from the drive... remove the drive from the system... pop the drive into the new system... boot it up... and not get a blue screen of death due to mismatching HAL types. Your project seems to deal with the same issue but from a different angle. Is there any way possible for me to accomplish this without re-imaging?

#17 Galapo

Galapo

    Platinum Member

  • .script developer
  • 3841 posts
  •  
    Australia

Posted 09 September 2008 - 11:43 PM

Hi Siginet,

You may use OfflineSysPrep to set HAL of your choosing or let it set the one matching your hardware.

Regards,
Galapo.

#18 Siginet

Siginet

    Frequent Member

  • .script developer
  • 173 posts
  •  
    United States

Posted 10 September 2008 - 12:43 AM

sweet! Thanks Galapo!

#19 MedEvil

MedEvil

    Platinum Member

  • .script developer
  • 7771 posts

Posted 10 September 2008 - 12:53 AM

Or simply in the boot.ini HAL=...

:huh:

#20 kickarse

kickarse

    Member

  • Members
  • 67 posts
  • Location:USA
  •  
    United States

Posted 19 September 2008 - 06:22 PM

Or simply in the boot.ini HAL=...

:huh:


I'm curious if this options
/numproc = number
/NUMPROC= Specifies the number of CPUs that can be used on a multiprocessor system. Example: /NUMPROC=2 on a four-way system will prevent Windows from using two of the four processors.
/ONECPU = Causes Windows to use only one CPU on a multiprocessor system.

would enable a multiprocessor machine the ability to boot a uniprocessor hal?

#21 MedEvil

MedEvil

    Platinum Member

  • .script developer
  • 7771 posts

Posted 19 September 2008 - 07:08 PM

Don't know, if i've got you right.
But you can use a uniprocessor hal + a uniprocessor kernel also on a multiprocessor machine. (look at PE)
But only 1 CPU will work of course.

:huh:

#22 kickarse

kickarse

    Member

  • Members
  • 67 posts
  • Location:USA
  •  
    United States

Posted 19 September 2008 - 07:48 PM

I know I was just stating that I was curious if these options in boot.ini would work with a multiprocessor machine.

#23 MedEvil

MedEvil

    Platinum Member

  • .script developer
  • 7771 posts

Posted 19 September 2008 - 09:01 PM

I know I was just stating that I was curious if these options in boot.ini would work with a multiprocessor machine.

:huh:
I would suspect so, as they were pretty useless on a single processor system.

:huh:

#24 kickarse

kickarse

    Member

  • Members
  • 67 posts
  • Location:USA
  •  
    United States

Posted 20 September 2008 - 11:35 AM

:huh:
I would suspect so, as they were pretty useless on a single processor system.

:huh:


I meant in regards to sysprep... :)

#25 MedEvil

MedEvil

    Platinum Member

  • .script developer
  • 7771 posts

Posted 20 September 2008 - 06:33 PM

I meant in regards to sysprep... :huh:

:huh: What has sysprep to do with boot.ini parameters?

:)




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users