Does Safely Ejecting From a USB Port Actually Do Anything?

iStock
iStock

Does safely ejecting from a USB port actually do anything?

Phillip Remaker:

Is there any harm to be incurred by just pulling a flash drive out? Why do we need safe removal at all?

Historically, operating systems (OS) treat disks as objects that can be trusted not to change state suddenly. When reading or writing files, the OS expects the files to remain accessible and not suddenly disappear in mid-read or mid-write. If a file is open, a program reading the file expects to be able to return to it and continue reading. Similarly, write commands may be dispatched to a writing subroutine and forgotten by the main program. If a drive disappears between the time the subroutine is called and the data is written to disk, that data is lost forever.

In ye olde days, there were formal processes to physically "mount" and "unmount" storage media, and the physical act of mounting a tape or a disk pack triggered some mechanical switch to detect the presence or absence of media. Once the mechanism was engaged, the software could start to use the media (a "soft mount"). Some media even had mechanical interlock to prevent media from being ejected or removed until the software processes using the media released the lock.

The Macintosh floppy and optical disk provide more modern examples of an interlocked physical and soft mount. One could only eject media through a software command, but that command might fail if some program was holding a file open on the medium. 

Enter USB connected storage. There is no mechanical interlock in a USB connection to coordinate the hard and soft mount. The user can decide to rip the disk out from under the operating system at any time, and endure all manner of programs freaking out about the sudden loss of media. "Hey! I was using that!" Symptoms could include: Lost data, corrupted file systems, crashing programs, or hanging computers requiring a reboot. A safe removal executes the "soft unmount" needed to prevent any unexpected Bad Things that may happen if a program loses its access to media.

A safe removal does a few things:

  • It flushes all active writes to disk.
  • It alerts all programs (that know how to be alerted) that the disk is going away, and to take appropriate action.
  • It alerts the user when programs have failed to take action, and still are holding files open.

You can remove a disk at any time, but you are at the mercy of how well programs using the disk cope with the sudden disappearance of that disk.

In the modern computer, many steps have been taken to defend against the capricious and careless removal of media. For example, Windows introduced a feature called "Optimize for Quick Removal," which makes sure data is written quickly instead of batched up and written efficiently. 

It is very hard to get people to change habits. If you are doing exclusively reads on a media, safe removal is probably not needed. If you are doing writes, you are probably OK to skip safe removal if you haven't written recently and you aren't doing something silly like indexing that disk.

As a good friend of mine once said: "Life is too short to safely eject the disk."

However, safe removal does a number of important things and is, in fact, the only assuredly safe way to remove a disk. You probably don't need it most of the time, but it is a good habit to have since data loss sucks.

This post originally appeared on Quora. Click here to view.

Surprise! Microsoft Admits That People Are Listening In on Your Cortana and Skype Conversations

mabe123/iStock via Getty Images
mabe123/iStock via Getty Images

In a turn of events that, at this point, probably shocks no one, Microsoft has confessed that human contractors have been listening in on some people's private conversations via Skype and Cortana.

Vice first broke the news on the privacy breach earlier this month, after a contractor passed along documents, screenshots, and actual audio files of some conversations. “The fact that I can even share some of this with you shows how lax things are in terms of protecting user data,” the contractor, whose name was withheld (for obvious reasons), told Motherboard. Unlike Apple’s recent Siri snafu, these conversations didn’t include potential criminal activity, but they did catch intimate exchanges about weight loss, love, and relationship problems.

Also unlike Apple: Microsoft is not suspending its practices. Instead, the tech monolith has updated its privacy policy to clarify that humans might, in fact, be eavesdropping on you.

“We realized, based on questions raised recently, that we could do a better job of clarifying that humans sometimes review this content,” a Microsoft representative told Vice. Before, the Skype website had mentioned that your content could be analyzed in order to improve the technology, but it never explicitly stated that humans would be listening to it.

Microsoft only records Skype conversations that use its translation features, in order to “help the translation and speech technology learn and grow,” according to the Skype FAQ section. If you’re not using translation features, your sweet nothings are reportedly as private as you want them to be. The updated FAQ section also now states that “Microsoft employees and vendors” may be transcribing the translated audio, and the procedures are “designed to protect users’ privacy, including taking steps to de-identify data, requiring non-disclosure agreements with vendors and their employees,” and more.

But Cortana’s data gathering isn’t limited to translation. According to its support page, Microsoft can collect your voice data literally any time you “use your voice to say something to Cortana or invoke skills.” If that worries you, we recommend spending some time adjusting the settings on your Microsoft Privacy Dashboard.

[h/t Vice]

Amazon Is Making It Easier for Sellers to Donate Returned or Unsold Items Instead of Trashing Them

ronstik/iStock via Getty Images
ronstik/iStock via Getty Images

After mailing back an unwanted Amazon order or bringing it to a drop-off location, you may assume your return will find its way to a good home. But not every item returned to Amazon is re-listed on the website. Many third-party sellers working through Amazon simply toss returned products in the trash along with any surplus goods they can't sell. That's about to change: As CNBC reports, the retailer will make its new Fulfillment by Amazon (FBA) Donations program the default option for independent shops based in the U.S. and the UK.

Starting in September 2019, sellers that have unwanted returns or unsold items sitting in an Amazon warehouse can depend on the company to donate them to a good cause. In the U.S., products that are eligible for donation will be sent to various nonprofits through a charity group called Good360, and in the UK, groups including Newlife, Salvation Army, and Barnardo will distribute the goods.

“We know getting products into the hands of those who need them transforms lives and strengthens local communities,” Alice Shobe, director of Amazon in the Community, said in a statement. “We are delighted to extend this program to sellers who use our fulfillment services.”

Amazon charges independent sellers 50 cents to ship unsold items back to them and just 15 cents to throw them away, meaning that donating or trying to resell returned items wasn't always cost-effective for businesses. Amazon reportedly wasted 293,000 products over a nine-month period in just one French distribution center alone.

The company now aims to incentivize sellers to donate their unsold and returned inventory by making it the cheaper option, according to sellers who spoke to CNBC. As part of this program, Amazon will also manage the logistics and work with charities in an effort to "streamline the donation process for independent sellers."

The Fulfillment by Amazon Donations program will be the default for U.S. and UK sellers starting on September 1, but stores will still have the opportunity to opt out if they wish.

[h/t CNBC]

SECTIONS

arrow
LIVE SMARTER