The Oven

Project World => Gena HomePage => Gena Support => Topic started by: gbrao on March 07, 2013, 10:47:31 AM

Title: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: gbrao on March 07, 2013, 10:47:31 AM
When I boot the HDD image created by BootDI directly ( not from the ISO, but using g4d ) I get the error message
"ExpEnvVar Error information file
 Error: no tag file found
 Expected tag file was: MEDIA.DRIVE"

Is there any harm in just copying MEDIA.DRIVE to the HDD image ?

Background : I was using wimboot rather than iso until recently. But due to problems with Recuva (http://theoven.org/index.php?topic=524.0) I switched to iso. I then thought it would be better to use a HDD image instead because it is easier to modify/update a img/vhd - I boot from HDD/UFD using g4d, I haven't booted from CD/DVD in years.
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: Galapo on March 07, 2013, 11:10:34 AM
All applications are located inside the HDD image?

If so, then I think the appropriate location if you are booting it directly is within the image, i.e., it will reside on %SystemDrive% once booted.

Regards,
Galapo.
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: anshad on March 07, 2013, 11:19:13 AM
Hi Grabo

MEDIA.DRIVE is the tag file used to identify the boot medium (CD or USB) and set "%cddrive%" variable. That file should be presented in the root of boot media and not inside your HDD image. I believe copying MEDIA.DRIVE to the root of your  CD should solve the problem :smile:
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: gbrao on March 07, 2013, 11:29:01 AM
- yes everything is in the HDD image ( i'm using a vhd actually ). i copied all files from the img generated by bootdi to the vhd.

- there is no cd or iso at all. i'm booting from a vhd using grub4dos.

btw, the vhd works ok with or without the MEDIA.DRIVE file, if it is not present i only get a error popup.
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: anshad on March 07, 2013, 11:48:47 AM
Hi Gbrao

how did you boot your VHD?. If you are using a USB drive copy MEDIA.DRIVE to the root of your USB drive. I am no expert in VHD :grin:
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: gbrao on March 07, 2013, 12:11:06 PM
see : http://i.imgur.com/jNhF7mT.jpg
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: anshad on March 07, 2013, 02:23:10 PM
Hi Gbrao

So basically your VHD file will be loaded in to memory by Grub4DOS (like ISO mem mapping) before booting from it. If that is the case removing tag file search will be best for you. I am not sure how to do that (need to edit the script). Either Galapo or Lancelot can help.

btw..your boot disk looks nice :thumbsup:
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: gbrao on March 07, 2013, 02:33:08 PM
yes, vhd booted from memory. vhd easy to modify, update,  defrag ;-) .

made some more improvements. systemdrive is writable i moved user profiles to systemdrive. set ramdrive to r:.


Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: anshad on March 07, 2013, 02:46:34 PM
Hi Gbrao

Grub4dos uses int15 hooking to boot images. Once the image loaded in to memory interrupt redirection will be lost. BIOS won't see virtual devices loaded in memory like memory mapped ISO or HDD image.That is the reason  ExpEnvvar can't see your tag file. I am not sure if there any work around exists.
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: Galapo on March 09, 2013, 12:13:11 AM
Ok, good. Copy MEDIA.DRIVE file to the root of your HDD image for the time being.

When I get time, I can provide the option to on ShortcutsCentro to disable the tagfile and simply set the %CDDrive% variable to what %SystemDrive% expands to.

Regards,
Galapo.
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: gbrao on March 09, 2013, 04:44:51 AM
right now with MEDIA.DRIVE copied to the vhd : http://i.imgur.com/eDlN107.jpg
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: Galapo on March 09, 2013, 06:01:55 AM
Yep, looks fine to me.

Regards,
Galapo.
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: gbrao on November 02, 2013, 06:14:59 PM
I made a GENA vhd as per the OP today. I'm not using LetterSwap.

On boot, I get a ExpEnvVar popup saying "No proper tag file found. Alternate tag file found. Select one or none". If I select "X" it works OK. Is there any way to avoid that popup ?

The vhd has BOOTFLAG & MEDIA.DRIVE .

EDIT : OK managed to avoid the popup.
1) Uncompressed BOOTFLAG & MEDIA.DRIVE.
2) Made a ISO and copied that MEDIA.DRIVE to the VHD. Is the content of the MEDIA.DRIVE checked ? The MEDIA.DRIVE I used earlier was from my prev vhd (Gena=2013.03.08 14:59:37).
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: Galapo on November 03, 2013, 10:29:29 PM
Hi gbrao,

Sorry for the delay in reply, I'm on holiday with the family at the moment. :surfing:

Yes, the content of MEDIA.DRIVE is checked. You'll see that a build date is written. This is checked to make sure that the drive that has been detected is the one of the running PE.

Regards,
Galapo.
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: ZYX on April 25, 2017, 08:03:35 AM
Sorry for the necromancy of this old thread, but I have the similar problem with this tag file. I have multi-boot USB flash drive which has Syslinux boot manager and I have several Gena builds in different ISO files on it, they are loaded during boot using memdisk.

I could copy MEDIA.DRIVE from some ISO build into the root of UFD, but it seems that ExpEnvVar.exe is checking the date which is stored in that file with the build date stored in ExpEnvVar.txt inside of each ISO. The problem is that those ISOs are made on different dates.

Is there any way to disable that tag checking during boot?
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: Galapo on April 27, 2017, 05:31:10 AM
ExpEnvVar.exe is able to use whatever tag file you want. However, the project doesn't yet provide the option to the end user to set another file. Currently it is hardcoded in ShortcutsCentro.

Possibly we could adjust this to a user option or a default build-specific option of something like MEDIA-%ProjectName%-%BuildDate%.DRIVE

Regards,
Galapo.
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: ZYX on April 27, 2017, 07:13:25 AM
ExpEnvVar.exe is able to use whatever tag file you want.
I am not sure that understand what you are saying.

Here is one example: I have two builds saved as two ISO files on the same UFD, I made Syslinux menu to choose which one of them I want to boot. Those two builds have different dates in their MEDIA.DRIVE files. If I copy MEDIA.DRIVE from the first one to the root of UFD, when I boot the first ISO everything is fine, but when I boot the second one I get the message "No proper Tag file found - alternate Tag files on drives - pick one or None". Similarly, when I copy MEDIA.DRIVE from the second ISO to the root of UFD, the boot of the second ISO is fine, but when I try to boot the first one I get the mentioned message.

I don't want to get that message with any build. Is there any way to accomplish that?

Consider I am dumb. Could you explain to me as simple as possible why that checking is required at all?
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: Galapo on April 27, 2017, 07:43:17 AM
Sorry for the confusion. :embarrassed:

What I meant was that the executable file that processes this stuff (ExpEnvVar.exe) will support what you are after. However, Gena does not support this feature yet. There will need to be some plugins modified with this in mind, starting with ShortcutsCentro.

We found that the checking was needed because we were getting various issues from end-users (I forget the details now). The checking is there to make sure that the build date of the PE system files corresponds to the non-system files (which can be located outside of the ISO etc in various ways).

Regards,
Galapo.
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: ZYX on April 27, 2017, 10:03:03 AM
The only issue that I have now is that one with the error message during boot and the fact that that checking just slows down the boot (and the another one that Avast is reporting ExpEnvVar.exe as a malware when it is unUpx-ed, but that was in LiveXP, I don't see it anymore in Gena, but maybe that is because I have now disabled all unUpx-ing).

When I remove MEDIA.DRIVE from the root of the UFD, I get the mentioned message on the boot, but after that it seems that everything is working fine. So, I don't see any purpose of this checking, it just leads to such nuisance with that message.

Could you explain what the date of the build has in connection with the correspondence with "the non-system files" (outside of ISO or wherever)?

Is there any possibility for me to remove that checking through the editing of some plugin code, if not though the settings? What will happen if I remove all references to ExpEnvVar.exe in all plugins?
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: Galapo on April 27, 2017, 12:34:54 PM
Is there any possibility for me to remove that checking through the editing of some plugin code, if not though the settings? What will happen if I remove all references to ExpEnvVar.exe in all plugins?

Umm, you will totally stuff up your PE. :heh:

ExpEnvVar.exe is used for a number of things, e.g., writing various registry entries that can only be added at boot-time; setting some variables; etc. You therefore can't get rid of it without either substituting it with something else that does the same things, or causing many problems which ExpEnvVar.exe is used to solve.

Regards,
Galapo.
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: ZYX on April 27, 2017, 01:10:44 PM
Ok, I understand that it is needed for various stuff, but you said that "ExpEnvVar.exe will support what you are after." Is that means that the .exe file already supports disabling of the checking of tag file without the need for its modification and recompilation? In another words, could I disable that checking by modification of ShortcutsCentro by myself, if you don't have time for that?

I just would like to get yes/no answer, I don't want to waste my time analyzing its code just to find out that that is not possible.
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: Galapo on April 27, 2017, 01:22:11 PM
you said that "ExpEnvVar.exe will support what you are after."

Yes, that's right. The executable itself already has built into it the ability to able to use whatever tag file is specified on the commandline. It is not limited to MEDIA.DRIVE.

However, like I said, the Gena project does not yet leverage that functionality to do what you desire. Someone will need to code this into the project, starting with the ShortcutsCentro plugin.

Regards,
Galapo.
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: ZYX on April 27, 2017, 01:47:03 PM
Sorry for bothering you, but I think you didn't understand my request. I don't want an ability to specify any tag file. I want to be able to completely disable tag file checking during boot. Is that possible or not?

What is the purpose of this checking if everything is working fine without found MEDIA.DRIVE file?
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: Galapo on April 28, 2017, 12:55:57 AM
Hi ZYX,

The fact that your PE is working fine means that ExpEnvVar.exe, along with the tag file, are doing their job.  :great: Remove either of them and like I said you will completely stuff up your PE. If either was not needed, then we wouldn't be making use of them. :thumbsup:

ExpEnvVar.exe accomplishes a number of tasks at boot and cannot be removed without another program being written to do the same things.

The tag file is needed so that the drive can be identified and various shortcuts and registry entries that couldn't be written at build-time due to the unknown drive letter can be written and generated at boot-time. So remove the tag file and you will have shortcut and registry problems in your PE, particularly under various conditions.

The tag file mechanism can be improved, as you suggest. The person to do this will need to start with the ShortcutsCentro plugin and work out from there.

Regards,
Galapo.
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: ZYX on April 28, 2017, 05:39:23 AM
The fact that your PE is working fine means that ExpEnvVar.exe, along with the tag file, are doing their job.  :great: Remove either of them and like I said you will completely stuff up your PE.
...
So remove the tag file and you will have shortcut and registry problems in your PE.
It seems you still don't understand. Here is what I said few posts ago:

When I remove MEDIA.DRIVE from the root of the UFD, I get the mentioned message on the boot, but after that it seems that everything is working fine.
That's right, in many of my tests I don't have MEDIA.DRIVE file in the root of UFD, and yes, I get the message how that file is missing, but after I click on the OK button I get all schortcuts fine and everything is working fine. How is that if you say that it is needed?

I understand that ExpEnvVar.exe is needed for a number of other tasks at boot, but I don't want it to do the tag file checking. Ok, maybe that tag file is really needed in some occasions with some another configurations, but that should not be a reason for such nuisance with that message in other configurations like mine. Maybe there is a way that you find out in which configurations it is needed during build and only in that case that it is set for checking on the boot.

As I said, what is also important with that tag checking beside of that annoying message, is the fact that your tag checking is slowing down the boot significantly, especially with computers containing many disk partitions. For me, and I suppose for many other users, the boot time is very important characteristic of WinPE.
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: Lancelot on April 28, 2017, 11:13:50 AM
Hi ZYX, Galapo,

There are 3 reasons I know that effects scan drives.

* Empty Floppy

ZYX make sure
Gena\Components\Tweaks\"Remove Floppy A Mount Point"
or
Gena\Components\Tweaks\"Remove Floppy ALL Mount Point 'BL MountVol'"
Selected

* Empty MMC Card Reader

@Galapo
As far as I remember
Gena\Apps\Portable Finder CMD
Avoid this Empty MMC thing

Also
At
SE\Build\CdDrive - X: - Y:
Chris might did something to "MountPEMedia.exe" to avoid Empty MMC delay.




:turtle:
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: Galapo on April 29, 2017, 01:59:38 AM
That's right, in many of my tests I don't have MEDIA.DRIVE file in the root of UFD, and yes, I get the message how that file is missing, but after I click on the OK button I get all schortcuts fine and everything is working fine. How is that if you say that it is needed?

Yep, that's expected. ExpEnvVar.exe is smart. :smile: It has detected an end-user making a mistake and has chosen to attempt what it detects as the mostly likely configuration to get a working PE. :great: :great:

Maybe there is a way that you find out in which configurations it is needed during build and only in that case that it is set for checking on the boot.
Yes, it's basically under all conditions when programs are run from a location other than %SystemDrive%.


@Lancelot
I can't see within 'Portable Finder CMD' or MountPEMedia.exe where MMC delay is avoided.

I do have MMC stuff coded into Flush.exe and call pull stuff from there if needed.

By the way, you said you knew three reasons that give a drive scanning delay, but only gave us two.  :wink:

Regards,
Galapo.
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: ZYX on April 29, 2017, 06:25:27 AM
No, I don't have floppy drives or card readers in my test computers. I do have CD-drives in my two laptops, but as you could see from the tests that I posted in another thread (http://theoven.org/index.php?topic=2110.msg23313#msg23313), the newest desktop computer which don't even have CD drive is slower than the older laptop which have CD drive. However, that newer computer has one more internal HD drive having more partitions, and I suspect that is a reason for slower boot on newer and faster computer. And as I said in that another thread, when I had attached one external USB hard drive, I got at least 10 seconds longer boot. I am pretty sure that searching for the tag file causes that.

@Galapo
Do ExpEnvVar.exe have any command line switch to turn off checking for MEDIA.DRIVE file? Is there any way to force it to "attempt what it detects as the mostly likely configuration to get a working PE" without displaying that annoying message about missing tag file?

By the way, it is not my end-user mistake if I have two or more ISO files made on different dates put on the same UFD with single MEDIA.DRIVE in the root of UFD, in which case I would get the another error message during boot with all ISOs, except the one which is that tag file.
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: Galapo on April 29, 2017, 04:24:36 PM
Hi ZYX,

I have just uploaded an updated version of the ShortcutsCentro plugin. It now has some options for more advanced tagfile naming. For example, you can locate tagfiles into a tagfile folder and have different ones there for different builds.

Still to do:
1) Update WimBoot
2) Update ExpEnvVar.exe to support disabling of build-date checking

Regards,
Galapo.
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: Galapo on April 29, 2017, 04:38:34 PM
WimBoot now updated as well.

Regards,
Galapo.
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: Galapo on April 29, 2017, 05:05:41 PM
And tagfile date checking can now be disabled. Of course, do this at own risk.  :wink:

Regards,
Galapo
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: ZYX on April 29, 2017, 06:53:23 PM
Galapo, thank you very much for this! It works great!

I have tested several different basic configurations until now (BootDI_CAB+My_WimPack_Outside_System, WimBoot+My_WimPack_Outside, WimBoot+WimPack_VMDK_Outside) with single MEDIA.DRIVE in the root and didn't get error message with any of them, all shortcuts are there and programs are starting fine.

If I knew that my request could be accomplished without modification of ExpEnvVar.exe I wouldn't bother you so much before trying to change ShortcutsCentro by myself.

I have just one small suggestion and one question. The check box has caption: "Disable ExpEnvVar.exe tagfile date checking (only enable if you know what your're doing)". I think that someone could think that used "enable" verb is related to the tag checking, but not to the checked state of the control, i.e. it could be interpreted as "Enable ExpEnvVar.exe tagfile checking only if you know what you are doing". I think it would be better if you use term "turn on" or "check on" or "tick on" - i.e. "only check on if you know what you are doing".

The question is related to the %ProgramTitle% variable. What is it? Is it just "Gena" or it could be user specified? I already saw that in some plugin code and tried to find it where could be defined. It seems to me that all builds made by Gena have that same %ProgramTitle% and hence I don't know how that variable is useful in naming tag file. I doubt that I will ever use some another tag name different than the default one, since I have now that disabled date checking that you added, just saying my opinion about it.

Thanks again!
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: Galapo on April 30, 2017, 05:24:14 AM
Hi ZYX,

Thanks for your feedback and comments.

I've uploaded another updated version. This has your suggestion of more clear information in the new checkbox. Also it now checks whether shortcuts.exe is selected for PE1 and provides a message to instead use FreeShc.exe.

%ProgamTitle% in a plugin is a variable specified for each plugin. It will be listed under [Variables].

Regards,
Galapo.
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: ZYX on April 30, 2017, 09:07:23 AM
Thanks!
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: ZYX on May 07, 2017, 09:22:10 AM
WimBoot now updated as well.

I am getting an error with the initial empty project and this update. Here is the relevant part of log file:
             [Success] IF - [] is not equal to: [backup] evaluated string: [If,Not,%backup%,Equal,backup,Begin]
                   [Success] IniRead - [%BaseDir%\Projects\Gena\script.project] Section [IniVariables] Key [Media_Tagfile] to variable: [%Media_Tagfile%] with value []
                   [Success] IF - [] is equal to: [] evaluated string: [If,%Media_Tagfile%,Equal,"",Begin]
                         [Ignore] IF - File exists: [%BaseDir%\ISO\Gena\HddBoot\MEDIA.DRIVE] evaluated string: [If,Not,ExistFile,%RAMFolder%\%pTextBox5%,FileCreateBlank,%RAMFolder%\%pTextBox5%]
                         [Success] ELSE - executing command: [Begin]
                               [Success] StrFormat - converted: [%TargetDir%\%Media_Tagfile%] to variable: [%Media_Tagfile_Filename%] with result: []
                               [Success] StrFormat - converted: [%TargetDir%\%Media_Tagfile%] to variable: [%Media_Tagfile_Folder%] with result: [%BaseDir%\Target\Gena\]
                               [Ignore] IF - Directory exists: [%BaseDir%\Target\Gena\] evaluated string: [If,Not,EXISTDIR,%Media_Tagfile_Folder%,DirMake,%Media_Tagfile_Folder%]
                               [Success] IF - File does not exist: [%BaseDir%\Target\Gena\] evaluated string: [If,Not,ExistFile,%TargetDir%\%Media_Tagfile%,FileCreateBlank,%TargetDir%\%Media_Tagfile%]
                              [Failed] Cannot create file "%BaseDir%\Target\Gena\". The system cannot find the path specified: [FileCreateBlank,%TargetDir%\%Media_Tagfile%]
                              [Warning] Halt
                         Run - Processed section [Perform-RAM_exclude] in file: [%BaseDir%\Projects\Gena\Finals\2 Create Image\WimBoot.script]

I think you have one End on wrong place. Here is your added code:
    If,%Media_Tagfile%,Equal,"",Begin
      If,Not,ExistFile,%RAMFolder%\%pTextBox5%,FileCreateBlank,%RAMFolder%\%pTextBox5%
      Else,Begin
        StrFormat,FILENAME,%TargetDir%\%Media_Tagfile%,%Media_Tagfile_Filename%
        StrFormat,PATH,%TargetDir%\%Media_Tagfile%,%Media_Tagfile_Folder%
        If,Not,EXISTDIR,%Media_Tagfile_Folder%,DirMake,%Media_Tagfile_Folder%
        If,Not,ExistFile,%TargetDir%\%Media_Tagfile%,FileCreateBlank,%TargetDir%\%Media_Tagfile%
      End
    End

It works fine with this:
    If,%Media_Tagfile%,Equal,"",Begin
      If,Not,ExistFile,%RAMFolder%\%pTextBox5%,FileCreateBlank,%RAMFolder%\%pTextBox5%
    End
    Else,Begin
      StrFormat,FILENAME,%TargetDir%\%Media_Tagfile%,%Media_Tagfile_Filename%
      StrFormat,PATH,%TargetDir%\%Media_Tagfile%,%Media_Tagfile_Folder%
      If,Not,EXISTDIR,%Media_Tagfile_Folder%,DirMake,%Media_Tagfile_Folder%
      If,Not,ExistFile,%TargetDir%\%Media_Tagfile%,FileCreateBlank,%TargetDir%\%Media_Tagfile%
    End
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: Galapo on May 07, 2017, 01:20:29 PM
Thank you for reporting this. I have uploaded an updated version.

Regards,
Galapo.
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: ZYX on May 09, 2017, 06:42:12 AM
I am thinking to write my own plugin for adding portable apps or to modify some existing one, it should find the booting drive. I could use the approach used in WimPack whose WimMount.cmd looks for a drive with the WIMs folder when VMDK is enabled, but I would like to avoid that because it is just another scanning of drives which could slow down the boot.

Is there any way to:
- start some batch file after ExpEnvVar finished with scanning and found the booting drive containing MEDIA.DRIVE;
- get the drive letter of the booting drive from it?
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: Galapo on May 09, 2017, 08:32:24 AM
At boot you will have a %CDDrive% variable set containing the drive letter where MEDIA.DRIVE tagfile was found.

Booting drive for PE will always be %SystemDrive% and thus X:.

Regards,
Galapo.
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: ZYX on May 09, 2017, 10:04:38 AM
Sorry for not being clear and for wrong terminology. I have multiple WinPEs put on the same UFD as ISOs or extracted their image files, e.g. into I386 folder, all made with BootDI or WimBoot. I have on the same UFD one folder containing portable apps, e.g. Programs, and MEDIA.DRIVE in its root. I have Syslinux boot manager and I choose from its menu which PE I want to boot.

After I boot one PE, I get its system folder always on X:, but the Programs folder is on the UFD which has not a fixed drive letter, it could be any, so I need to find it out scanning all drives for that folder.

If I understand you correctly, the %CDDrive% variable contains the drive letter where MEDIA.DRIVE was found by ExpEnvVar which will be my UFD. I am now wondering, when exactly that happens during boot. If I want to modify e.g. WimPack whose WimMount.cmd is executed during boot, will it have %CDDrive% already determined? Is your ExpEnvVar.exe executed and set the mentioned variable before WimMount.cmd starts?
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: Galapo on May 09, 2017, 10:13:09 AM
If I understand you correctly, the %CDDrive% variable contains the drive letter where MEDIA.DRIVE was found by ExpEnvVar which will be my UFD.

Yes, that's right.

Is your ExpEnvVar.exe executed and set the mentioned variable before WimMount.cmd starts?

The relevant ExpEnvVar.exe call is made under RunOnceEx registry entry with the name '480'. WimPack runs with the name '000', so it executes earlier.

Regards,
Galapo.
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: ZYX on May 09, 2017, 10:22:36 AM
Ok, thanks. Obviously, it will be safest to do the scanning for the wanted drive without relaying on the result of ExpEnvVar scan.
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: Lancelot on June 21, 2017, 10:55:03 AM
Apps\System Tools\Portable Finder CMD
Apps\System Tools\Portable Finder Startup
Apps\System Tools\Portable Finder Startup CD

plugins there and provide method to do your own portable organizations freely.

->
"Portable Finder Startup" plugin should accomplish what you are after.

:turtle:
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: gbrao on July 05, 2017, 07:27:16 AM
If you use grub4dos to boot a GENA ISO and you get the "Error: no tag file found" message it could be due to grub4dos.

I was using v 0.4.6a 2016-12-24 of grub4dos on one of my systems and got that error. In fact GENA could not read the contents of the WinPE (CD) drive - it said unrecognised file system. I could not understand why. It worked OK on another system. Then it occured to me it might be grub4dos. When I installed grub4dos-0.4.5c-2016-01-18 it worked OK.

In fact the problem I mentioned here : http://theoven.org/index.php?topic=2164.0 might also be due to that.

grub4dos download : http://grub4dos.chenall.net/downloads/grub4dos-0.4.5c-2016-01-18/
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: Lancelot on July 05, 2017, 02:44:43 PM
Hi gbrao,

As you already know, In order to get Gena.iso (CreateISO) boot with grub4dos,
2 ways are, you need firadisk or winvblock
Gena\Drivers\5 Ramdisk\"FiraDisk"
Gena\Drivers\5 Ramdisk\"WinVBlock"

on other topic, you seem to use "FiraDisk" ,
test Gena.iso (CreateISO) with "WinVBlock" with  v0.4.6a 2016-12-24 of grub4dos
let us know how it goes ?

:turtle:
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: gbrao on July 08, 2017, 11:17:49 AM
with WinVBlock and  v0.4.6a 2016-12-24 of grub4dos, using wimboot I get the "Error: no tag file found". I need a small ISO thats why I use wimboot.

[attach=1]

I'll try with createiso later.
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: Lancelot on August 14, 2017, 11:48:10 AM
I'll try with createiso later.
And result ?
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: gbrao on August 15, 2017, 03:00:51 AM
haven't had the time, I'll do it this week end.
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: gbrao on August 19, 2017, 08:35:18 AM
Used Create ISO. These plugins:
 [attach=1]

G4D menu :
[attach=2]


System Intel Haswell + Z87.

g4d 4.6a and no usb thumb drive attached - BSOD 7B
g4d 4.6a and usb thumb drive attached - BSOD 7B


g4d 4.5c and no usb  thumb drive attached - boots OK
g4d 4.5c and usb  thumb drive attached (first boot after starting up system) : BSOD 7F
g4d 4.5c and usb  thumb drive attached (subsequent start ups) : boots OK.


That is, if the system was shut down and then I start it up and try to boot from the ISO with a UFD attached  I get a BSOD.
But the system was booted OK from another windows or pe, then I restart the system and try to boot the ISO with a UFD attached , then it works OK.
Both the above with g4d 4.5c.
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: Lancelot on August 19, 2017, 11:22:47 PM
But the system was booted OK from another windows or pe, then I restart the system and try to boot the ISO with a UFD attached , then it works OK.

I get the "Error: no tag file found". I need a small ISO that's why I use wimboot.

One by one:
Following topic, when you use CreateISO + grub4dos + isoboot , with a successful boot, you do not have "Error: no tag file found" anymore?
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: gbrao on August 20, 2017, 04:36:05 AM
One by one:
Following topic, when you use CreateISO + grub4dos + isoboot , with a successful boot, you do not have "Error: no tag file found" anymore?
[/quote]

No
Title: Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
Post by: Lancelot on August 20, 2017, 04:58:05 PM
then you fix the error you have.  :thumbsup:

Further:
For SE or Gena, when you boot with from .iso (via grub4dos, grub, isolinux etc.) you need to provide an ini file
See topic:
http://theoven.org/index.php?topic=346
For Gena see reply1

:turtle: