Topic: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.  (Read 14363 times)

ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
« on: March 07, 2013, 10:47:31 AM »

gbrao

  • Chef
  • ***
  • Date Registered: Sep 2011
  • Posts: 258
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.

Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
« Reply #1 on: March 07, 2013, 11:10:34 AM »

Galapo

  • Moderator, Gena Baker
  • Grand Chef
  • *****
  • Location: Australia
  • Date Registered: Sep 2010
  • Posts: 2207
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.

Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
« Reply #2 on: March 07, 2013, 11:19:13 AM »

anshad

  • Chef
  • ***
  • Date Registered: Apr 2012
  • Posts: 323
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:

Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
« Reply #3 on: March 07, 2013, 11:29:01 AM »

gbrao

  • Chef
  • ***
  • Date Registered: Sep 2011
  • Posts: 258
- 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.
« Last Edit: March 07, 2013, 11:31:33 AM by gbrao »

Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
« Reply #4 on: March 07, 2013, 11:48:47 AM »

anshad

  • Chef
  • ***
  • Date Registered: Apr 2012
  • Posts: 323
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:
« Last Edit: March 07, 2013, 02:39:14 PM by anshad »

Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
« Reply #5 on: March 07, 2013, 12:11:06 PM »

gbrao

  • Chef
  • ***
  • Date Registered: Sep 2011
  • Posts: 258

Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
« Reply #6 on: March 07, 2013, 02:23:10 PM »

anshad

  • Chef
  • ***
  • Date Registered: Apr 2012
  • Posts: 323
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:
« Last Edit: March 07, 2013, 02:38:52 PM by anshad »

Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
« Reply #7 on: March 07, 2013, 02:33:08 PM »

gbrao

  • Chef
  • ***
  • Date Registered: Sep 2011
  • Posts: 258
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:.



Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
« Reply #8 on: March 07, 2013, 02:46:34 PM »

anshad

  • Chef
  • ***
  • Date Registered: Apr 2012
  • Posts: 323
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.

Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
« Reply #9 on: March 09, 2013, 12:13:11 AM »

Galapo

  • Moderator, Gena Baker
  • Grand Chef
  • *****
  • Location: Australia
  • Date Registered: Sep 2010
  • Posts: 2207
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.

Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
« Reply #10 on: March 09, 2013, 04:44:51 AM »

gbrao

  • Chef
  • ***
  • Date Registered: Sep 2011
  • Posts: 258
right now with MEDIA.DRIVE copied to the vhd : http://i.imgur.com/eDlN107.jpg

Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
« Reply #11 on: March 09, 2013, 06:01:55 AM »

Galapo

  • Moderator, Gena Baker
  • Grand Chef
  • *****
  • Location: Australia
  • Date Registered: Sep 2010
  • Posts: 2207
Yep, looks fine to me.

Regards,
Galapo.

Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
« Reply #12 on: November 02, 2013, 06:14:59 PM »

gbrao

  • Chef
  • ***
  • Date Registered: Sep 2011
  • Posts: 258
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).
« Last Edit: November 03, 2013, 07:04:24 AM by gbrao »

Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
« Reply #13 on: November 03, 2013, 10:29:29 PM »

Galapo

  • Moderator, Gena Baker
  • Grand Chef
  • *****
  • Location: Australia
  • Date Registered: Sep 2010
  • Posts: 2207
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.

Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
« Reply #14 on: April 25, 2017, 08:03:35 AM »

ZYX

  • Code Baker
  • Jr. Chef
  • **
  • Date Registered: Apr 2017
  • Posts: 59
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?

Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
« Reply #15 on: April 27, 2017, 05:31:10 AM »

Galapo

  • Moderator, Gena Baker
  • Grand Chef
  • *****
  • Location: Australia
  • Date Registered: Sep 2010
  • Posts: 2207
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.

Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
« Reply #16 on: April 27, 2017, 07:13:25 AM »

ZYX

  • Code Baker
  • Jr. Chef
  • **
  • Date Registered: Apr 2017
  • Posts: 59
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?

Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
« Reply #17 on: April 27, 2017, 07:43:17 AM »

Galapo

  • Moderator, Gena Baker
  • Grand Chef
  • *****
  • Location: Australia
  • Date Registered: Sep 2010
  • Posts: 2207
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.

Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
« Reply #18 on: April 27, 2017, 10:03:03 AM »

ZYX

  • Code Baker
  • Jr. Chef
  • **
  • Date Registered: Apr 2017
  • Posts: 59
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?

Re: ExpEnvVar, MEDIA.DRIVE & BootDI HDD image.
« Reply #19 on: April 27, 2017, 12:34:54 PM »

Galapo

  • Moderator, Gena Baker
  • Grand Chef
  • *****
  • Location: Australia
  • Date Registered: Sep 2010
  • Posts: 2207
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.

 

Powered by EzPortal