Failed to install CGI when adjusting Enterprise sharing attribute

After installing Panorama 6 on macOS 10.12.6 (which required manually turning off Gatekeeper), I am now attempting to adjust the Local Network & Internet Zones but each time I attempt to alter the Sharing or Web Publishing attributes to Yes, I get an error 'Failed to install CGI (could not copy file).

That’s been around for a while and is due to the inability of the installer to put Panorama.cgi where it belongs - and which varies epending on the OS. It also depends on if you’re running OS Server or using a standard OS.

Below is a post by Jim Rea from some time back that is still valid. I’ve added additional notes to it. If you’re on OS Sever let me know and I have far more that I can share.

OS X Server and Enterprise
I have confirmed that Apple’s new web server folder arrangement described by Jim Cook only applies to OS X 10.8 SERVER. In regular OS X 10.8, the web server still uses the old folders that were used in 10.7, 10.6 and earlier versions:


ALL versions of OS X and OS X SERVER use the above folders for web publishing EXCEPT OS X 10.8 SERVER, which use the new folder arrangement discovered by Jim Cook:


This means that if you want to use Panorama Server Web Publishing or Internet Sharing on OS X 10.8 Server you will have to manually install the Panorama.cgi file. Here are instructions for doing that.

The panorama.cgi file is located here:


Hold down the option key and drag it to /Library/Server/Web/Data/CGI-Executables

To set up the permissions, type this line into

sudo cd /Library/Server/Web/Data/CGI-Executables; chown USERNAME panorama.cgi;chmod 6755 panorama.cgi

Replace USERNAME with your actual unix user name (usually the name of your home folder).

If you need to manually install panorama.cgi on regular 10.8 or any previous version of OS X or OS X Server you can use the same instructions, but substitute /Library/WebServer/CGI-Executables instead of /Library/Server/Web/Data/CGI-Executables

Note: Whatever system you are using, these two folders must have permissions set so that the current user can write files in the folders. On newer systems (10.7 and later) this is NOT the default permissions as shipped by Apple, so you must modify the permissions for these folders, either with the Get Info command or with

Jim Cook, right back at you in appreciation of your efforts in tracking this down.
Webserver>Documents is not the Apache default on 10.8 and appears to be deprecated.

Instead it uses Library/Server/Web/Data/Sites and Library/Server/Web/Data/CGI-Executables.

Dragging a copy of panorama.cgi to the Library/Server/Web/Data/CGI-Executables folder made the difference. It’s working like a charm now

panorama.cgi is found in Panorama/Extensions/Enterprise.cgi-bin.

Argh. Getting close but not quite there.

Running 10.12.6 (Not Server)

Relevant directory:

Copied panorama.cgi there

In Terminal ran:
sudo cd /Library/WebServer/CGI-Executables; chown db_server panorama.cgi;chmod 6755 panorama.cgi

I entered the password, then the response was:
chown: panorama.cgi: No such file or directory
chmod: panorama.cgi: No such file or directory

Interestingly, the panorama.cgi file icon is an unix executable icon until I click on the ‘no’ in the Sharing or Web Publishing column in Panorama Server. The panorama.cgi icon changes to a generic icon, then it asks me for the System Administrator Password. I enter the Admin password for the computer, I get an error message ‘Failed to install CGI (incorrect system administrator password).’ and the icon reverts back to the unix executable icon.

Have you tried connecting from a client? The server almost always throws this message when enabling IP or web sharing, but when I get the message, I just ignore it and the clients can connect even though the error says it didn’t work.


I’ve never understood the difference, but the Panorama.cgi icon must be a unix icon or it doesn’t work. Sometimes I just have to copy it again from the Panorama folder.