Can a filesystem ever be specified by its mount point?

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












0















Is it correct that for an umounted filesystem, the only way to specify it is to specify its underlying partition?



For a mounted filesystem, can we specify it by either specifying its underlying partition or specifying its mount point? In particular, can a filesystem ever be specified by its mount point?



Thanks.










share|improve this question






















  • What Unix are you referring to? Linux only?

    – Kusalananda
    Feb 21 at 19:56











  • I have never used Unix. I am not sure if it is different in Unix.

    – Tim
    Feb 21 at 20:01











  • @Tim Gnu/Linux (e.g. Debian, Ubuntu, Centos, Suse, …) is Unix. However it is not UNIX. The title for site is miss-leading. (Also Linux is a kernel, not an OS, it can be part of a Unix OS e.g. Gnu/Linux, or a not Unix OS. Gnu is a Unix OS and has many kernels: Linux, Hurd, BSD, cygwin (A MS-Windows dll), LSW (another MS-Windows thing).

    – ctrl-alt-delor
    Feb 21 at 21:22












  • It is unclear what context you are asking. What you are saying about mount-point or partition-device is true of the umount command, but will not be true of all commands.

    – ctrl-alt-delor
    Feb 21 at 21:23











  • @ctrl Can you be specific about "What you are saying about mount-point or partition-device is true of the umount command, but will not be true of all commands"? Maybe in a reply?

    – Tim
    Feb 21 at 21:25
















0















Is it correct that for an umounted filesystem, the only way to specify it is to specify its underlying partition?



For a mounted filesystem, can we specify it by either specifying its underlying partition or specifying its mount point? In particular, can a filesystem ever be specified by its mount point?



Thanks.










share|improve this question






















  • What Unix are you referring to? Linux only?

    – Kusalananda
    Feb 21 at 19:56











  • I have never used Unix. I am not sure if it is different in Unix.

    – Tim
    Feb 21 at 20:01











  • @Tim Gnu/Linux (e.g. Debian, Ubuntu, Centos, Suse, …) is Unix. However it is not UNIX. The title for site is miss-leading. (Also Linux is a kernel, not an OS, it can be part of a Unix OS e.g. Gnu/Linux, or a not Unix OS. Gnu is a Unix OS and has many kernels: Linux, Hurd, BSD, cygwin (A MS-Windows dll), LSW (another MS-Windows thing).

    – ctrl-alt-delor
    Feb 21 at 21:22












  • It is unclear what context you are asking. What you are saying about mount-point or partition-device is true of the umount command, but will not be true of all commands.

    – ctrl-alt-delor
    Feb 21 at 21:23











  • @ctrl Can you be specific about "What you are saying about mount-point or partition-device is true of the umount command, but will not be true of all commands"? Maybe in a reply?

    – Tim
    Feb 21 at 21:25














0












0








0








Is it correct that for an umounted filesystem, the only way to specify it is to specify its underlying partition?



For a mounted filesystem, can we specify it by either specifying its underlying partition or specifying its mount point? In particular, can a filesystem ever be specified by its mount point?



Thanks.










share|improve this question














Is it correct that for an umounted filesystem, the only way to specify it is to specify its underlying partition?



For a mounted filesystem, can we specify it by either specifying its underlying partition or specifying its mount point? In particular, can a filesystem ever be specified by its mount point?



Thanks.







filesystems






share|improve this question













share|improve this question











share|improve this question




share|improve this question










asked Feb 21 at 19:34









TimTim

27.8k78269486




27.8k78269486












  • What Unix are you referring to? Linux only?

    – Kusalananda
    Feb 21 at 19:56











  • I have never used Unix. I am not sure if it is different in Unix.

    – Tim
    Feb 21 at 20:01











  • @Tim Gnu/Linux (e.g. Debian, Ubuntu, Centos, Suse, …) is Unix. However it is not UNIX. The title for site is miss-leading. (Also Linux is a kernel, not an OS, it can be part of a Unix OS e.g. Gnu/Linux, or a not Unix OS. Gnu is a Unix OS and has many kernels: Linux, Hurd, BSD, cygwin (A MS-Windows dll), LSW (another MS-Windows thing).

    – ctrl-alt-delor
    Feb 21 at 21:22












  • It is unclear what context you are asking. What you are saying about mount-point or partition-device is true of the umount command, but will not be true of all commands.

    – ctrl-alt-delor
    Feb 21 at 21:23











  • @ctrl Can you be specific about "What you are saying about mount-point or partition-device is true of the umount command, but will not be true of all commands"? Maybe in a reply?

    – Tim
    Feb 21 at 21:25


















  • What Unix are you referring to? Linux only?

    – Kusalananda
    Feb 21 at 19:56











  • I have never used Unix. I am not sure if it is different in Unix.

    – Tim
    Feb 21 at 20:01











  • @Tim Gnu/Linux (e.g. Debian, Ubuntu, Centos, Suse, …) is Unix. However it is not UNIX. The title for site is miss-leading. (Also Linux is a kernel, not an OS, it can be part of a Unix OS e.g. Gnu/Linux, or a not Unix OS. Gnu is a Unix OS and has many kernels: Linux, Hurd, BSD, cygwin (A MS-Windows dll), LSW (another MS-Windows thing).

    – ctrl-alt-delor
    Feb 21 at 21:22












  • It is unclear what context you are asking. What you are saying about mount-point or partition-device is true of the umount command, but will not be true of all commands.

    – ctrl-alt-delor
    Feb 21 at 21:23











  • @ctrl Can you be specific about "What you are saying about mount-point or partition-device is true of the umount command, but will not be true of all commands"? Maybe in a reply?

    – Tim
    Feb 21 at 21:25

















What Unix are you referring to? Linux only?

– Kusalananda
Feb 21 at 19:56





What Unix are you referring to? Linux only?

– Kusalananda
Feb 21 at 19:56













I have never used Unix. I am not sure if it is different in Unix.

– Tim
Feb 21 at 20:01





I have never used Unix. I am not sure if it is different in Unix.

– Tim
Feb 21 at 20:01













@Tim Gnu/Linux (e.g. Debian, Ubuntu, Centos, Suse, …) is Unix. However it is not UNIX. The title for site is miss-leading. (Also Linux is a kernel, not an OS, it can be part of a Unix OS e.g. Gnu/Linux, or a not Unix OS. Gnu is a Unix OS and has many kernels: Linux, Hurd, BSD, cygwin (A MS-Windows dll), LSW (another MS-Windows thing).

– ctrl-alt-delor
Feb 21 at 21:22






@Tim Gnu/Linux (e.g. Debian, Ubuntu, Centos, Suse, …) is Unix. However it is not UNIX. The title for site is miss-leading. (Also Linux is a kernel, not an OS, it can be part of a Unix OS e.g. Gnu/Linux, or a not Unix OS. Gnu is a Unix OS and has many kernels: Linux, Hurd, BSD, cygwin (A MS-Windows dll), LSW (another MS-Windows thing).

– ctrl-alt-delor
Feb 21 at 21:22














It is unclear what context you are asking. What you are saying about mount-point or partition-device is true of the umount command, but will not be true of all commands.

– ctrl-alt-delor
Feb 21 at 21:23





It is unclear what context you are asking. What you are saying about mount-point or partition-device is true of the umount command, but will not be true of all commands.

– ctrl-alt-delor
Feb 21 at 21:23













@ctrl Can you be specific about "What you are saying about mount-point or partition-device is true of the umount command, but will not be true of all commands"? Maybe in a reply?

– Tim
Feb 21 at 21:25






@ctrl Can you be specific about "What you are saying about mount-point or partition-device is true of the umount command, but will not be true of all commands"? Maybe in a reply?

– Tim
Feb 21 at 21:25











2 Answers
2






active

oldest

votes


















4














You may also specify an unmounted filesystem by its label or by its UUID. You may have entries like “LABEL=foobar” or “UUID=00000000-0000-0000-0000-000000000000” in your /etc/fstab.



As far as I know, that is handled by udev: when it discovers a partition, it reads its UUID and LABEL, and add links to the partition in /dev/disk/by-uuid and /dev/disk/by-label.



The label might contain the mount point, so you can reference the partition by its mount point.






share|improve this answer






























    1














    Let's say it in another way.



    How can you specify something? You have to uniquely describe it, at least not causing any confusing. A pathname, without context, you can't actually know what is it refering to, could be simply path ,or the device with its device number, or the device node file or the filesystem stored in the device with its device number.



    resize2fs gets a string from you and interpret it as a pathname of a device file and think you want to resize the filesystem lives on the corresponding device.



    While other tools or APIs might not use the same assumption. chmod also gets a string from you and interpret it as a pathname of a file, but just change the permission of that inode instead of touching the corresponding device or even the filesystem lives on it. chmod doesn't even care about wether it's a device node or not.






    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',
      autoActivateHeartbeat: false,
      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%2f502158%2fcan-a-filesystem-ever-be-specified-by-its-mount-point%23new-answer', 'question_page');

      );

      Post as a guest















      Required, but never shown

























      2 Answers
      2






      active

      oldest

      votes








      2 Answers
      2






      active

      oldest

      votes









      active

      oldest

      votes






      active

      oldest

      votes









      4














      You may also specify an unmounted filesystem by its label or by its UUID. You may have entries like “LABEL=foobar” or “UUID=00000000-0000-0000-0000-000000000000” in your /etc/fstab.



      As far as I know, that is handled by udev: when it discovers a partition, it reads its UUID and LABEL, and add links to the partition in /dev/disk/by-uuid and /dev/disk/by-label.



      The label might contain the mount point, so you can reference the partition by its mount point.






      share|improve this answer



























        4














        You may also specify an unmounted filesystem by its label or by its UUID. You may have entries like “LABEL=foobar” or “UUID=00000000-0000-0000-0000-000000000000” in your /etc/fstab.



        As far as I know, that is handled by udev: when it discovers a partition, it reads its UUID and LABEL, and add links to the partition in /dev/disk/by-uuid and /dev/disk/by-label.



        The label might contain the mount point, so you can reference the partition by its mount point.






        share|improve this answer

























          4












          4








          4







          You may also specify an unmounted filesystem by its label or by its UUID. You may have entries like “LABEL=foobar” or “UUID=00000000-0000-0000-0000-000000000000” in your /etc/fstab.



          As far as I know, that is handled by udev: when it discovers a partition, it reads its UUID and LABEL, and add links to the partition in /dev/disk/by-uuid and /dev/disk/by-label.



          The label might contain the mount point, so you can reference the partition by its mount point.






          share|improve this answer













          You may also specify an unmounted filesystem by its label or by its UUID. You may have entries like “LABEL=foobar” or “UUID=00000000-0000-0000-0000-000000000000” in your /etc/fstab.



          As far as I know, that is handled by udev: when it discovers a partition, it reads its UUID and LABEL, and add links to the partition in /dev/disk/by-uuid and /dev/disk/by-label.



          The label might contain the mount point, so you can reference the partition by its mount point.







          share|improve this answer












          share|improve this answer



          share|improve this answer










          answered Feb 21 at 19:42









          user2233709user2233709

          1,098412




          1,098412























              1














              Let's say it in another way.



              How can you specify something? You have to uniquely describe it, at least not causing any confusing. A pathname, without context, you can't actually know what is it refering to, could be simply path ,or the device with its device number, or the device node file or the filesystem stored in the device with its device number.



              resize2fs gets a string from you and interpret it as a pathname of a device file and think you want to resize the filesystem lives on the corresponding device.



              While other tools or APIs might not use the same assumption. chmod also gets a string from you and interpret it as a pathname of a file, but just change the permission of that inode instead of touching the corresponding device or even the filesystem lives on it. chmod doesn't even care about wether it's a device node or not.






              share|improve this answer



























                1














                Let's say it in another way.



                How can you specify something? You have to uniquely describe it, at least not causing any confusing. A pathname, without context, you can't actually know what is it refering to, could be simply path ,or the device with its device number, or the device node file or the filesystem stored in the device with its device number.



                resize2fs gets a string from you and interpret it as a pathname of a device file and think you want to resize the filesystem lives on the corresponding device.



                While other tools or APIs might not use the same assumption. chmod also gets a string from you and interpret it as a pathname of a file, but just change the permission of that inode instead of touching the corresponding device or even the filesystem lives on it. chmod doesn't even care about wether it's a device node or not.






                share|improve this answer

























                  1












                  1








                  1







                  Let's say it in another way.



                  How can you specify something? You have to uniquely describe it, at least not causing any confusing. A pathname, without context, you can't actually know what is it refering to, could be simply path ,or the device with its device number, or the device node file or the filesystem stored in the device with its device number.



                  resize2fs gets a string from you and interpret it as a pathname of a device file and think you want to resize the filesystem lives on the corresponding device.



                  While other tools or APIs might not use the same assumption. chmod also gets a string from you and interpret it as a pathname of a file, but just change the permission of that inode instead of touching the corresponding device or even the filesystem lives on it. chmod doesn't even care about wether it's a device node or not.






                  share|improve this answer













                  Let's say it in another way.



                  How can you specify something? You have to uniquely describe it, at least not causing any confusing. A pathname, without context, you can't actually know what is it refering to, could be simply path ,or the device with its device number, or the device node file or the filesystem stored in the device with its device number.



                  resize2fs gets a string from you and interpret it as a pathname of a device file and think you want to resize the filesystem lives on the corresponding device.



                  While other tools or APIs might not use the same assumption. chmod also gets a string from you and interpret it as a pathname of a file, but just change the permission of that inode instead of touching the corresponding device or even the filesystem lives on it. chmod doesn't even care about wether it's a device node or not.







                  share|improve this answer












                  share|improve this answer



                  share|improve this answer










                  answered Feb 22 at 5:42









                  炸鱼薯条德里克炸鱼薯条德里克

                  5811316




                  5811316



























                      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.




                      draft saved


                      draft discarded














                      StackExchange.ready(
                      function ()
                      StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f502158%2fcan-a-filesystem-ever-be-specified-by-its-mount-point%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?