What I'm i doing wrong

Frankie Clark:
What I’m i doing wrong

Mahesh Babu:
check the folder and file exits.

Frankie Clark:
Hi I don’t remember how to check folder

Alistair Mackay:
Your mistake was this

sudo mv /opt/food/ /var/www/html/

The question asks to move the content of /opt/food. You have moved the directory itself…

thor@host01 ~$ ls -l /var/www/html/
total 4
drwxrwxrwx 3 root root 4096 Sep 14 11:07 food

^^ Directory food placed inside of /var/www/html - and no longer present in /opt, hence you got the stat error when you executed the correct command next - food directory had already gone

thor@host01 ~$ ls -l /opt
total 0 

To move the content, you needed to do this straight off

thor@host01 ~$ sudo mv /opt/food/* /var/www/html/

Now when we examine the html directory, the files are correctly placed

thor@host01 ~$ ls -l /var/www/html/
total 12
drwxrwxrwx 2 root root 4096 Sep 14 11:07 food_files
-rw-rw-rw- 1 root root 5701 Sep 14 11:07 index.html