diff options
author | Stephen Toub <stoub@microsoft.com> | 2016-08-20 01:37:27 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-08-20 01:37:27 +0300 |
commit | 63b1853235add3fce243b9d2b743b1c73a74548e (patch) | |
tree | 5e8c42074f68da01c440c977c2e6f647b03cf18c /scripts | |
parent | 3f1154bcc4e212c52fdcc52151687bf300e7b9ea (diff) | |
parent | ae8a5bd5f70da138cc97cc78356357a35b538a9f (diff) |
Merge pull request #10284 from sjsinju/not_unmount
ARM-CI : Add logging for getting the reason of unmounting issue.
Diffstat (limited to 'scripts')
-rwxr-xr-x | scripts/arm32_ci_script.sh | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/scripts/arm32_ci_script.sh b/scripts/arm32_ci_script.sh index 7d94fd8e93..0fbafd6eb0 100755 --- a/scripts/arm32_ci_script.sh +++ b/scripts/arm32_ci_script.sh @@ -78,7 +78,15 @@ function check_git_head { function unmount_rootfs { local rootfsFolder="$1" - if grep -qs "$rootfsFolder" /proc/mounts; then + #Check if there are any open files in this directory. + if [ -d $rootfsFolder ]; then + #If we find information about the file + if sudo lsof +D $rootfsFolder; then + (set +x; echo 'See above for lsof information. Continuing with the build.') + fi + fi + + if mountpoint -q -- "$rootfsFolder"; then sudo umount "$rootfsFolder" fi } |