How to know which hard disk is the new one and which one is the old one

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP











up vote
0
down vote

favorite












I ordered 2 SSDs from my provider.



However, which drive is the main drive?



How do I know which drive is the new SSD drives?










share|improve this question

















  • 1




    The UUIDs differ. If you set a disklabel that's a way to distinguish them. The partition scheme might be different as well as the content. If this all does not help I would look at the SMART data, the new drive will show a short total operation time.
    – Marco
    Jan 4 '13 at 11:20










  • Why close it? From what I see, The OP just want to know which drive is mounted as root device
    – daisy
    Jan 5 '13 at 1:47










  • It looks like you are trying to find the age of your drives, is this correct?
    – ctrl-alt-delor
    Nov 23 at 20:44














up vote
0
down vote

favorite












I ordered 2 SSDs from my provider.



However, which drive is the main drive?



How do I know which drive is the new SSD drives?










share|improve this question

















  • 1




    The UUIDs differ. If you set a disklabel that's a way to distinguish them. The partition scheme might be different as well as the content. If this all does not help I would look at the SMART data, the new drive will show a short total operation time.
    – Marco
    Jan 4 '13 at 11:20










  • Why close it? From what I see, The OP just want to know which drive is mounted as root device
    – daisy
    Jan 5 '13 at 1:47










  • It looks like you are trying to find the age of your drives, is this correct?
    – ctrl-alt-delor
    Nov 23 at 20:44












up vote
0
down vote

favorite









up vote
0
down vote

favorite











I ordered 2 SSDs from my provider.



However, which drive is the main drive?



How do I know which drive is the new SSD drives?










share|improve this question













I ordered 2 SSDs from my provider.



However, which drive is the main drive?



How do I know which drive is the new SSD drives?







linux centos ssd






share|improve this question













share|improve this question











share|improve this question




share|improve this question










asked Jan 4 '13 at 11:12









user4951

3,301204976




3,301204976







  • 1




    The UUIDs differ. If you set a disklabel that's a way to distinguish them. The partition scheme might be different as well as the content. If this all does not help I would look at the SMART data, the new drive will show a short total operation time.
    – Marco
    Jan 4 '13 at 11:20










  • Why close it? From what I see, The OP just want to know which drive is mounted as root device
    – daisy
    Jan 5 '13 at 1:47










  • It looks like you are trying to find the age of your drives, is this correct?
    – ctrl-alt-delor
    Nov 23 at 20:44












  • 1




    The UUIDs differ. If you set a disklabel that's a way to distinguish them. The partition scheme might be different as well as the content. If this all does not help I would look at the SMART data, the new drive will show a short total operation time.
    – Marco
    Jan 4 '13 at 11:20










  • Why close it? From what I see, The OP just want to know which drive is mounted as root device
    – daisy
    Jan 5 '13 at 1:47










  • It looks like you are trying to find the age of your drives, is this correct?
    – ctrl-alt-delor
    Nov 23 at 20:44







1




1




The UUIDs differ. If you set a disklabel that's a way to distinguish them. The partition scheme might be different as well as the content. If this all does not help I would look at the SMART data, the new drive will show a short total operation time.
– Marco
Jan 4 '13 at 11:20




The UUIDs differ. If you set a disklabel that's a way to distinguish them. The partition scheme might be different as well as the content. If this all does not help I would look at the SMART data, the new drive will show a short total operation time.
– Marco
Jan 4 '13 at 11:20












Why close it? From what I see, The OP just want to know which drive is mounted as root device
– daisy
Jan 5 '13 at 1:47




Why close it? From what I see, The OP just want to know which drive is mounted as root device
– daisy
Jan 5 '13 at 1:47












It looks like you are trying to find the age of your drives, is this correct?
– ctrl-alt-delor
Nov 23 at 20:44




It looks like you are trying to find the age of your drives, is this correct?
– ctrl-alt-delor
Nov 23 at 20:44










3 Answers
3






active

oldest

votes

















up vote
1
down vote



accepted










You could check it by using the command



mount


It will give you all the mounted file systems. What you are interested is where the root file system is mounted (i presume thats what you mean by main drive).



This is my sample output of the mount command (just the line which contains the main disc)



/dev/sda1 on / type ext4 (rw,errors=remount-ro)


What it says is that the partition sda1 (just sda represents the disn, sda1 represents the partition) is mounted as root. So now we know that the main disc is sda. Now we have to check what disc is actually sda.



Using lshw



Chech that with



sudo lshw -class disk


My output is



*-disk 
description: ATA Disk
product: TOSHIBA
vendor: ...
physical id: ....
bus info: ...
logical name: /dev/sda
version: ...
serial: ...
size: 465GiB (500GB)


From which we can see that sda is the 500GB Toshiba disc.



Using fdisk



sudo fdisk -l sda


Output:



Disk sda: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders, total 976773168 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00024cba





share|improve this answer






















  • lshw is not a command in centos
    – user4951
    Jan 4 '13 at 11:54










  • how do you know sda is the root?
    – user4951
    Jan 4 '13 at 11:54










  • /dev/sda1 on / Its the / in that expression that represents the root file system.
    – TheMeaningfulEngineer
    Jan 4 '13 at 11:55










  • The disks are not mounted yet.
    – user4951
    Feb 21 '13 at 8:39










  • @JimThio Not sure a understand your comment. Do you have three discs, one old, and two new SSD-s? And now you want to check which of file in /dev represents which SSD without mounting them?
    – TheMeaningfulEngineer
    Feb 21 '13 at 16:23


















up vote
0
down vote













With parted which is available at CentOS afaik you won't need to mount any device



parted
print devices


or



parted
print list


will give you further details






share|improve this answer



























    up vote
    0
    down vote













    If you have ordered and received two new drives then the simple way to determine which is which is to first list the devices you have connected before you connect them. You can do this using (as root) fdisk -l or as non-root (if you can use sudo)...



    sudo fdisk -l


    Then connect one drive at a time and repeat this and you can work out which is which.



    You can look to see what the the UUID and/or the label are by...



    ls -l /dev/disk/by-*


    If labels are set then they will point to the device and appropriate entries can be made in your /etc/fstab. If labels are not set and you wish to set them then you can do so using e2label.






    share|improve this answer




















      Your Answer








      StackExchange.ready(function()
      var channelOptions =
      tags: "".split(" "),
      id: "106"
      ;
      initTagRenderer("".split(" "), "".split(" "), channelOptions);

      StackExchange.using("externalEditor", function()
      // Have to fire editor after snippets, if snippets enabled
      if (StackExchange.settings.snippets.snippetsEnabled)
      StackExchange.using("snippets", function()
      createEditor();
      );

      else
      createEditor();

      );

      function createEditor()
      StackExchange.prepareEditor(
      heartbeatType: 'answer',
      convertImagesToLinks: false,
      noModals: true,
      showLowRepImageUploadWarning: true,
      reputationToPostImages: null,
      bindNavPrevention: true,
      postfix: "",
      imageUploader:
      brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
      contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
      allowUrls: true
      ,
      onDemand: true,
      discardSelector: ".discard-answer"
      ,immediatelyShowMarkdownHelp:true
      );



      );













      draft saved

      draft discarded


















      StackExchange.ready(
      function ()
      StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f60273%2fhow-to-know-which-hard-disk-is-the-new-one-and-which-one-is-the-old-one%23new-answer', 'question_page');

      );

      Post as a guest















      Required, but never shown

























      3 Answers
      3






      active

      oldest

      votes








      3 Answers
      3






      active

      oldest

      votes









      active

      oldest

      votes






      active

      oldest

      votes








      up vote
      1
      down vote



      accepted










      You could check it by using the command



      mount


      It will give you all the mounted file systems. What you are interested is where the root file system is mounted (i presume thats what you mean by main drive).



      This is my sample output of the mount command (just the line which contains the main disc)



      /dev/sda1 on / type ext4 (rw,errors=remount-ro)


      What it says is that the partition sda1 (just sda represents the disn, sda1 represents the partition) is mounted as root. So now we know that the main disc is sda. Now we have to check what disc is actually sda.



      Using lshw



      Chech that with



      sudo lshw -class disk


      My output is



      *-disk 
      description: ATA Disk
      product: TOSHIBA
      vendor: ...
      physical id: ....
      bus info: ...
      logical name: /dev/sda
      version: ...
      serial: ...
      size: 465GiB (500GB)


      From which we can see that sda is the 500GB Toshiba disc.



      Using fdisk



      sudo fdisk -l sda


      Output:



      Disk sda: 500.1 GB, 500107862016 bytes
      255 heads, 63 sectors/track, 60801 cylinders, total 976773168 sectors
      Units = sectors of 1 * 512 = 512 bytes
      Sector size (logical/physical): 512 bytes / 512 bytes
      I/O size (minimum/optimal): 512 bytes / 512 bytes
      Disk identifier: 0x00024cba





      share|improve this answer






















      • lshw is not a command in centos
        – user4951
        Jan 4 '13 at 11:54










      • how do you know sda is the root?
        – user4951
        Jan 4 '13 at 11:54










      • /dev/sda1 on / Its the / in that expression that represents the root file system.
        – TheMeaningfulEngineer
        Jan 4 '13 at 11:55










      • The disks are not mounted yet.
        – user4951
        Feb 21 '13 at 8:39










      • @JimThio Not sure a understand your comment. Do you have three discs, one old, and two new SSD-s? And now you want to check which of file in /dev represents which SSD without mounting them?
        – TheMeaningfulEngineer
        Feb 21 '13 at 16:23















      up vote
      1
      down vote



      accepted










      You could check it by using the command



      mount


      It will give you all the mounted file systems. What you are interested is where the root file system is mounted (i presume thats what you mean by main drive).



      This is my sample output of the mount command (just the line which contains the main disc)



      /dev/sda1 on / type ext4 (rw,errors=remount-ro)


      What it says is that the partition sda1 (just sda represents the disn, sda1 represents the partition) is mounted as root. So now we know that the main disc is sda. Now we have to check what disc is actually sda.



      Using lshw



      Chech that with



      sudo lshw -class disk


      My output is



      *-disk 
      description: ATA Disk
      product: TOSHIBA
      vendor: ...
      physical id: ....
      bus info: ...
      logical name: /dev/sda
      version: ...
      serial: ...
      size: 465GiB (500GB)


      From which we can see that sda is the 500GB Toshiba disc.



      Using fdisk



      sudo fdisk -l sda


      Output:



      Disk sda: 500.1 GB, 500107862016 bytes
      255 heads, 63 sectors/track, 60801 cylinders, total 976773168 sectors
      Units = sectors of 1 * 512 = 512 bytes
      Sector size (logical/physical): 512 bytes / 512 bytes
      I/O size (minimum/optimal): 512 bytes / 512 bytes
      Disk identifier: 0x00024cba





      share|improve this answer






















      • lshw is not a command in centos
        – user4951
        Jan 4 '13 at 11:54










      • how do you know sda is the root?
        – user4951
        Jan 4 '13 at 11:54










      • /dev/sda1 on / Its the / in that expression that represents the root file system.
        – TheMeaningfulEngineer
        Jan 4 '13 at 11:55










      • The disks are not mounted yet.
        – user4951
        Feb 21 '13 at 8:39










      • @JimThio Not sure a understand your comment. Do you have three discs, one old, and two new SSD-s? And now you want to check which of file in /dev represents which SSD without mounting them?
        – TheMeaningfulEngineer
        Feb 21 '13 at 16:23













      up vote
      1
      down vote



      accepted







      up vote
      1
      down vote



      accepted






      You could check it by using the command



      mount


      It will give you all the mounted file systems. What you are interested is where the root file system is mounted (i presume thats what you mean by main drive).



      This is my sample output of the mount command (just the line which contains the main disc)



      /dev/sda1 on / type ext4 (rw,errors=remount-ro)


      What it says is that the partition sda1 (just sda represents the disn, sda1 represents the partition) is mounted as root. So now we know that the main disc is sda. Now we have to check what disc is actually sda.



      Using lshw



      Chech that with



      sudo lshw -class disk


      My output is



      *-disk 
      description: ATA Disk
      product: TOSHIBA
      vendor: ...
      physical id: ....
      bus info: ...
      logical name: /dev/sda
      version: ...
      serial: ...
      size: 465GiB (500GB)


      From which we can see that sda is the 500GB Toshiba disc.



      Using fdisk



      sudo fdisk -l sda


      Output:



      Disk sda: 500.1 GB, 500107862016 bytes
      255 heads, 63 sectors/track, 60801 cylinders, total 976773168 sectors
      Units = sectors of 1 * 512 = 512 bytes
      Sector size (logical/physical): 512 bytes / 512 bytes
      I/O size (minimum/optimal): 512 bytes / 512 bytes
      Disk identifier: 0x00024cba





      share|improve this answer














      You could check it by using the command



      mount


      It will give you all the mounted file systems. What you are interested is where the root file system is mounted (i presume thats what you mean by main drive).



      This is my sample output of the mount command (just the line which contains the main disc)



      /dev/sda1 on / type ext4 (rw,errors=remount-ro)


      What it says is that the partition sda1 (just sda represents the disn, sda1 represents the partition) is mounted as root. So now we know that the main disc is sda. Now we have to check what disc is actually sda.



      Using lshw



      Chech that with



      sudo lshw -class disk


      My output is



      *-disk 
      description: ATA Disk
      product: TOSHIBA
      vendor: ...
      physical id: ....
      bus info: ...
      logical name: /dev/sda
      version: ...
      serial: ...
      size: 465GiB (500GB)


      From which we can see that sda is the 500GB Toshiba disc.



      Using fdisk



      sudo fdisk -l sda


      Output:



      Disk sda: 500.1 GB, 500107862016 bytes
      255 heads, 63 sectors/track, 60801 cylinders, total 976773168 sectors
      Units = sectors of 1 * 512 = 512 bytes
      Sector size (logical/physical): 512 bytes / 512 bytes
      I/O size (minimum/optimal): 512 bytes / 512 bytes
      Disk identifier: 0x00024cba






      share|improve this answer














      share|improve this answer



      share|improve this answer








      edited Jan 4 '13 at 12:03

























      answered Jan 4 '13 at 11:34









      TheMeaningfulEngineer

      1,61363569




      1,61363569











      • lshw is not a command in centos
        – user4951
        Jan 4 '13 at 11:54










      • how do you know sda is the root?
        – user4951
        Jan 4 '13 at 11:54










      • /dev/sda1 on / Its the / in that expression that represents the root file system.
        – TheMeaningfulEngineer
        Jan 4 '13 at 11:55










      • The disks are not mounted yet.
        – user4951
        Feb 21 '13 at 8:39










      • @JimThio Not sure a understand your comment. Do you have three discs, one old, and two new SSD-s? And now you want to check which of file in /dev represents which SSD without mounting them?
        – TheMeaningfulEngineer
        Feb 21 '13 at 16:23

















      • lshw is not a command in centos
        – user4951
        Jan 4 '13 at 11:54










      • how do you know sda is the root?
        – user4951
        Jan 4 '13 at 11:54










      • /dev/sda1 on / Its the / in that expression that represents the root file system.
        – TheMeaningfulEngineer
        Jan 4 '13 at 11:55










      • The disks are not mounted yet.
        – user4951
        Feb 21 '13 at 8:39










      • @JimThio Not sure a understand your comment. Do you have three discs, one old, and two new SSD-s? And now you want to check which of file in /dev represents which SSD without mounting them?
        – TheMeaningfulEngineer
        Feb 21 '13 at 16:23
















      lshw is not a command in centos
      – user4951
      Jan 4 '13 at 11:54




      lshw is not a command in centos
      – user4951
      Jan 4 '13 at 11:54












      how do you know sda is the root?
      – user4951
      Jan 4 '13 at 11:54




      how do you know sda is the root?
      – user4951
      Jan 4 '13 at 11:54












      /dev/sda1 on / Its the / in that expression that represents the root file system.
      – TheMeaningfulEngineer
      Jan 4 '13 at 11:55




      /dev/sda1 on / Its the / in that expression that represents the root file system.
      – TheMeaningfulEngineer
      Jan 4 '13 at 11:55












      The disks are not mounted yet.
      – user4951
      Feb 21 '13 at 8:39




      The disks are not mounted yet.
      – user4951
      Feb 21 '13 at 8:39












      @JimThio Not sure a understand your comment. Do you have three discs, one old, and two new SSD-s? And now you want to check which of file in /dev represents which SSD without mounting them?
      – TheMeaningfulEngineer
      Feb 21 '13 at 16:23





      @JimThio Not sure a understand your comment. Do you have three discs, one old, and two new SSD-s? And now you want to check which of file in /dev represents which SSD without mounting them?
      – TheMeaningfulEngineer
      Feb 21 '13 at 16:23













      up vote
      0
      down vote













      With parted which is available at CentOS afaik you won't need to mount any device



      parted
      print devices


      or



      parted
      print list


      will give you further details






      share|improve this answer
























        up vote
        0
        down vote













        With parted which is available at CentOS afaik you won't need to mount any device



        parted
        print devices


        or



        parted
        print list


        will give you further details






        share|improve this answer






















          up vote
          0
          down vote










          up vote
          0
          down vote









          With parted which is available at CentOS afaik you won't need to mount any device



          parted
          print devices


          or



          parted
          print list


          will give you further details






          share|improve this answer












          With parted which is available at CentOS afaik you won't need to mount any device



          parted
          print devices


          or



          parted
          print list


          will give you further details







          share|improve this answer












          share|improve this answer



          share|improve this answer










          answered Mar 24 '14 at 19:55









          Jaime Agudo

          26626




          26626




















              up vote
              0
              down vote













              If you have ordered and received two new drives then the simple way to determine which is which is to first list the devices you have connected before you connect them. You can do this using (as root) fdisk -l or as non-root (if you can use sudo)...



              sudo fdisk -l


              Then connect one drive at a time and repeat this and you can work out which is which.



              You can look to see what the the UUID and/or the label are by...



              ls -l /dev/disk/by-*


              If labels are set then they will point to the device and appropriate entries can be made in your /etc/fstab. If labels are not set and you wish to set them then you can do so using e2label.






              share|improve this answer
























                up vote
                0
                down vote













                If you have ordered and received two new drives then the simple way to determine which is which is to first list the devices you have connected before you connect them. You can do this using (as root) fdisk -l or as non-root (if you can use sudo)...



                sudo fdisk -l


                Then connect one drive at a time and repeat this and you can work out which is which.



                You can look to see what the the UUID and/or the label are by...



                ls -l /dev/disk/by-*


                If labels are set then they will point to the device and appropriate entries can be made in your /etc/fstab. If labels are not set and you wish to set them then you can do so using e2label.






                share|improve this answer






















                  up vote
                  0
                  down vote










                  up vote
                  0
                  down vote









                  If you have ordered and received two new drives then the simple way to determine which is which is to first list the devices you have connected before you connect them. You can do this using (as root) fdisk -l or as non-root (if you can use sudo)...



                  sudo fdisk -l


                  Then connect one drive at a time and repeat this and you can work out which is which.



                  You can look to see what the the UUID and/or the label are by...



                  ls -l /dev/disk/by-*


                  If labels are set then they will point to the device and appropriate entries can be made in your /etc/fstab. If labels are not set and you wish to set them then you can do so using e2label.






                  share|improve this answer












                  If you have ordered and received two new drives then the simple way to determine which is which is to first list the devices you have connected before you connect them. You can do this using (as root) fdisk -l or as non-root (if you can use sudo)...



                  sudo fdisk -l


                  Then connect one drive at a time and repeat this and you can work out which is which.



                  You can look to see what the the UUID and/or the label are by...



                  ls -l /dev/disk/by-*


                  If labels are set then they will point to the device and appropriate entries can be made in your /etc/fstab. If labels are not set and you wish to set them then you can do so using e2label.







                  share|improve this answer












                  share|improve this answer



                  share|improve this answer










                  answered Nov 23 at 20:10









                  slackline

                  2011412




                  2011412



























                      draft saved

                      draft discarded
















































                      Thanks for contributing an answer to Unix & Linux Stack Exchange!


                      • Please be sure to answer the question. Provide details and share your research!

                      But avoid


                      • Asking for help, clarification, or responding to other answers.

                      • Making statements based on opinion; back them up with references or personal experience.

                      To learn more, see our tips on writing great answers.





                      Some of your past answers have not been well-received, and you're in danger of being blocked from answering.


                      Please pay close attention to the following guidance:


                      • Please be sure to answer the question. Provide details and share your research!

                      But avoid


                      • Asking for help, clarification, or responding to other answers.

                      • Making statements based on opinion; back them up with references or personal experience.

                      To learn more, see our tips on writing great answers.




                      draft saved


                      draft discarded














                      StackExchange.ready(
                      function ()
                      StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f60273%2fhow-to-know-which-hard-disk-is-the-new-one-and-which-one-is-the-old-one%23new-answer', 'question_page');

                      );

                      Post as a guest















                      Required, but never shown





















































                      Required, but never shown














                      Required, but never shown












                      Required, but never shown







                      Required, but never shown

































                      Required, but never shown














                      Required, but never shown












                      Required, but never shown







                      Required, but never shown






                      Popular posts from this blog

                      How to check contact read email or not when send email to Individual?

                      Displaying single band from multi-band raster using QGIS

                      How many registers does an x86_64 CPU actually have?