Merge r1614538 from trunk. YARN-2354. DistributedShell may allocate more containers than client specified after AM restarts. Contributed by Li Lu

git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/branches/branch-2@1614539 13f79535-47bb-0310-9956-ffa450edef68