首页 > 解决方案 > Shell script to check if the azcopy command to upload the files from linux to azure storage is successful or not

问题描述

I have tried to upload the db backup files from Linux platform to azure storage using the azcopy command. Sometimes it is failing as the storage is full. can you please tell me how can I write a shell script to check if the upload is successful or not (status code). if upload failed then send an email to respective email ids. I have tried below command to upload the files from Linux to Azure Storage:

azcopy --source <sourcepath> --include "*.zip" --destination <destination> \
    --dest-sas "?sv=2019-02-02&ss=bfqt&srt=sco&sp=rwdlacup&se=2021-01-27T13:31:23Z&st=2020-01-27T05:31:23Z&spr=https&sig=5eQClAaajnLNcw3bUtZvWSumSj0FkWalApGm8Y90IgY%3D"

标签: azure

解决方案


推荐阅读