LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 06-11-2012, 09:33 PM   #1
nitzix
LQ Newbie
 
Registered: Jun 2012
Location: Tennessee, United States
Distribution: Ubuntu
Posts: 9

Rep: Reputation: Disabled
How do you use the terminal to list different drives?


What is the terminal command to list drives and partitiions in the terminal?
 
Old 06-11-2012, 09:45 PM   #2
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,380

Rep: Reputation: 4190Reputation: 4190Reputation: 4190Reputation: 4190Reputation: 4190Reputation: 4190Reputation: 4190Reputation: 4190Reputation: 4190Reputation: 4190Reputation: 4190
Sounds suspiciously like homework.
What are to trying to achieve, and what have you tried ?.
 
Old 06-11-2012, 09:50 PM   #3
nitzix
LQ Newbie
 
Registered: Jun 2012
Location: Tennessee, United States
Distribution: Ubuntu
Posts: 9

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by syg00 View Post
Sounds suspiciously like homework.
What are to trying to achieve, and what have you tried ?.
Well I was trying just trying to figure a way to switch drives using the terminal. I really prefer terminal interface to GUI. I actually a command for it the other day, but now, for the life of me, I cannot remember what command it was.
 
Old 06-11-2012, 09:59 PM   #4
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,380

Rep: Reputation: 4190Reputation: 4190Reputation: 4190Reputation: 4190Reputation: 4190Reputation: 4190Reputation: 4190Reputation: 4190Reputation: 4190Reputation: 4190Reputation: 4190
"parted -l" (or "fdisk -l") maybe. For Ubuntu you'll need to use "sudo".

"df" will show what is mounted - may or may not be what you're looking for. I prefer "df -hT" (see "man df" for details).
"ls" on (almost) anything listed will show lower levels - which can may be able to "cd" into. See the relevant manpages.
 
Old 06-11-2012, 10:02 PM   #5
nitzix
LQ Newbie
 
Registered: Jun 2012
Location: Tennessee, United States
Distribution: Ubuntu
Posts: 9

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by syg00 View Post
"parted -l" (or "fdisk -l") maybe. For Ubuntu you'll need to use "sudo".

"df" will show what is mounted - may or may not be what you're looking for. I prefer "df -hT" (see "man df" for details).
"ls" on (almost) anything listed will show lower levels - which can may be able to "cd" into. See the relevant manpages.
Thank you, 'df' was the command I was looking for!
 
Old 06-11-2012, 10:11 PM   #6
frankbell
LQ Guru
 
Registered: Jan 2006
Location: Virginia, USA
Distribution: Slackware, Ubuntu MATE, Mageia, and whatever VMs I happen to be playing with
Posts: 19,889
Blog Entries: 28

Rep: Reputation: 6344Reputation: 6344Reputation: 6344Reputation: 6344Reputation: 6344Reputation: 6344Reputation: 6344Reputation: 6344Reputation: 6344Reputation: 6344Reputation: 6344
I like cat /etc/mtab to show mounted drives, especially when I'm finetuning /etc/fstab.
 
  


Reply

Tags
command, drives, terminal


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Terminal : How to list previous commands? concoran Linux - Newbie 6 07-12-2011 09:00 AM
Script to list content of Hard Drives wildcard Linux - Software 3 08-03-2010 04:08 PM
Is there a list of a system's installed hard drives? ojaiguy Linux - Hardware 20 06-16-2008 01:15 PM
How to get a list of physical drives in C++ ManuPeng Programming 11 03-20-2007 02:15 PM
Get list of loaded built-in drives? MarleyGPN Linux - Software 1 05-20-2006 09:47 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 12:47 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration