I needed to move a directory temp/ between sda1 -> sda2 partition to free some space in sda1.

Some how I ended up:

sda1: the directory temp/ is not shown sda2: no directory moved here.

I used testdisk and I could recover most of the file and I can see that the directory temp/ and all sub directories are still on sda1 and I hoped to use extundelete to make temp/ visible but did not work.

I think I have most of the data recovered but the problem is that the sda1 is still full (did not free any extra space apparently)

I used extundelete from a live installation on sda1 not mounted in this way: extundelete /dev/sda1 --restore-directory /mnt/temp

the program shows 556 inodes to restore and ends with 556 inodes not restored (if it helps). After normal reboot still no sign of the temp/ directory

Any hint? How do I recovery the faulty mv command? How do I release the memory?

I runs lubuntu 16.04


  • What exact command did you use? You can't mv files between partitions ... only between folders. I guess /mnt/temp is the mount point of sda1 ... Where is sda2 mounted? – derHugo Jul 26 '17 at 5:53
  • It is / /dev/sda1 with /mnt/temp ( temporary files before moving these to other directories).It contains some subdirectories. I know it is not 'correct' but easier to move things around /mnt/doc /dev/sda2 i did not know about not using mv between different partitions :( thanks for the info:) in any case I tried to move the folder temp aiming to something like /mnt/doc/temp so temp is a directory in /dev/sda2 i hope this help – gipsea Jul 27 '17 at 5:40
  • Ok how I understand /dev/sda1 is mounted to / and it has a path /mnt/temp on it. /dev/sda1 is mounted to /mnt/doc. Than you could do something like 1. Make new directory in sudo mkdir /mnt/doc/temp 2. COPY not move the files with sudo cp /mnt/temp/* /mnt/doc/temp 3. Check if all files reached. 4. If everything went good than remove the old files via sudo rm -rf /mnt/temp. This way you confirm before removing the files – derHugo Jul 27 '17 at 5:55
  • Just to be sure: can you write/copy any file to /dev/sda2 in /mnt/doc ? – derHugo Jul 27 '17 at 5:56
  • quick amend on your last commend. /dev/sda2 is mounted on /mnt/doc. – gipsea Jul 27 '17 at 14:47

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.