?
Solved

Partitioning & mounting - please confirm/correct my understanding

Posted on 2003-03-28
4
Medium Priority
?
347 Views
Last Modified: 2008-02-01
Hi folks.

I'm learning about partitioning and mounting today, as I ran out of space on my root mount.
I started out with the following partitions:

cfdisk showed:
#      hda1              Boot              Primary        Linux ext2                                        2500.49
#      hda2                                Primary        Linux swap                                         254.99
#      hda3                                Primary        Linux                                             2500.49
#                                          Logical        Free Space                                        1192.68

Mounts were:
#  root@julia:~# df
#  Filesystem           1k-blocks      Used Available Use% Mounted on
#  /dev/hda1              2365268   2178684     64492  98% /


Not knowing if hda3 was contains information, I decided to play it safe and test this by creating a new partition (cfdisk & reboot) at /dev/hda5 (why wasn't it assigned 4 ?), used mkfs to format (is that a correct term? "build a Linux file system" sounds weird) and then mounted it succesfully.

After this, it is my understanding that hda3 is partitioned (during installation I guess), yet never formatted (and mounted), as I get the following error when I try to mount it:
#  root@julia:~# mount /dev/hda3 /tmp/testmount/ -t autofs
#  mount: wrong fs type, bad option, bad superblock on /dev/hda3,
#         or too many mounted file systems

(before I used mkfs on hda5, I tried to mount it and got this error, which lead me to my assumption that the formating step was missing)

Is my assumption correct that this space is currently unused and that all I need to do is format and mount it?

Thanks for your patience,

Monchanger
0
Comment
Question by:Monchanger
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
4 Comments
 
LVL 1

Accepted Solution

by:
arn0ld earned 300 total points
ID: 8228306
i prefer fdisk -l. For my hda, this dsisplays:
Disk /dev/hda: 16 heads, 63 sectors, 29762 cylinders
Units = cylinders of 1008 * 512 bytes
   Device Boot    Start       End    Blocks   Id  System
/dev/hda1   *         1      4160   2096608+   e  Win95 FAT16 (LBA)
/dev/hda2          4161      8161   2016504    6  FAT16
/dev/hda3          8162     12162   2016504   83  Linux
/dev/hda4         12163     29762   8870400    5  Extended
/dev/hda5         12163     16163   2016472+  83  Linux
/dev/hda6         16164     20164   2016472+  83  Linux
/dev/hda7         20165     24165   2016472+  83  Linux
/dev/hda8         24166     28166   2016472+  83  Linux
/dev/hda9         28167     29762    804352+  82  Linux swap

hda4 is the extended partition. For compatiblity, intel-86 type bios
allows 4 partitions: 3 primary, 1 extended. extended (typically 4, but can be 1-4) contains 5,6 .....  An Id of 83/Linux simply indicates the contents of 1 certain byte in the partition.

man mkfs
man  mke2fs
man fs
man fstab
man fsck

You are probably right about fomatting (mke2fs)
  mount - should not see hda3.
 grep hda3 /etc/fstab - should not be there.
  fsck /dev/hda3 - should fail with similar message as mount
0
 
LVL 4

Author Comment

by:Monchanger
ID: 8250429
arn0ld- I thank you for your time spent on replying, but I really need a yes or no answer here. This is a bit too risky a subject to take a "maybe" seriously.

I'm going to close this question soon with a B, unless I get something more definite.

Thanks again,

Monchanger
0
 
LVL 1

Expert Comment

by:arn0ld
ID: 8250511
yes, that is why i included 3 tests - you run any of them?
0
 
LVL 4

Author Comment

by:Monchanger
ID: 8252845
Thanks for suggesting running fsck on it, which failed of course. This gave me enough confidence to believe that the partition was indeed raw. I formatted the thing and now it's mounted perfectly.

I checked to see if there was a difference between running 'fdisk -l' before & after the format&mount. There was none. I guess linux people should know by heart how their hard drives are partitioned ;-)

Thanks again,

Monchanger

0

Featured Post

How Blockchain Is Impacting Every Industry

Blockchain expert Alex Tapscott talks to Acronis VP Frank Jablonski about this revolutionary technology and how it's making inroads into other industries and facets of everyday life.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The purpose of this article is to demonstrate how we can upgrade Python from version 2.7.6 to Python 2.7.10 on the Linux Mint operating system. I am using an Oracle Virtual Box where I have installed Linux Mint operating system version 17.2. Once yo…
Google Drive is extremely cheap offsite storage, and it's even possible to get extra storage for free for two years.  You can use the free account 15GB, and if you have an Android device..when you install Google Drive for the first time it will give…
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.
Suggested Courses
Course of the Month12 days, 21 hours left to enroll

777 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question