AF:
NF:0
PS:10
SRH:1
SFN:
DSR:
MID:<20090429101500.14f54c61@ripper.onstor.net>
CFG:
PT:0
S:andy.sharp@onstor.com
RQ:
SSV:mail.onstor.net
NSV:
SSH:
R:<patrick.haverty@onstor.com>,<doug.cook@onstor.com>,<narayan.venkat@onstor.com>,<dl-leopard@onstor.com>,<john.keiffer@onstor.com>
MAID:1
X-Sylpheed-Privacy-System:
X-Sylpheed-Sign:0
SCF:#mh/Mailbox/sent
RMID:#imap/andys@onstor.net@exch1.onstor.net/INBOX	0	102AB4F33EBBDB4C91915B145C8E9FB31284F9BCC3@exch1.onstor.net
X-Sylpheed-End-Special-Headers: 1
Date: Wed, 29 Apr 2009 10:15:33 -0700
From: Andrew Sharp <andy.sharp@onstor.com>
To: Patrick Haverty <patrick.haverty@onstor.com>
Cc: Doug Cook <doug.cook@onstor.com>, Narayan Venkat
 <narayan.venkat@onstor.com>, dl-leopard@onstor.com, John Keiffer
 <john.keiffer@onstor.com>
Subject: Re: How do I unmount a folder on Leopard?
Message-ID: <20090429101533.3bf36a42@ripper.onstor.net>
In-Reply-To: <102AB4F33EBBDB4C91915B145C8E9FB31284F9BCC3@exch1.onstor.net>
References: <102AB4F33EBBDB4C91915B145C8E9FB31284F9BCC0@exch1.onstor.net>
	<102AB4F33EBBDB4C91915B145C8E9FB31284F9BCC3@exch1.onstor.net>
Organization: Onstor
X-Mailer: Sylpheed-Claws 2.6.0 (GTK+ 2.8.20; x86_64-pc-linux-gnu)
Mime-Version: 1.0
Content-Type: text/plain; charset=US-ASCII
Content-Transfer-Encoding: 7bit

I think it's a bug, but remember the "smb user"/workgroup case is, as I
understand it, not considered to be that common a setup.  That said,
the workgroup mode has been ongoing with problems from the beginning,
so it doesn't surprise me that corner cases like this exist.  We should
file a bug and get it fixed by Nexenta.  Pat is also right about the GUI
should also offer the force option, possibly as a pop-up or somesuch.

On Wed, 29 Apr 2009 09:10:17 -0700 Patrick Haverty
<patrick.haverty@onstor.com> wrote:

> On second thought, if the -f option works, maybe this is a works as
> designed and not a bug.  Maybe it would be an enhancement request to
> have the force option in the GUI?
> 
> ________________________________
> From: Patrick Haverty
> Sent: Wednesday, April 29, 2009 9:04 AM
> To: Doug Cook; Narayan Venkat; dl-leopard
> Subject: RE: How do I unmount a folder on Leopard?
> 
> I recreated the situation and this does not appear to be the same
> issue I had seen earlier, though it results in the same "device busy"
> problem.  This one appears to specifically be related to the smb user
> mounting the folder.  I created a folder, shared with CIFS and NFS,
> did not mount from any clients and could delete the folder from the
> CLI without any problem.  I then created a folder shared, with CIFS and
> NFS, mounted the share from a Linux client, used the CLI to unshare the
> folder while still mounted from the Linux client and was able to delete
> the folder from the GUI without any problem.  And I then, for the second
> time, created a folder, shared with CIFS and NFS, mounted the share from
> a Windows client (SMB user).  I did not map the drive and no mapping
> showed up even when looking under Tools - Disconnect Network Drives.
> I used the CLI to unshare the folder, which was successful, but I could
> not destroy the folder from the GUI or CLI, always getting the "device
> busy" error.  And this morning I disconnected the Windows Client (took it
> of the network) to see if it would break the mount, but it had no affect.
> So I agree this is a bug, and it's a new one.
> 
> The system I'm using is in workgroup mode.  What systems did Doug and Narayan see the issue on and were they joined to a domain?
> 
> I too agree it is unrealistic to have every user unmount a folder before it can be destroyed, and I think that is exactly the reason there is a force option.
> 
> I don't know what changed from the previous version, but I understand there may have been some changes in regards to CIFS sharing.
> 
> Thanks,
> 
> Pat
> 
> 
> 
> ________________________________
> From: Doug Cook
> Sent: Wednesday, April 29, 2009 3:52 AM
> To: Patrick Haverty; Narayan Venkat; dl-leopard
> Subject: RE: How do I unmount a folder on Leopard?
> 
> Hey Pat,
> 
> For several reasons I believe this should be considered a bug.
> 
> 
>  1.  Requiring an administrator to disable/enable protocol services on a system-wide basis as part of a process to remove unwanted folders is excessive.  What about the other folders shared/exported and being used in production at the time?  Not good.
>  2.  Removing a folder means using the CLI as root and executing several steps, one of which requires an ungraceful "force" option.
>  3.  Yes, it makes sense that all users should be un-mounted before a folder can be destroyed, but this is an unrealistic expectation in an environment where this system could be supporting hundreds of users.  Admins cannot search out every system that may have a folder accessed.
> 
> I guess one question that should be asked is "What changed between 1.1.6 and 1.1.7?"  As I mentioned earlier, I believe that in 1.1.6 if an admin wants to destroy a folder, it can be done by hitting the delete button in the GUI.
> 
> Thanks,
> 
> Doug
> 
> ________________________________
> From: Patrick Haverty
> Sent: Tuesday, April 28, 2009 11:15 PM
> To: Doug Cook; Bob Miller; Narayan Venkat; dl-leopard
> Subject: RE: How do I unmount a folder on Leopard?
> 
> I have seen similar situations and they have always seemed to be related to the clients still being mounted despite the folder's share attributes being disabled (sharing being turned off).  This is why I first recommended the nfs-server restart.  For me, that usually cleared up the "device busy" issue when trying to delete the folders.  Most recently I saw a situation where a Windows machine was still mounted, but you would not see that in any Explorer window, only when you opened (from an Explorer window) Tools - Disconnect Networks Drives.  Then you could delete the connection, which may or may not have a mapped drive letter.
> 
> It seems to me to be correct that users should be un-mounted before a filesystem can be destroyed, whether that is by the clients disconnecting or the administrator forcing the un-mount.  So I'm not sure if this should be considered a bug, a request for a new feature, or documentation enhancement.
> 
> Pat
> 
> ________________________________
> From: Doug Cook
> Sent: Tuesday, April 28, 2009 6:30 PM
> To: Doug Cook; Patrick Haverty; Bob Miller; Narayan Venkat; dl-leopard
> Subject: RE: How do I unmount a folder on Leopard?
> Just now I successfully destroyed the folder I wanted to.  I had to SSH to the CLI as "admin", su to root, forcefully unmount the folder, and finally via the nmc destroy the folder.  Not a pretty solution, but it worked.
> 
> This system is running 1.1.7.  I believe, and someone with access please verify, that when we had this system on 1.1.6 destroying a folder via the GUI was as simple as clicking the red X link for deletion.
> 
> DC
> 
> ________________________________
> From: Doug Cook
> Sent: Tuesday, April 28, 2009 9:24 PM
> To: Patrick Haverty; Bob Miller; Narayan Venkat; dl-leopard
> Subject: RE: How do I unmount a folder on Leopard?
> 
> "Un-sharing" the folder is not the problem as that can be done successfully via GUI and CLI.  Removing/destroying the folder cannot be done without an error.  I tried unsuccessfully via the GUI and the CLI.
> 
> DC
> 
> ________________________________
> From: Patrick Haverty
> Sent: Tuesday, April 28, 2009 9:13 PM
> To: Bob Miller; Doug Cook; Narayan Venkat; dl-leopard
> Subject: RE: How do I unmount a folder on Leopard?
> 
> I guess I assumed the acceptable workflow was unsuccessful.  From the CLI you could run "setup folder <foldername> unshare <share type>" for the each of the share types.  Then run "show folder <foldername>" to see if it is still mounted.
> 
> ________________________________
> From: Bob Miller
> Sent: Tuesday, April 28, 2009 5:55 PM
> To: Doug Cook; Patrick Haverty; Narayan Venkat; dl-leopard
> Subject: RE: How do I unmount a folder on Leopard?
> Is that an acceptable workflow?
> B
> 
> ________________________________
> From: Doug Cook
> Sent: Tuesday, April 28, 2009 5:53 PM
> To: Patrick Haverty; Narayan Venkat; dl-leopard
> Subject: RE: How do I unmount a folder on Leopard?
> 
> I encountered the same problem just now on a folder created for, and shared via, CIFS.  I disabled the CIFS sharing, retried deleting the folder, and achieved the same results.
> 
> DC
> 
> ________________________________
> From: Patrick Haverty
> Sent: Tuesday, April 28, 2009 8:32 PM
> To: Narayan Venkat; dl-leopard
> Subject: RE: How do I unmount a folder on Leopard?
> 
> I think there's a bug related to that, but I'll have to search.  Try stopping then restarting the NFS server, from either the GUI or CLI, then see if you can destroy it.
> 
> ________________________________
> From: Narayan Venkat
> Sent: Tuesday, April 28, 2009 5:16 PM
> To: dl-leopard
> Subject: How do I unmount a folder on Leopard?
> I am trying to destroy a filesystem that I created but I get an error saying device is busy.  I need to unmount the filesystem.  What sequence of commands do I use on the CLI?
> 
> Thanks.
> 
> Narayan Venkat
> Vice President, Marketing
> ONStor Inc. (www.onstor.com<http://www.onstor.com>)
> Tel: (408) 963-2404
> Cell: (408) 221-4297
> 
