0

Today is the first day of my 38 years on this planet that I am using Linux. So please be patient with me.

I have successfully followed a series of steps to mount a share folder from my Windows Desktop, to appear in Ubuntu - I've installed Samba Client, created my local directory, my credentials, and finally mounted with sudo nano /etc/fstab and entering the correct details -

//IP-ADDRESS/SHARE FOLDER 1 /media/LOCAL FOLDER 1 cifs credentials= etc etc

I would now like to add a second share folder from the same Windows Machine and I have no idea how to go about it. I tried amending fstab to read -

//IP-ADDRESS/SHARE FOLDER 1 /media/LOCAL FOLDER 1 cifs credentials= etc etc

//IP-ADDRESS/SHARE FOLDER 2 /media/LOCAL FOLDER 2 cifs credentials= etc etc

But whenever I try to mount that, I get an error:

mount: /etc/fstab: parse error at line 14 -- ignored

Any pointers on what to do here would be hugely appreciated.

Many thanks

3
  • 1
    There is nothing wrong with mounting 2 different shares on 2 different lines in fstab. My guess is there is some kind of syntax error in your 2nd line. Perhaps you can post that more literally? I recommend not using spaces in your folder names, else you need to use an escape char space \040 in fstab
    – Matt M
    Commented Oct 4, 2023 at 16:37
  • 1
    @MattM Thanks so much for your reply. There was indeed a space in the filename of the folder that I was trying to mount, and replacing the char space with \040 solved the problem! Thank you :)
    – MartyCH85
    Commented Oct 5, 2023 at 8:45
  • No problem! Spaces in folder/file names can often be a recurring issue in Linux. I recommend using underscores when possible.
    – Matt M
    Commented Oct 7, 2023 at 4:33

0

You must log in to answer this question.

Browse other questions tagged .