backport from lucid.