home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #16 / NN_1992_16.iso / spool / comp / os / linux / 6505 < prev    next >
Encoding:
Text File  |  1992-07-22  |  3.6 KB  |  89 lines

  1. Newsgroups: comp.os.linux
  2. Path: sparky!uunet!cs.utexas.edu!zaphod.mps.ohio-state.edu!menudo.uh.edu!lobster!buster!uhura1!bryan
  3. From: bryan@uhura1.uucp (Bryan Curnutt)
  4. Subject: Re: Device names (was Re: ttys2 not responding)
  5. Message-ID: <1992Jul22.142823.28893@uhura1.uucp>
  6. Reply-To: bryan%uhura1@uunet.uu.net
  7. Organization: Stoner Associates, Inc./DREM Incorporated, Houston Texas
  8. References: <711742044.F00069@remote.halcyon.com>
  9. Date: Wed, 22 Jul 1992 14:28:23 GMT
  10. Lines: 77
  11.  
  12. In article <711742044.F00069@remote.halcyon.com> Rob.Levin@f217.n3802.z1.fidonet.org (Rob Levin) writes:
  13. > TT> This is very confusing - drive _letters_ are a DOS anachronism and
  14. > TT> should have no place in Linux.
  15. >
  16. >You seem to be arguing that, because something is done a certain way in
  17. >DOS, it is anathema.  I'll be interested in hearing other, more
  18. >substantive, arguments.  ;-)
  19.  
  20. The only plus I can think of is that you can make drives conform
  21. directly to SCSI id numbers, so SCSI id 0 is /dev/hd0, SCSI id 1
  22. is /dev/hd1, etc.
  23.  
  24. >Could you be more specific on the BSD convention for hard disk naming? 
  25. >And for partitions, if such a thing exists in the vanilla BSD
  26. >environment?
  27.  
  28. I can't comment on "vanilla BSD," but I've seen this on a couple of
  29. BSD-derived systems:
  30.  
  31. Hard disks are labelled using a digit to denote the hard disk, and
  32. a letter to denote the partition.  If the device type you're using
  33. is named "hd" then the "first" disk (which may not exist, e.g. the
  34. "first" disk may be the disk with SCSI ID 0, while the only disk
  35. you have may be the "fourth" disk with SCSI ID 3) would look like
  36. this:
  37.  
  38.     /dev/hd0a  /dev/hd0b  /dev/hd0c  /dev/hd0d  /dev/hd0e  /dev/hd0f
  39.     /dev/hd0g  /dev/hd0h
  40.  
  41. (There will also be appropriate "raw" devices /dev/rhd0a, /dev/rhd0b,
  42. etc.)
  43.  
  44. Partitions are always labelled a through h.  Letters beyond h are
  45. illegal.  For historical reasons, partition "c" is *always* the
  46. entire drive (equivalent to MCC-Interim Linux's /dev/hda).  By
  47. tradition, the root partition is on partition "a", swap is on
  48. partition "b", and /usr is on partition "g".  You can never have
  49. more than seven partitions on a disk, because only "a" through "h"
  50. are available, and "c" is used to represent the entire disk.  (This
  51. is annoying -- there have been times when I've wanted to divide a
  52. hard disk into >7 partitions.)
  53.  
  54. If Linux were to switch over to this ugly and bletcherous scheme
  55. (me? no, I'm not opinionated), a typical Linux installation might
  56. translate to something like this:
  57.  
  58.     /dev/hd0a  /
  59.     /dev/hd0b  swap
  60.     /dev/hd0c  [entire hard disk, not usable for anything else]
  61.     /dev/hd0d  DOS partition???
  62.     /dev/hd0e  -not used-
  63.     /dev/hd0f  -not used-
  64.     /dev/hd0g  either /usr or -not used- if /usr is kept on /dev/hd0a
  65.     /dev/hd0h  /home
  66.  
  67. Usually, the partitions are laid out sequentially on the hard disk,
  68. so /dev/hd0a occupies blocks 0 through N, /dev/hd0b occupies blocks
  69. N through N+M, etc.  Since my DOS partition is going to be the first
  70. partition on my hard disk, my current layout of
  71.  
  72.     /dev/hda   [entire hard disk, not usable for anything else]
  73.     /dev/hda1  DOS partition
  74.     /dev/hda2  /
  75.     /dev/hda3  swap
  76.     /dev/hda4  /home
  77.  
  78. doesn't translate nicely to the traditional BSD scheme.
  79.  
  80. Frankly, I much prefer the /dev/hda way of doing things.  I wouldn't
  81. mind switching to /dev/hd0 for the entire disk and /dev/hd0a for the
  82. first partition, /dev/hd0b for the second, etc. but I'd like to see
  83. the BSD partitioning conventions left out of it.
  84. -- 
  85. Any opinions above are mine, and do not necessarily reflect the views of SAI.
  86.  
  87. Bryan Curnutt                   | "I hope that UNIX is more like my diner
  88. bryan%uhura1@uunet.uu.net       |  than like McDonald's." -- Doug McIlroy
  89.