[LODR-U] DotNet_2 in 5 ways
#1
Posted 29 June 2009 - 10:28 AM
Update 30.08.09 for nt6.x http://www.mediafire..._vista_LODR.rar
There seems to be information about dotnet for PE spread all over, and lots of opinions about it too. Some of my own post are mostly hidden in other threads, about other stuff. A little summary of it;
The fact is;
- It is BLOAT
- Some good applications depends on it
- It can be added extremely easy to PE and don't necessarily need much free space to be added
The way I see it there's 5 different ways to add dotnet to PE;
1. Junctioning ramloading bootcd with ntfs formatted ramdisk image. Have the files collected and a registry patch. Make junction points from %SystemDrive% and to your externally connected disk where your dotnet2 files are. Does not work with vista and 2k8 sources because of wim format limitations. Requires less space in X:\.
2. Have an Installrite Kit (or similar) for dotnet2 to install. Works with ramloading, FBWF and EWF, and will require anything from 40-80 Mb of free space, depending on how stripped down your dotnet2 is.
3. This is a modification of number 2 that involves splitting the package in two, where the directory Microsoft.NET is placed externally and only the assembly & winsxs directories are located under %SystemRoot%. This only makes sense when NOT dealing with junction points on ntfs formatted X:\. It means that roughly 61 Mb (without much optimization) can be placed outside of X:\. The effect of this is that dotnet2 now is reduced to only 40 Mb uncompressed on the systemdrive.
4. Have a plugin or script that includes dotnet2 at buildtime.
5. Application virtualization like with ThinApp. Will fail to load certain complex applications because of the kernel drivers and system services that it depends on, but thinapped dotnet will work on less complex apps. Requires little space in %temp%.
I have not looked at dotnet 3.5 yet, but guess it's similar in structure to the previous versions.
My LODR dotnet2 package have 3 batches;
3 ways of adding (hotplugging) dotnet2 to a running windows livecd based on xp/2k3.
1. Execute for_ntfs.cmd. Will make junction points inside %SystemRoot% that points to externally located directories. Will only work on ramloading build with ntfs formatted ramdisks. Will copy only 2 Mb into %SystemRoot%.
2. Execute non_ntfs.cmd. Will be the same as an Installrite kit as it copies everything into %SystemRoot%. Will require about 92 Mb of free space on the systemdrive. To be used in companion with File Based Write Filter (FBWF) or Enhanced Write Filter (EWF).
3. Execute split_install.cmd. Copies only the assembly and winsxs directories into %SystemRoot%. Leaves the Microsoft.NET directory out of the systemdrive and therefore only requires 41 Mb of free space on the systemdrive (X:\). The path to the Microsoft.NET directory is currently hardcoded to "C:\LODR\dotnet2\Microsoft.NET" but can tweaked easily. If so, then open the file dotnet2_split.reg and replace the string C:\\LODR\\dotnet2\\Microsoft.NET with what is wanted.
The binaries have been upx'ed and tested, and it works. Confirmed working on LiveXP with 2k3 sources, BartPE with xpsp2 sources, and MOA with 2k3 sources. The complete dotnet2 platform can now be added to PE in a couple of seconds, following the above.
http://www.mediafire...gmk/dotnet2.rar
Joakim
(even though we all hate it, we sometimes can't live without it)
#2
Posted 30 June 2009 - 08:17 AM
#3
Posted 13 August 2009 - 05:38 PM
dotnet2.reg and dotnet_split.reg registry files should be cleaned. Monitoring a real install on Windows, you have a bunch of unwanted stuff (from Windows installer).
following keys and subkeys:
HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Installer\Features This key contains many <Package Code> keys. HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Installer\Products This key contains many <Package Code> keys. [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Installer] [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall]
You can safely remove all this crap. It's only used to modify, repair or remove an installer msi package.
You have also registy entries related to DW20:
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\VolumeCaches\Microsoft_Event_Reporting_2.0_Temp_Files] @="{5A79987F-5D0A-425C-B70D-E49AD5B6BF23}" [HKEY_LOCAL_MACHINE\SOFTWARE\Classes\AppID\{58FC39EB-9DBD-4EA7-B7B4-9404CC6ACFAB}] key and subkeys [HKEY_LOCAL_MACHINE\SOFTWARE\Classes\CLSID\{5A79987F-5D0A-425C-B70D-E49AD5B6BF23}] keys and subkeys [HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Services\EventLog\Application\Microsoft ® Visual C# 2005 Compiler] [HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Services\EventLog\Application\.NET Runtime 2.0 Error Reporting] [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\PCHealth\ErrorReporting\DW\Installed]useless...
For more infos, i have downloaded this interesting document from Microsoft:
Installing_DotNet_Framework
#4
Posted 30 August 2009 - 04:23 PM
http://www.mediafire..._vista_LODR.rar
It is a heavy modification of Max_Real Qnx's original script. Includes dotnet2 & VC 2005 Runtimes. Needs less than 30 Mb of free space in X:\, which means dotnet2 & vc2005 can easily be added to a standard vista recovery cd with scratchspace of 32 Mb without rebuilding it. Downloadable package is at 54 Mb.
From the readme.txt;
LODR for dotnet2 for vista/2008. 2 options; - dotnet2_vista_split_LODR.exe Installs to X:\ only the parts that cannot be placed outside %SystemRoot%, and keep the rest on alternative drive. Needs 29,6 Mb of free space on X:\. - dotnet2_vista_full_LODR.exe Installs all dotnet2 binaries to X:\, which means roughly 60 Mb of free space on X:\. There is no advantage of using this option so go for the split option. The Mb notations are given as compressed (since X:\ would be compressed). How To; Just place this folder ("dotnet2_vista_LODR") somewhere accessible to your running PE environment and execute dotnet2_vista_split_LODR.exe once. Dotnet2 is installed in a few seconds. Do not rename the folders inside this one. There should be 3 folders; "Microsoft.NET", "NativeImages" and "Windows". The path to dotnet2_vista_split_LODR.exe can be almost anything. Some examples; "D:\blabla\dotnet2_vista_split_LODR.exe" "H:\whatever\whatever\dotnet2_vista_split_LODR.exe" "R:\dotnet2_vista_split_LODR.exe" "X:\programs\dotnet2_vista_LODR\dotnet2_vista_split_LODR.exe"
Joakim
#5
Posted 22 September 2009 - 09:26 AM
dotnet2_win7rc1_LODR
Requires 46 Mb of free space on X:\.
Joakim
#6
Posted 16 December 2009 - 12:26 PM
On my XPSP3 PE Norton Ghost 14 tells me there is no .net installed, after running the non_ntfs.cmd
am I missing something?
Cu
#7
Posted 27 July 2010 - 04:46 PM
Dotnet2 also available the LODR way for Win7Pe (RC1). No beta sources supported.
dotnet2_win7rc1_LODR
Requires 46 Mb of free space on X:\.
Joakim
I'm new to the world of WinPE, but not to the world of IT.
I'm needing to get .net 2 into my Windows 7 Boot.wim. I tried the dotnet2_win7rc1_LODR, but I'm not sure that I'm calling the EXE correctly.
I unzipped the zip into X:\Windows\Temp\dotnet.... then call the EXE from there using the winpeshl.ini:
[Launchapps]
x:\windows\temp\dotnet2_win7_LODR\dotnet2_win7_LODR.exe
I get the DOS box that comes up and says that a "winpeshl.ini exists, but nothing was executed"
If go to the folder and try to execute dotnet2_win7_LODR.exe, I get the error message stating that the subsystem needed to run this is not installed.
What am I doing wrong, if there a better location to force PE to run an executable?
In the end, we are needing to launch a .net utility, that requires network access, before setup starts so we can gather info and create the unattended.xml, etc.
Any help would be greatly appreciated.
Thanks
#8
Posted 27 July 2010 - 04:52 PM
Read here first:
http://www.boot-land...?showtopic=6621
Wonko
#9
Posted 27 July 2010 - 05:48 PM
I guess you are missing the basic idea of the LODR-U approach.
Read here first:
http://www.boot-land...?showtopic=6621
Wonko
Wonko, thanks for the link, but I'm still a little lost. The link looks more like it is for building LODR packs, maybe I missed something in the 50+ pages . For now I'm interested in getting .net installed then I'll work on, I guess, building a LODR for our utility.
I basically just need to know how/where to call the LODR as winpe is booting. There's mention of the prenetwork-batch.cmd and late-batch.cmd. Are these normal winpe recognized cmd files? I can't find anything else about them on the net, so I'm guessing not.
Thanks,
Greg
#10
Posted 27 July 2010 - 06:15 PM
The LODR approach is a sort of "install on demand" from what you posted I thought you were looking to "install permanently" the stoopid thing to a PE that you want to re-package and somehow distribute.
It is possible that the actual .EXE doesn't work because:
- your PE misses some pre-requisite (libraries and what not)
- your PE is most probably RTM based, whilst the program was tested on rc1
You are booted in your PE and running directly from command prompt dotnet2_win7_LODR.exe gives you an error right?
Post the exact error, from what you write the error is due to #1.
Try tracing it with dependency walker and/or similar tools.
Wonko
#11
Posted 09 September 2010 - 03:27 AM
Any chance you can try to build for a win7 that is not rc1?
I have tried running it and it gives me an error saying that it will exit since the OS is not RC1. If not can you tell me what the exe does so i can try it in my build. Thanks
0 user(s) are reading this topic
0 members, 0 guests, 0 anonymous users