Windows 10 Drivers Not Copying


  • Moderator

    @uwpviolator Well then, I think you might want to change up your fog.drivers script a bit. Right now its working fine for win7 but not win10. So in the first script you posted modify this section of code.

    #############################################
    dots "Preparing Drivers"
    # below creates local folder on imaged pc
    # this can be anywhere you want just remember
    # to make sure it matches throughout! (case IS important here)
    clientdriverpath="/ntfs/Windows/inf/Drivers"
    remotedriverpath="/images/drivers/$machine/$osn/$arch"
    

    to this

    #############################################
    dots "Preparing Drivers"
    # below creates local folder on imaged pc
    # this can be anywhere you want just remember
    # to make sure it matches throughout! (case IS important here)
    if [ $osid -eq 9 ]
    then
        clientdriverpath="/ntfs/Drivers"
    else
        clientdriverpath="/ntfs/Windows/inf/Drivers"
    fi
    remotedriverpath="/images/drivers/$machine/$osn/$arch"
    

    You might ask, so what will that do for you? The patch tests to see what OS you are deploying. If the OSID==9 then you are deploying a win10 image. In that case it will copy the drivers to C:\Drivers, all other OS’ the drivers will be copied to C:\Windows\Inf\Drivers.

    Then in your unattend.xml file, tell oobe to look in c:\Drivers for its files.



  • @george1421 @Tom-Elliott

    Uploaded fresh image no unattended file. Still no files on HD. See my last reply. Which one do I replace in my fog.drivers file?



  • @tom-elliott

    This

    echo "System breakpoint";
    debugPause;
    
    rsync -azP "$remotedriverpath" "$clientdriverpath"
    [[ ! $? -eq 0 ]] && handleError "Failed to download driver information for [$machine/$osn/$arch]"
    
    echo "End driver copy";
    debugPause;```
    

    or This

    echo "System breakpoint";
    debugPause;
    
    rsync -azP "$remotedriverpath" "$clientdriverpath"
    
    echo "End driver copy";
    debugPause;
    

  • Moderator

    @uwpviolator You asked yesterday about the unattend.xml file. I started with my win7 config file and it worked for win10. But our config file was very basic. If you need a good starting point you can go to this web site to create a template unattend.xml file. http://windowsafg.no-ip.org/

    Just don’t put any private information into this configuration. Put generic license keys and such and then hand exit afterwards.



  • @tom-elliott @george1421

    So worked with George yesterday on this. Here is what we know and where we left of.
    Ran Debug
    Broke out of script after Driver Copy
    Checked the HD and the x64 folder was there and in it the test .txt file
    Then sysprep
    Folder is gone after sysprep

    So it might be an issue with unattended file. I did not make it it was from our last image which was Win 10 EDU 1609. I am going to upload a blank image with no unattended file and see if the file sticks.


  • Senior Developer

    I’d also suggest, for debugging, echoing the $clientdriverpath and $remotedriverpath variables instead of putting “System breakpoint”; This way you know exactly what the variables are defined as.


  • Senior Developer

    rsync -aqz "$remotedriverpath" "$clientdriverpath" >/dev/null 2>&1

    I might recommend changing the line above to something like:
    rsync -azP "$remotedriverpath" "$clientdriverpath"

    This should show progress as well as spit out any errors it may be running into giving you more information to look at.

    As for the post earlier, where you couldn’t cd to one to the OptiPlex folders, you would need to quote the string or escape the space. This could be something like:
    cd "OptiPlex 580" or cd OptiPlex\ 580


  • Moderator

    @uwpviolator Hmmm… that looks OK too.



  • @george1421

    #!/bin/sh
    ## This file serves as a starting point to call your custom postimaging scripts.
    ## <SCRIPTNAME> should be changed to the script you're planning to use.
    ## Syntax of post download scripts are
    #. ${postdownpath}<SCRIPTNAME>
    
    echo "starting postdownload"; 
    
    . /usr/share/fog/lib/funcs.sh
    [[ -z $postdownpath ]] && postdownpath="/images/postdownloadscripts/"
    case $osid in
        5|6|7|9)
            clear
            [[ ! -d /ntfs ]] && mkdir -p /ntfs
            getHardDisk
            if [[ -z $hd ]]; then
                handleError "Could not find hdd to use"
            fi
            getPartitions $hd
            for part in $parts; do
                umount /ntfs >/dev/null 2>&1
                fsTypeSetting "$part"
                echo  "$part"
                case $fstype in
                    ntfs)
                        dots "Testing partition $part"
                        ntfs-3g -o force,rw $part /ntfs
                        ntfsstatus="$?"
                        if [[ ! $ntfsstatus -eq 0 ]]; then
                            echo "Skipped"
                            continue
                        fi
                        if [[ ! -d /ntfs/windows && ! -d /ntfs/Windows && ! -d /ntfs/WINDOWS ]]; then
                            echo "Not found"
                            umount /ntfs >/dev/null 2>&1
                            continue
                        fi
                        echo "Success"
                        break
                        ;;
                    *)
                        echo " * Partition $part not NTFS filesystem"
                        ;;
                esac
            done
            if [[ ! $ntfsstatus -eq 0 ]]; then
                echo "Failed"
                debugPause
                handleError "Failed to mount $part ($0)\n    Args: $*"
            fi
            echo "Done, fixing to load the drivers"
            debugPause
            # . ${postdownpath}fog.log
            . ${postdownpath}fog.drivers
            # . ${postdownpath}fog.ad
            umount /ntfs
            ;;
        *)
            echo "Non-Windows Deployment"
            debugPause
            return
            ;;
    esac
    

  • Moderator

    @uwpviolator Ok, what does your fog.postdown file look like. There is something that maps the partitions. The older setup for win7 made some assumptions based on Win7.

    Also I’ve been working on an updated tutorial to the original one here: https://forums.fogproject.org/topic/11126/using-fog-postinstall-scripts-for-windows-driver-injection-2017-ed You may want to review it since it was intended to be more towards win10.



  • @george1421

    Here is the ls

    0_1513618506431_59bd5bde-7f50-4d06-89bb-06d21dd9ca24-image.png



  • 0_1513616954032_a4bfd15d-7e38-48a9-aef7-b2af2ce44a2f-image.png

    I am not seeing any difference between my win7 and win10 setup so it leads me to believe it’s the script.


  • Moderator

    @uwpviolator said in Windows 10 Drivers Not Copying:

    What does the files in /images/drivers/OptiPlex 580/win10 look like?

    Remember that case is important to linux.


Log in to reply
 

362
Online

5.7k
Users

13.0k
Topics

122.0k
Posts