extras/hookscripts: Fix the multiple entries in smb.conf problem.

Problem:
1. Force starts and user.smb sets were adding multiple entries to
the smb.conf file for the same volume.
Make a check for the entry and search with exact name.

2. Again, while deleting the share name from smb.conf search with
exact name so that volumes with names which are substrings of ones to
be deleted don't get deleted.

3. We don't need to use a tmp file while using sed -i, fixed that.

Change-Id: Ie0f7c9d4790ef9a177a043378a761c9ffe1628e5
BUG: 994727
Signed-off-by: Raghavendra Talur <rtalur@redhat.com>
Reviewed-on: http://review.gluster.org/6043
Reviewed-by: Niels de Vos <ndevos@redhat.com>
Reviewed-by: Lalatendu Mohanty <lmohanty@redhat.com>
Tested-by: Lalatendu Mohanty <lmohanty@redhat.com>
cli,glusterd: Implement 'volume status tasks'

oVirt's Gluster Integration needs an inexpensive command that can be
executed every 10 seconds to monitor async tasks and their parameters,
for all volumes.

The solution involves adding a 'tasks' sub-command to 'volume status'
to fetch only the async task IDs, type and other relevant parameters.
Only the originator glusterd participates in this command as all the
information needed is available on all the nodes. This is to make the
command suitable for being executed every 10 seconds.

Change-Id: I1edc607baf29b001a5585079dec681d7c641b3d1
BUG: 1012346
Signed-off-by: Krutika Dhananjay <kdhananj@redhat.com>
Reviewed-on: http://review.gluster.org/6006
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Kaushal M <kaushal@redhat.com>