I have installed Ubuntu 16.04 on a 32GB pen drive, because my hard disk stopped working. It runs okay from the pen drive, but it sometimes hangs for a few seconds during write operations (and maybe sometimes read operations too) on the pen drive. This frequently causes applications to become unresponsive for around 5 to 15 seconds (they usually turn grey during this time).
Probably enabling write-back caching will help. Does anyone know how to enable caching so that I don't suffer from occasional extremely high write (and maybe read) times?
I realize that this question is a duplicate of How can I change the cache mode of an USB drive?. An answer there says:
You can try remounting the partition with different options, example
sudo mount -o remount,rw,relatime,data=writeback /dev/sda1 /
Another option is to pass the argument via Grub.
Executing the above command gives this error message (in dmesg
):
EXT4-fs (sdb1): Cannot change data mode on remount
I don't know how to pass this argument via Grub.
Update:
Here is my /etc/fstab
:
# <file system> <mount point> <type> <options> <dump> <pass>
# / was on /dev/sdc1 during installation
UUID=75f3da54-9738-4180-8f48-fcef12d8c1ca / ext4 errors=remount-ro 0 1
/dev/disk/by-label/DELLUTILITY /mnt/DELLUTILITY auto nosuid,nodev,nofail,noauto 0 0
/dev/disk/by-label/Recovery /mnt/Recovery auto nosuid,nodev,nofail,noauto 0 0
/dev/disk/by-label/win7 /mnt/win7 auto nosuid,nodev,nofail,noauto 0 0
/dev/disk/by-label/SPARE /mnt/SPARE auto nosuid,nodev,nofail,noauto 0 0
/dev/disk/by-label/GoFlex /mnt/GoFlex auto nosuid,nodev,nofail,noauto,x-gvfs-show,umask=002,uid=1000,gid=1000 0 0
/dev/sda
is my non-functional hard disk/dev/sdb
is my pen drive.
/etc/fstab
file on the drive you boot from.