tar and copy command not work with installed operation sytem partition

Asked by ajay patil

Hi ,
I install ubuntu 20.04 on USB pen-drive after installation two partition are created which is EFI system and linux filesystem. We try the both copy or create tar file of this two partition and after untar or copy it into other USB pen-drive the operating system is not booting only grub will show. Also we try using dd and it was work for me. But using the copy and tar it was not work. Any suggestion how to create right way of tar of both the partition and after untar that USB pen-drive will work as operating system.
Thanks and Regarding
  Ajay

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu Edit question
Assignee:
No assignee Edit question
Solved by:
Manfred Hampl
Solved:
Last query:
Last reply:
Revision history for this message
Manfred Hampl (m-hampl) said :
#1

If you want to boot from a device, that device needs certain settings which are stored in the boot sector of the device and not in the partitions. Copying or tar-ing the partitions does not work. You need to copy the whole USB stick, e.g. with dd.

Revision history for this message
ajay patil (ajay9292) said (last edit ):
#2

Hi hampl,
Thanks for reply.
Is there method that first store boot sector setting information after that store the root file system?
Without using dd any other method to achieve the goal.

Thanks
ajay

Revision history for this message
Best Manfred Hampl (m-hampl) said :
#3

The only way of accessing the boot sector that I know is with dd (or similar tools that directly access the device).

Revision history for this message
ajay patil (ajay9292) said :
#4

Thanks for quick reply.
There is way to make the custom root file system ? or how to customize the root file system ?

Thanks and Regarding
     Ajay

Revision history for this message
ajay patil (ajay9292) said :
#5

Thanks Manfred Hampl, that solved my question.

Revision history for this message
ajay patil (ajay9292) said :
#6