aboutsummaryrefslogtreecommitdiff
path: root/template/install-on-archpi.html.j2
diff options
context:
space:
mode:
Diffstat (limited to 'template/install-on-archpi.html.j2')
-rw-r--r--template/install-on-archpi.html.j2163
1 files changed, 163 insertions, 0 deletions
diff --git a/template/install-on-archpi.html.j2 b/template/install-on-archpi.html.j2
new file mode 100644
index 00000000..2fdfab07
--- /dev/null
+++ b/template/install-on-archpi.html.j2
@@ -0,0 +1,163 @@
1{% extends "common/base.j2" %}
2{% block body_content %}
3<div class="container">
4
5<h2>{{ _("Tutorial: GNUnet on Archlinux/Pi") }}</h2>
6
7Welcome to this GNUnet tutorial for Archlinux on a Raspberry Pi 3. If you want
8to run a GNUnet node on a separte system, permanently online, with low energy
9consumption, this might be the thing for you. This tutorial shows you how to
10install, run, and operate it.
11
12<h3>{{ _("Requirements") }}</h3>
13
14<p>First you need the hardware. This tutorial works with a Raspberry Pi 3. The
15other Pi versions I haven't tested, but they should probably work, too. To
16install Archlinux on the Pi3, follow the instructions from <a
17href="https://archlinuxarm.org/platforms/armv8/broadcom/raspberry-pi-3">archlinuxarm.org</a>.</p>
18
19<p>That was easy, right? Our goal now is to build GNUnet from source. So, let's
20install the tools for building new software.</p>
21
22<p><code>
23> sudo pacman -S base-devel
24</code></p>
25
26<p>Now we can continue to install the following Archlinux dependencies to
27compile GNUnet on our Pi.</p>
28
29<p><code>
30$ pacman -Su libmicrohttpd libgcrypt gnurl libunistring gnutls libidn
31libextractor openssl libltdl sqlite texinfo which gettext zlib
32pkg-config git miniupnpc libextractor jansson nim
33</code></p>
34
35<h3>{{ _("Get the Source Code") }}</h3>
36
37<p>We are getting closer. Download the GNUnet source code which we will build
38in the next step:<p>
39
40<p><code>
41> git clone https://gnunet.org/git/gnunet.git<br>
42</code></p>
43
44<p>Now it's time to compile GNUnet.</p>
45
46<p><code>
47> cd gnunet<br>
48> ./bootstrap # Run this to generate the configure files.<br>
49> ./configure # Use --help to see the various flags available to you.<br>
50> make -j$(nproc || echo -n 1)<br>
51> sudo make install<br>
52</code></p>
53
54<p>Congrats! GNUnet is now installed!</p>
55
56<h3>{{ _("Run") }}</h3>
57
58<p>By default GNUnet looks in our home directory for the file
59~/.config/gnunet.conf. We can start with an empty file for now:</p>
60
61<p><code>
62> touch ~/.config/gnunet.conf
63</code></p>
64 <br />
65 <p>
66 It's reccomended that you increase your bandwidth restrictions
67 from the acutely low defaults. The example below sets the WAN
68 and LAN limits to the value "unlimited".
69 </p>
70 <br />
71 <code>
72 $ gnunet-config -s ats -o WAN_QUOTA_IN -V unlimited<br />
73 $ gnunet-config -s ats -o WAN_QUOTA_OUT -V unlimited<br />
74 $ gnunet-config -s ats -o LAN_QUOTA_IN -V unlimited<br />
75 $ gnunet-config -s ats -o LAN_QUOTA_OUT -V unlimited<br />
76 </code>
77 <br />
78<p>Now we can start it with the commandline tool gnunet-arm (Automatic Restart
79Manager).</p>
80
81<p><code>
82> gnunet-arm -s
83</code></p>
84
85<p>It starts the default GNUnet services. We can list them with the -I option:</p>
86
87<p><code>
88> gnunet-arm -I<br>
89Running services:<br>
90ats (gnunet-service-ats)<br>
91revocation (gnunet-service-revocation)<br>
92set (gnunet-service-set)<br>
93nat (gnunet-service-nat)<br>
94transport (gnunet-service-transport)<br>
95peerstore (gnunet-service-peerstore)<br>
96hostlist (gnunet-daemon-hostlist)<br>
97identity (gnunet-service-identity)<br>
98namecache (gnunet-service-namecache)<br>
99peerinfo (gnunet-service-peerinfo)<br>
100datastore (gnunet-service-datastore)<br>
101zonemaster (gnunet-service-zonemaster)<br>
102zonemaster-monitor (gnunet-service-zonemaster-monitor)<br>
103nse (gnunet-service-nse)<br>
104cadet (gnunet-service-cadet)<br>
105dht (gnunet-service-dht)<br>
106core (gnunet-service-core)<br>
107gns (gnunet-service-gns)<br>
108statistics (gnunet-service-statistics)<br>
109topology (gnunet-daemon-topology)<br>
110fs (gnunet-service-fs)<br>
111namestore (gnunet-service-namestore)<br>
112vpn (gnunet-service-vpn)<br>
113</code></p>
114
115<p>For stopping GNUnet again we can use the -e option.</p>
116
117<p><code>
118> gnunet-arm -e
119</code></p>
120
121<h3>{{ _("Make sure, it works!") }}</h3>
122
123After starting GNUnet you should make sure that your peer is connecting to the
124P2P-network. By typing gnunet-core you should see something like this:
125
126<p><code>
127> gnunet-core<br>
128Tue Oct 30 19:58:48 2018: connection established DSTJ (timeout in 293 s)<br>
129Tue Oct 30 19:58:48 2018: connection established A4MK (timeout in 292 s)<br>
130Tue Oct 30 19:58:48 2018: connection established 7WRD (timeout in 299 s)<br>
131Tue Oct 30 19:58:48 2018: connection established 5WBG (timeout in 299 s)<br>
132</code></p>
133
134<h3>{{ _("Chat the cat") }}</h3>
135
136<p>To be able to chat, we need to install and compile additional
137software.</p>
138
139<p><code>
140> git clone https://gnunet.org/git/gnunet-nim.git<br>
141> cd gnunet-nim/examples<br>
142> nim c groupchat.nim
143</code></p>
144
145<p>Fine! We can now try to enter a chat server running on another GNUnet node.
146
147<p><code>
148> LD_LIBRARY_PATH=/path/to/gnunetlibs ./groupchat --config=/path/to/gnunet.conf --server=YV6G9EP9K3X41BM3FJ3D29BDZR6358XNZ6KDZVV7DFW729YB0KCG --port=welcome --nick=YOURNICK
149</code></p>
150
151<p>You should now see something like this:</p>
152
153<p><code>
154> 2018-10-30 19:50:10 Welcome 8Q2T! participants: @[] <br>
155Hello GNUnet!<br>
1562018-10-30 19:52:53 [8Q2T] Hello GNUnet!
157</code></p>
158
159<p>Here we have typed "Hello gnunet!" to standard in which is then written out
160to standard out after having been sent back from GNUnet.</p>
161
162</div>
163{% endblock body_content %}