Google Chrome 71 / 72 Trail Dragging Issue when Maximized on Windows 7 2008 R2

I have been working recently on an issue for one of my clients whereby after updating to Chrome 71.0.3578 (and also in 72.0.3626) a display issue started to occur when Chrome is maximized; Any foreground window over Chrome leaves “trails” of itself over Chrome Window. If Chrome gets the focus again, the trails disappear. The issue does not happen if Chrome is not maximized.

We have seen this on XenDesktop Windows 7 virtual and physical machines  – Also this was seen on XenApp Windows 2008 R2 Servers. 

Troubleshooting 

We have initially ruled out that a recent Windows Update has caused a conflict of some sort. We also could reproduce the problem on machines that has no Citrix VDA installed and using RDP rather than ICA, so it’s not ICA graphics related. In a VDI scenario, we have also confirmed that H/W Accelerator was indeed disabled and was not behind this behaviour.  

With that knowledge, we turned the attention to Chrome settings and flags, in particular the ones that are graphic related. 

The Solution

We could see that disabling Viz Display Compositor (OOP-D) resolves the issue. Although the flag is set to “Default” by default, which doesn’t mean “Enabled” or active, it appears that force disabling the flag is resolving the issue. Disabling this flag stops moving the display compositor from the browser to the GPU Processor.

This can be done manually by following the below steps:

  1. Go to Chrome and type: chrome://flags/
  2. Search for: Viz Display Compositor (OOP-D)
  3. Set it to disabled and relaunch – problem solved.

How Can We Automate This? 

Until Google fixes this issue, there are two scenarios where you can automate the solution for all affected users: 

Adding a Switch to Chrome Shortcut

You can automate setting the flag per user session by adding a switch to Chrome shortcut. If you use AppSense EM or equivalent,  you can add a “Pre-Desktop” action to re-create the Chrome shortcut in the start menu and pass the switch as below

“C:\Program Files (x86)\Google\Chrome\Application\chrome.exe” –disable-features=VizDisplayCompositor 

Note that if you check Chrome Flags, you will not see the flag marked as “disabled” in Chrome, mainly because the switch applies “on the fly” for that instance and does not save the flag into Chrome settings. 

Changing Chrome Settings Using Powershell

Alternatively if you need to fix this session wide as oppose to per shortcut, we can modify “Local State” JSON file, which sits in every user’s profile under “C:\Users\[USERID]\AppData\Local\Google\Chrome\User Data\Local State”

The below script would read the JSON file and modify it to disable the flag, the logic add the flag without touching any of the other settings the user may have already – this is particularly helpful if Chrome user settings are being personalised. 

You may want to add this as “Desktop Created” or “Process Start” if you are using Ivanti (Appsense) EM or equivalent 

Google Chrome 71 / 72 Trail Dragging Issue when Maximized on Windows 7 2008 R2
Tagged on:                             

10 thoughts on “Google Chrome 71 / 72 Trail Dragging Issue when Maximized on Windows 7 2008 R2

  • March 7, 2019 at 8:40 am
    Permalink

    Hi there, thanks for this post. We had this reported by customers, it took us a while to work out what was going on, but this post has been a big help!

    Thanks

    Reply
    • March 7, 2019 at 2:51 pm
      Permalink

      Cheers James! I am glad it was helpful! Thanks for the feedback it’s really appreciated.

      Reply
  • March 11, 2019 at 7:02 pm
    Permalink

    Hi Amir. Hoping to see if you can assist with the powershell option.
    It seems that your script does not work for some of our users. Not sure how to fix.
    they get the error ”
    Convertfrom-Json: cannot process argument because the value of argument “name” is not valid. Change the value of the “name” argument and run the operation again.

    same error with ConvertTo-json.

    Reply
    • March 11, 2019 at 11:09 pm
      Permalink

      Hello Andrew, it seems that the “Local State” file for those users has one or more directories with an empty name. an example would be something like this:

      {
      "policies": {
      "Policy1": {
      "": "Server1=ServerName;Database=DateBaseName;Integrated Security=value;"
      }
      }
      }

      although the above is a valid JSON file, it appears to confuse the powershell command ConvertFrom-Json as it is looking to convert the string from the JSONfile to PSObjects which expects to have a not-null name for every object. You can reproduce the problem by saving the above simple JSON file and running my script against it.

      Now if you run my script against the below, no errors will occur
      {
      "policies": {
      "Policy1": {
      "ANYNAME": "Server1=ServerName;Database=DateBaseName;Integrated Security=value;"
      }
      }
      }

      A workaround for this issue is to replace the JSON file of affected users with a “working” one. You can achieve this by wrapping your code with a try/catch block – the below is an example !!!Please Test First!!!

      #Get Google Local State settings
      $ChromePrefFile = "$env:localappdata\Google\Chrome\User Data\Local State"
      #Read JSON file
      try {
      $Settings = Get-Content -path $ChromePrefFile | ConvertFrom-Json -ErrorAction Stop
      }
      catch {
      Copy-Item -Path $Path_Of_Working_LocalState -Destination $ChromePrefFile -Force
      $Settings = Get-Content -path $ChromePrefFile | ConvertFrom-Json -ErrorAction Stop
      }

      Reply
      • March 12, 2019 at 1:43 pm
        Permalink

        great, thanks!

  • March 12, 2019 at 1:33 pm
    Permalink

    Hi Amir
    I noticed that you have presented an option for a citrix environment.. We are a full vmware shop and have a mixture of windows 7 X32 X64 and windows 10 X64. All of our windows 7 users are affected by this.. I would like to place a reg key to actually disable this to a mass quantity of users.. We have about 500 machines. How would i go about doing this or if you can think of an easier option.

    Reply
    • March 12, 2019 at 3:53 pm
      Permalink

      Hi Chirag, the solution is not Citrix specific; you can still apply the script to any VM running Windows 7 machine using Appsense EM or any equivalent (GPO user login script?). If you are not worried about keeping the user’s other settings as is, then you may consider preparing a clean and generalised copy of “Local State” JSON file with the flag already set in it, then copying this new file to all 500 users’s machines. You may as well consider the workaround I provided to Andrew Chang above.

      Reply
  • March 22, 2019 at 12:10 pm
    Permalink

    Hello Amir. Thanks a lot for your solution, it really helped me at work. Greetings from Germany!

    Reply
    • March 22, 2019 at 12:50 pm
      Permalink

      Hello Natascha, you are welcome! glad it helped! 🙂

      Reply
  • May 22, 2019 at 1:54 pm
    Permalink

    Hi,

    Cool to find this, I have written a batch for this a while ago:

    if exist “%localappdata%\Google\Chrome\User Data\Local State” (
    pushd “%localappdata%\Google\Chrome\User Data\”
    set pad=”%localappdata%\Google\Chrome\User Data\”
    ) else (
    pushd “%appdata%\Google\Chrome\User Data\”
    set pad=”%appdata%\Google\Chrome\User Data\”
    )
    find /v “enable-viz-display-compositor@2” “Local State” >nul
    if “%errorlevel%” == “1” (
    goto vizend
    )
    findstr /v “enabled_labs_experiments\”:\[\]” “Local State”
    if “%errorlevel%” == “1” (
    powershell -Command “& {(Get-Content ‘Local State’) | Foreach-Object {$_ -replace ‘enabled_labs_experiments\”:\[\]’, ‘enabled_labs_experiments\”:[\”enable-viz-display-compositor@2\”]’} | Set-Content ‘Local State’}”
    goto vizend
    )
    findstr /v “enabled_labs_experiments\”:\[” “Local State”
    if “%errorlevel%” == “1” (
    powershell -Command “& {(Get-Content ‘Local State’) | Foreach-Object {$_ -replace ‘enabled_labs_experiments\”:\[‘, ‘enabled_labs_experiments\”:[\”enable-viz-display-compositor@2\”,’} | Set-Content ‘Local State’}”
    goto vizend
    )
    findstr /v “\”browser\”” “Local State”
    if “%errorlevel%” == “1” (
    powershell -Command “& {(Get-Content ‘Local State’) | Foreach-Object {$_ -replace ‘\”browser\”:{‘, ‘\”browser\”:{\”enabled_labs_experiments\”:[\”enable-viz-display-compositor@2\”],’} | Set-Content ‘Local State’}”
    goto vizend
    ) else (
    powershell -Command “& {(Get-Content ‘Local State’) | Foreach-Object {$_ -replace ‘\A\{‘, ‘{\”browser\”:{\”enabled_labs_experiments\”:[\”enable-viz-display-compositor@2\”]},’} | Set-Content ‘Local State’}”
    goto vizend
    )
    :vizend
    popd

    Reply

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Discover more from Amir Sayes

Subscribe now to keep reading and get access to the full archive.

Continue reading