status-update-july-2022.html 9.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104
  1. <!DOCTYPE html><head><meta charset="utf-8" /><meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no" /><meta name="keywords" content="GNU, Emacs, Libre Software, Hurd, Guile, Guix" /><meta name="description" content="GNUcode.me is a website focusing on libre software projects, especially the GNU project." /><link type="application/atom+xml" rel="alternate" title="GNUcode.me -- Feed" href="/feed.xml" /><a rel="me" href="https://fosstodon.org/@thegnuguy"></a><link type="text/css" href="css/footer.min.css" rel="stylesheet"></link><link type="text/css" href="css/header.min.css" rel="stylesheet"></link><link type="text/css" href="css/main.min.css" rel="stylesheet"></link><title>Status Update July 2022 — GNUcode.me</title></head><body><header><nav><ul><li><a href="index.html">GNUcode.me</a></li><li><a href="services.html">Services</a></li><li><a href="about.html">About</a></li><li><a href="business-ideas.html">Business-ideas</a></li></ul></nav></header><h1>Status Update July 2022</h1><main><section class="basic-section-padding"><article><h3>by Joshua Branson — August 02, 2022</h3><div><p>So I recently bought a guix system server! It cost me about $250. It’s got 16GB
  2. of RAM (I can upgrade to 32GB) with a 4TB harddrive. I may play with RAID at
  3. some point, but that’s a little down the line. If you want some help getting
  4. something like this for yourself, please contact me. This blog post is my first
  5. attempt at trying to figure out how to connect to <code>copertino</code>, to the
  6. internet. Now on with the blog post!</p><p>So when you are like me, and you start to wonder how the internets work, a good
  7. thing to learn first is difference between <strong>WAN</strong> and <strong>LAN</strong>. LAN is your local area
  8. network. When you are at home, on your computer, you are on your LAN. If your
  9. computer talks to another computer in your house, then those machines are using
  10. the LAN. When your computer talks to <code>www.gnu.org</code>, your computer is accessing
  11. the WAN, which is the wide area network, usually called the internet.</p><p>Computers talk to each other via IP addresses. An IP address is a numerical ID
  12. that is unique to each computer. Computers use IP address as essentially phone
  13. numbers to reach out and say, “Hey what time are we having this binary number
  14. crunching date?” What’s interesting, is computers have more than just a phone
  15. number, they have a phone number, plus several extensions.</p><p>When you call a business, and they say, “Thanks for calling Bank of Scotland.
  16. Please press 5 to talk to a manager, 4 to talk to a sales person, and 3 to open
  17. an account. Thanks!” 5, 4, and 3 are extensions. Computers have the same
  18. thing, on steroids. They calls extensions ports, and there are like 50,000+
  19. ports. Ports are usually set up to be used by specific applications. For
  20. example, your web browser uses port 80 and 443 to visit websites.</p><p>Here’s a crazy example.</p><pre><code>ping -c 1 gnu.org</code></pre><p>PING gnu.org (209.51.188.116): 56 data bytes
  21. 64 bytes from 209.51.188.116: icmp&lt;sub&gt;seq&lt;/sub&gt;=0 ttl=55 time=39.078 ms
  22. — gnu.org ping statistics —
  23. 1 packets transmitted, 1 packets received, 0% packet loss
  24. round-trip min/avg/max/stddev = 39.078/39.078/39.078/0.000 ms</p><p>So, we now know that gnu.org is serving it’s website on 209.51.188.116. Try
  25. posting this in a web browser url: 209.51.188.116. You’ll end up at
  26. savannah.nongnu.org, which is a website that the fabulous people at GNU run.</p><p>Anyway, let’s take a look at your IP address:</p><pre><code>ip address show</code></pre><p>1: lo: &lt;LOOPBACK,MULTICAST,UP,LOWER&lt;sub&gt;UP&lt;/sub&gt;&gt; mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
  27. link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
  28. inet 127.0.0.1/8 scope global lo
  29. valid&lt;sub&gt;lft&lt;/sub&gt; forever preferred&lt;sub&gt;lft&lt;/sub&gt; forever
  30. 2: enp0s25: &lt;BROADCAST,MULTICAST,UP,LOWER&lt;sub&gt;UP&lt;/sub&gt;&gt; mtu 1500 qdisc pfifo&lt;sub&gt;fast&lt;/sub&gt; state UP group default qlen 1000
  31. link/ether 00:1c:25:9a:37:ba brd ff:ff:ff:ff:ff:ff
  32. inet 192.168.1.122/24 brd 192.168.1.255 scope global dynamic noprefixroute enp0s25
  33. valid&lt;sub&gt;lft&lt;/sub&gt; 22986sec preferred&lt;sub&gt;lft&lt;/sub&gt; 22986sec
  34. inet6 fe80::36a7:f91e:a1e0:16fe/64 scope link noprefixroute
  35. valid&lt;sub&gt;lft&lt;/sub&gt; forever preferred&lt;sub&gt;lft&lt;/sub&gt; forever
  36. 3: wlp2s0: &lt;NO-CARRIER,BROADCAST,MULTICAST,UP&gt; mtu 1500 qdisc noqueue state DOWN group default qlen 1000
  37. link/ether b6:cf:27:17:7c:fc brd ff:ff:ff:ff:ff:ff permaddr e4:ce:8f:59:d6:bf</p><p>Let’s take the above output line by line:</p><pre><code>1: lo: &lt;LOOPBACK,MULTICAST,UP,LOWER_UP&gt; mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
  38. link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
  39. inet *127.0.0.1/8* scope global lo
  40. valid_lft forever preferred_lft forever
  41. lo is your loopback device, which is fancy talk for &quot;ME&quot;. The embolded
  42. *127.0.0.1* is a universal alias for &quot;ME&quot;. If you have a web site running on
  43. your computer, typing in 127.0.0.1:80 lets you access that website. 127.0.0.1:80
  44. means, talk to the computer at address 127.0.0.1 (which is me), and request the
  45. content on port 80.
  46. 2: *enp0s25*: &lt;BROADCAST,MULTICAST,UP,LOWER_UP&gt; mtu 1500 qdisc pfifo_fast state UP group default qlen 1000
  47. link/ether 00:1c:25:9a:37:ba brd ff:ff:ff:ff:ff:ff
  48. *inet* *192.168.1.122/24* brd 192.168.1.255 scope global dynamic noprefixroute enp0s25
  49. valid_lft 22986sec preferred_lft 22986sec
  50. *inet6* *fe80::36a7:f91e:a1e0:16fe/64* scope link noprefixroute
  51. valid_lft forever preferred_lft forever
  52. *enp0s25* is your ethernet device. Anything that begins with an 'e' is usually
  53. an ethernet device. Ethernet is usually the blue cable that you
  54. plug into your laptop or server. Laptops increasingly do not have ethernet,
  55. which is sad 'cause ethernet is faster than wifi.
  56. *init* means IPv4. Remember when I said that computers have IP address? Well
  57. than have one that looks like *192.168.1.122*. That is the IPv4 address. People
  58. now adays have phones, tablets, gaming consoles, smart watches, etc. and each
  59. need an IP address. As a result, the IPv4 address space is getting a little
  60. crowded. So some smart people introduced IPv6, which has much more unique IDs.
  61. (Keep reading to see an example IPv6 address).
  62. Unfortunately for me, an IP address of 192.168.number.number is a LAN IP. That
  63. means I have to be in my house to talk to view my personal website. I cannot
  64. view that website at work. :(
  65. *init6* is IPv6. And *fe80::36a7:f91e:a1e0:16fe* is this computer's IPv6
  66. address. fe80 is also a LAN IPv6 address. The outside world cannot use that
  67. address to talk to this local computer.
  68. 3: *wlp2s0*: &lt;NO-CARRIER,BROADCAST,MULTICAST,UP&gt; mtu 1500 qdisc noqueue state DOWN group default qlen 1000
  69. link/ether b6:cf:27:17:7c:fc brd ff:ff:ff:ff:ff:ff permaddr e4:ce:8f:59:d6:bf
  70. This is my wifi device. Anything that begins with an 'w' is usually a wifi device.
  71. ip route</code></pre><p>default via 192.168.1.1 dev enp0s25 proto dhcp metric 100
  72. 192.168.1.0/24 dev enp0s25 proto kernel scope link src 192.168.1.122 metric 100</p><p>The number after <strong>default</strong> is the default gateway. That is my router’s LAN IP
  73. address. If I type that into a web browser, when I am at home, then I can log
  74. into my router. Usually your router’s username and password is on a stick on the
  75. back of your router.</p><p>Also, it should be possible for me to log into the router and tell it to open up
  76. ports 80 and 443 (http and https), so that anyone connecting to say
  77. <code>www.copertino.me</code> would be connecting to my computer only, AND NOT my
  78. roommates’ laptop. However, an attacker could still potentially break into my
  79. guix system computer, and attack my roommate’s computer.</p><p>Also, if you decide to play around with customizing your router, I would
  80. recommend OpenBSD. OpenBSD potentially has some binary blobs for wifi, which is
  81. why the <a href="https://www.gnu.org/distros/free-distros.en.html">FSF</a> will not endorse it as a free distro. but if you don’t use wifi,
  82. then there is no software freedom issues. Anyway, I have recently developed
  83. quite the crush on OpenBSD, and I found this <a href="https://openbsdrouterguide.net/">guide</a>, that helps you use OpenBSD
  84. for your router. It’s actually quite comprehensive:</p><blockquote><p>In this guide we’re going to take a look at how we can use cheap and “low end”
  85. hardware to build an amazing OpenBSD router with firewalling capabilities,
  86. segmented local area networks, DNS with domain blocking, DHCP and more.</p><p>We will use a setup in which the router segments the local area network (LAN)
  87. into three separate networks, one for the grown-ups in the house, one for the
  88. children, and one for public facing servers (a DMZ), such as a private web
  89. server or mail server. We will also look at how we can use DNS to block out ads,
  90. porn, and other websites on the Internet. The OpenBSD router can also be used on
  91. small to mid-size offices.</p></blockquote></div></article></section></main><footer><p>© 2020 Joshua Branson. The text on this site is free culture under the Creative Commons Attribution Share-Alike 4.0 International license.</p><p>This website is build with Haunt, a static site generator written in Guile Scheme. Source code is <a href="https://notabug.org/jbranso/gnucode.me">available.</a></p><p>The color theme of this website is based off of the famous <a href="#3f3f3f" target="_blank">zenburn</a> theme.</p></footer></body>