SQL SERVER – Installation Error – INSTALLSHAREDDIR parameter is not valid because this directory is compressed or is in a compressed directory

One of my blog reader contacted me for assistance. Here is his email:

Hello Pinal,
I am trying to install SQL Server on my laptop but getting below errors:

  • SqlServer.Configuration.Sco.DirectoryAttributesMissmatch: Folder C:\Program Files\Microsoft SQL Server has an unsupported attribute (Compressed) set. Please resolve this issue by removing the unsupported attribute from the folder using folder properties dialog.
  • SqlServer.Configuration.SetupExtension.CompressedDirException: The specified directory, “C:\Program Files\Microsoft SQL Server\”, for the INSTALLSHAREDDIR parameter is not valid because this directory is compressed or is in a compressed directory. Specify a directory that is not compressed.
  • SqlServer.Configuration.SetupExtension.CompressedDirException: The specified directory, “C:\Program Files (x86)\Microsoft SQL Server\”, for the INSTALLSHAREDWOWDIR parameter is not valid because this directory is compressed or is in a compressed directory. Specify a directory that is not compressed.

Can you help me in understanding the error and the fix of the issue?

Since the error messages were talking about compression so I checked MSDN to find whether SQL can be installed on compressed directory or not. And I found https://msdn.microsoft.com/en-us/library/ms143506.aspx (Hardware and Software Requirements for Installing SQL Server). This says “SQL Server Setup will block installations on read-only, mapped, or compressed drives”

Having said all this, in this era of faster disks and infinite storage. I am still wondering how many of you out there is using compression on your disks for files stored by applications? If we read the message it, the solution is simple. Here are the steps to un-compress a folder.

  • On the desired folder (in our case “C:\Program Files”) right click and go to properties.
  • Click on “Advanced” button.
  • Uncheck the box “Compress the drive to save space”
  • Click Apply and then Ok.
  • Let the process finish.

SQL SERVER - Installation Error - INSTALLSHAREDDIR parameter is not valid because this directory is compressed or is in a compressed directory compress-01

Later I got message from the reader that he was able to install SQL without any further issues. As I say always, most of the error messages are self-explanatory. All we need is to understand how the system is being used. In this context it is worth to know there are few KB Articles (231347)

Reference: Pinal Dave (https://blog.sqlauthority.com)

SQL Error Messages
Previous Post
Interview Question of the Week #007 – How to Reindex Every Table of the Database?
Next Post
SQL SERVER – Cloud Based Data Integration Made Easy – A Real World Scenario

Related Posts

26 Comments. Leave new

  • Thank you!

    Reply
    • My pleasure.

      Reply
      • Hello, sorry to come with the same question, but i have tried to apply toe solution decompressed even C/.. programme files/… MSS/… the same message keep on empeaching the installation
        Could you help ?
        Thank you in advance

  • Thank You Pinal Dave :-)

    Reply
  • Eres un genio, gracias :)

    Reply
  • I have this error on a system where the folder is shown as not compressed (there is no check in the box).

    Reply
  • Thank you a lot!

    Reply
  • Nikitha Nimbalkar
    September 16, 2016 12:00 pm

    Thanks it worked!

    Reply
  • eduardo manuel ruiz facundo
    October 22, 2016 3:46 am

    gracias la vdd buscaba esta solucion, como dices el mismo error nos indica donde esta el problema, en mi caso yo aplicaba el mismo paso pero en la carperta de archivos x86 y era en la otra carpeta de archivos aora si utilizo mi sql sin problema alguno gracias amigo !
    saludos y suerte ..

    [Google Translate]
    thanks vdd seeking this solution, as you say the same error indicates where the problem is, in my case I applied the same step but in carperta file x86 and was in the other folder aora files if I use my sql without any problems thanks friend !
    greetings and luck ..

    Reply
  • Thank you

    Reply
  • Girish Kolte
    May 26, 2017 11:40 am

    Thank you

    Reply
  • Thanks you so much

    Reply
  • think you

    Reply
  • Great ! thank you Pinal. This solution perfectly works.

    Reply
  • Rich Farmbrough
    October 9, 2018 8:50 pm

    Of course, that means we have to uncompress all our program files, many gigabytes. Also compressed files are often faster. This seems like a broken piece of Microsoftery.

    Reply
  • if you get the message continually, make sure to check the error message. It might be pointing to the x86 or non-x86 program files subdirectory. This threw me off because I had SQL Server installed in both places until I saw the message was indicating a different directory but with similar looking name Hope this helps someone

    Reply
  • Afonso Filipe
    May 27, 2021 4:09 pm

    I will try this solution later I will say something

    Reply
  • Its not working on my computer, can someone help me?

    Reply
  • thank you, that is great solution

    Reply
  • Hi can you help me yo clera this error while installing the SQL
    [Error Message]
    The specified directory, “C:\Program Files\Microsoft SQL Server\”, for the INSTALLSHAREDDIR parameter is not valid because this directory is compressed or is in a compressed directory. Specify a directory that is not compressed.

    [Details]
    Microsoft.SqlServer.Configuration.SetupExtension.CompressedDirException: The specified directory, “C:\Program Files\Microsoft SQL Server\”, for the INSTALLSHAREDDIR parameter is not valid because this directory is compressed or is in a compressed directory. Specify a directory that is not compressed.
    ================================================================================

    Reply
  • HUGO DA CRUZ SILVA
    January 5, 2025 3:47 am

    3 meses procurando uma resposta, e achei aqui, obrigado pessoa.

    Reply

Leave a Reply