Difference between revisions of "Adding a Second Hard Drive"

From FreekiWiki
Jump to navigation Jump to search
m (reordered and updated for readability)
m (more clarification)
Line 16: Line 16:
  
 
==Granting Permissions to Normal Users==
 
==Granting Permissions to Normal Users==
*If you want to allow a normal user to create files on this drive, you can either give this user ownership of the top directory of the drive filesystem: (replace USERNAME with the username)
+
Once you can access the drive under "Places," we want to make it so everyday users of the machine can modify files on the new drive.
 +
*For a single user, you can give the user ownership of the top directory of the drive filesystem:
 +
(replace USERNAME with the username)
 
  sudo chown -R USERNAME:USERNAME /media/mynewdrive
 
  sudo chown -R USERNAME:USERNAME /media/mynewdrive
  
*or in a more flexible way, practical if you have several users, allow for instance the users in the plugdev group (usually those who are meant to be able to mount removable disks, desktop users) to create files and sub-directories on the disk:
+
*For multiple users, give the users in the plugdev group permissions on the new disk:
 +
(unless something funny happened, the plugdev group will contain those who are meant to be able to mount removable disks, aka normal users):
 
  sudo chgrp plugdev /media/mynewdrive
 
  sudo chgrp plugdev /media/mynewdrive
 
  sudo chmod g+w /media/mynewdrive
 
  sudo chmod g+w /media/mynewdrive

Revision as of 15:10, 15 April 2011

This page is about making a second hard drive visible from a working install of Ubuntu.

See the following documentation for command line/manual instructions.

Formatting an Unformatted Drive

Obviously, do this first if the drive is not formatted

1) Turn machine on, connect to Network
2) Get gparted via software center, synaptic, or sudo apt-get (command line)
3) Open it (System > Administration > GParted)
4) In upper right corner of GParted window use pull down to select second drive
5) In main window of Gparted select line that looks like this"
  • unallocated ..... unallocated XX.XX GB
  • right click on it and select, "New"
  • Create
6) select ext4 as format type (or ext3 for backwards compatibility with Hardy)
7) Hard drive will not be seen under "Places" until restart

Granting Permissions to Normal Users

Once you can access the drive under "Places," we want to make it so everyday users of the machine can modify files on the new drive.

  • For a single user, you can give the user ownership of the top directory of the drive filesystem:

(replace USERNAME with the username)

sudo chown -R USERNAME:USERNAME /media/mynewdrive
  • For multiple users, give the users in the plugdev group permissions on the new disk:

(unless something funny happened, the plugdev group will contain those who are meant to be able to mount removable disks, aka normal users):

sudo chgrp plugdev /media/mynewdrive
sudo chmod g+w /media/mynewdrive
sudo chmod +t /media/mynewdrive