• Recent
  • Unsolved
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Register
  • Login
  • Recent
  • Unsolved
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Register
  • Login

21H1 imaging issue-variables do not populate

Scheduled Pinned Locked Moved
FOG Problems
3
4
373
Loading More Posts
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • B
    bruce.stewart
    last edited by Sebastian Roth Jul 20, 2021, 1:10 PM Jul 19, 2021, 9:05 PM

    Everything has worked for me in 1909, 1903, 1809, etc, etc.

    I tried in 20H (gave up) and now 21H and my post imaging scripts (found in the forums) no longer work.

    My variables don’t seem to get populated.

    For example if I type

    echo $machine

    from a debug session, it provides no output

    If I type dmidecode -s system-product-name from a debug session, I get the model name as expected.

    Entire script below.

    #!/bin/bash
    ceol=`tput el`;
    
    machine=$(dmidecode -s system-product-name)
    
    # Detect System Architecture
    system64="/ntfs/Windows/SysWOW64/regedit.exe" # sloppy detect if 64bit or not
    #[[ ! -f $system64 ]] && arch="x86" || arch="x64"
    [[ ! -f $system64 ]] && arch="x64" || arch="x64"
    
    # Detect Operating System
    case $osid in
        5) osn="win7" ;;
        6) osn="win8" ;;
        7) osn="win8.1" ;;
        9) osn="win10" ;;
    esac
    
    dots "Copying Drivers"
    # Create Driver Store and Copy Drivers
    clientdriverpath="/ntfs/Drivers"
    remotedriverpath="/images/drivers/$machine/$osn/$arch"
    
    [[ ! -d $clientdriverpath ]] && mkdir -p "$clientdriverpath" >/dev/null 2>&1
    echo "In Progress"
    
    rsync -avz "$remotedriverpath/" "$clientdriverpath" >/dev/null 2>&1
    [[ ! $? -eq 0 ]] && handleError "Failed to download driver information for [$machine/$osn/$arch]"
    
    
    regfile="/ntfs/Windows/System32/config/SOFTWARE"
    key="\Microsoft\Windows\CurrentVersion\DevicePath"
    devpath="%SystemRoot%\DRV;%SystemRoot%\inf;";
    reged -e "$regfile" &>/dev/null <<EOFREG
    ed $key
    $devpath
    q
    y
    EOFREG
    echo -e "\b\b\b\b\b\b\b\b\b\b\b${ceol}Done"; # this just removes "In Progress and replaces it with done :-)"
    

    Screenshot from 2021-07-16 18-15-17.png

    G 1 Reply Last reply Jul 20, 2021, 2:14 PM Reply Quote 0
    • G
      george1421 Moderator @bruce.stewart
      last edited by Jul 20, 2021, 2:14 PM

      @bruce-stewart The postinstall scripts execute under FOS Linux bash shell. FOS Linux doesn’t know/care about the target computer’s OS. When the script runs windows is not involved. So it kind of makes me think the issue is elsewhere.

      Are you using these instructions for the postinstall script? https://forums.fogproject.org/topic/11126/using-fog-postinstall-scripts-for-windows-driver-injection-2017-ed

      Please help us build the FOG community with everyone involved. It's not just about coding - way more we need people to test things, update documentation and most importantly work on uniting the community of people enjoying and working on FOG!

      B 1 Reply Last reply Aug 24, 2021, 1:28 PM Reply Quote 0
      • B
        bruce.stewart @george1421
        last edited by Aug 24, 2021, 1:28 PM

        @george1421 yes for the post install.

        1 Reply Last reply Reply Quote 0
        • S
          Sebastian Roth Moderator
          last edited by Aug 25, 2021, 9:12 AM

          @bruce-stewart said in 21H1 imaging issue-variables do not populate:

          My variables don’t seem to get populated.

          Well that’s pretty normal when you don’t use bash command export to make those available globally.

          Web GUI issue? Please check apache error (debian/ubuntu: /var/log/apache2/error.log, centos/fedora/rhel: /var/log/httpd/error_log) and php-fpm log (/var/log/php*-fpm.log)

          Please support FOG if you like it: https://wiki.fogproject.org/wiki/index.php/Support_FOG

          1 Reply Last reply Reply Quote 0
          • 1 / 1
          • First post
            Last post

          153

          Online

          12.1k

          Users

          17.3k

          Topics

          155.3k

          Posts
          Copyright © 2012-2024 FOG Project