From 2e00396e04f261af45c33b55b9b73157a2e8fc72 Mon Sep 17 00:00:00 2001 From: Kaushal M Date: Tue, 27 Sep 2011 12:37:22 +0530 Subject: storage/posix : prevent unmount of underlying fs posix xlator now performs opendir () on the brick directory during init (). This will prevent the underlying filesystem mounted to that directory from being unmounted. Change-Id: I02c190ab8a91abc4ab06959b36f50e0a3fa527ae BUG: 3578 Reviewed-on: http://review.gluster.com/509 Reviewed-by: Amar Tumballi Tested-by: Gluster Build System Reviewed-by: Vijay Bellur --- xlators/storage/posix/src/posix.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'xlators/storage/posix/src/posix.h') diff --git a/xlators/storage/posix/src/posix.h b/xlators/storage/posix/src/posix.h index 21170ea59..1733eadd1 100644 --- a/xlators/storage/posix/src/posix.h +++ b/xlators/storage/posix/src/posix.h @@ -114,6 +114,8 @@ struct posix_private { pthread_t janitor; gf_boolean_t janitor_present; char * trash_path; +/* lock for brick dir */ + DIR *mount_lock; }; #define POSIX_BASE_PATH(this) (((struct posix_private *)this->private)->base_path) -- cgit