none
Got 500 internal server error while uploading a file in storage

    Question

  • Hi,

    I am using PHP Rest API on Ubuntu VM for accessing storage. While trying to upload files I got a 500 internal server error. Outbound port 80 and 443 are opened. Please help.

    Thanks,

    Wednesday, October 19, 2016 9:42 AM

All replies

  • Hi,

    There could be many reasons for this issue;

    This issue may occur if the storage account that was created before upgrade?

    Make sure you have included the phpAzure SDK files.

    For this you should have the phpAzure SDK ( http://phpazure.codeplex.com/ ) somewhere in your include path or in the current directory.

    You could be getting this error because you're trying to upload a very large file in one go. When uploading large files, it is recommended that you upload them by splitting them in chunks. In Windows Azure terms, you would need to split the file into smaller blocks and upload those blocks using PutBlock method. Once all blocks are uploaded, you would then commit these blocks using PutBlockList method. If you trace the upload request through Fiddler when you're uploading using Azure Storage Explorer, you should notice that it is doing the same thing.

    Since interaction with Windows Azure Storage happens via REST API (i.e. either on port 80 or 443), you need not worry about opening up any additional ports in the firewall.

    You may also check;
    The permission levels of Containers are set properly.
    Try creating the containers manually and run the app, so you can distinguish what goes wrong.
    Check the URL, storage key.

    Regards,
    Sumanth BM


    Wednesday, October 19, 2016 4:39 PM
    Moderator