Sunday, June 10, 2007

Vista Partition and Backup

对盘使用“压缩卷”就可以了。压缩以后,对未使用空间建立新的简单卷就可以了。
1. 先下载Imagex6000(点击下载),并解压放在非Vista系统,这里路径为:“C:\Imagex6000”。
2. 在Vista安装光盘中有一个“install.wim”文件,在其中封装了7个版本的Vista,但是只占用2.15GB的空间. INSTALL.WIM文件在安装光盘镜像文件根目录下的“SOURCES”文件夹.
3. 运行命令
Imagex /append c: d:\install.wim "Vista Back"
程序将整个硬盘C分区备份封装,追加到“install.wim”文件中。
4. 检验封装
Imagex /info d:\install.wim
封装成功的话,可运行UltraISO加载Vista安装光盘镜像ISO文件,删除掉原来的“install.wim”文件,把生成的“install.wim”,重新拖进原来的ISO文件保存
5. 系统还原
用Windows PE或Windows XP引导系统,在命令窗口,执行如下命令
Imagex /apply d:\install.wim "Vista Back" c:
附: 微软封装工具ImageX的应用
创建一个C盘的映像
ximage /capture c: d:\data.wim "Drive C " /verify /compress maximum
ximage /split d:\data.wim d:\datasplited.swm 650
  • 启用Administrator超级管理员权限
    单击“开始”菜单,选择“所有程序”>“附件”,右键单击“命令提示符”,选择“以管理员身份运行”
    net user Administrator /Active:yes
  • UAC用户帐号控制
用户工作在管理员帐户下,只是这个管理员帐户经过特殊的降级处理多数情况下,用户并不会有掣肘之感。如果要运行需要高特权的管理任务,系统会自动侦测到这种请求,在得到用户确认后,会自动提升到高级特权环境,以便顺利完成管理任务。

To turn of UAC, goto Control Panel/User Accounts and Family Safety/User Accounts/Turn User Account Control on or off.
Or run MsConfig and goto System Configuration/Tools/Disable UAC
Or gpedit.msc then goto Computer Configuration -> Windows Settings -> Security Settings -> Local Policies -> Security Options.
Integrity Levels (IL) mechanism has been introduced to help implementing UAC. This mechanism is very simple – every process can be assigned one of the four possible integrity levels:

• Low
• Medium
• High
• System

Similarly, every securable object in the system, like e.g. a directory, file or registry key, can also be assigned an integrity level. Integrity level is nothing else then just an ACE of a special type assigned to the SACL list. If there’s no such ACE at all, then the integrity level of the object is assumed to be Medium. You can use icacls command to see integrity levels on file system objects.

Now, the whole concept behind IL is that a process can only get write-access to those objects which have the same or lower integrity level then the process itself.

The default behavior of IL and is “NW”, which stands for NoWriteUp policy. You can use the chml tool by Mark Minasi to set also a different policy, i.e. NoReadUp (NR) or NoExecuteUp (NX), which would result that IL mechanism will not allow a lower integrity process to read or execute the objects marked with higher IL. For example, to prevent all the low IL processes, like e.g. Protected Mode IE, from reading the contents of your secret directory.
chml.exe c:\secrets -i:m -nr -nx
1. Assumes that Vista has been installed on a partition which takes up 100% of the hard drive, so we need to create some space.

Boot off the Vista DVD, select “Install now”, don’t type in your product key, untick “Automatically activate Windows when I’m online”, select any edition of Vista, accept the license terms and hit “Next” again, then choose a Custom installation.

On the screen where you’re asked where you want to install Windows, press SHIFT + F10 to open a PE 2.0 command window.

Type in

DISKPART
list disk
select disk 0
list volume
select volume 0
shrink
EXIT
EXIT

Go back to the install screen. Click Refresh and the partition window will update – you should now see the original Primary partition plus a brand new partition.

Eject the Vista DVD, reset the machine and boot off the Windows XP CD to install XP.
Note:
If got blue screen in load XP installation, goto BIOS and change the RAID from 'On' to 'Auto-detect' or hard disk for "SATA" to "Auto-detect".

2. Restoring Vista and dual booting
After the initial file copy(XP), Windows XP reboots and loads up the GUI-based component of the install. You may get the following error: “A disk read error occurred – press Ctrl-Alt-Del to continue”. This is caused by a corrupt bootloader.

Boot from the Vista DVD and on the screen where you’re prompted to “Install now”, select “Repair your computer”.
Select the first option – Startup Repair in System Recovery Options screen.

Click Close and then Finish, and the system will restart and boot into Vista.

Use EasyBCD to add a boot entry for XP, then click on "Configure Boot". Select you Windows XP OS under "Entry-Based Settings" and note the drive location. Make sure it's set to C:\.
copy e:\i386\ntldr c:\
copy e:\i386\ntdetect.com c:\
copy d:\boot.ini c:\
(Change the part # from 5 to 4 in boot.ini for Vista)

Then reboot into XP to continue on with XP's installation.

3. Reinstall Vista BootLoader
If you do not have error stated in step 2 and got XP installed, you can run
EasyBCD in XP, it required .Net 2.0 framework. Then run Manage Bootloader and reinstalled the Vista bootloader. Then booted into Vista and installed BCD and Added an entry for XP.

4. Change boot menu in Vista
To edit Vista’s boot manager you have to use the command line BCDEDIT utility.
Bcdedit /create {legacy} /d “Windows XP”
Bcdedit /set {legacy} device boot
Bcdedit /set {legacy} path \ntldr
Bcdedit /displayorder {legacy} /addlast

Or the easy way is use the EasyBCD.