Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have ubuntu 12.04 installed in my internal HDD. Is it possible to carry my desktop in my pendrive and use in my office computer and synchronize with my computer when I am back at home.

share|improve this question
Possible duplicate:… – Glutanimate Sep 22 '12 at 12:15
16988 is about installing and running Ubuntu from a USB. Namshum just wants to keep data on a USB pendrive and sync it from one computer to another. – fabricator4 Sep 22 '12 at 12:33
@Glutanimate I want to carry my whole working desktop including my data with me where ever I go and use it and just sync when I am at home. – Namshum Sep 22 '12 at 12:40
You are right, I am sorry. Have you tried out Unison? – Glutanimate Sep 22 '12 at 12:48
up vote 1 down vote accepted

I do something similar, and just use rsync to keep the pendrive up to date or to update one of the computers. rsync works best because with the right switches it will back everything up without overwriting the same file each time, or overwriting newer files with an older version.

To backup (for example) your Documents directory to the Pendrive first give the pendrive a label (volume name) and make a target directory such as 'Documents' on it. By giving the pendrive a label it will be easily found under the /media directory. Next issue the following command:

rsync -av ~/Documents/ /media/yourlabelname/Documents/

This command will backup up everything in your home Documents onto the pendrive. To reverse the process and update the files on another comptuer, simply reverse the rsync command eg:

rsync -av /media/yourlabelname/Documnets/ ~/Documents/

It's easy enough to put both of these commands into very short bash scripts and execute one each time by typing the name of the bash script. If the scripts are in ~/bin then they will get included in the executable path.

Note that if the USB drive is formatted FAT then the volume name is normally limited to capitals only, even if you typed the volume name in lowercase when you created it. Because bash is completely case sensitive you must get the volume name and directory name exactly right or the rsync commands will fail to work.

share|improve this answer
I rename my pendrive and created folder "Documents" but it shows and error sending incremental file list rsync: mkdir "/media/Manuranjan/Documents" failed: No such file or directory (2) rsync error: error in file IO (code 11) at main.c(605) [Receiver=3.0.9] rsync: connection unexpectedly closed (9 bytes received so far) [sender] rsync error: error in rsync protocol data stream (code 12) at io.c(605) [sender=3.0.9] – Namshum Sep 22 '12 at 14:05
Either the pendrive is not not mounted correctly, or there's an error in capitalisation. Remount the drive and check your syntax. After you change the volume name you must remount the drive to get it on the correct mount point. – fabricator4 Sep 22 '12 at 21:15
Thanks! The error was due to capitalisation of the usb device label – Namshum Sep 30 '12 at 9:09
Thankyou, I've added information to the answer to make it clearer for anyone else using this that Linux is very case sensitive, and that FAT volume names can be upper case only. – fabricator4 Sep 30 '12 at 9:36

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.