Not able to copy file to the VM

I have copied products.part2.json file I cannot view it on VM

Hi @Rakshith_79674,

Can you please let me know where did you copy the file and where exactly are you checking for it in the VM?

Thanks,
Muskan

1 Like

I copied it into the shared folder and tried to look at it into the folder called shared

vagrant@m103:/$ ls
bin   dataset  etc         initrd.img.old  lost+found  opt   run     srv  usr      vmlinuz
boot  db       home        lib             media       proc  sbin    sys  vagrant  vmlinuz.old
data  dev      initrd.img  lib64           mnt         root  shared  tmp  var
vagrant@m103:/$ cd shared
vagrant@m103:/shared$ ls
vagrant@m103:/shared$

2

I copied it into shared and, it is even copied in dataset folder

Hi @Rakshith_79674,

Your current directory is not correct.

“/” indicates you are in root. Please cd into /home/vagrant and then you’ll be able to see your files in shared folder after you ls them as below.

ls /shared

Thanks,
Muskan

1 Like
vagrant@m103:/$ cd home/vagrant/
vagrant@m103:~$ ls /shared
vagrant@m103:~$ ls /shared
vagrant@m103:~$

I could not see any file there

Hi @Rakshith_79674,

Okay, I see.

Just one more thing - can you please run below commands and share their output?

vagrant@m103:~$ pwd

vagrant@m103:~$ cd /home/vagrant/shared

vagrant@m103:~$ ls -lrt

Also, before this instance, where were you keeping all the files like config files and other .json files from handouts?
Was it in this same /shared folder?

Thanks,
Muskan

1 Like
D:\My Files\university-mongoDB\M103\m103-vagrant-env\shared>scp -P 2222 products.part2.json vagrant@127.0.0.1:/shared
The authenticity of host '[127.0.0.1]:2222 ([127.0.0.1]:2222)' can't be established.
ECDSA key fingerprint is SHA256:QgkYI+lPcP/Iio3QxHNreuuqa03nvHyx162qmXADd/M.
Are you sure you want to continue connecting (yes/no)?
Please type 'yes' or 'no':
Warning: Permanently added '[127.0.0.1]:2222' (ECDSA) to the list of known hosts.
vagrant@127.0.0.1's password:
products.part2.json                                                                   100%   44MB  78.7MB/s   00:00

I just copied this way from stack overflow can you please explain what does ECDSA is and why it’s added.

I could not complete last lab :expressionless:

@Muskan_47318 is probably finished for the day… maybe he’s home having dinner :shallow_pan_of_food: :tropical_drink:

@Rakshith_79674 not sure why you used scp. Can you answer this question please?

And did you do what @Muskan_47318 suggested here? Where’s the output?

Deadline just missed?

1 Like

The place where the vagrant box was configured there was a file called shared.
I used to copy the handouts to that file and accessed it through vagrant ssh.
I don’t know why the shared folder is empty when I ls
I tried chmod and chown commands to permit and changed the owner of the shared file, even though I dont find the json file

Yes, I missed 2 labs because of deadline.
I had my classes till evening 5 PM :sob:

I understand. And what about this? Run it and show us.

Next session you’ll finish the course in under one week :wink:

1 Like

After this which course would you recommend to take?

M121: The MongoDB Aggregation Framework?

Hi, I pretty much did all courses (except the external one) and I think after Basic Cluster Administration the reasonable course would be Performance (I guess preferred due to usage indexes by Aggregation Pipeline, explanation of pushing stages, out stage and routing) or directly Aggregation Framework, basically when it comes to knowledge there is no course between these. Security could work as well - if you are more DBA. Diagnostic should be probably as the last one.

Depends how much you want to push that - I always took 2–3 courses during that class scheduling, otherwise it would take forever take it one by one. Also it is possible to take more courses and fail some of them to open topic for learning as needed/wanted

2 Likes