Microsoft MVP성태의 닷넷 이야기
Windows: 36. Windows PE ISO 이미지 만들기 [링크 복사], [링크+제목 복사],
조회: 38105
글쓴 사람
정성태 (techsharer at outlook.com)
홈페이지
첨부 파일
 
(연관된 글이 4개 있습니다.)

Windows PE ISO 이미지 만들기


의외로 PE에 대한 자료가 웹에 많이 있어서 만들어 보는 것이 그다지 어렵지 않았습니다. 우선, technet에 소개된 마이크로소프트의 자료가 있고,

Windows PE 이미지 만들기 (Vista)
; https://learn.microsoft.com/en-us/previous-versions/windows/it-pro/windows-vista/cc766066(v=ws.10)

Windows PE와는 다른 "Bart PE"를 소개한 글들도 있습니다.

Bart's Preinstalled Environment (BartPE) bootable live windows CD/DVD
; http://www.nu2.nu/pebuilder/

PE Builder를 이용 BartPE(Windows PE) 만들기
; http://itka.kr/zbxe/?mid=oswindows&sort_index=readed_count&order_type=desc&document_srl=2231

제가 선택한 방법은 Bart PE가 아닌 Windows PE였습니다. 선택 기준은 ^^ 뚜렷하지 않았고 단지 지속적으로 향상될 가능성이라는 면에서 택한 것 뿐입니다. 게다가 복잡할 것 같은 이런 과정을 쭉 정리해준 아래의 글이 있어서 제법 쉽게 할 수 있었습니다. ^^

WINDOWS DESKTOP MANAGEMENT TIPS
How to create a Windows Vista boot CD with WinPE
; http://searchenterprisedesktop.techtarget.com/tip/0,289483,sid192_gci1297757,00.html?track=sy43&asrc=RSS_RSS-2_43

그럼, 한번 따라해 볼까요? ^^




1. AIK 다운로드


아래의 사이트에서 AIK를 다운로드, 설치합니다.

Automated Installation Kit (AIK) for Windows Vista SP1 and Windows Server 2008
; http://www.microsoft.com/downloads/details.aspx?FamilyId=94BB6E34-D890-4932-81A5-5B50C657DE08

[그림 1: Windows AIK Setup]
vista_windows_pe_install_1.png

2. PE 파일 복사

설치된 프로그램 "Windows PE Tools Command Prompt"를 실행시키면 다음과 같은 창이 보입니다. 시작 폴더가 "%ProgramFiles%\Windows AIK\Tools\PETools"임을 확인합니다.

[그림 2: "Windows PE Tools Command Prompt" 실행]
vista_windows_pe_install_2.png

이제 새로운 폴더로 PE 파일을 복사합니다. 이때 대상이 되는 폴더가 미리 생성되어 있으면 안됩니다. 예를 들어, 저 같은 경우에는 E:\VistaPE라는 경로를 지정했고, 이때 VistaPE라는 이름의 폴더는 없는 상태입니다. 아래는 실행 결과입니다.

E:\Program Files\Windows AIK\Tools\PETools>CopyPE x86 e:\VistaPE

===================================================
Creating Windows PE customization working directory

    e:\VistaPE
===================================================

        1 file(s) copied.
        1 file(s) copied.
E:\Program Files\Windows AIK\Tools\PETools\X86\boot\bcd
E:\Program Files\Windows AIK\Tools\PETools\X86\boot\boot.sdi
E:\Program Files\Windows AIK\Tools\PETools\X86\boot\bootfix.bin
E:\Program Files\Windows AIK\Tools\PETools\X86\boot\etfsboot.com
E:\Program Files\Windows AIK\Tools\PETools\X86\boot\fonts\chs_boot.ttf
E:\Program Files\Windows AIK\Tools\PETools\X86\boot\fonts\cht_boot.ttf
E:\Program Files\Windows AIK\Tools\PETools\X86\boot\fonts\jpn_boot.ttf
E:\Program Files\Windows AIK\Tools\PETools\X86\boot\fonts\kor_boot.ttf
E:\Program Files\Windows AIK\Tools\PETools\X86\boot\fonts\wgl4_boot.ttf
9 File(s) copied
E:\Program Files\Windows AIK\Tools\PETools\X86\EFI\microsoft\boot\bcd
E:\Program Files\Windows AIK\Tools\PETools\X86\EFI\microsoft\boot\fonts\chs_boot.ttf
E:\Program Files\Windows AIK\Tools\PETools\X86\EFI\microsoft\boot\fonts\cht_boot.ttf
E:\Program Files\Windows AIK\Tools\PETools\X86\EFI\microsoft\boot\fonts\jpn_boot.ttf
E:\Program Files\Windows AIK\Tools\PETools\X86\EFI\microsoft\boot\fonts\kor_boot.ttf
E:\Program Files\Windows AIK\Tools\PETools\X86\EFI\microsoft\boot\fonts\wgl4_boot.ttf
6 File(s) copied
        1 file(s) copied.
        1 file(s) copied.

Success

Updating path to include peimg, oscdimg, imagex

   E:\Program Files\Windows AIK\Tools\PETools\
   E:\Program Files\Windows AIK\Tools\PETools\..\x86


e:\VistaPE>

3. 사용자 정의 파일 복사


PE로 부팅했을 때 사용하고 싶은 파일들이 있다면 복사해 놓습니다. 저 같은 경우에는... 음... 딱히 필요한 파일이 없어서 그냥 생략했습니다.

4. Windows PE 이미지(Winpe.wim) 적용


2번 단계에서의 "Windows PE Tools Command Prompt" 프로그램을 다시 실행시켜서 "x86" 하위 폴더로 이동한 후, 아래와 같이 부팅 이미지를 "VistaPE" 폴더에 적용합니다. (비스타 사용자는, 이때 명령어 창을 관리자 권한으로 실행시켜야 합니다.)

[그림 3: imagex 프로그램으로 부팅 이미지 생성]
vista_windows_pe_install_3.png

Updating path to include peimg, oscdimg, imagex

   E:\Program Files\Windows AIK\Tools\PETools\
   E:\Program Files\Windows AIK\Tools\PETools\..\x86


C:\Windows\system32>cd "e:\Program Files\Windows AIK\tools\PETools\x86"

C:\Windows\system32>e:

e:\Program Files\Windows AIK\Tools\PETools\x86>imagex /apply winpe.wim 1 e:\VistaPE\mount

ImageX Tool for Windows
Copyright (C) Microsoft Corp. 1981-2005. All rights reserved.



Progress: 100%

Successfully applied image.



e:\Program Files\Windows AIK\Tools\PETools\x86>

5. 드라이버 및 패키지 설치


3번 단계에서는 단순 exe 유형의 프로그램을 복사했던 반면, 이번에는 드라이버나 일정 포맷에 맞게 미리 정의된 패키지를 설치할 수 있습니다. AIK에서 미리 제공되는 몇 가지 유형의 패키지가 있는데 선택해서 설치를 합니다.

참고로, 패키지 목록은 peimg /list 명령어를 통해서 아래와 같이 확인할 수 있습니다.

e:\Program Files\Windows AIK\Tools\PETools\x86>peimg /list e:\VistaPE\mount\Windows
Preinstallation Environment Image Setup Tool for Windows
Copyright (C) Microsoft Corporation. All rights reserved.

Culture:          en-US
Time zone offset: (GMT-08:00) Pacific Time (US & Canada)
Time zone name:   "Pacific Standard Time" (use with /timezone)

Lang  | Version       | Ins | Name
------+---------------+-----+-----------------------------------------------
en-US |6.0.6000.16386 |  -  | WinPE-HTA-Package
------+---------------+-----+-----------------------------------------------
      |6.0.6000.16386 |  -  | WinPE-HTA-Package
------+---------------+-----+-----------------------------------------------
en-US |6.0.6000.16386 |  -  | WinPE-MDAC-Package
------+---------------+-----+-----------------------------------------------
      |6.0.6000.16386 |  -  | WinPE-MDAC-Package
------+---------------+-----+-----------------------------------------------
en-US |6.0.6000.16386 |  -  | WinPE-Scripting-Package
------+---------------+-----+-----------------------------------------------
      |6.0.6000.16386 |  -  | WinPE-Scripting-Package
------+---------------+-----+-----------------------------------------------
en-US |6.0.6000.16386 |  -  | WinPE-WMI-Package
------+---------------+-----+-----------------------------------------------
      |6.0.6000.16386 |  -  | WinPE-WMI-Package
------+---------------+-----+-----------------------------------------------
en-US |6.0.6000.16386 |  -  | WinPE-XML-Package
------+---------------+-----+-----------------------------------------------
      |6.0.6000.16386 |  -  | WinPE-XML-Package
------+---------------+-----+-----------------------------------------------
      |6.0.6000.16386 |  -  | WinPE-FontSupport-JA-JP-Package
------+---------------+-----+-----------------------------------------------
      |6.0.6000.16386 |  -  | WinPE-FontSupport-KO-KR-Package
------+---------------+-----+-----------------------------------------------
      |6.0.6000.16386 |  -  | WinPE-FontSupport-ZH-CN-Package
------+---------------+-----+-----------------------------------------------
      |6.0.6000.16386 |  -  | WinPE-FontSupport-ZH-HK-Package
------+---------------+-----+-----------------------------------------------
      |6.0.6000.16386 |  -  | WinPE-FontSupport-ZH-TW-Package
------+---------------+-----+-----------------------------------------------

Listed 15 package(s).

PEIMG completed the operation successfully.

e:\Program Files\Windows AIK\Tools\PETools\x86>

그래서... 그냥 아래와 같은 배치 파일을 만들어서 실행시켜도 되겠지요.

e:\Program Files\Windows AIK\Tools\PETools\x86>type install-packages.bat
peimg /install=WinPE-XML-Package e:\VistaPE\mount
peimg /install=WinPE-HTA-Package e:\VistaPE\mount
peimg /install=WinPE-Scripting-Package e:\VistaPE\mount
peimg /install=WinPE-MDAC-Package e:\VistaPE\mount
peimg /install=WinPE-WMI-Package e:\VistaPE\mount

e:\Program Files\Windows AIK\Tools\PETools\x86>

6. 패키지 추가 완료 명시


원하는 패키지들을 모두 추가했다면, PE 이미지를 고정시켜줍니다. 일단 한번 아래와 같은 명령어로 고정이 되었다면 더 이상 패키지를 추가할 수 없기 때문에 원하는 패키지가 있다면 반드시 그 전에 추가해 주어야 합니다.

e:\Program Files\Windows AIK\Tools\PETools\x86>peimg /image=e:\VistaPE\mount /prep
Preinstallation Environment Image Setup Tool for Windows
Copyright (C) Microsoft Corporation. All rights reserved.

The /prep command will permanently modify a Windows PE image, so that it can
no longer be serviced.  This means that operations including:

   - Installing or uninstalling optional features
   - Applying hotfixes or other servicing packages
   - Installing language packs

Will not be possible on the prepared image.

To continue, enter "yes".  Any other input will exit the program.

Continue? yes
[==========================100.0%==========================]
PEIMG completed the operation successfully.

e:\Program Files\Windows AIK\Tools\PETools\x86>

위의 과정을 거치고 나면 최종 이미지에 지정되지 않은 모든 패키지 및 언어 팩들이 제거됩니다. 이 때문에 원래의 "E:\VistaPE" 폴더 크기가 1GB가 넘었는데, 위의 명령어 실행 이후 660MB 정도로 줄어들게 되었습니다.

7. ISO로 만들어질 이미지 생성


자... 이제 모든 설정이 적용된 이미지를 생성하면 됩니다.

e:\Program Files\Windows AIK\Tools\PETools\x86>imagex /boot /compress max /capture "e:\VistaPE\mount" "e:\VistaPE\iso\sources\boot.wim" "VistaPEImage"

ImageX Tool for Windows
Copyright (C) Microsoft Corp. 1981-2005. All rights reserved.


Files/folders excluded from image capture by default:

 \WINDOWS\CSC
 \RECYCLER
 \System Volume Information
 \pagefile.sys
 \hiberfil.sys
 \$ntfs.log


Progress: 100%

Successfully imaged e:\VistaPE\mount



e:\Program Files\Windows AIK\Tools\PETools\x86>

사실상, 이것으로 PE 이미지를 준비하는 작업은 완료가 되었습니다.

8. ISO 이미지 생성


7번 단계까지 해서 완료된 PE 이미지를 ISO로 변환시켜 줍니다. 이를 위해 AIK에는 oscdimg.exe라는 프로그램이 마련되어 있는데, 단순히 아래와 같이 실행시켜 주면 됩니다.

e:\Program Files\Windows AIK\Tools\PETools\x86>oscdimg -n e:\VistaPE\ISO e:\VistaPE\VistaPEImage.iso -n -be:\VistaPE\etfsboot.com

OSCDIMG 2.45 CD-ROM and DVD-ROM Premastering Utility
Copyright (C) Microsoft, 1993-2000.  All rights reserved.
For Microsoft internal use only.


Scanning source tree complete (17 files in 8 directories)

Computing directory information complete

Image file is 150368256 bytes

Writing 17 files in 8 directories to e:\VistaPE\VistaPEImage.iso

100% complete

Final image file is 150368256 bytes

Done.

e:\Program Files\Windows AIK\Tools\PETools\x86>

명령이 성공적으로 실행되고 나면 E:\VistaPE 폴더에 VistaPEImage.iso라는 이름의 ISO 이미지 파일이 생성됩니다. 용량도 146 MB로 확 줄었네요. ^^ 아래의 화면은 이 파일을 Virtual PC/Server에 마운팅시켜서 부팅시킨 모습입니다.

[그림 4: PE 이미지 부팅]
vista_windows_pe_install_4.png

이것으로 끝!



[이 토픽에 대해서 여러분들과 의견을 공유하고 싶습니다. 틀리거나 미흡한 부분 또는 의문 사항이 있으시면 언제든 댓글 남겨주십시오.]

[연관 글]






[최초 등록일: ]
[최종 수정일: 2/22/2024]

Creative Commons License
이 저작물은 크리에이티브 커먼즈 코리아 저작자표시-비영리-변경금지 2.0 대한민국 라이센스에 따라 이용하실 수 있습니다.
by SeongTae Jeong, mailto:techsharer at outlook.com

비밀번호

댓글 작성자
 



2009-03-04 12시38분
위의 설명은 x86을 대상으로 했는데요. 원래 AIK를 다운로드 받으면 "en_windows_vista_windows_automated_installation_kit_dvd_X13-63415.iso" 라는 이미지 파일안에 "WAIKAMD64.MSI"라는 이름으로 x64용 설치 파일이 있는 데 이걸 실행시켜서 설치한 후에 본문에서 설명한 동일한 방법을 따르면 x64용이 됩니다.

x86과 x64를 합치는 방법도 있는데... 일단 오늘은 여기까지! ^^
kevin25

... 181  182  183  184  185  186  187  188  189  190  191  192  [193]  194  195  ...
NoWriterDateCnt.TitleFile(s)
110정성태11/14/200516453.NET Framework: 28. VS.NET 2005 / SQL Server 2005 베타 버전 재설치 또는 업그레이드 [1]
111정성태3/7/200515328    답변글 VS.NET IDE: 28.1. [추가] SQL 2005 / VS.NET 2005 2005-02 CTP 버전이 올라왔네요. [1]
112정성태11/14/200516563        답변글 VS.NET IDE: 28.2. [추가] VS.NET 2005 2005-02 CTP 버전에서 달라진 점 ( VC++ )
127정성태3/29/200514617        답변글 VS.NET IDE: 28.4. [추가] SQL 2005 2005-02 CTP 버전에서 달라진 점
123정성태3/25/200518540    답변글 .NET Framework: 28.3. Uninstalling software without using Add Remove Programs...
108정성태3/4/200517996.NET Framework: 27. 시스템 이벤트 로그에 쌓이는 {00020906-0000-0000-C000-000000000046} 보안에러
107정성태3/1/200518190COM 개체 관련: 15. COM: Control 유형인 경우, IObjectWithSite 를 구현해도 SetSite/GetSite 가 호출이 안됨
106정성태2/28/200517516COM 개체 관련: 14. 탐색기 "처럼" 파일 열기
105정성태2/28/200516574.NET Framework: 26. VS.NET 2005 : 설치 프로젝트 - .NET Framework 설치 강제화
139정성태11/14/200514765    답변글 .NET Framework: 26.1. ^^ 역시, 배려가 되어 있네요. 제가 못 찾은 것이었습니다.
104정성태2/27/200517443VS.NET IDE: 23. MSI 설치 중에 GetLocalTime / GetSystemTime API 사용
132정성태3/30/200517070    답변글 VS.NET IDE: 23.1. [추가]: MSI 설치 동작 원리
102정성태2/16/200519720.NET Framework: 25. Verify that you are a member of the 'Debugger Users' group on the server. [2]
101정성태2/15/200517448.NET Framework: 24. WMI Win32_NTLogEvent 관리 이벤트를 Windows 2000 에서는 "Access Denied" 가 발생하는 문제파일 다운로드1
100정성태2/15/200523547VS.NET IDE: 22. 방화벽 환경에서의 WMI 연결을 위한 포트 설정 [2]
99정성태2/15/200521542COM 개체 관련: 13. 비동기 Drag & Drop 구현 : IAsyncOperation
103정성태2/23/200517762    답변글 COM 개체 관련: 13.1. [관련 자료] 그외 Drag & Drop 링크파일 다운로드1
97정성태2/14/200520723VS.NET IDE: 21. 설치된 Platform SDK 버전확인 방법
96정성태2/14/200522746기타: 9. http://www.google.com/webhp?complete=1&hl=en 검색에 관해서.
95정성태2/14/200532079VS.NET IDE: 20. Win32 특권 정리 [1]
94정성태1/29/200523376VC++: 13. VS.NET 2005 VC++ 컴파일러 에러 : cannot instantiate abstract class
93정성태1/29/200519259VS.NET IDE: 19. 혹시 VS.NET 2005 Beta2(2004/12 CTP Team System 버전)이 다운이 자주 되나요? [2]
92정성태1/29/200518085.NET Framework: 23. Unmanaged 환경에서 Managed DLL에 정의된 메서드 호출 시 오류 확인하는 방법
91정성태11/14/200518705VC++: 12. VS.NET 2005 VC++ Debug: Expression: ( (state != ST_INVALID ) )
90정성태1/27/200519505.NET Framework: 22. Debug: The underlying connection was closed: Unable to connect to the remote server.
89정성태1/26/200523996VC++: 11. Delay Loaded DLL
... 181  182  183  184  185  186  187  188  189  190  191  192  [193]  194  195  ...