I am new to Ubuntu(and Linux for that matter) and I am trying to access files using the terminal. The network folder is on my Desktop, but when I go to the Desktop folder via the terminal, the network folder is not there.

How do I access files on a network folder via the terminal?

8 Answers 8


First go to:


cd /run/user/1000/gvfs/

In this directory you will find the name and access of the server you connected to. Enter this cd "name of your server"

Now you connected the server from terminal, but before that you need to enter it from the gui

The other way is to use; sshfs


Network locations mounted under GNOME via the GUI are mounted under ~/.gvfs.

  • 1
    Is this still true? I can't confirm this is working on Ubuntu Maverick. I have 2 network folders (1 smb, 1 ftp) mounted via nautilus and they do not appear in ~/.gvfs.
    – kynan
    Sep 13, 2011 at 8:41
  • this is true for me under Ubuntu 12.04 Precise Aug 17, 2012 at 21:57
  • 2
    under /run/user/$UID/gvfs for me on Ubuntu 17.04 Jun 8, 2017 at 17:13
  • @JanusTroelsen /run/user/$UID/gvfs also works on ubuntu 14 Nov 20, 2017 at 23:40
  • Worked for me under /run/user/1000/gvfs/ on Ubuntu 22.04.2 LTS (jammy)
    – M. A.
    May 7, 2023 at 19:00

First, sudo apt-get install cifs-utils

Next, sudo mkdir -p /mnt/windows/share-name && sudo mount -t cifs //machine-name/share-name /mnt/windows/share-name -o username=your-username,domain=your-domain

It will then prompt you for a password.

If the machine is not domain joined, just use the machine name in place of the domain.

This worked for me just now.


For Ubuntu 14.04, Ignacio's answer doesn't work. In fact is at other location, as told here.


Use smbmount. It mounts a network location to a directory.


I have stucked and tried several way. none have worked. I found a simple solutions.

Go to the shared folder in Ubuntu. right click inside the empty space of the folder and select "open in terminal". That´s it.

  • I like this because all I was trying to do was figure out how the shared drive was referenced in terminal, and this gives me that path - now I can do with it whatever I want!
    – DPSSpatial
    Jul 6, 2023 at 16:26

A good way to go is to use find command and search for files on the network location. Found it under: /home/user/.gvfs.

  • Worked for me. I would have never worked out the path without this method. Linux is so damn awkward at times.
    – Jammer
    May 10, 2023 at 8:19

For those who are using the answers here above to access their Google Drives, there's a super easy solution without dealing all this. Some guy built a FUSE filesystem for Google Drive, written in OCaml.

Check the related git here: https://github.com/astrada/google-drive-ocamlfuse

It lets you mount your Google Drive on Linux in few steps. You'll be able to access everything on your drive from the CLI.

  • 1
    As it’s currently written, your answer is unclear. Please edit to add additional details that will help others understand how this addresses the question asked. You can find more information on how to write good answers in the help center.
    – Community Bot
    May 27, 2023 at 15:35

You must log in to answer this question.