MSFN Forum: Repacking driver.cab - MSFN Forum

Jump to content


  • 2 Pages +
  • 1
  • 2
  • You cannot start a new topic
  • You cannot reply to this topic

Repacking driver.cab Rate Topic: -----

#1 User is offline   RyanVM 

  • Like a big surly teddy bear.
  • PipPipPipPipPipPipPipPip
  • Group: Members
  • Posts: 2,661
  • Joined: 31-August 03

Posted 12 September 2004 - 08:42 PM

OK, I tried searching for the answer, but IBB is pretty much useless in its search functionality. What are the settings used for makecab when recompressing driver.cab (after combining it with the other driver cabs) that allows for faster decompression? Is it just lowering CompressionMemory?


#2 User is offline   big poppa pump 

  • Damn Newbies!!
  • PipPipPip
  • Group: Members
  • Posts: 406
  • Joined: 10-September 03

Posted 12 September 2004 - 10:30 PM

I pretty much used the default settings in powerarchiver when I recompressed driver.cab and sp2.cab

#3 User is offline   RyanVM 

  • Like a big surly teddy bear.
  • PipPipPipPipPipPipPipPip
  • Group: Members
  • Posts: 2,661
  • Joined: 31-August 03

Posted 13 September 2004 - 07:13 AM

This is driving me nuts, because I think it was GreenMachine who posted on this before, but I can't find his post.

#4 User is offline   Bâshrat the Sneaky 

  • aka Wim Leers
  • PipPipPipPipPipPipPipPip
  • Group: Members
  • Posts: 2,214
  • Joined: 29-October 03
  • OS:none specified
  • Country: Country Flag

Posted 13 September 2004 - 09:16 AM

RyanVM, on Sep 13 2004, 03:13 PM, said:

This is driving me nuts, because I think it was GreenMachine who posted on this before, but I can't find his post.

Why don't you take a look at Jdeboeck's batch files? They are able to remove drivers and other stuff and then recompress everything!

http://jdeboeck.msfnhosting.com

#5 User is offline   knight_dkn 

  • Uber Nerd
  • Pip
  • Group: Members
  • Posts: 70
  • Joined: 06-January 04

Posted 13 September 2004 - 09:33 AM

Here's the link to a specific thread about CABARC.EXE (CabARC) It's part of a discution on longhorn but it's the correct tool to use for making CAB's for XP install discs.

Here's the command line for it:
cabarc -r -p -m LZX:21 N mmssetup.cab *.*


I've used it several times when I was building both unattended XP install discs and testing MCE 2005. It's part of an offical Microsoft SDK that you can download free from their site (sorry cant remember where). It's offical name is "Cabinet Software Development Kit" the commands I've put in are very well documented but I've found I can shave a few meg off any standard MS cab by using this higher compression optimisation.

#6 User is offline   RyanVM 

  • Like a big surly teddy bear.
  • PipPipPipPipPipPipPipPip
  • Group: Members
  • Posts: 2,661
  • Joined: 31-August 03

Posted 13 September 2004 - 10:00 AM

Bâshrat the Sneaky, on Sep 13 2004, 11:16 AM, said:

RyanVM, on Sep 13 2004, 03:13 PM, said:

This is driving me nuts, because I think it was GreenMachine who posted on this before, but I can't find his post.

Why don't you take a look at Jdeboeck's batch files? They are able to remove drivers and other stuff and then recompress everything!

http://jdeboeck.msfnhosting.com

That's what I use :P. It suffers from the slow decompression time that I'm referring to. IIRC, you can adjust the settings so that the cab ends up at around 100MB (instead of ~80MB), but decompresses way faster. Heck, nLite even has the option to do the one or the other.

I think I'm gonna PM nuhi to get him in this thread :P

#7 User is offline   RyanVM 

  • Like a big surly teddy bear.
  • PipPipPipPipPipPipPipPip
  • Group: Members
  • Posts: 2,661
  • Joined: 31-August 03

Posted 13 September 2004 - 10:01 AM

knight_dkn, on Sep 13 2004, 11:33 AM, said:

Here's the link to a specific thread about CABARC.EXE (CabARC) It's part of a discution on longhorn but it's the correct tool to use for making CAB's for XP install discs.

Here's the command line for it:
cabarc -r -p -m LZX:21 N mmssetup.cab *.*


I've used it several times when I was building both unattended XP install discs and testing MCE 2005. It's part of an offical Microsoft SDK that you can download free from their site (sorry cant remember where). It's offical name is "Cabinet Software Development Kit" the commands I've put in are very well documented but I've found I can shave a few meg off any standard MS cab by using this higher compression optimisation.

LZX:21 is what's giving you the higher compression. Those options are available with makecab as well, using the command switches /D CompressionType=LZX and /D CompressionMemory=21.

#8 User is offline   nuhi 

  • ON PAUSE - nLite & vLite human.dll
  • Group: Developers
  • Posts: 4,299
  • Joined: 25-October 03

Posted 13 September 2004 - 05:35 PM

In your cab ddf file enter
.Set FolderSizeThreshold=5000000

or
.Set FolderSizeThreshold=2500000


Thx to mr. GreenMachine

#9 User is offline   RyanVM 

  • Like a big surly teddy bear.
  • PipPipPipPipPipPipPipPip
  • Group: Members
  • Posts: 2,661
  • Joined: 31-August 03

Posted 13 September 2004 - 06:21 PM

THAT'S IT!!!

Thanks :D

(And I KNEW it was GreenMachine who posted it first :P)

#10 User is offline   prathapml 

  • Follow the rules please :-)
  • Group: Patrons
  • Posts: 6,791
  • Joined: 14-November 03
  • OS:Windows 7 x64
  • Country: Country Flag

Posted 13 September 2004 - 06:48 PM

either that, or you're looking for this:
makecab /D CompressionType=LZX /D CompressionMemory=21
This is for individual files, I suppose.

#11 User is offline   RyanVM 

  • Like a big surly teddy bear.
  • PipPipPipPipPipPipPipPip
  • Group: Members
  • Posts: 2,661
  • Joined: 31-August 03

Posted 13 September 2004 - 08:18 PM

prathapml, on Sep 13 2004, 08:48 PM, said:

either that, or you're looking for this:
makecab /D CompressionType=LZX /D CompressionMemory=21
This is for individual files, I suppose.

And it's completely irrelevant. In fact, I already said those settings weren't what I needed.

RyanVM said:

LZX:21 is what's giving you the higher compression. Those options are available with makecab as well, using the command switches /D CompressionType=LZX and /D CompressionMemory=21.
nuhi gave me exactly what I was looking for.

#12 User is offline   RyanVM 

  • Like a big surly teddy bear.
  • PipPipPipPipPipPipPipPip
  • Group: Members
  • Posts: 2,661
  • Joined: 31-August 03

Posted 13 September 2004 - 09:07 PM

OMG, that made a HUGE difference! And driver.cab was still only 78MB (no drivers removed).

Thanks a million! :thumbsup

#13 User is offline   Bâshrat the Sneaky 

  • aka Wim Leers
  • PipPipPipPipPipPipPipPip
  • Group: Members
  • Posts: 2,214
  • Joined: 29-October 03
  • OS:none specified
  • Country: Country Flag

Posted 14 September 2004 - 09:13 AM

RyanVM, on Sep 14 2004, 05:07 AM, said:

OMG, that made a HUGE difference!  And driver.cab was still only 78MB (no drivers removed).

Thanks a million! :thumbsup

Could you maybe higher that value to get an even smaller driver.cab?

#14 User is offline   RyanVM 

  • Like a big surly teddy bear.
  • PipPipPipPipPipPipPipPip
  • Group: Members
  • Posts: 2,661
  • Joined: 31-August 03

Posted 14 September 2004 - 10:00 AM

The point of that number isn't to increase compression, but to speedup decompression. Using the default value, it can take a long time to decompress files from there (setup will just "hang" from time to time).

FolderSizeThreshold=5000000 made a HUGE difference.

#15 User is offline   Pyron 

  • Junior
  • Pip
  • Group: Members
  • Posts: 84
  • Joined: 04-December 03

Posted 14 September 2004 - 03:04 PM

I just found this document :http://home.hiwaay.n...ive/makecab.doc, which explains makecab/ddf files in detail.
This is what it says about FolderSizeThreshold:

Quote

Folders are compression/encryption boundaries.  The state of the compressor and cryptosystem are reset at folder boundaries.  To access a file in a folder, the folder must be decrypted and decompressed starting from the front of the folder and continuing through to the desired file.  Thus, smaller folder thresholds are appropriate for a layout where a small number of files needs to be randomly accessed quickly from a cabinet.  On the other hand, larger folder thresholds permit the compressor to examine more data, and so generally yield better compression results.  For a layout where the files will be accessed sequentially and most of the files will be accessed, a larger folder threshold is best.

--
Pyron

#16 User is offline   RyanVM 

  • Like a big surly teddy bear.
  • PipPipPipPipPipPipPipPip
  • Group: Members
  • Posts: 2,661
  • Joined: 31-August 03

Posted 14 September 2004 - 03:59 PM

Good info to have - thanks! That definitely explains why 5000000 helped so much. I suppose if I were really bored, I'd see how 10000000 worked, but not now. I've got some other stuff on my plate to keep my busy ;) :P

#17 User is offline   GreenMachine 

  • ineXPlicable
  • Group: Developers
  • Posts: 3,062
  • Joined: 22-August 03

Posted 14 September 2004 - 06:23 PM

****, missed my chance. I don't seem to make it over here much. Glad you found it RyanVM, I suffered very, very much till I changed that.

The default value is infinity (or at least way too high), thus everything is compressed into one "folder". Problem is, setup access a few "random" files, at different times. Thus the "hang" when getting a file from the end of the folder. Another good trick, once you get the other stuff off your plate, would be to move the few files that ARE used during setup to the front of the file, possibly uncompressed, and then you could pack the rest tighter. Another Microsoft recommendation is to group similar files together. When creating the list of files to add to DRIVERS.CAB, I use the DIR command, with a qualifier (/O-E) to list files by extension, in reverse order. Thus the sys files come before the exe and dll files.

#18 User is offline   RyanVM 

  • Like a big surly teddy bear.
  • PipPipPipPipPipPipPipPip
  • Group: Members
  • Posts: 2,661
  • Joined: 31-August 03

Posted 14 September 2004 - 06:24 PM

Does Windows setup actually extract them in that order, though?

#19 User is offline   GreenMachine 

  • ineXPlicable
  • Group: Developers
  • Posts: 3,062
  • Joined: 22-August 03

Posted 14 September 2004 - 06:51 PM

From what I see, there are some files that are always extracted (us* for example), and others that are extracted if needed, e.g. if the hardware needing the drivers is found. I think there are more .sys files used then .dll or .exe files, which is why I put them in that order.

I played with it a bit, way back when, and it seemed the order tweaks did not make nearly the impact the folder size did. I still believe the best would be to study DOSNET.INF and TXTSETUP.SIF, and see which files are actually (always) extracted from DRIVERS.CAB, and put them uncompressed in the begining. On the other hand, I was assured that Microsoft did not do anything fancy like this, and I, like you, lost motivation to tweak every byte and second out of it.

So ... in answer to your question, I don't really know which order they are extracted in, but I am sure it is not sequentially.

#20 User is offline   Diabolical82 

  • Member
  • PipPip
  • Group: Members
  • Posts: 145
  • Joined: 22-June 04

Posted 15 September 2004 - 02:55 PM

Maybe it's stupid question, how do i edit ddf?

Share this topic:


  • 2 Pages +
  • 1
  • 2
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users



All trademarks mentioned on this page are the property of their respective owners
Copyright © 2001 - 2013 msfn.org
Privacy Policy