From: Daniel Kobras Date: Wed, 28 Nov 2012 17:47:18 +0000 (-0800) Subject: LU-2302 scripts: fix lfs_migrate with non-English locale X-Git-Tag: 2.3.58~32 X-Git-Url: https://git.whamcloud.com/?p=fs%2Flustre-release.git;a=commitdiff_plain;h=a9d8c667e31b980404de2384d6813a1323577769 LU-2302 scripts: fix lfs_migrate with non-English locale Parsing of stat output assumes an English locale. Make sure this is always the case. Signed-off-by: Daniel Kobras Change-Id: I66acd6eb49cac749db701b97a5a375dc3b141a01 Reviewed-on: http://review.whamcloud.com/4697 Tested-by: Hudson Reviewed-by: Andreas Dilger Tested-by: Maloo Reviewed-by: Keith Mannthey --- diff --git a/lustre/scripts/lfs_migrate b/lustre/scripts/lfs_migrate index 969386e..1f35568 100755 --- a/lustre/scripts/lfs_migrate +++ b/lustre/scripts/lfs_migrate @@ -93,7 +93,7 @@ lfs_migrate() { $ECHO -n "$OLDNAME: " # avoid duplicate stat if possible - TYPE_LINK=($(stat -c "%h %F" "$OLDNAME" || true)) + TYPE_LINK=($(LANG=C stat -c "%h %F" "$OLDNAME" || true)) # skip non-regular files, since they don't have any objects # and there is no point in trying to migrate them.