Jump to content











Photo
* * * * * 1 votes

VHD_WIMBOOT - Apply and Capture of WIM Files for OS in VHD

ramdisk grub4dos wimlib svbus windows 10 ssd usb wim vhd wimboot

  • Please log in to reply
673 replies to this topic

#651 alacran

alacran

    Gold Member

  • .script developer
  • 2303 posts
  •  
    Mexico

Posted A week ago

@ antonino61

 

My friend, please remember this post from wimb, he is very friendly and  tolerant, but you are too insistent:

 

 

@antonino61

 

Your posts #517 - #520 belong to your own thread Get-alladafluff-out

 

Please do not post all your experiments in this thread VHD_WIMBOOT since it is becoming rather confusing.

 

alacran



#652 antonino61

antonino61

    Gold Member

  • Advanced user
  • 1225 posts
  •  
    Italy

Posted A week ago

sorry, I thought he was interested in my vhd sizes and he once asked me for filelists related to them, not only in terms of vhd smallness, but also in terms of vhd largeness. there are also some software details. if it is not the case now, I will post it in get-alladafluff-out. one day you will pls explain to me why whatever u post is poignant and whatever I post is preposterous, just to satisfy my curiosity, me if I were u, I would check both the file list and folder list I posted for culprits, in order to stand everybody (including u urself) in good stead, but of course it is my humblest opinion. the only difference I can see about the nature of ur posts and that of mine is ur infinitely greater IT knowledge and experience. Anyway I will post it where u said - do not know how to delete it from here, though.



#653 wimb

wimb

    Platinum Member

  • Developer
  • 3473 posts
  • Interests:Boot and Install from USB
  •  
    Netherlands

Posted A week ago

Update Win_Reduce_Trusted-50

 

Download:  from wimb GitHub  -  Win_Reduce_Trusted-50

 

Download File E = Encrypted PassWord = bootwimb

 

Manual:   VHD_WIMBOOT.pdf   - Download:  Win10_21H2 x64 ISO and  Win11 ISO from Microsoft

 

Our Mini-10x64 VHD deserves a better way to protect the UsedSize against Windows Update.

Until now the Firewall App Blocker is used for this purpose by using Enable WhiteList On and Allow the Selected Internet Browser only.

The problem is that the Enable Whitelist On Setting gives problem in getting good Internet Connection and also blocks FireFox in getting other pages.

We can solve this problem by Adding Windows Update Blocker to Block Windows Update.

 

Changes this Update:

 

- Added Windows Update Blocker - Wub folder in \Add_Folders_Files\Port_Apps folder of Win_reduce

- Shortcut on Desktop to launch Wub_x64.exe added in \Add_to_UserPath\Desktop folder

- Shortcut on Desktop to launch Network - ncpa.cpl - Easy Switch On / Off Network Adapter

- Added TK_Wub_Fix.reg registry to switch off Windows Update added in \Add_Registry folder

- Modified Add_Registry_files.txt in File_List folder by adding entry for TK_Wub_Fix.reg registry

- PS.exe is running now as Admin so that all apps in PStart Menu are Running as Admin

- Added Run_System_Info_x64.exe in \Add_to_UserPath\Desktop folder

  Run_System_Info_x64.exe will Find and Run \System_Info\System_Info_x64.exe on Any Drive

 

  For this purpose your System_Info-53 folder must be in Root of Any Drive and must be Renamed as System_Info

 

TK_Wub_Fix_reg.txt registry to switch off Windows Update (is not sufficient, OS changes these values to let Windows Update Auto Start)

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\TK_SYSTEM\ControlSet001\Services\DoSvc]
"Start"=dword:00000004

[HKEY_LOCAL_MACHINE\TK_SYSTEM\ControlSet001\Services\UsoSvc]
"Start"=dword:00000003

[HKEY_LOCAL_MACHINE\TK_SYSTEM\ControlSet001\Services\WaaSMedicSvc]
"Start"=dword:00000004

[HKEY_LOCAL_MACHINE\TK_SYSTEM\ControlSet001\Services\wuauserv]
"Start"=dword:00000004

On booting Mini-10x64.vhd then Windows Update is switched off by Registry (occurs but not guaranteed)

 

First time you need to boot Mini-10x64.vhd as FILEDISK and be sure there is No Network Connection possible.

Then you need on Desktop launch Wub_x64.exe to Disable Windows Update and further Protect this Setting.

 

It is now safe to connect to Network using Enable WhiteList Off setting in Firewall App Blocker.

 

Boot Mini-10x64.vhd as FILEDISK or from RAMDISK and

Connect to Internet and FireFox pages appear OK without an increase of the Mini-10x64 UsedSize  :)

 

Mini-10x64_2021-11-24_144508.jpg == Win_Reduce_2021-11-25_191305.jpg == Mini-10x64_2021-11-26_102921.jpg


  • alacran and antonino61 like this

#654 alacran

alacran

    Gold Member

  • .script developer
  • 2303 posts
  •  
    Mexico

Posted 3 days ago

Update Win_Reduce_Trusted-50

 

 

Just tested it in a copy of my old Mini-10x64.vhd (LZX Compact mode installed) made from 10x64 20H2 November update, or 2009 v2 (release.191206-1406), and there is an additional reduction of 82 MB in used size, at first seen it doesn't seems very much, but when talking of small size VHDs 20.297 % reduction in used size means a lot.

 

Please see attached photos, in both cases taken after run the VHDs at leasts once.

 

Good work wimb, congratulations for all the improvements.

 

alacran

Attached Thumbnails

  • Reduction.png

  • antonino61 likes this

#655 alacran

alacran

    Gold Member

  • .script developer
  • 2303 posts
  •  
    Mexico

Posted 3 days ago

To summarize, this is my experience of how far we can go with reduced VHDs and/or WinPE VHDs until today

 

For more detailed info please see this post.

 

Mini-10x64-LZX.vhd:

 

After recapture and reapply LXZ Compact mode, it's even a little better.

 

2 GB VHD >>> used space 1.57 GB >>> free space 426 MB >>> boots as filedisk very fine on a 2 GB Ram PC (Free Ram 1.2 GB).   Also capable to Ramboot very fine on a 4 GB PC as I have tested since long time ago.

Mini-10x64-WB.vhd:

800 MB VHD >>> 463 MB used size >>> 333 MB free size >>> 471 MB free Ram >>> Ramboots very fine on a 2 GB Ram PC.

Win10XPE_x64-WB.vhd:

500 MB VHD >>> 174 MB used size >>> 324 MB free size >>> 550 MB free Ram >>> Ramboots very fine on a 2 GB Ram PC.

 

Please see attached photos and linked post

 

Once again GOOD WORK WIMB!!!!!

 

alacran

Attached Thumbnails

  • Mini-10x64-WB.png
  • Win10XPE_x64-WB.png
  • Mini-10x64-LZX.png

  • wimb and devdevadev like this

#656 wimb

wimb

    Platinum Member

  • Developer
  • 3473 posts
  • Interests:Boot and Install from USB
  •  
    Netherlands

Posted 2 days ago

Thanks alacran for testing Win_Reduce_Trusted-50  :) and VHD_WIMBOOT_Trusted-64

 

The very small UsedSize for the different Mini versions of Windows OS is impressive.

 

Latest improvement of Win_Reduce is most visible in the reduction of the FileList of Mini-10x64

 

The FileList is reduced by 5470 files as compared to my previous Mini-10x64 and is now for Mini-10x64 21H2 18.806 files

 

We may conclude that about 10 % of Windows OS is really essential for most of the functionality.

 

Windows Update Blocker and Firewall App Blocker are quite effective in keeping the UsedSize reduced  :)


  • alacran likes this

#657 alacran

alacran

    Gold Member

  • .script developer
  • 2303 posts
  •  
    Mexico

Posted 2 days ago

My Mini-10x64-LZX.vhd has now, (after boot), 17204 files and 2022 folders.

 

Including this installed programs: 7-zip, CCleaner, Sumatra PDF and Classic Shell. Please see attached image.

 

About:

 

Windows Update Blocker and Firewall App Blocker are quite effective in keeping the UsedSize reduced

 

Yes, they are very good and I use both, only FireFox Portable is allow to connect to internet.

 

alacran

Attached Thumbnails

  • Number of files.png


#658 wimb

wimb

    Platinum Member

  • Developer
  • 3473 posts
  • Interests:Boot and Install from USB
  •  
    Netherlands

Posted 2 days ago

My Mini-10x64-LZX.vhd has now, (after boot), 17204 files and 2022 folders.

 

 

Very Good. Can you share your FileList of Mini-10x64 e.g. as made with Dir_List-24 ?

 

What do you remove extra as compared to Win_Reduce ?

 

In my case:

Mini_10x64_21H2 has   18.806 Files and   3.031 Folders according to Dir_List-24

Mini_10x64_21H2 has   17.997 Files and   2.367 Folders according to Windows Properties

 

Your Mini contains Boot and EFI folder wheras in my case these folders are in separate partiton

 

According to your figures it must be possible to remove even more for my case ....

But my case is 21H2 and yours is 20H2 , so that might also have some influence ....

 

Mini_10x64_21H2_2021-12-02_123713.jpg



#659 alacran

alacran

    Gold Member

  • .script developer
  • 2303 posts
  •  
    Mexico

Posted 2 days ago

Attached my Fyle_List, when opened with Notepad++ there are 18388 lines, so this is 18388 files.

 

alacran

Attached Files


  • wimb likes this

#660 wimb

wimb

    Platinum Member

  • Developer
  • 3473 posts
  • Interests:Boot and Install from USB
  •  
    Netherlands

Posted 2 days ago

Thank you for the FileList.

 

I will do a detailed comparison with my FileList for Mini-10x64 20H2 and hope to find what is causing the about 400 extra lines in my case.



#661 alacran

alacran

    Gold Member

  • .script developer
  • 2303 posts
  •  
    Mexico

Posted 2 days ago

Forgot I also installed ImDisk Toolkit by v77.    

 

This are some tips for you:

 

About 400 files is not too much, all *.log and *.etl can be more than that, I booted from Win10XPE_x64, found all of them using SwiftSearch, and deleted all of them, but you could code Win_Reduce to delete all *.log and *.etl files.

 

But also it is good before apply Win_Reduce to delete on Tasks Scheduller (taskschd.msc) all tasks related to Edge and OneDrive (if we are not going to use them), to avoid generate their respective *.log files every boot, this could also apply to other Apps to be deleted when running Win_Reduce especially in case of 20H2, if you want you can export as a *.xml file each task before delete it (just in case, during your tests), it is good to also dissable the respective service for this tasks, but only if it does not have any dependencies, latter this delete/dissable procedure could also be automated implementing it into Win_Reduce.

 

Custom_Command.cmd made by wimb works very fine for 20H1 and 20H2, it is based on the last section of Clean_All-Full.cmd (but my research was made for 20H1), it takes care to avoid the creation of several new *.log and/or *.etl files, but it is very possible you may need to add some new lines to update it to version 21H2, as I'm sure it will make more *.log and *.etl files than any other previous versions, in accordance with the known tendency.

 

Run Clean_All-Full.cmd, also helps a lot to remove garbage from our VHD, (but my research was made for 20H1), if booting as filedisk it is a good practice to run it before close windows, it is almosts as good as CCleaner, and in some aspects better, to compare just run an analysis on CCleaner, but don't delete anything, run Clean_All-Full.cmd and run again an analysis on CCleaner.

 

NOTE-1: Clean_All-Full.cmd was run again just before closing the VHD today After the FileList was done so there may be some variation, I ran a new full deletion of *.log files from Win10XPE before filedisk booting the VHD.  Clean_All-Full.cmd was run again just before closing the VHD.  There is not any *.etl file and only has the very few following *.log files, (please see attached picture):

 

\ProgramData\Microsoft\Network\Downloader\edb.log
\ProgramData\Microsoft\Network\Downloader\edbtmp.log
\Windows\debug\PASSWD.LOG
\Boot\BCD.LOG
\EFI\Microsoft\Boot\BCD.LOG >>> has not being recreated as I haven't reboot in UEFI

 

New fresh FileList updated attached.

 

alacran

Attached Thumbnails

  • Log files.png

Attached Files


  • wimb and antonino61 like this

#662 antonino61

antonino61

    Gold Member

  • Advanced user
  • 1225 posts
  •  
    Italy

Posted 2 days ago

do u want my list of services running on my vhd? I have been using only those 37-40 ones that are strictly necessary to get the system up and running. I first disabled the unneeded and then deleted them with device remover. and it has given me no issues, apart from losing the Settings panel (no problem, as crucial facilities can be recovered in other ways (e.g. ancient control panel, cmds, reg files, shell:..., wimb's sys info panel, or my powerful filename memory, so most of the functionality is guaranteed). Should u be fussy about the settings panel, u can still avoid getting rid of some of the services that I have deleted.



#663 alacran

alacran

    Gold Member

  • .script developer
  • 2303 posts
  •  
    Mexico

Posted 2 days ago

@ wimb

 

I think this info could be useful too:

 

Backup Windows 10 Services Startup Type Configuration.

 

Download page on GitHub.  (Downloak link to the *.zip file is on right upper corner)

 

This Vb Script is very useful to make a online full backup of the services status, it creates 2 files in same folder were it is located:

 

A *.reg file and a *.bat file, both contain same info, (in its own respective format), and both are able to restore the services status (Startup Type Configuration).

 

I recommend to read the full page, it has very good info, but just in case (specially for lazy future readers), I will add here this warning:

 

Be aware of this Note from the author of the Script:

 

In Windows 10, you can see many service names that have an underscore (_) and followed by some numbers. These numbers (suffix) may not match with that of other Windows 10 computers.

 

So, if planning to restore the settings on another PC, to avoid issues, better delete on both (*.reg and *.bat) files all sections/lines containing service names that have an underscore (_) and followed by some numbers, before running any of the files, in my case this is: _2e8ac

 

For your convenience I attached here the file Mini-10x64-Services-Backup.7z containing the folder Mini-10x64 with respective *.reg and *.bat files of my Mini-10x64 that you may use as a guide, or if you want to apply it to your Mini-10, then just remember to first delete all related to _2e8ac on your prefered file before run it.

 

Mini-10x64-Services-Backup.7z password is my user name = alacran

 

Suggestion:

 

If this Script and/or the *.reg and *.bat files of my Mini-10x64 prove to be useful after testing them, maybe it's not a bad idea to include the Script in System_Info program, and the *.reg and/or *.bat files of my Mini-10x64 in Win_Reduce program, of course you are free to edit them as required to improve or adapt to newer versions of OS.

 

alacran

Attached Files


  • wimb and antonino61 like this

#664 antonino61

antonino61

    Gold Member

  • Advanced user
  • 1225 posts
  •  
    Italy

Posted A day ago

Pls let me enthuse at Alacrán's overt suggestion upon my "covert" suggestion, well, let us call it a meta-suggestion. one more thing, if I may, can a correlation be made between services and respective files, so that the absence of, say, the windows update service (I do not remember what it is called) will more or less "automatically" lead to a deletion of all possible files related to it? that would be the real substantial improvement, both in terms of "system-cleanliness" and in terms of used space on the vhd.


  • wimb and alacran like this

#665 wimb

wimb

    Platinum Member

  • Developer
  • 3473 posts
  • Interests:Boot and Install from USB
  •  
    Netherlands

Posted A day ago

@alacran

@antonino61

 

Thanks for File_List_updated.7z and for Mini-10x64-Services-Backup.7z 

 

Thanks for all info regarding Services and Files that might be removed.

It will certainly help to further improve Mini-10x64 in VHD.  :)


  • alacran and antonino61 like this

#666 antonino61

antonino61

    Gold Member

  • Advanced user
  • 1225 posts
  •  
    Italy

Posted A day ago

the services kinda thing works wonders (at least so far) -- attaboy Alacrán!!!! guess what, I have run the shortest list I have (from win11) on a longer-listed win10 and .. no issues so far. I will hopefully confirm this diagnosis. talking about technicalities, it has reduced the number of the latter to that of the former, which was the aim of the thing, and I can see some _numberedservices (presumably restored by the system) on the new list (I had taken good care to exclude them from the reg file before merging it).



#667 wimb

wimb

    Platinum Member

  • Developer
  • 3473 posts
  • Interests:Boot and Install from USB
  •  
    Netherlands

Posted A day ago

I will do a detailed comparison with my FileList for Mini-10x64 20H2 and hope to find what is causing the about 400 extra lines in my case.

 

Found the main reason for the extra 400 lines in my case ....

 

Main reason is that 16 extra \Windows\SystemApps are removed in case of Mini-10x64 of alacran.

 

So we can adjust Custom_remove_folders.txt by adding:

; extra alacran
\ProgramData\Microsoft\Diagnosis
\ProgramData\Microsoft\EdgeUpdate
;
\Windows\SystemApps\Microsoft.AAD.BrokerPlugin_*
\Windows\SystemApps\Microsoft.BioEnrollment_*
\Windows\SystemApps\Microsoft.ECApp_*
\Windows\SystemApps\Microsoft.LockApp_*
\Windows\SystemApps\Microsoft.Win32WebViewHost_*
\Windows\SystemApps\Microsoft.Windows.AppRep.ChxApp_*
\Windows\SystemApps\Microsoft.Windows.CallingShellApp_*
\Windows\SystemApps\Microsoft.Windows.CloudExperienceHost_*
\Windows\SystemApps\Microsoft.Windows.ContentDeliveryManager_*
\Windows\SystemApps\Microsoft.Windows.FileExplorer_*
\Windows\SystemApps\microsoft.windows.narratorquickstart_*
\Windows\SystemApps\Microsoft.Windows.PeopleExperienceHost_*
\Windows\SystemApps\Microsoft.Windows.SecHealthUI_*
\Windows\SystemApps\Microsoft.XboxGameCallableUI_*
\Windows\SystemApps\ParentalControls_*
\Windows\SystemApps\Windows.CBSPreview_*
;

Also remove_ProgramData_App_folders.txt and remove_ProgramData_App_files.txt can be adjusted to take removal of these SystemApps into account

 

Now my Mini-10x64 21H2 has 17.418 files and 20H2 has 17.231 files ....

 

Will continue to search for improvements .....


  • alacran likes this

#668 alacran

alacran

    Gold Member

  • .script developer
  • 2303 posts
  •  
    Mexico

Posted A day ago

@ wimb

@ antonino61

 

But also it is good before apply Win_Reduce to delete on Tasks Scheduller (taskschd.msc) all tasks related to Edge and OneDrive (if we are not going to use them), to avoid generate their respective *.log files every boot, this could also apply to other Apps to be deleted when running Win_Reduce especially in case of 20H2, if you want you can export as a *.xml file each task before delete it (just in case, during your tests), it is good to also dissable the respective service for this tasks, but only if it does not have any dependencies, latter this delete/dissable procedure could also be automated implementing it into Win_Reduce.

 

Once we have easily identified (during the testing procedure on full installation before reduction) on the GUI Tasks Scheduller (taskschd.msc) those tasks we want to delete, this can also be done in command line by means of schtasks.exe, wich I think will be more useful to be used in Win_Reduce_Trusted program.

 

schtasks.exe page

 

 

The schtasks.exe tool performs the same operations as Scheduled Tasks in Control Panel. You can use these tools together and interchangeably.

 

 

if I may, can a correlation be made between services and respective files, so that the absence of, say, the windows update service (I do not remember what it is called) will more or less "automatically" lead to a deletion of all possible files related to it? that would be the real substantial improvement, both in terms of "system-cleanliness" and in terms of used space on the vhd.

Good observation my friend, only thing I would like to add is apply this approach to both: deleted tasks and disabled/deleted services.

 

In fact I don't know how much used space we can gain, and I don't think it could be very much, but certanly if there is something we will not use, there is no reason to keep it (unless it may cause certain issue).

 

alacran


  • wimb and antonino61 like this

#669 alacran

alacran

    Gold Member

  • .script developer
  • 2303 posts
  •  
    Mexico

Posted A day ago

Found the main reason for the extra 400 lines in my case ....

 

Main reason is that 16 extra \Windows\SystemApps are removed in case of Mini-10x64 of alacran.

 

Now my Mini-10x64 21H2 has 17.418 files and 20H2 has 17.231 files ....

 

Will continue to search for improvements .....

 

Good numbers, now better than mine, of course it also depends of programs installed by the user.

 

As mentioned on previous posts, I have this programs installed: 7-zip, CCleaner, Sumatra PDF, Classic Shell and ImDisk Toolkit by v77

 

Could you share what programs you have installed?

 

alacran



#670 wimb

wimb

    Platinum Member

  • Developer
  • 3473 posts
  • Interests:Boot and Install from USB
  •  
    Netherlands

Posted A day ago

Could you share what programs you have installed?

 

 

Only 7-zip is Installed and also Added to VHD by Win_Reduce is the Port_Apps Folder with calc, fab, Search and Wub given in Win_reduce\Add_Folders_Files\Port_Apps

 

I have removed additionally \Windows\SystemApps\Microsoft.Windows.CloudExperienceHost_* which is still present in your Mini-10x64


  • alacran likes this

#671 antonino61

antonino61

    Gold Member

  • Advanced user
  • 1225 posts
  •  
    Italy

Posted A day ago

Attaboy to both of u. Pls refer to get-alladafluff-out at ur will, in any attempt to systematize and coordinate the "brute-force" reduction process. Btw, are redundant entries in win_reduce annoying in terms of overall efficiency, or just in terms of formal cleanliness?



#672 alacran

alacran

    Gold Member

  • .script developer
  • 2303 posts
  •  
    Mexico

Posted A day ago

JFYI

 

I was able to reduce a little more my Mini-10x64.vhd

 

Uninstalled CCleaner and now I'm using the CCleaner Portable last version on Y:\Portables\CCleaner, moved some stuff that was in Documents to drive Y: and removed \Windows\SystemApps\Microsoft.Windows.CloudExperienceHost_* (as wimb suggested)

 

But keep installed: 7-zip, Sumatra PDF, Classic Shell and ImDisk Toolkit programs.

 

Fab is on C:\fab folder, as I use to have it always, CalcPlus, SwiftSearch and Wub are on Y:\Portables, each one into their respective folder.

 

Used space is now 1.53 GB after boot, (was 1.57 GB), free space is 468 MB now (was 426 MB), please see attached photo.

 

The VHD has now 17645 files (was 18388).

 

When we started cuts/reductions, I always had in my mind 1.5 GB as the more desirable goal. Well that goal has been almost reached, I'm now about 30 to 32 MB short.  But I don't want to get rid of the programs I still conserved (they consume only 25.5 MB).   So it will be better start looking for other options.

 

alacran

Attached Thumbnails

  • Mini-10x64 Filedisk on 4 GB Ram PC.png

  • wimb and antonino61 like this

#673 antonino61

antonino61

    Gold Member

  • Advanced user
  • 1225 posts
  •  
    Italy

Posted A day ago

of course, no point in getting rid of what one likes. me, I have always used the following philosophy - installed in, portable out.



#674 alacran

alacran

    Gold Member

  • .script developer
  • 2303 posts
  •  
    Mexico

Posted 15 hours ago

JFYI

 

Well, after all I can say I reached my desired Goal:

 

From the info in this post:

 

 

After fist boot:  Used space = 1.51 GB    Free space = 487 MB    Used Ram = 730 MB

 

That info was gotten from the Filedisk booted VHD.

 

But I ran Clean_All-Full.cmd, just before closing it and reboot, and when booting from my normal installed 10 OS, mounted the VHD to make the respective FileList, running Dir_List by means of PowerRun to get the best accurate results.

 

From mounted VHD, I got this data:    Used space = 1.50 GB    Free space = 505 MB   Files = 17505

 

Please see attached photo and FileList.

 

To all effects this are the real numbers our PC will use to launch the OS into the VHD, when booting as Filedisk, and of course will vary once the OS reach the desktop and writes anything to the VHD and/or to Ram.

But we can run Clean_All-Full.cmd, just before closing the OS into the VHD to get rid of almost all the undesired additional files.

In case of Ramboot the used size will remain unchanged, keeping the size as just after installed (keeping always the used size under 1.5 GB), as all additional files are volatile because they were written on the Ram.

 

alacran

Attached Thumbnails

  • Mini-10x64-20H2-final.png

Attached Files


  • wimb likes this





Also tagged with one or more of these keywords: ramdisk, grub4dos, wimlib, svbus, windows 10, ssd, usb, wim, vhd, wimboot

7 user(s) are reading this topic

0 members, 7 guests, 0 anonymous users