Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Cater for more explicit gist paths used in routes file #524

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
Nov 23, 2019

Conversation

lildude
Copy link
Member

@lildude lildude commented Nov 13, 2019

When backing up a cluster, the parallel rsyncs used for backing up the gists can result in File exists (17) errors. This happens when the same Gist prefix is used in the on-disk repo path for multiple gists on multiple nodes.

A change to better handle this is coming in the next releases of GitHub Enterprise Server which slightly changes the paths sent in the routes from the GitHub Enterprise Server being backed up. This PR implements a function to cater for this in the verification that happens immediately after all repositories and gists have been backed up.

/cc @djdefi @jatoben @maclarel @github/pe-hadr @github/backup-utils @dbussink

@lildude lildude requested a review from a team November 13, 2019 16:08
Copy link
Contributor

@dbussink dbussink left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Change makes sense to me!

@lildude lildude mentioned this pull request Nov 14, 2019
@github github deleted a comment Nov 23, 2019
@lildude lildude merged commit 39b2e05 into master Nov 23, 2019
@lildude lildude deleted the lildude/update-verify-routes branch November 23, 2019 12:12
@lildude lildude mentioned this pull request Dec 11, 2019
@ronnie ronnie restored the lildude/update-verify-routes branch January 7, 2020 21:15
Copy link

@n3waaf n3waaf left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

> تخطى الى المحتوى
> جيثب
> /
> أدوات النسخ الاحتياطي
> الشفرة
> مسائل
> 23
> طلبات السحب
> 8
> أجراءات
> المشاريع
> الأمان
> أفكار
> اذهب إلى الأسفل
> قم بتوفير مسارات جوهرية أكثر وضوحًا مستخدمة في ملف المسارات رقم 524
>  مندمجة
> ليلدود دمج 5 تلتزم رئيس من عند lildude / تحديث-التحقق من المسارات on 23 Nov 2019
> محادثة 1
> يلتزم 5
> الفحوصات 0
> تغيرت الملفات 1
>  مسح المرشحات
> تنفيذ الوظيفة لتحليل مسار جوهر مختلف
> 
>  رئيس ( رقم 524 )  الإصدار 2.22.0 
> ...
>  الإصدار 2.19.1
> تضمين التغريدةليلدود ارتكب on 13 Nov 2019 
> الالتزام 0a04ca087edd7738fad2095b0ea8eca16ba6866c
>  18  share / github-backup-utils / ghe-backup-repositories 
> -367،8 +367،24bm_end "$ (basename $ 0) - مزامنة دلائل البيانات الخاصة"
> إذا [ -z  " $ GHE_SKIP_ROUTE_VERIFICATION " ] ؛  ثم
>   bm_start " $ ( basename $ 0 ) - التحقق من المسارات "
> 
>   # تغيرت قائمة البيانات التي أرجعها المصدر في 2.16.22 و 2.17.13 و 2.18.7 و 2.19.1
>   # لذلك نحن بحاجة إلى حساب هذا الاختلاف هنا.
>   parse_paths () {
>     أثناء  قراءة خط r ؛  فعل
>       إذا [[ " $ GHE_REMOTE_VERSION "  = 2.16 &&  " $ ( الإصدار $ GHE_REMOTE_VERSION ) "  -ge  " $ ( الإصدار 2.16.22 ) " ] || \
>          [[ " $ GHE_REMOTE_VERSION "  = 2.17 &&  " $ ( الإصدار $ GHE_REMOTE_VERSION ) "  -ge  " $ ( الإصدار 2.17.13 ) " ]] || \
>          [[ " $ GHE_REMOTE_VERSION "  = 2.18 &&  " $ ( الإصدار $ GHE_REMOTE_VERSION ) "  -ge  " $ ( الإصدار 2.18.7 ) " ]] || \
>          [[ " $ GHE_REMOTE_VERSION "  = 2.19 &&  " $ ( الإصدار $ GHE_REMOTE_VERSION ) "  -ge  " $ ( الإصدار 2.19.1 ) " ]] && \
>          (صدى " $ line "  | grep -q " gist " ) ؛ ثم
>         صدى  " $ line "
>       آخر
>         اسم الدليل " $ line "
>       فاي
>     منجز
>   }
> 
>   القط $ tempdir / * .rsync | فرز | uniq >  $ tempdir / source_routes
>   (CD $ backup_dir / && تجد * -mindepth 5 -maxdepth 6 من نوع د -اسم \ * . بوابة |  حين قراءة خط -r ، لا إذا [[ ! $ خط == * / جوهر / * ]] ، ثم dirname " $ line " ؛ else echo " $ line " ؛ fi ؛ done | sort | uniq) >               $ tempdir / destination_routes
>   (CD $ backup_dir / && تجد * -mindepth 5 -maxdepth 6 من نوع د -اسم \ * . بوابة |  parse_paths  | نوع | UNIQ) >  $ tempdir / destination_routes
> 
>   git - no-pager diff --unified = 0 - no -prefix - $ tempdir / source_routes $ tempdir / destination_routes ||  صدى  " تحذير: لم يتم العثور على واحدة أو أكثر من شبكات المستودعات و / أو الجسيمات في الجهاز المصدر. الرجاء الاتصال بدعم GitHub Enterprise للحصول على المساعدة. "
> 
>  نصيحة محترف! استخدام nو pالتنقل بين يرتكب في طلب سحب.
> © 2020 جيثب ، Inc.
> شروط
> خصوصية
> الأمان
> الحالة
> مساعدة
> اتصل بـ GitHub
> التسعير
> API
> تدريب
> مدونة
> حول
> تم العثور على 1 نتائج.

@lildude lildude deleted the lildude/update-verify-routes branch November 11, 2020 16:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants