LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
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 11-24-2009, 01:08 PM   #1
Adam Sylvester
LQ Newbie
 
Registered: Nov 2009
Posts: 3

Rep: Reputation: 0
Determining file system type of disk


I am trying to determine the file system type of a (possibly unmounted) disk drive on SUSE 11. Through some Google searches, I found that I can get what I want with something like this:

/sbin/udevadm info -p -n --query=env --path=/sys/block/sdc/sdc1
and looking at the ID_FS_TYPE line.

I can run this command and grep and awk out the result, but I was wondering if this value was available via one of the "files" in /sys/block/sdc/sdc1. I couldn't find it anywhere in there... where is udevadm getting this information?

Thanks.
adam
 
Old 11-25-2009, 12:55 AM   #2
ywzhaifei
LQ Newbie
 
Registered: Nov 2009
Distribution: archlinux
Posts: 6

Rep: Reputation: 0
another way
Code:
sudo blkid
will print out all partitions(include unmounted) infos. include the type.
 
  


Reply


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
Determining file system type? Sigkill(9) Linux - General 7 09-22-2006 02:11 AM
Determining filesystem type in use chriscore Linux - Newbie 6 03-22-2005 08:19 PM
Determining MIME Type of a File Jose Muņiz Linux - General 2 08-16-2004 01:44 AM
determining fs type FirebirdV0273 Linux - General 3 10-09-2003 06:25 PM
determining file system 24jedi Linux - General 2 07-31-2003 10:26 AM

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

All times are GMT -5. The time now is 11:21 PM.

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