Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.user > #230782

Re: Add a hard drive to existing system??

From David Christensen <dpchrist@holgerdanske.com>
Newsgroups linux.debian.user
Subject Re: Add a hard drive to existing system??
Date 2021-01-18 10:10 +0100
Message-ID <ByyHU-2KF-17@gated-at.bofh.it> (permalink)
References <Bylrk-2Y2-15@gated-at.bofh.it> <Bylrk-2Y2-13@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On 2021-01-17 10:52, Jerry Mellon wrote:
> Hello, New to Debian, but have gotten Debian 10.7 loaded on to my
> system. I have an ASUS gaming laptop(dont use it for gaming) with
> 12gb of memory and intel corei7 and a 500gb hard drive.
> 
> My question is what is the best(use dummy for linus statements
> please) way to add a second hard drive with 2T of space. I wiil use
> this to store photos and documents etc.


On 2021-01-17 14:44, Jerry Mellon wrote:
> Hi, The Asus that I have is G75V series. It has 2 hdd bays onboard.
> The 500mv is the drive that is current installed and Debian 10.7 is 
> installed. I have purchased another 2T Segate drive that will go
> into the empty bay.
> 
> I don't want to do anything fancy, just install and update fstat.
> The question is what do I do in fstat to set it up. Currently the
> fstab file reads as follows.
> 
> 
> 
> Disk /dev/sda: 465.8 GiB, 500107862016 bytes, 976773168 sectors Disk
> model: ST9500325AS Units: sectors of 1 * 512 = 512 bytes Sector size
> (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal):
> 512 bytes / 512 bytes Disklabel type: dos Disk identifier:
> 0x0d0d6868
> 
> Device     Boot     Start       End   Sectors   Size Id Type 
> /dev/sda1  *         2048 951703551 951701504 453.8G 83 Linux 
> /dev/sda2       951705598 976771071  25065474    12G  5 Extended 
> /dev/sda5       951705600 976771071  25065472    12G 82 Linux swap / 
> Solaris
> 
> 
> Do I set the new drive as /dev/sda6 , 7 , 8 ???? and would it be a 
> single partition?


I am curious why your fstab(5) uses "/dev/sd..." values for the fs_spec 
field, rather than "LABEL=..." or "UUID=..." values.  Did a the Debian 
10.7 installer create these entries?


As other readers have pointed out, "/dev/sd*" device nodes are assigned 
by the Linux kernel during the boot process and can change whenever 
drives are added or removed.  Adding another drive (including an 
external drive) could cause the system drive device nodes to change, 
which could break boot.


It might be possible to rework the fstab(5) entries to use "LABEL=...", 
"UUID=...", and/or "/dev/disk/by-id/..." values, and then run 
update-initramfs(8) and update-grub(8).  If the first attempt fails, it 
may be necessary to boot the d-i into a rescue shell, mount the root 
filesystem read-write, edit /etc/fstab, invoke chroot(8), run the 
updates, and try again.


Once you install the second drive and boot successfully, you will need 
to apply a partitioning scheme, create a partition, format the 
partition, create a mount point, and create an fstab(5) entry.  There 
are a variety of tools for first two steps; I use parted(8) 'mklabel' 
and 'mkpart'.  There are a variety of filesystems available; I suggest 
ext4 and using mkfs.ext4(8).


David

Back to linux.debian.user | Previous | Next — Previous in thread | Find similar | Unroll thread


Thread

Add a hard drive to existing system?? Jerry Mellon <jfmellon@netscape.net> - 2021-01-17 20:00 +0100
  Re: Add a hard drive to existing system?? Alain D D Williams <addw@phcomp.co.uk> - 2021-01-17 20:00 +0100
    Re: Add a hard drive to existing system?? Joe <joe@jretrading.com> - 2021-01-17 20:20 +0100
  Re: Add a hard drive to existing system?? Charles Curley <charlescurley@charlescurley.com> - 2021-01-17 21:20 +0100
  Re: Add a hard drive to existing system?? "Alexander V. Makartsev" <avbetev@gmail.com> - 2021-01-17 21:20 +0100
  Re: Add a hard drive to existing system?? Jerry Mellon <jfmellon@netscape.net> - 2021-01-17 23:50 +0100
    Re: Add a hard drive to existing system?? Dan Ritter <dsr@randomstring.org> - 2021-01-18 00:00 +0100
      Re: Add a hard drive to existing system?? Stefan Monnier <monnier@iro.umontreal.ca> - 2021-01-18 00:20 +0100
        Re: Add a hard drive to existing system?? Dan Ritter <dsr@randomstring.org> - 2021-01-18 00:40 +0100
        Re: Add a hard drive to existing system?? Keith Bainbridge <ke1thozgroups@gmx.com> - 2021-01-18 08:50 +0100
    Re: Add a hard drive to existing system?? Andrei POPESCU <andreimpopescu@gmail.com> - 2021-01-18 09:00 +0100
    Re: Add a hard drive to existing system?? Keith Bainbridge <ke1thozgroups@gmx.com> - 2021-01-18 10:10 +0100
      Re: Add a hard drive to existing system?? David Christensen <dpchrist@holgerdanske.com> - 2021-01-18 10:30 +0100
        Re: Add a hard drive to existing system?? David Christensen <dpchrist@holgerdanske.com> - 2021-01-18 21:20 +0100
          Re: Add a hard drive to existing system?? Keith Bainbridge <ke1thozgroups@gmx.com> - 2021-01-19 07:40 +0100
  Re: Add a hard drive to existing system?? David Christensen <dpchrist@holgerdanske.com> - 2021-01-18 10:10 +0100

csiph-web