Is it wrong to pull USB out without ejecting?

usb

Your computer will often display a scary warning if you fail to safely eject the drive. But do you actually still need to do this? What happens if you don’t?

Is there any harm to be incurred by just pulling a flash drive out? Why do we need safe removal at all?
We have all been guilty of ripping our USB drives out of our computers instead of ejecting them properly, only to receive the judgemental pop up telling us we really shouldn’t have done that.

But when everything on the USB works fine next time you plug it in, you can’t help but doubt: does it actually do anything when you safely eject your disk before removing it?

Well, we’ve done a little background study, and it turns out that it does. In fact, waiting those extra 30 seconds to safely eject could help to properly save your data and software.

Previously, operating systems treat disks as items that can be trusted not to change state unexpectedly. When reading or writing files, the OS expects the files to remain available and not suddenly vanish 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 orders may be dispatched to a writing subroutine and forgotten by the main program. If a drive disappears between the times the subroutine is called and the data is written to disk, that data is lost eternally.

In the olden days, there were official 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 identify 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 avoid media from being expelled or removed until the software processes using the media free the lock.

As Phillip Remaker explains over at Quora that our operating systems have been programmed to treat our external drives like USB sticks – like they’ll always be there. It expects the files on it to remain reachable indefinitely and these changes the way it interacts with a flash drive.

This means if a program on your computer is just reading a file and not actually saving any information to the drive, it’s probably not going mess things up too much for the files on your USB stick if you suddenly pull it out. But you do risk confusing your computer, says Remaker. “Symptoms could include: Lost data, corrupted file systems, crashing programs, or hanging computers requiring a reboot.”

The Macintosh floppy and optical disk provide more current 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!”

A safe removal does a few things like it flushes all active writes to disk, alerts all programs (that know how to be alerted) that the disk is going away, and to take suitable action and 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 pity of how well programs using the disk manage with the sudden disappearance of that disk.

In the new computer, many steps have been taken to protect against the unpredictable and casual removal of media. For example, Windows even introduced a feature called “Optimise for Quick Removal” that makes sure data is written quickly instead of batched up and written professionally. It is very hard to get people to change habits. If you are doing exclusively reads on a media, safe removal is perhaps 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 small to safely eject the disk.

However, Safe Removal does a number of essential things and is, in fact, the only assuredly secure 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.

 

If you like our posts please like us on facebook and support us.

Please let us know about your views in comments.

The 5 Most Infamous Software Bugs in History

In the digital era, computer bugs can affect our lives, the economy of a nation and even the well-functioning of society in general. As the internet of things gradually invades all aspects of our environment, the importance of identifying and preventing computer bugs grows exponentially.

These are 5 infamous software bugs that went down in history:

1 – The “Moth-er” of all bugs

BBVA-OpenMind-ventana-primer-bug-ppal1

After finding a moth inside the Harvard Mark II computer on September 9th, 1947 at 3:45 p.m., Grace Murray Hopper logged the first computer bug in her log book. She wrote the time and the sentence: “First actual case of bug being found”. Nowadays, the term “bug” in computer science is not taken literally, of course. We use it to talk about a flaw or failure in a computer program that causes it to produce an unexpected result or crash.

You may already be familiar with this story, but is it really true…?

2 – The Y2K bug

bug02

In the last century, software developers had never thought that their code and creations would survive into the new millennium. For this reason, many assumed that writing “19” before the variable “year” was an unnecessary waste of memory. Most decided to omit these two digits.

All good until the turn of the century: the closer we got December 31st, 1999,  the more we started worrying about the fact that computer systems in New Year’s Eve would update their clock to January 1st, 1900 instead of 2000 and, because of this, major disasters would be unleashed and it would be the end of mankind.

However, we are still here to tell the tale: nuclear missiles were not fired on their own, planes did not fall from the sky and banks did not lose all the information about their clients’ savings.

The Y2K bug was real, nevertheless. Billions of dollars were spent in order to upgrade computer systems worldwide. Also, some small incidents were reported: In Spain, some parking meters failed. The French meteorological institute published on its website the weather for January 1st 19100 and in Australia, some bus-ticket validation machines crashed.

3 – The Dhahran Missile

In February 1991 (First Gulf War), an Iraqi missile hit the US base of Dhahran in Saudi Arabia, killing 28 American soldiers.

Following an investigation, it was determined that the base’s antiballistic system failed to launch because of a computer bug: the Patriot missile battery, whose role is to detect and intercept enemy missiles by “crashing” against them in mid-air, had been running for 100 hours straight. After every hour, the internal clock drifted by milliseconds and that had a huge impact on the system (a delay of  ⅓ of a second after 100 hours).

For a person, 0.33 seconds is an infinitesimal amount; but for a radar that tries to track anAl Hussein Scud missile –  that reaches Mach 4.2 (1.5 km per second / 0.88 miles per second ), this “micro-delay” translates into a “600 meter” error. In the case of the Dhahran incident, the radar first identified an object in the sky but didn’t manage to track it due to the error, and thus, the missile didn’t launch itself.

 

4 – Feet or meters? The Mars Climate Orbiter nav bug

bug03.jpg

The Mars Climate Orbiter was launched in 1998 with the goal of studying climate on Mars, although it never managed to fulfill its mission.

After traveling through space for several months, the probe was destroyed because of a navigation error: teams who controlled the probe from Earth used parameters in imperial units meanwhile the software calculations were using the metric system. These miscalculations had an impact on the flight path. In the end, the probe was destroyed because of friction with the Martian atmosphere (an error of almost 100 km).

5 – Too many digits for Ariane 5

bug04.jpg

When coding, a developer has to define variables the program will use and also the size those variables will take in the computer’s memory. The amount of memory required by the variable is expressed in bits.

A 16 bits variable can have a value of −32.768 to 32.767.

On the other hand, a 64 bits variable can have a value of −9.223.372.036.854.775.808 to 9.223.372.036.854.775.807 (that’s almost an infinity of options).

On June 4th, 1996 and only 30 seconds after the launch, the Ariane 5 rocket began to disintegrate slowly until its final explosion. Simulations with a similiar flight system and the same conditions revealed that in the rocket’s software (which came from Ariane 4), a 64-bit variable with decimals was transformed into a 16-bit variable without decimals.

These variables, taking different sizes in memory, triggered a series of bugs that affected all the on-board computers and hardware, paralyzing the entire ship and triggering its self-destruct sequence.

 

 

 

If you like our posts please let us know in comments.

Access PC files on smartphones

Yes, you heard that right. You can access your computer’s hard drive with your smartphone in few simple steps.  For this, you don’t have to download or install any big software on your PC or  smartphone. Your Android’s file explorer can do the task easily.

The good thing with this tutorial is that you can copy and paste big files, software, and other things easily to your phone at high speed. Let’s take a look at how this works:

To make this trick work, you should be connected to same network (Wi-Fi).

Step 1: Right click on the drive you want to share.  Use the below-mentioned path to share this folder. You will see an icon appeared which mean the drive is shared.

Properties> Sharing> Advance sharing>share this folder.

public-access.jpg

Step 2: In order to access files from hard drive with smartphone open ES file explorer.  Now click on the three line hamburger symbol then click on LAN

access-files-PC-android-1.jpg

Step 3: Now perform a scan and you will see  your PC if it’s connected to the same network. Now enter the username and password of your PC.  There you will see the shared folder. 

access-files-PC-android-2.jpg

Step 4: Here you will all the items in your computer’s drive. You can tap and hold to copy or cut any folder to your smartphone.

access-files-PC-android-31

I performed copy action and achieved nearly 5 Mbps speed.

 

access-files-PC-android-4.jpg

 

 

If you like our post please let us know in comments

Use smartphone as webcam

Many would doubt the concept as of why one would prefer using his phone as a webcam? Well, there are a bunch of reasons to push this idea:

• Old phone having no front cam? You could use rear camera for video calling instead of buying one.
• A good chance that it can stand for a pretty good “Security camera”, monitoring your babies or other watch hours, without buying expensive standalone cameras!
Oh yes, it is a matter of concern that you would buy a new camera for the purpose but still if you want to save those few dollars/rupees, you can stick to this idea. Don’t sell that old one in your pocket, it can still serve you well.
Now the question arise on How-to-do stuff? Isn’t it? Well there are certain right apps that would provide you with satisfying interface and make worth it.

Android:

Android Phone
Play store as well as private developers provide a number of apps for this purpose. But beware of those fake tagline, you could be fooled and end up in wasting worthy data or leak of some personal information.
Out of the most tested, IP Webcam is the best one which proves for this purpose. Unlike DroidCam (which require a similar application to be installed in Windows), this app works through your browser, giving you the compatibility and freedom to move over platforms.

Step-to-do:

  1. Connect you phone and computer to the same Wi-Fi network.
  2. Install the app IP Webcam on your phone.
  3. It is advisable to close any app which uses your phone’s camera (kill’em using task manager).
  4. Launch the app. Scroll down until a tab appears- “Start server”.
  5. The app will now display a URL, something like- http://abc.de.fg.ij:klmn (alphabets represents numerical).
  6. Enter this URL in your web browser and hit Enter.
  7. In the browser, you’ll see a drop down menu next to Video renderer. Select Browser.
  8. Next, you’ll see Audio renderer. Select HTML wav.

Lava Android Phone

Now you’re good to go. You’ll see a live video feed in your browser. You can record it via browser. You’ll get used to controls once you use it.

Although there might be some problem in HTML wav audio streaming, you can prefer VLC media player for this purpose.

Download it from here, install it. Go to Media>Network Stream and enter the URL generated from the app.
Once the app is running, you don’t need to keep the phone’s screen on. It works smoothly even if phone is locked but video feed experience is slightly better when phone’s screen is on.

iOS:

EpocCam and PocketCam rule the app market in race of making your iProduct a better webcam. PocketCam is messy to configure, and gives access to only black n white video, no audio in free version. You can rely on the paid one to get better service.

iPhone 4S

EpocCam is free and quite easy to set up too! Here’s how to make it under use:

  1. Download EpocCam on your iDevice as well as for your Mac or PC.
  2. Make sure both the devices are connected on the same network.
  3. While installing, several prompt may appear asking you to install some drivers. Install them, they essential audio and video drivers used by the app.
  4. Start the app on both devices.
  5. The app will automatically searches for the device running EpocCam on the same Wi-Fi network. Soon, the video from your iDevice will be shown up on your computer.
  6. There might be a few occasions when the app won’t connect your device to your computer. In the case, restarting the app quickly fixes the issue. Also, there is no video recording feature in this app, but video recording apps like CamStudio, ScreenPresso, etc. will work for you.

Video Calling- Setting up your phone as a Webcam:

Android:
Disappointing though, IP Webcam doesn’t work with Skype, so you need to stick with DroidCam and its PC Client to work.

DroidCam

Step-to-do:

  1. Install DroidCam on your phone, as well as on your computer. (As DroidCam Client, here)
  2. Connect both the devices to the same network.
  3. Open the app on the phone and write down the Wi-Fi IP listed on the main screen.
  4. Open the Windows client and paste the IP on your computer.
  5. If you have slow internet connection, select low from the video quality drop down menu.
  6. Click Start.
  7. Now you’ll see video feed from your phone on the DroidCam Windows application.
  8. Better to keep your phone unlocked, to avoid minimal stutter and lag. Keep android app open and turn off auto-lock.
  9. Restart Skype (if it is already opened) and select DroidCamSource1 as webcam.
    Good to go again. Use your phone as the webcam.

iOS:

The procedure is simple. EpocCam enables you to connect to Skype and use your iDevice as Webcam.
Steps-to-do:

  1. Install app on both devices, as mentioned earlier.
  2. Start the app, it will connect automatically.
  3. Now, restart Skype and select EpocCam as the webcam.
  4. Now you’ll be using your iDevice as Webcam.

How to set default camera on Skype:
Skype on your PC will require the camera configuration.

Skype

Steps-to-do:

  1. Download and Install desktop version Skype app.
  2. Sign in to your account and enter Tools>Options.
  3. Click video setting under the general tab.
  4. Select the correct camera from the drop down menu next to Select webcam. The name of the camera will be similar to the name of the app
  5. you are using. Select it.
  6. Click save.

You can now place video calls from your computer using your phone as a webcam!

Note for iPhone, iPad users: The app stops working if you hit the home button or lock your phone.

 

If you have some suggestions of your own please let us know in comments!