X-Recipient: archive-cygwin AT delorie DOT com DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:date:from:reply-to:message-id:to:subject :in-reply-to:references:mime-version:content-type :content-transfer-encoding; q=dns; s=default; b=IFq1yUpXcRkNc/oc Bwbyq9ja1TaPH6rBu8E+6l/WclcGAHhicw3AE1GYRv9xYiemUd0XjRiM1mvv5lqG XNeCsi3QQ5ueHmvmZk00hpI98danfKQ32dgMawj76fIwyNda8xwU3YgmJve03xUJ 7BBh2mX/w4QfYF7rhYxD6vmeVxQ= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:date:from:reply-to:message-id:to:subject :in-reply-to:references:mime-version:content-type :content-transfer-encoding; s=default; bh=nDqWcmho6U6EC8iJ7ZXsch cMh5U=; b=Jq9Xq08qbN9edHq04d0GXUf2VA9tGPhxIeG9+L9F+LEe/7XICasLor /5+mkdZvcW0Sqw235JObOlUA/eOrL8POpDr4L0TKEGqeTHbmif8B56AFluA1uLZ1 E50NHw7YuipZiUrX20gE5FJYUiMKkLIrf2Y6rXV1VYa96f/c6Y/GE= Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=1.2 required=5.0 tests=BAYES_20,FREEMAIL_FROM,KAM_THEBAT,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=no version=3.3.2 spammy=plays, H*F:D*yandex.ru, fischer, Fischer X-HELO: forward101p.mail.yandex.net Authentication-Results: smtp3p.mail.yandex.net; dkim=pass header.i=@yandex.ru Date: Tue, 23 Jan 2018 21:41:56 +0300 From: Andrey Repin Reply-To: cygwin AT cygwin DOT com Message-ID: <383708668.20180123214156@yandex.ru> To: Ronald Fischer , cygwin AT cygwin DOT com Subject: Re: Ejecting a USB drive using Cygwin (sync)? In-Reply-To: <1516706057.3270332.1245015392.5FE803A3@webmail.messagingengine.com> References: <1516706057 DOT 3270332 DOT 1245015392 DOT 5FE803A3 AT webmail DOT messagingengine DOT com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-IsSubscribed: yes Greetings, Ronald Fischer! > I'm looking for a command, which would allow me from a shell script to > prepare the removal of a USB device (stick, external hard drive etc.). Windows device disconnect option syncs the device. Just find a tool that plays right. > With other words, after issuing the command, I should be able to physically > remove the USB device. > Can the `sync` command be used, for instance > sync -f /cygdrive/e > assuming that the USB device is on drive E:? The man page of *sync* is a > bit vague in this respect. Or is there another Cygwin command which can be > used for this purpose? There's no "eject" implementation, to my knowledge. Also, please keep in mind that ejecting drive vs. detaching a device is a distinctive operation. I.e. detaching a multi-mode card reader may leave system unable to access newly inserted cards. -- With best regards, Andrey Repin Tuesday, January 23, 2018 21:33:21 Sorry for my terrible english... -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple