LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   adding new disk (https://www.linuxquestions.org/questions/linux-newbie-8/adding-new-disk-620431/)

wynnsk8 02-11-2008 06:58 PM

adding new disk
 
good day guys, how do i add a new disk? the new disk is form a partition of a 2 terabyte storage(HP-EVA).what should i configure?TIA!

jailbait 02-11-2008 07:03 PM

What type of controller does the new disk attach to, IDE, SATA, SCSI, USB?

Do you use LVM?

What Linux distribution are you using?

Could you post a copy of your /etc/fstab?

-------------------
Steve Stites

wynnsk8 02-11-2008 07:30 PM

# This file is edited by fstab-sync - see 'man fstab-sync' for details
/dev/md3 / ext3 defaults 1 1
/dev/sda1 /boot/efi vfat defaults 0 0
none /dev/pts devpts gid=5,mode=620 0 0
none /dev/shm tmpfs defaults 0 0
/dev/vgsystem/lvhome /home ext3 defaults 1 2
none /proc proc defaults 0 0
none /sys sysfs defaults 0 0
/dev/vgsystem/lvtmp /tmp ext3 defaults 1 2
/dev/vgsystem/lvu01 /u01 ext3 defaults 1 2
/dev/vgsystem/lvusr /usr ext3 defaults 1 2
/dev/vgsystem/lvvar /var ext3 defaults 1 2
/dev/md0 swap swap defaults 0 0
/dev/md1 swap swap defaults 0 0
/dev/md2 swap swap defaults 0 0

# /dev/sdg1 /mnt/sdg1 ocfs2 noauto,_netdev 0 0
/dev/sdg1 /mnt/sdg1 ext3 defaults 1 2
/dev/hda /media/cdrom auto pamconsole,exec,noauto,managed 0 0

/dev/sdn1 /mnt/sdn1 ext2 defaults 1 2==>this is the new disk,instead of /mnt/sdn1 i would like to make a u02 mount point

sundialsvcs 02-11-2008 08:52 PM

As a general rule, the things to be mindful of are as-follows:
  1. When you install the drive and restart your system, Linux should see that a new hard-drive device exists. For example, a typical IDE hard-drive will show up as /dev/hda.../dev/hdd where the letter a-d corresponds to the controller and drive-number. But there will be no number following the letter at this point, because a blank drive has no partitions.
  2. Now, use a tool such as parted or fdisk must be used to partition the drive. The partition-table divides the drive into one or more physical segments and specifies which kind of file-system will be placed on each one.
  3. Next, you must create a filesystem within each partition. The kind of filesystem that you create must be the one that you "promised" in the partition-table. (Other purposes, such as swap-space, are similarly created.)
  4. Every filesystem has a mount point, which is the "apparent" place in the file-hierarchy where files on this disk-volume will appear. By convention, an empty subdirectory is created in the /mnt directory for this purpose. Then, a new entry is made in the /etc/fstab file to define this new disk and its mount-point. (Notice that, at this point, you will be using not only the device-identifier but also a number corresponding to the partition. The first ("zeroth...") partition on device /dev/hdc is /dev/hdc0.)
  5. Finally, the mount command is used to mount the new disk in its chosen location.
Obviously, your particular distro might have a nice, automatic utility to do all of these things. :)

Furthermore, if you are dealing with very large disks or with many disks, you might be using a Logical Volume Manager (LVM) which allows you to define storage pools and to distribute those pools among many disk-volumes and/or partitions. In this case, the preparation of your new disk could be substantially different. By the way... LVM's are very handy when you're dealing with multiple drives and/or high-capacity drives because they allow your programs to specify file-locations strictly in terms of the filesystem, and they allow you to specify the distribution of physical storage without worrying about inconveniencing (or interfering with) your programs! They're not hard to understand, and they're also not hard to manage. They're a very useful solution to a vexing problem, and well worth getting to know.

Personally, I find this sort of explanation helpful, even if it is a bit daunting at first. I think it helps, in the long run, to "get the big picture" of what the computer is actually doing behind the scenes. This is what any operating-system does with regard to disk-volumes... including Microsoft Windows.

wynnsk8 02-11-2008 11:13 PM

thanks man! big help!


All times are GMT -5. The time now is 10:37 PM.