autoexec.bat 설명

Dos 부팅이 가능한 USB에서 4가지 버전의 Windows 설치를 위한 autoexec.bat 파일입니다
  • Windows 8.1 32bit
  • Windows 8.1 64 bit
  • Windows 10 32bit
  • Windows 10 64bit
Windows 설치 USB 만들기 - 윈도우 파일 및 폴더 이름 바꾸기에서 설명한대로 반드시 파일 및 폴더명을 변경하고 진행해야 합니다

위의 4가지 버전을 다 사용할 경우 autoexec.bat, config.sys 그대로 사용하고, 그 외는 해당 버전의 줄을 삭제 하여 3가지 2가지 버전으로 사용가능합니다

예: windows 10 32bit 없이 사용하려는 경우
  1. autoexec.bat 파일의 1086이 있는 모든 줄을 삭제하고  :1086inst 하단 goto BHRG 삭제합니다
  2. config.sys 파일의 1086이 있는 모든 줄을 삭제합니다

  • autoexec.bat

@echo off ← 실행명령어 감추기
PROMPT $P$G ← 프롬프트 위치표시

set path=%path%;\;\mdir; ← path 설정 - 해당 디렉토리의 파일을 메모리에 상주

if not exist bootmgr goto NOBMGR ← bootmgr이 없으면 NOBMGR로 이동
if exist bootmgr goto BMGR ← bootmgr이 있으면 BMGR로 이동  

:NOBMGR ← menuitem - NOBMGR : 파일 및 폴더를 확인하고 이동
if not exist 8186mgr goto ERROR
if not exist 8164mgr goto ERROR
if not exist 1086mgr goto ERROR
if not exist 1064mgr goto ERROR
goto %config% ← config.sys에서 선택한 menuitem으로 이동

:BMGR ← menuitem - BMGR : 파일 및 폴더 숨기고 다음 단계 이동
attrib -h boot ← 폴더 보이기
attrib -h sources
attrib -h bootmgr ← 파일 보이기
attrib -h efi
attrib -h bootmgr.efi
if not exist 8186mgr goto 8186 ← 8186mgr 이 없으면 8186로 이동
if not exist 8164mgr goto 8164
if not exist 1086mgr goto 1086
if not exist 1064mgr goto 1064
goto BHE ← BHE로 이동

:8186 ← menuitem - 8186
if not exist 8164mgr goto BHE
if not exist 1086mgr goto BHE
if not exist 1064mgr goto BHE
ren boot 8186boot ← windows 8.1 x86 에 맞는 이름으로 변경
ren sources 8186sour
ren bootmgr 8186mgr
ren efi 8186efi
ren bootmgr.efi 8186mgr.efi
attrib +h 8186boot ← windows 8.1 x86 파일 및 폴더 숨기기
attrib +h 8186sour
attrib +h 8186mgr
attrib +h 8186efi
attrib +h 8186mgr.efi
goto %config% ← config.sys에서 선택한 menuitem으로 이동

:8164 ← menuitem - 8164
if not exist 1086mgr goto BHE
if not exist 1064mgr goto BHE
ren boot 8164boot
ren sources 8164sour
ren bootmgr 8164mgr
ren efi 8164efi
ren bootmgr.efi 8164mgr.efi
attrib +h 8164boot
attrib +h 8164sour
attrib +h 8164mgr
attrib +h 8164efi
attrib +h 8164mgr.efi
goto %config%

:1086 ← menuitem - 1086
if not exist 1064mgr goto BHE
ren boot 1086boot
ren sources 1086sour
ren bootmgr 1086mgr
ren efi 1086efi
ren bootmgr.efi 1086mgr.efi
attrib +h 1086boot
attrib +h 1086sour
attrib +h 1086mgr
attrib +h 1086efi
attrib +h 1086mgr.efi
goto %config%

:1064 ← menuitem - 1064
ren boot 1064boot
ren sources 1064sour
ren bootmgr 1064mgr
ren efi 1064efi
ren bootmgr.efi 1064mgr.efi
attrib +h 1064boot
attrib +h 1064sour
attrib +h 1064mgr
attrib +h 1064efi
attrib +h 1064mgr.efi
goto %config%

:BHE ← menuitem - BHE : 파일 및 폴더 숨기고 ERROR로 이동
attrib +h boot ← 파일 및 폴더 숨기기
attrib +h sources
attrib +h bootmgr
attrib +h efi
attrib +h bootmgr.efi
goto ERROR ← ERROR로 이동

:ERROR ← menuitem -ERROR : 설치 파일이 없을 때
if exist bootmgr echo exist Unidentified windows install files ← bootmgr이 있으면 echo
if not exist 8186mgr echo not exist windows 8.1 x86 install files
if not exist 8164mgr echo not exist windows 8.1 x64 install files
if not exist 1086mgr echo not exist windows 10 x86 install files
if not exist 1064mgr echo not exist windows 10 x64 install files
if %config%==8186inst goto quit ← 시작시 선택한 menuitem이 8186이면 quit로 이동
if %config%==8164inst goto quit
if %config%==1086inst goto quit
if %config%==1064inst goto quit
goto %config% ← config.sys에서 선택한 menuitem으로 이동

:8186inst ← menuitem - 8186inst : windows 8.1 32bit 설치파일 및 폴더 이름변경
attrib -h 8186boot
attrib -h 8186sour
attrib -h 8186mgr
attrib -h 8186efi
attrib -h 8186mgr.efi
ren 8186boot boot
ren 8186sour sources
ren 8186mgr bootmgr
ren 8186efi efi
ren 8186mgr.efi bootmgr.efi
goto BHRG

:8164inst ← menuitem - 8164inst
attrib -h 8164boot
attrib -h 8164sour
attrib -h 8164mgr
attrib -h 8164efi
attrib -h 8164mgr.efi
ren 8164boot boot
ren 8164sour sources
ren 8164mgr bootmgr
ren 8164efi efi
ren 8164mgr.efi bootmgr.efi
goto BHRG

:1086inst ← menuitem - 1086inst
attrib -h 1086boot
attrib -h 1086sour
attrib -h 1086mgr
attrib -h 1086efi
attrib -h 1086mgr.efi
ren 1086boot boot
ren 1086sour sources
ren 1086mgr bootmgr
ren 1086efi efi
ren 1086mgr.efi bootmgr.efi
goto BHRG

:1064inst ← menuitem - 1064inst
attrib -h 1064boot
attrib -h 1064sour
attrib -h 1064mgr
attrib -h 1064efi
attrib -h 1064mgr.efi
ren 1064boot boot
ren 1064sour sources
ren 1064mgr bootmgr
ren 1064efi efi
ren 1064mgr.efi bootmgr.efi
goto BHRG

:BHRG ← menuitem - BHRG : 설치파일 및 폴더를 감추고 grub4dos 실행
attrib +h boot
attrib +h sources
attrib +h bootmgr
attrib +h efi
attrib +h bootmgr.efi
grub4dos.exe ← grub4dos 실행
goto quit ← quit로 이동

:dos ← menuitem - dos
ver ← 도스버전
goto quit ← quit로 이동

:quit ← menuitem - quit
Share on Google Plus

About 2651911

This is a short description in the author block about the author. You edit it by entering text in the "Biographical Info" field in the user admin panel.
    Blogger Comment
    Facebook Comment

0 개의 댓글 :

댓글 쓰기