From: Niu Yawei Date: Sun, 1 Apr 2012 05:13:35 +0000 (-0700) Subject: LU-1257 config: keep using old osc name X-Git-Tag: 2.3.55~10 X-Git-Url: https://git.whamcloud.com/?a=commitdiff_plain;h=bb46105ffae1f1f6716d6d0a54180665f1a39acc;p=fs%2Flustre-release.git LU-1257 config: keep using old osc name When adding new OST to a system upgraded from 1.8, we arbitrarily use the new OSC naming style in the MDT config log, however, config parameter (conf_param) updating code will use old naming OSC style for the newly added OST since it found that the system is upgraded from 1.8. Such OSC name mismatching problem will cause error when processing the parameter config records. This patch changed the registration code to follow the same rule as the param updating code: always use old OSC naming style for the upgraded 1.8 system. Signed-off-by: Niu Yawei Change-Id: I4d9b02bfa439fb95993bdbdb0b05fc5a38c9af96 Reviewed-on: http://review.whamcloud.com/2432 Tested-by: Hudson Reviewed-by: wangdi Tested-by: Maloo Reviewed-by: Andreas Dilger --- diff --git a/lustre/mgs/mgs_llog.c b/lustre/mgs/mgs_llog.c index 6253213..acc2dc9 100644 --- a/lustre/mgs/mgs_llog.c +++ b/lustre/mgs/mgs_llog.c @@ -1862,7 +1862,12 @@ static int mgs_write_log_osc_to_lov(const struct lu_env *env, rc = name_create(&svname, mti->mti_svname, "-osc"); if (rc) GOTO(out_free, rc); - rc = name_create(&oscname, svname, suffix); + /* for the system upgraded from old 1.8, keep using the old osc naming + * style for mdt, see name_create_mdt_osc(). LU-1257 */ + if (cfs_test_bit(FSDB_OSCNAME18, &fsdb->fsdb_flags)) + rc = name_create(&oscname, svname, ""); + else + rc = name_create(&oscname, svname, suffix); if (rc) GOTO(out_free, rc); rc = name_create(&oscuuid, oscname, "_UUID");