Bug 145 - Tries to mount /etc/fstab entries in file install
Status: RESOLVED DUPLICATE of bug 147
Alias: None
Product: Unreal Tournament 2003
Classification: Unclassified
Component: Installer/Updater
Version: Full (Build 2107)
Hardware: PC Linux
: P2 normal
Assignee: Ryan C. Gordon
QA Contact:
URL:
Depends on:
Blocks:
 
Reported: 2002-09-29 16:03 EDT by David Jung
Modified: 2002-10-04 18:14:06 EDT
1 user (show)

See Also:



Description David Jung 2002-09-29 16:03:33 EDT
During the install, on every file that is being copied/installed in the
graphical installer, the terminal windows shows several messages like:
mount: No medium found
mount: /dev/sda1 is not a valid block device
mount: /dev/sdb1 is not a valid block device
mount: /dev/sdc1 is not a valid block device
mount: /dev/fd0 is not a valid block device

Each of these corresponded to an /etc/fstab entry for which the media wasn't
present, or the devices wasn't connected (the sdaX devices are for USB portable
drives).
The result of this was an *extremely slow* install.  I just temporarily
commented the corresponding entries from the /etc/fstab (as the install was in
progress) and the messages stoped (and the install proceeded as the
expected/normal speed).

The installation was done as root (I haven't tried it as a regular user).
I am running Redhat 8.0-beta2 (null).

The process name of the install was .setup1988 (in case it's relevant).

Also, the install eventually ended with an "Install Aborted" message advising to
press exit to clean up temporary files.  I don't know if that is related either.
Comment 1 Ryan C. Gordon 2002-10-02 01:55:05 EDT
Can you look at the conversation in Bug #147 and see if it resolves your problem?

--ryan.

Comment 2 Ryan C. Gordon 2002-10-02 06:52:34 EDT
(oh, and you can try setting the environment variable SETUP_CDROM to the
directory where the CDs will be mounted? I haven't tried this, but a loki_setup
developer tells me this should help.)

--ryan.

Comment 3 David Jung 2002-10-02 11:59:11 EDT
To follow up...
Yes, it sounds related to bug #147.
I sucessfully installed the game - although I don't know if this is helpful.
Originally I was installing as the root user and had the trouble.  On my second
attempt I installed as a regular user.  That changed the default install dir,
that's all.  I still had the fstab entries commented out - so I don't know if
that would have been a problem or not.
Also, the abort error I mentioned was probably a CD read issue.  The original
install was from a high-speed DVD drive, the second time I uses a slow CDRW
drive and it went through fine (without complaining about a file).

On both occasions I did install directly from the script on the C3 - without
copying it somewhere else first.
I haven't tried setting the CDROM_SETUP environment variable (as I mananged to
get it to install anyway).  

Thanks for the help.
Cheers.
Comment 4 David Jung 2002-10-02 12:24:04 EDT
I can see the problem, but not sure how it could be fixed appropriately...
In the loki_setup CVS, version 1.39 of the detect.c file contains the code:

<pre>

   /* Try to mount unmounted CDROM filesystems */
    mountfp = setmntent( FSTAB, "r" );
    if( mountfp != NULL ) {
        while( (mntent = getmntent( mountfp )) != NULL ){
            if ( !strcmp(mntent->mnt_type, MNTTYPE_CDROM) 
#ifdef sgi
		|| !strcmp(mntent->mnt_type, "cdfs")
#endif
		|| !strcmp(mntent->mnt_type, "auto") ) {
                char *fsname = strdup(mntent->mnt_fsname);
                char *dir = strdup(mntent->mnt_dir);
                if ( !is_fs_mounted(fsname)) {
                    if ( ! run_command(NULL, "mount", fsname, 1) ) {
                        add_mounted_entry(fsname, dir);
                        log_normal(_("Mounted device %s"), fsname);
                    }
                }
                free(fsname);
                free(dir);
            }
        }
        endmntent(mountfp);
    }
</pre>
Obviously, it is trying to mount anything that has the fs type set to auto. 
That's not really appropriate (esp. not for every file access!), however I don't
know a good way to single out only CDROM entries.
Under Redhat they are called /dev/cdrom, /dev/cdrom1 etc.  
I don't know if they can be called other names (e.g. if someone had a SCSI/USB
cdrom drive called /dev/sda1 or something.)
Perhaps a special case can look for just /dev/cdromX entries and failing to find
any, or failing to find the install CD, can prompt the user to select the CDROM
device from a dropdown list?
Would the cdrecord program have any logic that can look at devices at a lower
level to find CDROM drives? (yuk!)

Hope this helps.
Comment 5 Ryan C. Gordon 2002-10-04 18:14:06 EDT
(I'm going to flag this as a duplicate of bug #147, so all the information is
linked together.)

--ryan.

*** This bug has been marked as a duplicate of 147 ***