Commit 18ebc364 by liyapeng

ceshi

1 parent 739b9d48
Showing with 19 additions and 5 deletions
cos:
base:
secretid: 3kNZR4wfjUgOqbHffiQSMw==
secretkey: 3kNZR4wfjUgOqbHffiQSMw==
sessiontoken: 3kNZR4wfjUgOqbHffiQSMw==
protocol: https
mode: ""
cvmrolename: ""
buckets:
- name: ""
alias: ""
region: ""
endpoint: ""
ofs: false
......@@ -22,8 +22,6 @@ space=$(df -hm / | tail -n 1 | awk '{print $(NF-2) }')
echo -e "\033[41;33m This script is used as a daily troubleshooting and does not involve collecting relevant privacy data \033[0m"
main
systemlog() {
#收集操作系统产生的日志
mkdir -p ${LOG_FILE_PATH}/systemlog
......@@ -98,7 +96,7 @@ Bundlinglogfiles() {
uploadlogfile() {
echo "upload log file"
chmod +x coscli
./coscli -e ${ENDPOINT} -i ${TMP_SECRET_ID} -k ${TMP_SECRET_KEY} --token ${TMP_SESSION_TOKEN} cp /tmp/${LOG_DIR}.tar cos://${BUCKET_NAME}/${LOG_DIR}.tar
./coscli -c ./.cos.yaml -e ${ENDPOINT} -i ${TMP_SECRET_ID} -k ${TMP_SECRET_KEY} --token ${TMP_SESSION_TOKEN} cp /tmp/${LOG_DIR}.tar cos://${BUCKET_NAME}/${LOG_DIR}.tar
}
main() {
......@@ -110,4 +108,6 @@ main() {
Bundlinglogfiles
uploadlogfile
rm -r ${LOG_FILE_PATH}
}
\ No newline at end of file
}
main
\ No newline at end of file
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!