Jump to content











Photo
* * * * - 4 votes

Adding Driver after boot (not before)


  • Please log in to reply
495 replies to this topic

#476 Bukvod

Bukvod

    Frequent Member

  • Advanced user
  • 123 posts
  •  
    United States

Posted 03 August 2010 - 09:03 AM

[codebox]@echo off setLocal EnableDelayedExpansion title Smart Driver Import color 1f cd /d "%~dp0" for %%d in (b c d e f g h i j k l m n o p q r s t u v w x y z) do ( if exist %%d:\drivers set dir=%%d:\drivers ) if exist %dir% goto sdb if exist b: md b:\Drivers if exist b:\drivers goto nx if exist r: md r:\Drivers if exist r:\drivers goto nx if exist x: md x:\Drivers if exist x:\drivers goto nx :nx for %%r in (b r x) do if exist %%r:\drivers set dir=%%r:\drivers if exist %dir% goto sdb call dipe.cmd & exit :sdb if not exist lpeh if exist run.vbs call run.vbs echo. if exist incl goto incl sdb_console /SAVE:NONMS /WIN:C:\WINDOWS /DEST:%dir% if exist %dir%\*.log del %dir%\*.log dir /b %dir%>lis goto lis **********************************************changed :incl set WinDrives= for %%d in (b c d e f g h i j k l m n o p q r s t u v w x y z) do ( if exist %%d:\NUL call :IsWinDrive %%d ) if WinDrives== goto Finished_SDB for %%d in (%WinDrives%) do ( sdb_console /SAVE:NONMS /WIN:%%d:\WINDOWS /DEST:%dir%\temp ) goto Finished_SDB :IsWinDrive if exist %1:\windows\system32\winlogon.exe set WinDrives=%WinDrives% %1 goto :EOF :Finished_SDB ******************************************************changed if exist %dir%\temp\*.log del %dir%\temp\*.log dir /b %dir%\temp>lis :lis for /F "delims=" %%j in (lis) do ( set line=%%j set line=!line: =`! echo.!line!>> lisu ) for /F "delims=" %%j in (ndlist.txt) do ( set line=%%j set line=!line: =`! echo.!line!>> lndu ) set count=0 for /F "tokens=* delims=" %%j in (lndu) do ( set /A count+=1 echo.set v!count!=%%j>>lnd ) echo.@echo off>ln copy ln+lnd+fstr lnp.cmd > nul :lp If not exist lnp.cmd goto lp call lnp.cmd for /F "delims=" %%j in (linu) do ( set line=%%j set line=!line:`= ! echo.!line!>> lfin ) if exist incl goto inc for /f "tokens=* delims=" %%a in (lfin) do ( echo.rd /s /q "%dir%\%%a">>lil ) copy ln+lil lid.cmd > nul goto ld :inc for /f "tokens=* delims=" %%a in (lfin) do ( echo.xcopy "%dir%\temp\%%a" "%dir%\%%a" /i /y >>lil ) copy ln+lil lid.cmd > nul :ld If not exist lid.cmd goto ld call lid.cmd > nul if exist "%dir%\temp" rd /s /q "%dir%\temp" > nul call dipe.cmd exit[/codebox]Here is how and what we modified in your batch file. It works but Im not sure that SDB_CONSOLE can to find the drivers. If the host drive has been pushed back from c: to d: and run this new batch file it compiles a list from all the drives that has a winlogon.exe in windows/system32 folder and pulls all the drivers from each drive. In my case the audio card drivers are not in the windows folder and the drivers that have been pulled are in the drivers folder inculding the audio card but the 3 files that are needed to be loaded that are not in the windows folder are not there. The driver import log shows the files could not be copied because it could not find them on C:. After inspecting the host registery the location has been hard coded to C:. My guess is that if the proper driver files are not in the windows folder then it uses the registry entry to locate the driver and if the host drive has but pushed back to D: it can not locate the files for that driver. Is there any way to keep the Host at C: when using wimboot? Here is the modified Batch file

#477 Bukvod

Bukvod

    Frequent Member

  • Advanced user
  • 123 posts
  •  
    United States

Posted 03 August 2010 - 02:41 PM

Amalux,
Can you test this change we made? I have had some time to try it fully incorporated into a build on my home computer and it WORKS !!!!( before I was manually running it on computer at work ) My home computer boots completely up silently and adds Lan , Wireless, and Audio and it only adds about 20secs to the boot time. I added 2 fake (windows\system32\winlogon.exe) on different drives, have my recovery partition and my host drive has been moved from C: to D:, so Sdb_console is running 4 times and it works perfect on my home computer. I still think it will fail on my computer at work but that may be an isolated situation just with that one particular sound card driver. I'd like to see if you and a couple other would try it and see what the results are? Thanks

#478 amalux

amalux

    Platinum Member

  • Tutorial Writer
  • 2813 posts
  •  
    United States

Posted 03 August 2010 - 10:34 PM

Hi Bukvod,

I've been hammered at work all day, just finding some time to look at your script, it looks good :o , so you want sdb to grab drivers from all windows directories, not just the first it finds. My only concern was time and you say that's not a problem so I guess this should be added as an option in the script :D .


My guess is that if the proper driver files are not in the windows folder then it uses the registry entry to locate the driver and if the host drive has but pushed back to D: it can not locate the files for that driver. Is there any way to keep the Host at C: when using wimboot?

I don't see wimboot as the culprit in shifting C: to D:, it's just a function of Windows working around your usb-hd (or similar). My experience has been that if the drivers exist in Windows directory, regardless of drive letter, sdb will find and back them up. It's possible that there is another issue to look at, sdb now discards any M$ drivers, I left it like this because originally there was no include only option and it does take more time and space etc. It may be that the drivers you need are M$! I haven't run into this issue but I can see it happening. An easy test would be to direct sdb (use the stand alone program included in the build) to the Windows directory and backup ALL drivers (or just look for the ones you need); if this gets you the drivers you need, we can look at adding this option as well but I need to confirm this won't cause unwanted problems. I still think it's best to do these 'extended' searches after login, e.g. do a quick search and install at runonce but if drivers not found, give options for additional search parameters when manually run or possibly just have sdb gui open and let people choose their own drivers, what do you think?

#479 Bukvod

Bukvod

    Frequent Member

  • Advanced user
  • 123 posts
  •  
    United States

Posted 04 August 2010 - 08:32 AM

I guess that to each there own. I personal like being able to grab the drivers automatically from every drive possible just due to the fact the the host drive seems to move. I can also see why having a user interaction to select the proper windows folder is also is a valid option also. I personally think that if the correct drivers are not loaded automatically the user can easily run Smart driver backup to get the correct ones if possible.(see below)

As far as wimboot, Only if using Wimboot does my host drive get moved.??? I have experienced a few wierd things also. It is possible it has only to do with using the dummy usb filter script in junction with Wimboot. I made a new bootable USB. I made two partitions then I copied the masterboot record from my original USB bootable drive to the new one and copied all the files from my 2nd partition root of original booting USB including the wimboot iso file to the 2nd partition root of the new USB. Now when I use the new usb, my boot partition moves back to G: and the first non booting USB partiton takes C:??? Why! Why! Why!???????

The driver Import program ran from desktop cannot import the sound driver either if the host has been shifted back to D: The driver is for "SoundMAX Integrated Digital High Definition Audio" and the files it needs are located at C:\Program Files\Analog Devices\Core\.I truley believe now that it fails with just this one particular Sound Card maker. As a test, I made the directory stucture and copied the needed files to my boot partition to mimick the host and low and behold it works fine. I really would like to know why the drives move??? Does anyone know why this is happening? My friends laptop has this same sound card and it does the same on it (does not find the files). I really like Wimboot as my perfered way to make LiveXP, but I really would like the Host drive to stay at C:. If its not wimboot then what else can it be. BootSDI script always leaves the host as C: but with Wimboot is seems to move all over the place.

#480 amalux

amalux

    Platinum Member

  • Tutorial Writer
  • 2813 posts
  •  
    United States

Posted 04 August 2010 - 05:50 PM

As far as wimboot, Only if using Wimboot does my host drive get moved.??? I have experienced a few wierd things also. It is possible it has only to do with using the dummy usb filter script in junction with Wimboot.

I just booted from a wimboot iso residing on the first active (ntfs) partition of a dual partition usb-hd
usb_hd.png
sure enough, when booted up, L: shifts to C: (and C: to D:); I think this is 'normal' for Windows, it sees the usb first (based on bios settings) and tries to assign the first active boot disk it sees as C: etc. Now, sdbdipe (di70 and yours) was able to gather all drivers from D: without issue and dipe installed them fine on my system.


I made a new bootable USB. I made two partitions then I copied the masterboot record from my original USB bootable drive to the new one and copied all the files from my 2nd partition root of original booting USB including the wimboot iso file to the 2nd partition root of the new USB. Now when I use the new usb, my boot partition moves back to G: and the first non booting USB partiton takes C:??? Why! Why! Why!???????

I don't know, something to do with how the drives are setup or ??? A screen shot like the one above would be interesting...


The driver Import program ran from desktop cannot import the sound driver either if the host has been shifted back to D: The driver is for "SoundMAX Integrated Digital High Definition Audio" and the files it needs are located at C:\Program Files\Analog Devices\Core\.I truley believe now that it fails with just this one particular Sound Card maker. As a test, I made the directory stucture and copied the needed files to my boot partition to mimick the host and low and behold it works fine.

Very good detective work and it does seem to be a limitation in sdb (and dipe gui). If we knew every possible scenario like this a batch could be written but...


I really would like to know why the drives move??? Does anyone know why this is happening? My friends laptop has this same sound card and it does the same on it (does not find the files). I really like Wimboot as my perfered way to make LiveXP, but I really would like the Host drive to stay at C:. If its not wimboot then what else can it be. BootSDI script always leaves the host as C: but with Wimboot is seems to move all over the place.

I think I understand what you're saying now :D , bottom line, you want host C: to stay C: and wimboot iso to use other partition to boot from (well, it's actually booting from X: but you know what I mean) when using usb-hd, right? You say this works with bootsdi built iso on usb-hd? I can't find a bootsdi iso, I'll have to build one to test...

#481 amalux

amalux

    Platinum Member

  • Tutorial Writer
  • 2813 posts
  •  
    United States

Posted 04 August 2010 - 07:22 PM

I just tested with bootsdi image on usb-hd and get same results as wimboot image.
lxbsdi_usb1.png

in pe:
lxbsdi_usbhd_pe.PNG

It's not wimboot vs. bootsdi, it's removable vs. fixed; no?

#482 Bukvod

Bukvod

    Frequent Member

  • Advanced user
  • 123 posts
  •  
    United States

Posted 04 August 2010 - 07:55 PM

I was primarily using bootsdi in my builds and never saw the host drive moved. I download your tutorial build and since have been using it as my base to build from. I changed to your base due to my previous post about programs and documentand setting folder being used one on x and the other b. Let me go back and build a bootsdi.iso with my old base and see what happens I will post the results.

I also have a question somewhat offtopic but you showed me how to inject something in iso image, and it got me thinking is there any script or procedure to autosave a booted build. So any changes are saved like in virtualbox?

#483 amalux

amalux

    Platinum Member

  • Tutorial Writer
  • 2813 posts
  •  
    United States

Posted 04 August 2010 - 08:06 PM

There is ImageCreator which claims to do this but I have had limited success.

#484 Bukvod

Bukvod

    Frequent Member

  • Advanced user
  • 123 posts
  •  
    United States

Posted 06 August 2010 - 08:10 AM

Amalux,
I have repeated tried different combinations with both BOOTSDI and WIMBOOT. All with the same result. If Boodsdi is used compressed or not with W2003 ramdisk.sys and Setupldr, firadisk or WinVblock the Host drive stays at C:. If Wimboot is used in anyway the Host gets moved back from c: to d:. I tried everything from using al the lastest scripts to mix and matching to using your base script with updated app scripts but everytime I use WIMBOOT the the host gets moved.

Also anytime I use anything but your base, My documents and settings for livexp shows up on B: and X: along with the program files folder? Ive check the settings between your base and what is available on winbuilder server and made them exactly the same but still get the same result. Do you have any idea as to why this is?

I think I am going to just settle with the larger slower BOOTSDI with your base as a model,as there are too many problems with the host moving to D:.Do you have any suggestions?
I can post a couple of screenshot I took if you would like.

#485 amalux

amalux

    Platinum Member

  • Tutorial Writer
  • 2813 posts
  •  
    United States

Posted 06 August 2010 - 03:13 PM

Amalux,
I have repeated tried different combinations with both BOOTSDI and WIMBOOT. All with the same result. If Boodsdi is used compressed or not with W2003 ramdisk.sys and Setupldr, firadisk or WinVblock the Host drive stays at C:. If Wimboot is used in anyway the Host gets moved back from c: to d:. I tried everything from using al the lastest scripts to mix and matching to using your base script with updated app scripts but everytime I use WIMBOOT the the host gets moved.

--
I think I am going to just settle with the larger slower BOOTSDI with your base as a model,as there are too many problems with the host moving to D:.Do you have any suggestions?
I can post a couple of screenshot I took if you would like.

You know I love screenshots :D , i really don't know what else to tell you; as said, i can't reproduce this odd behavior on my machines. BootSDI and WimBoot both boot similarly in this respect; shifting C: dependent on active primary assigned before original C: or not (e.g. an active primary usb partition) which has nothing to do with WimBoot. BootSDI is great! If this solves your issue, go with BootSDI!


--
Also anytime I use anything but your base, My documents and settings for livexp shows up on B: and X: along with the program files folder? Ive check the settings between your base and what is available on winbuilder server and made them exactly the same but still get the same result. Do you have any idea as to why this is?

These settings are in the project options here:
1.png
2.png
3.png

Hope that helps :D

#486 Bukvod

Bukvod

    Frequent Member

  • Advanced user
  • 123 posts
  •  
    United States

Posted 07 August 2010 - 12:09 AM

Since you love screenshots. Here you go........
This is BOOTSDI build from home computer. BOOT is 2nd partition of boot usb.
Posted Image

This is screenshot of another BOOTSDI build from computer at work.
Posted Image

Also, Notice both found audio driver. YES! BootSDI is a liitle bigger (100M) and a little slower to boot. But works fantastic just wish I had some answers to why Wimboot is behaving this way. Also to note, I tried winbuilder 80 and your version of winbuilder (76sp6)? I think that is it.

I hate to keep asking , but heres another. Notice on the screenshots above the first one shows a virtual removable cd labeled BootSDI. How do you make that show up like that? Some of my experimental build had it and some did not?? I like it because it may make it easier to figure out a way to back up LiveXP booted in RAM.

At any rate, I thank you for all you have done to improve LiveXP and to try and help us beginners.

P.S. I added a reply to the WIMBOOT forum on this issue to see if anyone knew if what was causing this!

#487 amalux

amalux

    Platinum Member

  • Tutorial Writer
  • 2813 posts
  •  
    United States

Posted 07 August 2010 - 12:40 AM

Nice screenies! :unsure:

Glad it's working well and happy to help.

Are you sure that's a virtual drive? UltraISO or other can create virtual drives but that looks like a CD you're booting from :D

:dubbio:

#488 Bukvod

Bukvod

    Frequent Member

  • Advanced user
  • 123 posts
  •  
    United States

Posted 07 August 2010 - 08:02 AM

Yes, Its a virtual drive created by LiveXP build.How or why I'm not sure. I do not know much of the basics. Does wimboot or bootsdi create a virtual drive to boot into Ram? Maybe this has something to do with the Host drive moving????

#489 amalux

amalux

    Platinum Member

  • Tutorial Writer
  • 2813 posts
  •  
    United States

Posted 07 August 2010 - 08:56 AM

It doesn't seem to be one of my projects (untouched), imdisk B: etc so it's just guess work now.
If I boot a bootsdi image from first pri-active of two partition usb-hdd it looks like this in windows:
usb_hd1.png

and this in PE (note the C: to D: slide):
usb_hd2.png

Same image booted from CD (usb-hdd removed), like this in windows:
cd1.png

and this in PE (closest to yours):
cd2.png

#490 dsolomon

dsolomon

    Frequent Member

  • Advanced user
  • 243 posts

Posted 06 June 2011 - 09:08 PM

ok, so i am using v70 of DrvImpe_AmaluxE.script
works GREAT!
my only gripe is how it decompresses my .7z archives from driverpacks.net to find a suitable driver.
at the root of my CD i have a "Drivers" folder with 2 .7z archives in it.
lan.7z and wlan.7z
and when my LiveXP PE starts up it decompresses both these archives into my B:\ (IMDISK) drive until it finds the correct driver.
and then leaves all remaining drivers in my IMDISK drive.If i decompress my lan.7z and my wlan.7z i get a total of 318MB in my Valuable IMDISK drive.
is there a "cleaner" way of autoinstalling my driverpacks without taking up all of my IMDISK Space?

#491 amalux

amalux

    Platinum Member

  • Tutorial Writer
  • 2813 posts
  •  
    United States

Posted 06 June 2011 - 09:35 PM

Hi dsolomon,

That is very odd behavior and definitely not by design. There is no overt unpacking of archives by the script or internal batch commands; Dipe searches the archives intact and only unpacks specific drivers matching hardware found on your machine. Why unpacked archives are ending up in your B: drive is a mystery.

Are you sure the files are from the archives? Is it possible you're importing drivers from your host with the SDBackup portion of the script? If so, you just need to tighten up the include/exclude parameters in the script UI or turn off SDB altogether if you're supplying DriverPacks. You'll have to give me enough information (log is a good start) to try and reproduce this strange condition; also a screen shot of your script settings will help.

#492 dsolomon

dsolomon

    Frequent Member

  • Advanced user
  • 243 posts

Posted 06 June 2011 - 10:22 PM

my apologies amalux.
the behaviour of my DrvImpe_AmaluxE.script "autosearch" feature is as follows.

1. LiveXP PE starts up
2. DIPE "Autosearch" Feature initiates
3. DIPE "Autosearch" finds lan.7z and wlan.7z in "drivers" folder at root of my CD
4. DIPE Starts decompresses .7z files into B:\drvimp_dps\ (as shown below - the "drvimp_dps" folder is at 9MB of my 10MB available in my IMDISK)

Posted Image
5. (Im Assuming), DIPE Purges any drivers that are not suitable from my IMDISK to make room for more decompressed drivers from lan.7z and wlan.7z
6. when both archives are fully searched - DIPE deletes the "drvimp_dps" folder from my IMDISK - leaving me with plenty of space.

i am not using the SDbackup feature either. the drivers listed in my B:\drvimp_dps\ folder are 100% from lan.7z and/or wlan.7z. also to add - i am not using the "Include drivers in build for dipe to autoload at startup" feature.
the driverpacks i am using are
http://driverpacks.n.../x86/wlan/11.01
and
http://driverpacks.n...p/x86/lan/11.01
im downloading those two .7z archives and placing them in the "Drivers" folder on the root of my CD.

attached is my log. and below is my settings for v70 DrvImpe_AmaluxE.script.

thx for the prompt reply =)
Posted Image

also to add - here is a screeshot of my mounted drives in my livexp PE
Posted Image
RAM_DRIVE (B:) - IMDISK
OS (C:) - Sick Windows HD
Boot (X:) - Ram loaded I386 and Program Files Folders
WimPE (D:) - PE CD

Attached Files

  • Attached File  log.zip   420.65KB   381 downloads


#493 amalux

amalux

    Platinum Member

  • Tutorial Writer
  • 2813 posts
  •  
    United States

Posted 06 June 2011 - 11:12 PM

OK, I'm guessing this has to do with the fact your running Dipe from RO media and something interrupts Dipe before it has a chance to clean up that temp folder. Hard to say what until I run some tests but it seems to me you could add a clean up routine in my batch that would catch this. Something like:

for %%r in (b r x) do if exist %%r:\drvimp_dps set dps=%%r:\drvimp_dps
if exist %dps% rd /s /q "%dps%"


You can add this to the :end section in dipe.cmd to see if it helps. I'll run some tests to confirm as well and add to script for next release.

:cheers:

#494 dsolomon

dsolomon

    Frequent Member

  • Advanced user
  • 243 posts

Posted 06 June 2011 - 11:19 PM

my initial post to my issue was slighty wrong.
after DIPE runs and finds the appropriate drivers - the folder in my B:\ drive with the decompressed drivers is deleted.
The problem is the fact that DIPE is decompressing my .7z archives in my B: drive until it finds the right one.
so if it finds the correct driver quickly - then i may have 2MB of decompressed drivers in my B: drive. but if it takes forever to find the correct drivers - then i could end up with my entire B: drive full.

#495 amalux

amalux

    Platinum Member

  • Tutorial Writer
  • 2813 posts
  •  
    United States

Posted 06 June 2011 - 11:42 PM

Now I'm confused, if the folder is deleted you should have all of your available space back, no? You're saying it can take Dipe a long time to import the drivers and during this time temp space is taken up? In my builds, using the same DriverPacks archives, the whole process takes only seconds and I never see the temp folder because it's gone by the time the shell is loaded.

Can I ask why you don't use the 'Include drivers in build for Dipe to auto load at startup' option? It seems perfect for your situation and takes up no space on your system drive for drivers or temp files, all is deleted immediately before shell loads if runonce autostart is selected. The process is very fast this way as opposed to running from RO media, have you tried using this way? Also there is version 71 which is even faster than 70.

:cheers:

#496 dsolomon

dsolomon

    Frequent Member

  • Advanced user
  • 243 posts

Posted 07 June 2011 - 12:03 AM

hmm.... ok. i pointed my 'Include drivers in build for Dipe to auto load at startup' option to a folder that has my lan.7z and wlan.7z archives.
im building now and will test shortly.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users