4.5. Drive labels and serial numbers with wine

Written by Petr Tomasek Nov 14 1999

Changes by Andreas Mohr Jan 25 2000

(Extracted from wine/documentation/cdrom-labels)

Until now, your only possibility of specifying drive volume labels and serial numbers was to set them manually in the wine config file. By now, wine can read them directly from the device as well. This may be useful for many Win 9x games or for setup programs distributed on CD-ROMs that check for volume label.

4.5.1. What's Supported?

File SystemTypesComment
FAT systemshd, floppyreads labels and serial numbers
ISO9660cdromreads labels and serial numbers (not mixed-mode CDs yet !)

4.5.2. How To Set Up?

Reading labels and serial numbers just works automagically if you specify a Device= line in the [Drive X] section in your ~/.wine/config. Note that the device has to exist and must be accessible if you do this, though.

If you don't do that, then you should give fixed "Label" = or "Serial" = entries in ~/.wine/config, as Wine returns these entries instead if no device is given. If they don't exist, then Wine will return default values (label Drive X and serial 12345678).

If you want to give a "Device" = entry only for drive raw sector accesses, but not for reading the volume info from the device (i.e. you want a fixed, preconfigured label), you need to specify "ReadVolInfo" = "0" to tell Wine to skip the volume reading.

4.5.3. EXAMPLES

Here's a simple example of cdrom and floppy; labels will be read from the device on both cdrom and floppy; serial numbers on floppy only:

[Drive A]
"Path" = "/mnt/floppy"
"Type" = "floppy"
"Device" = "/dev/fd0"
"Filesystem" = "msdos"

[Drive R]
"Path" = "/mnt/cdrom"
"Type" = "cdrom"
"Device" = "/dev/hda1"
"Filesystem" = "win95"
        

Here's an example of overriding the CD-ROM label:

[Drive J]
"Path" = "/mnt/cdrom"
"Type" = "cdrom"
"Label" = "X234GCDSE"
; note that the device isn't really needed here as we have a fixed label
"Device" = "/dev/cdrom"
"Filesystem" = "msdos"
        

4.5.4. Todo / Open Issues