MB-10505 check permissions on output directory before collecting info

Change-Id: I16e7476a9f8557e0a0609d606aabfd06d18ca6b4
Reviewed-on: http://review.couchbase.org/36329
Reviewed-by: Aliaksey Artamonau <aliaksiej.artamonau@gmail.com>
Tested-by: Aliaksey Artamonau <aliaksiej.artamonau@gmail.com>