• 4grams
      link
      fedilink
      English
      arrow-up
      2
      ·
      edit-2
      2 hours ago

      I mean if it’s an old joke, shouldn’t it be 0.0.0.1?

      I guess it could be a fat joke if it were a subnet…

  • rizzothesmall@sh.itjust.works
    link
    fedilink
    arrow-up
    11
    ·
    edit-2
    13 hours ago

    I got similar for a friend when he got a new house. Not http, just the localhost ip.

    I agree it would be better as “there’s no place like ~/”

  • Bananskal@nord.pub
    link
    fedilink
    English
    arrow-up
    48
    ·
    20 hours ago

    The http:// part bothers me a little. I would’ve personally put just 127.0.0.1, or maybe ::1 😁

    • kalpol@lemmy.ca
      link
      fedilink
      arrow-up
      9
      ·
      20 hours ago

      Came to say the same thing. Its like saying home can only be accessed by the ladder to the 80th-story window

        • kalpol@lemmy.ca
          link
          fedilink
          arrow-up
          2
          ·
          8 hours ago

          That’s just the street door, then you gotta look through the doorbell wall and ring the right doorbell. (This is a TCP multiplexing joke)

    • JonEFive@piefed.social
      link
      fedilink
      English
      arrow-up
      7
      ·
      19 hours ago

      I always had this problem too. There’s no place like localhost? or maybe loopback? It’s like a joke created by someone who has only the the most basic understanding of what they’re trying to joke about.

      If you wanted to be a little loose with it, I could even see it being “here”, but even that doesn’t fit with “there’s no place like…”

      “There’s no place like ᱻ/” Would make more sense.

      • Taldan@lemmy.world
        link
        fedilink
        arrow-up
        1
        ·
        1 hour ago

        You’re taking it way too literally. It’s meant conceptually, not as a literal word substitute

        It’s referring to your own computer, your place. Hence the substitution with 127.1

  • anewfox@lemmy.zip
    link
    fedilink
    arrow-up
    51
    ·
    1 day ago

    specifying http kinda borks the joke a little. my home has many more services than http.

  • Obeca@pawb.social
    link
    fedilink
    arrow-up
    6
    ·
    19 hours ago

    I don’t know, 127.1.2.3 seems quite similar.

    Something it took me a while to realize is that each and every one of these addresses have a complete set of ports available for usage, so you can use port 80 on 127.0.1.0 and port 80 on 127.0.0.2 for different services.

    • anewfox@lemmy.zip
      link
      fedilink
      arrow-up
      5
      ·
      edit-2
      1 day ago

      most of the stuff thinkgeek sold can be found on alibaba for a tenth of the price, if you still want that stuff. literally the same stuff, they just resold it, and china didn’t stop making it after thinkgeek got bought and shut down.

      • db2@lemmy.world
        link
        fedilink
        arrow-up
        3
        ·
        22 hours ago

        That wasn’t the point of thinkgeek though. It was more than just the stuff.

  • supersquirrel@lemmy.ca
    link
    fedilink
    arrow-up
    14
    ·
    1 day ago

    Side note, why the hell did programmers make this as the home ip? Why couldn’t it have been something intuitive that said to normal people “home” in some way?

    I will never not be grumpy about this, it is such a trivial, random choice that only makes sense once you understand everything about it already.

    • wheezy@lemmy.ml
      link
      fedilink
      English
      arrow-up
      62
      ·
      edit-2
      1 day ago

      Most satisfying answer I could find.

      The designers of the Internet really knew how the hardware worked, and they designed with low level implementation in mind.

      The values 0, 127 and 255 are special in 8 bit assembly and machine language programming because there are “tricks” you can use to test for these values and branch to different code using smaller instructions that execute faster than for other integers. 127 is the highest signed 8 bit integer, so incrementing it by 1 will cause a signed overflow. Similarly, incrementing 255 will cause unsigned overflow. Merely loading the value 0 into a register will usually set a zero flag on the chip. Imagine the networking program looks like this in pseudocode:

      if (value == 0) doLocal();

      if (value == 127) doLoopback();

      if (value == 255) doNetwork();

      Although it depends on the chip, in those days most chips could encode these tests with 2 words, 3 words and 3 words respectively (total 8 words) and further those particular tests were all likely to execute in 1 clock cycle each. Using any other value would probably require 4 words each (total 12 words), a 50% increase in code size and likely a 50% increase in execution time as well.

      https://superuser.com/questions/31824/why-is-localhost-ip-127-0-0-1

      • Taldan@lemmy.world
        link
        fedilink
        arrow-up
        1
        ·
        edit-2
        1 hour ago

        Specifically, all loopback addresses will begin with 0111 1111

        Any time a computer reads an address beginning with those 8 digits, it can already determine it’s a loopback address without reading the other 24 digits (keep in mind, computers read IP addresses in binary)

        Why they decided to use an entire /8 CIDR block, I’ll never know. It is an absurd number of addresses to allocate out for localhost

      • Artwork@lemmy.world
        link
        fedilink
        English
        arrow-up
        26
        ·
        edit-2
        1 day ago

        Thank you… Thank you heartfelt… for not referencing/using sorrowful empty LLM for it, but referencing an actually accountable answer with an author to appreciate and learn from, with a direct link to the source.

        I upvoted the answers I found supportive, the question, read more to recall it all again, and bookmarked.

      • folekaule@lemmy.world
        link
        fedilink
        arrow-up
        10
        ·
        1 day ago

        Excellent explanation. Just came here to add more context: This was before CIDR routing when networks were classful. Localhost is in the class A network range and was reserved in 1981 for loopback use in IPv4. In 1981 processors were much, much slower than today and every cycle counted. If you look at bit patterns for the various networks and netmasks, it will all start to make more sense.

        IPv6 Always had ::1 for loopback.

    • KaninchenSpeed@lemmy.blahaj.zone
      link
      fedilink
      arrow-up
      20
      ·
      edit-2
      1 day ago

      its not only this ip. In ipv4 the whole 127.0.0.0/8 subnet is the current computer / localhost, so every 127.x.x.x points to localhost (i know its a bit silly, but so is a lot of legacy ip). 127.0.0.1 is just the first address in this subnet that can be used for devices. I would assume 127 was chosen because its the largest 7 bit number so its 01111111 in 8 bit which is easy to detect in hardware.

      In ipv6 its much more sensible, only ::1 is localhost.

      Sorry for wasting your time (but please use ipv6 anyways >:3)

      • Taldan@lemmy.world
        link
        fedilink
        arrow-up
        1
        ·
        57 minutes ago

        The fact 127.80085 is an RFC compliant loopback address will never not be funny to me

      • supersquirrel@lemmy.ca
        link
        fedilink
        arrow-up
        3
        ·
        edit-2
        1 day ago

        I super appreciate the explanation and I figured that it makes sense when you look at the context… but still did this really have to be the home ip? I can never remember the sequence of numbers, I know it is only a handful of them but it is just so damn unintuitive that I almost always have to look it up because my memory recall is trash… and I don’t think I should have to it should be so obvious that anybody can remember it.

        Even if this “had” to be the home ip grammar… couldn’t they have at least created a commonly accepted shortcut/alternate name you could type in that normal people could remember?

        • John@leminal.space
          link
          fedilink
          arrow-up
          12
          ·
          edit-2
          1 day ago

          Easy, just remember 01111111 and convert back when you need it 🙃

          For real tho just use ipv6 ::1 or localhost if you can’t remember

          • supersquirrel@lemmy.ca
            link
            fedilink
            arrow-up
            1
            ·
            1 day ago

            An easy to remember pattern of any kind would have been better, a repeating sequence like 1010101 or 1234567 or something else that doesn’t feel completely and utterly arbitrary (almost to the point of condescension to normal non-techy users in my opinion).

            • SparroHawc@piefed.world
              link
              fedilink
              English
              arrow-up
              3
              ·
              1 day ago

              127 is the highest number you can fit in 7 bits of binary. It’s a lot easier to remember if you know your powers of 2.

              One bit can hold the numbers 0 and 1.
              Two bits can hold 0 through 3.
              Three bits can hold 0 through 7. Et cetera. These numbers were far more important to remember when everyone who did programming had to do low-level programming to get any sort of performance out of their code.

                • SparroHawc@piefed.world
                  link
                  fedilink
                  English
                  arrow-up
                  1
                  ·
                  17 hours ago

                  But… but then you’re mixing signed and unsigned numbers in the same address! Panic! Human sacrifice! Dogs and cats living together! MASS HYSTERIA!!