06 July 2019

Using dd instead of disk and partition cloners like CloneZilla or PartImage

The problem with applications like CloneZilla is that although they are excellent for disk imaging, they have very un-intuitive interfaces, the number of steps they make you go through is huge and they suffer from problems with UEFI when creating a USB version.

Linux's dd command on the other hand, is projected as being very dangerous and people say it's better to use something like CloneZilla just to be safe. But from what I've seen, as long as you type the command properly, dd is actually far more convenient than the other applications.

Here are some useful commands:

To compress and clone entire sda onto a folder on sdb or sdc:

*** Caution: Verify all the commands below before executing them ***
*** Caution: The folder paths and partitions will be different for you *** 

When you plugin the pen drive or external hard disk, it'll get mounted as sdb or sdc. Find out where it got mounted. Mine was in /media/ubuntu/Nav/ and it was in sdc, since sdb was the Ubuntu startup USB. Created a folder named "bkp" in Nav and:
sudo dd bs=1M if=/dev/sda | gzip > /media/ubuntu/Nav/bkp/backup.img.gz
Don't worry. Even though sdc and sdb are mounted on /media, which is the root folder (and hence you'd think it's part of sda), Linux knows that these are mounted filesystems, so it won't consider it part of sda.
Instead of using bs=1M, you could speed it up by checking what your disk buffer size is using sudo hdparm -i /dev/sda, and set that as the bs value. So if the buffer size is 8MB, set bs=8M.

If the disk was not automatically mounted, you can mount it yourself using:
cd mnt/
sudo mkdir bkp
mount /dev/sdc1 /mnt/bkp

Now take a backup
sudo dd bs=8M if=/dev/sda | gzip > /mnt/bkp/backup.img.gz

Restoring sda is done via:
gunzip /mnt/bkp/backup.img.gz | dd of=/dev/sda

Taking a backup of sda means that even unallocated space gets backed up, and that can take very long (3.6 hours for a 500GB HDD). If you don't need a full disk backup and can manage with just the few numbered sda partitions, then just do a backup and restore of sda1, sda2 etc. To do that you'll have to also backup and restore a copy of the partition table as shown below.

You can take a copy of the partition table info using:
sudo sfdisk -d /dev/sda > my_partitions

Now create backups (these commands are a bit risky because you have to take care to not mess up the "if" and "of". Safer commands are shown below):
sudo -i
dd if=/dev/sda1 of=/media/ubuntu/Nav/bkp/sda1.img bs=8M
dd if=/dev/sda2 of=/media/ubuntu/Nav/bkp/sda2.img bs=8M

Restoring  the partition table info is done via:
sudo sfdisk --force /dev/sda < my_partitions

Restoring backups:
sudo -i
dd if=/media/ubuntu/Nav/bkp/sda1.img of=/dev/sda1 bs=8M
dd if=/media/ubuntu/Nav/bkp/sda2.img of=/dev/sda2 bs=8M

Okay, so the safer commands are:
sudo dd bs=8M if=/dev/sda1 | gzip > /mnt/bkp/sda1.img.gz
sudo dd bs=8M if=/dev/sda2 | gzip > /mnt/bkp/sda2.img.gz

Restoring sda is done via:
gunzip /mnt/bkp/sda1.img.gz | dd of=/dev/sda1
gunzip /mnt/bkp/sda2.img.gz | dd of=/dev/sda2

The good part about these safer commands is that they also compress the backup, which saves you a good amount of space. I recommend taking backups of each partition separately instead of taking a full disk backup or directly backing up the entire sda, because having separate partition backups helps restore them separately too.

To wipe the first 1MB of any disk:

dd if=/dev/zero of=/dev/sdb bs=1M count=1

Here, the "b" highlighted in bold red should be changed to "a" or "c" etc., based on which disk's first 1MB you want to wipe. The partition information will disappear, so this command is useful when trying to re-purpose any disk. Once the command is run, just use GParted to create the partitions.

To write zeros onto the entire disk:

dd if=/dev/zero of=/dev/sda bs=4096

This is helpful when you want to experiment with whether dd works well for backups. I used this command to fill the disk with zeros, then installed Windows and tried backing up. The 500GB disk with around 20GB of data on the Windows partition got gzip backed up into 12GB. The high compression was because the rest of the disk was full of zeros.

02 July 2019

Ather. My review and first impressions on my first visit and test ride

I had been hoping to visit the Ather center at Indiranagar for a little more than a year. Was passing by today, so dropped in. I'm not a bike expert or enthusiast, so these are just my first impressions. I've also mentioned a lot of the questions I asked them and what answers I received. I haven't yet verified the veracity of their replies.

Took the bike for a test ride and noticed a lot of heads turning when they heard the unique "whoooieeee" sound of the motor :-) The disc brakes can bring the bike to a halt quite fast, and can make the bike skid a little. When this happened, the noise irritated a dog, and it began barking and chasing me. The acceleration from the bike was so good that the dog couldn't keep up. I would've never escaped this easily on my geared bike :-)

The good
  • The bike looks smart from the front and side.
  • Good acceleration.
  • Good quality rubber belts (they say it's reinforced with carbon-fibre and can last 60K to 90K kilometer).
  • Low center of gravity, so could ride it at even 3 kmph.  
  • A reasonably pleasant experience when riding.
  • Good road grip and balance.
  • Reasonable turning radius.
  • Good control.
  • In general, body parts seem to have a reasonably good quality.
  • Reasonably smooth ride. 
  • Hassle-free test ride process, polite, intelligent, helpful and down-to-earth people.
  • Indicator lights switch off automatically when a turn is detected or after a certain number of seconds.
  • Large boot area to keep the helmet, with extra pockets for keeping documents etc. below the seat.
  • There don't seem to be parts that would need frequent replacement like in petrol bikes. 
  • The dash provides info about tyre pressure (okay, this is super cool!).
  • Headlight seemed bright enough.
  • Alloy wheels and tubeless tyre.
  • The onboard map was a fabulous feature (though I could do without it).
  • The functionality to move in reverse was superb! Not really necessary if you have strong legs, but useful.
  • They show you details of your test ride with some lovely graphics. 

(I'm not entirely sure this was the ride I took, because it certainly didn't feel like I rode for 31 min, and the screen showed that I didn't go on 80 ft road, but I actually did, immediately after the dog-chase).

The bad
  • The area of the bike is kind-of exposed and high above the wheel, which makes it look ugly.
  • The physical buttons are a bit hard to reach with the thumbs. 
  • When moving on a road hump, the rear suspension clangs, which makes it feel like as though a helmet in the boot is getting jostled around even if there's nothing in the boot.
  • The company knows your exact travel path. Data privacy issue.
  • The handle grip felt too hard and straight. I'm not sure if it was the fact that it was too thin, that made me need to grip it harder or just the hardness, but it felt uncomfortable for long duration use.
  • When the bike is driven with uneven speeds for a while, a fan turns on for cooling. The noise from it can be extremely annoying (As of Oct 2019, I hear they've made it less noisy).
  • Although the bike has an incognito mode, it gets disabled the next day and data about your ride is transmitted to the company server again unless you remember to disable it.
  • When using the key to lock or unlock the bike, the quality of the locking mechanism didn't seem as good as I would've expected from such an expensive bike. There was a certain amount of shakiness or some odd feeling that didn't lend it a perception of excellent quality (although you could say it was good-enough quality). The physical buttons also seemed to be of ordinary quality.
  • Slight chance of the bike being difficult on your back muscles due to the positioning of the handle, and the seat design.
  • At speeds below 20kmph, there can be a bit of a dragging/rough feeling, which is probably because of the rubber belt, but it's tolerable.
  • The headlight is always on. BIS regulation.
  • The seat locking system was unreliable. It should've just been a mechanism where you can push downward and the seat gets locked, but they designed it so that it needs to be dropped from a height of 1 or 2 feet, and I had to drop it multiple times until it got locked. A bit annoying even if practice makes perfect. 
  • I was not informed of what the procedures would be if I encountered an accident during the test ride.
  • If parked under the sun for too long, there's a good chance it could be bad for the battery. Heat is always bad for batteries.
  • The suspension was rather stiff, and they said they couldn't adjust it. It's designed that way to strike a balance between control and comfort.
  • If you aren't covered under insurance, the damage to parts or scratches fixing can cost you a bit more than the average bike.
  • Battery life: Will decrease with time. By the 5th or 6th year it may give only 25km on a single charge (this is what I was told by one person and another person said it'd be more than 25km), but the power of the drive won't be affected.
  • Many parts of the bike were quite pointy. A more curved design would look better (just my opinion).

Questions I asked and responses
  • Units of electricity consumed: Per charge, 3 units. Approx. Rs.20.
  • Charging via solar or inverter: Yes, but only if 1KW and can last for 4.5 hours.
  • Space at footrest for carrying gas cylinder or 20L water: Yes.
  • Doorstep servicing charge if not opting for Rs.8000 or Rs.6000 plan: Rs. 1500 to Rs.1800. 
  • Servicing interval: Every 5000km. Doorstep servicing.
  • Battery cost: Rs.35K to 45K (price is reducing).
  • Battery protection from water: Yes. Can survive complete submerging for 30 min.
  • Riding in water-logged road: Yes. Some dirt may get lodged between wheel area, but will come off after riding a while. Roadside assistance also available.
  • Assistance and servicing radius: Within Bangalore only for now. Plans to setup in Chennai and Hyderabad too.
  • Time for charging: For single phase AC, it takes 4.5hr (at your home) and for 3 phase DC (at Ather charging points), it charges at a rate of giving you 1km range per 1 min of charging.
  • RTO visit when buying bike: No need.
  • Exchange offer for old bike: No. They've considered it, but found it impractical.
  • Charging in apartment basement: Difficult unless you have reserved parking space. Their team can provide a fixed charging point for free for 20m from the electricity meter, but any extra length of wire you'll have to pay.
  • If company closes: Unlikely because they are backed by biggies and the demand for EV's is growing, but if a shutdown happens, they are legally obliged to continue offering servicing for 10 years.
  • Lithium availability: At least 10 years or more.
  • Charging stations: They plan to have one every 1.5km by end of one year.
  • Oiling and greasing requirement: No. Will be done during servicing.
  • Theft: Not easy to remove battery. If bike is stolen, when it's switched on, the location will be transmitted. Some parts like the license plate and mirrors can be removed by mischief-mongers.
  • Max weight: 165kg without loss of efficiency.
  • Insurance provider: Go Digit.
  • Cost of insurance: Rs.6000 for 5 years. First year is comprehensive insurance (bumper to bumper). Second year onward, third party insurance only. If you want comprehensive insurance, you'll have to pay Rs.1500.
  • Wait time after placing order: 3 months. You have the option to postpone the delivery/buy date at no extra charge.
  • Lease option: Bike can be taken on lease and returned after the lease period if not satisfied.
  • Portable charger same as fixed charger: Yes. The fixed charger only provides the convenience of being fixed at the parking spot.
  • Not using bike for some time: Bike has a shutdown mode in which it won't draw power from peripherals, and can safely last for around 2 months in this state.
  • Battery explosion possibility: The person said this is unlikely because of the way in which the charging and discharging is managed, but I wasn't fully convinced. In any case, we have been carrying highly inflammable material in petrol vehicle tanks. Whether batteries are safe or not, time will tell.

My wish-list for electric vehicles
  • Matte finish body and options for grey shades instead of just white.
  • Separation of vehicle performance data sent to the company and vehicle location data. I don't mind sending performance data, but sending location data is a violation of privacy. Some people just don't seem to understand why that's a problem.
  • Physical buttons that are easier to access with the thumbs.
  • Option to sell old bike like at Maruti True Value.
  • A press-to-lock mechanism for the seat (when closing it after storing something in the under-seat compartment) instead of a drop-to-lock.
  • Switching between eco and sport mode without having to stop the bike.
  • Option to switch off the headlight.
  • Capability to display the driving license, bike registration and insurance certificate on the dash, to show to traffic police when they stop bike for checks.
  • Safety mechanisms to prevent injury in case of battery explosion.
  • A less noisy cooling fan (as of Oct 2019, I hear they've already made it quieter)
  • Drum brakes instead of disc brakes (I don't want to depend on brake fluid).
  • A covered rear wheel area, instead of leaving it so exposed.
  • Rat-proofing: Sometimes rats chew away at wires or rubber tubes etc. Since Ather's drive belt is made of rubber (and expensive), I hope there would be some kind of rat-proofing.  
  • In Bangalore, even the pillion rider needs to wear a helmet, so it'd help if the bike has some kind of a pre-built lock or extra space under the seat to ensure that two helmets could be stored/locked on the bike.
  • Wide-angle camera at the front and back to record the trip (locally; not on the cloud) for safety purposes.
  • Removable batteries that can be exchanged/rented for charged batteries at charging stations, where the batteries can be tracked via blockchain. This would eliminate the need to charge batteries at home (especially helpful if you stay at an apartment complex). The video below shows many such bikes with removable batteries.
  • Fewer (or zero) power-cuts in Bangalore and more solar electricity. Especially on roof-tops and parking spaces (this is of course not a bike feature, but it's part of the wishlist anyway).
This solar parking space was built by Tata Power (as I remember)

Overall, the Ather was a nice bike to ride. Happy that it is designed and manufactured in India. They've got a forum where people share their experiences. Given that there are quite a few points on my wishlist that would remain unfulfilled, the high cost of the vehicle and given the current difficulties in finding charging points and also the person mentioning that they wouldn't be able to make hardware changes (like the handle button position) easily, I'd probably not buy an Ather for a rather long time. If I do decide to buy, the review process is going to be far more detailed than this.

Ather vs. petrol bikes
A somewhat practical analysis of the costs of Ather vs. petrol bikes is done on this website and this website.

Alien and mosquito designs
I had a look at a lot of other electric bikes, and almost all of them have a pointy, mosquito or alien look. It looks like the designers were more interested in impressing their bosses/investors rather than in designing a bike that would actually look streamlined and decent. If any designer is reading this post: Please design a bike that looks like something a common citizen would want to buy.

Have you ever tried an Ather or another electric bike? What was your experience like?