I've plugged an external hdd into my usb port, and it shows up on the desktop and in nautilus. How can i access this mounted hdd via the command line?


automounted drives usually sit on /media/{label of your partition}. You can browse into it by cd command in terminal say if my pendrive is labeled SAGAR

cd /media/SAGAR

You can view the path in nautilus with ctrl+l and cd from terminal copying the path as well

EDIT: In Newer version, the username is used for directory: /media/${USER}/{SOME_HASH}

| improve this answer | |

Every mounted devices have a "mount point" where they are mounted to. You can try to guess them (most removable stuffs are mounted into directories inside /media), but a nicer way to use the mount command within a shell, so you can see the mounted file systems. Then it's easy to check the directories you need to look ("something on somewhere" at every lines, look at "somewhere"). Also you can install a nautilus extension, in packages nautilus-terminal and nautilus-open-terminal, as far as I remember, one of these can open a terminal for you at the location where you are in nautilus, so you don't even need to use a single cd command to get there :) But anyway, if you're using nautilus you can navigate to the device's directory you are interested in, and the location bar will show you (or you may need to press CTRL-L then ...)

| improve this answer | |
  • command is "mount" not mound ... – sagarchalise Feb 17 '11 at 11:21
  • well of course, it was only a typo! Thanks for noticing! – LGB Feb 17 '11 at 12:15

Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.