1 | <?xml version="1.0" encoding="UTF-8"?>
|
---|
2 | <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
|
---|
3 | "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
|
---|
4 | <!ENTITY % general-entities SYSTEM "../../general.ent">
|
---|
5 | %general-entities;
|
---|
6 |
|
---|
7 | <!ENTITY fuse3-download-http "https://github.com/libfuse/libfuse/releases/download/fuse-&fuse3-version;/fuse-&fuse3-version;.tar.gz">
|
---|
8 | <!ENTITY fuse3-download-ftp " ">
|
---|
9 | <!ENTITY fuse3-md5sum "b00bf08b27ead4a9411578777e94a1cc">
|
---|
10 | <!ENTITY fuse3-size "14 MB">
|
---|
11 | <!ENTITY fuse3-buildsize "222 MB (with tests and documentation)">
|
---|
12 | <!ENTITY fuse3-time "0.2 SBU (add 0.3 SBU for tests)">
|
---|
13 | ]>
|
---|
14 |
|
---|
15 | <sect1 id="fuse3" xreflabel="Fuse-&fuse3-version;">
|
---|
16 | <?dbhtml filename="fuse.html"?>
|
---|
17 |
|
---|
18 |
|
---|
19 | <title>Fuse-&fuse3-version;</title>
|
---|
20 |
|
---|
21 | <indexterm zone="fuse3">
|
---|
22 | <primary sortas="a-fuse-3">Fuse 3</primary>
|
---|
23 | </indexterm>
|
---|
24 |
|
---|
25 | <sect2 role="package">
|
---|
26 | <title>Introduction to Fuse</title>
|
---|
27 |
|
---|
28 | <para>
|
---|
29 | <application>FUSE</application> (Filesystem in Userspace) is a simple
|
---|
30 | interface for userspace programs to export a virtual filesystem to the
|
---|
31 | Linux kernel. <application>Fuse</application> also aims to provide a
|
---|
32 | secure method for non privileged users to create and mount their own
|
---|
33 | filesystem implementations.
|
---|
34 | </para>
|
---|
35 |
|
---|
36 | &lfs122_checked;
|
---|
37 |
|
---|
38 | <bridgehead renderas="sect3">Package Information</bridgehead>
|
---|
39 | <itemizedlist spacing="compact">
|
---|
40 | <listitem>
|
---|
41 | <para>
|
---|
42 | Download (HTTP): <ulink url="&fuse3-download-http;"/>
|
---|
43 | </para>
|
---|
44 | </listitem>
|
---|
45 | <listitem>
|
---|
46 | <para>
|
---|
47 | Download (FTP): <ulink url="&fuse3-download-ftp;"/>
|
---|
48 | </para>
|
---|
49 | </listitem>
|
---|
50 | <listitem>
|
---|
51 | <para>
|
---|
52 | Download MD5 sum: &fuse3-md5sum;
|
---|
53 | </para>
|
---|
54 | </listitem>
|
---|
55 | <listitem>
|
---|
56 | <para>
|
---|
57 | Download size: &fuse3-size;
|
---|
58 | </para>
|
---|
59 | </listitem>
|
---|
60 | <listitem>
|
---|
61 | <para>
|
---|
62 | Estimated disk space required: &fuse3-buildsize;
|
---|
63 | </para>
|
---|
64 | </listitem>
|
---|
65 | <listitem>
|
---|
66 | <para>
|
---|
67 | Estimated build time: &fuse3-time;
|
---|
68 | </para>
|
---|
69 | </listitem>
|
---|
70 | </itemizedlist>
|
---|
71 |
|
---|
72 | <bridgehead renderas="sect3">Fuse Dependencies</bridgehead>
|
---|
73 | <bridgehead renderas="sect4">Optional</bridgehead>
|
---|
74 | <para role="optional">
|
---|
75 | <xref linkend="doxygen"/> (to rebuild the API documentation),
|
---|
76 | <xref linkend="pytest"/> (required for tests), and
|
---|
77 | <ulink url="https://pypi.org/project/looseversion/">looseversion</ulink>
|
---|
78 | (for tests)
|
---|
79 | </para>
|
---|
80 |
|
---|
81 | </sect2>
|
---|
82 |
|
---|
83 | <sect2 role="kernel" id="fuse-kernel">
|
---|
84 | <title>Kernel Configuration</title>
|
---|
85 |
|
---|
86 | <para>
|
---|
87 | Enable the following options in the kernel configuration and recompile the
|
---|
88 | kernel if necessary:
|
---|
89 | </para>
|
---|
90 |
|
---|
91 | <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
|
---|
92 | href="fuse-kernel.xml"/>
|
---|
93 |
|
---|
94 | <para>
|
---|
95 | Character devices in userspace should be enabled too for running the
|
---|
96 | tests:
|
---|
97 | </para>
|
---|
98 |
|
---|
99 | <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
|
---|
100 | href="fuse-test-kernel.xml"/>
|
---|
101 |
|
---|
102 | <indexterm zone="fuse3 fuse-kernel">
|
---|
103 | <primary sortas="d-fuse3">Fuse 3</primary>
|
---|
104 | </indexterm>
|
---|
105 | </sect2>
|
---|
106 |
|
---|
107 | <sect2 role="installation">
|
---|
108 | <title>Installation of Fuse</title>
|
---|
109 |
|
---|
110 | <para>
|
---|
111 | Install <application>Fuse</application> by running the following
|
---|
112 | commands:
|
---|
113 | </para>
|
---|
114 |
|
---|
115 | <screen><userinput>sed -i '/^udev/,$ s/^/#/' util/meson.build &&
|
---|
116 |
|
---|
117 | mkdir build &&
|
---|
118 | cd build &&
|
---|
119 |
|
---|
120 | meson setup --prefix=/usr --buildtype=release .. &&
|
---|
121 | ninja</userinput></screen>
|
---|
122 |
|
---|
123 | <para>
|
---|
124 | The API documentation is included in the package, but
|
---|
125 | if you have <xref linkend="doxygen"/> installed and wish to rebuild
|
---|
126 | it, issue:
|
---|
127 | </para>
|
---|
128 |
|
---|
129 | <screen remap="doc"><userinput>pushd .. &&
|
---|
130 | doxygen doc/Doxyfile &&
|
---|
131 | popd</userinput></screen>
|
---|
132 |
|
---|
133 | <para>
|
---|
134 | To test the results, issue the following commands (as the <systemitem
|
---|
135 | role="username">root</systemitem> user):
|
---|
136 | </para>
|
---|
137 |
|
---|
138 | <!-- EDITORS NOTE:
|
---|
139 |
|
---|
140 | Don't use 'pytest' instead of 'python3 -m pytest'. There is no
|
---|
141 | testenv/bin/pytest (as at pytest-7.4.0) so 'pytest' resolves to
|
---|
142 | /usr/bin/pytest, and the shebang of it is /usr/bin/python3.11.
|
---|
143 | So it won't find the looseversion installed in testenv.
|
---|
144 |
|
---|
145 | To view the results of the tests, look for
|
---|
146 | "short test summary info" at the end of your log. Below skipped tests,
|
---|
147 | you will see "X passed, X skipped, X failed (if any) in X seconds" -->
|
---|
148 |
|
---|
149 | <screen role="root" remap="test"><userinput>python3 -m venv --system-site-packages testenv &&
|
---|
150 | source testenv/bin/activate &&
|
---|
151 | pip3 install looseversion &&
|
---|
152 | python3 -m pytest
|
---|
153 | deactivate</userinput></screen>
|
---|
154 |
|
---|
155 | <para>
|
---|
156 | The <xref linkend="pytest"/> Python
|
---|
157 | module is required for the tests. One test named
|
---|
158 | <filename>test_cuse</filename> will fail if the
|
---|
159 | <parameter>CONFIG_CUSE</parameter> configuration item was not enabled
|
---|
160 | when the kernel was built. One test,
|
---|
161 | <filename>test/util.py</filename>, will output a warning due to the usage
|
---|
162 | of an unknown mark in pytest.
|
---|
163 | </para>
|
---|
164 |
|
---|
165 | <para>
|
---|
166 | Now, as the <systemitem class="username">root</systemitem> user:
|
---|
167 | </para>
|
---|
168 |
|
---|
169 | <screen role="root"><userinput>ninja install &&
|
---|
170 | chmod u+s /usr/bin/fusermount3 &&
|
---|
171 |
|
---|
172 | cd .. &&
|
---|
173 | cp -Rv doc/html -T /usr/share/doc/fuse-&fuse3-version; &&
|
---|
174 | install -v -m644 doc/{README.NFS,kernel.txt} \
|
---|
175 | /usr/share/doc/fuse-&fuse3-version;</userinput></screen>
|
---|
176 |
|
---|
177 | </sect2>
|
---|
178 |
|
---|
179 | <sect2 role="commands">
|
---|
180 | <title>Command Explanations</title>
|
---|
181 |
|
---|
182 | <para>
|
---|
183 | <command>sed ... util/meson.build</command>: This command disables the
|
---|
184 | installation of a boot script and udev rule that are not needed.
|
---|
185 | </para>
|
---|
186 |
|
---|
187 | <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
|
---|
188 | href="../../xincludes/meson-buildtype-release.xml"/>
|
---|
189 |
|
---|
190 | </sect2>
|
---|
191 |
|
---|
192 | <sect2 role="configuration" id="fuse-configuration">
|
---|
193 | <title>Configuring fuse</title>
|
---|
194 |
|
---|
195 | <sect3 id="fuse-config">
|
---|
196 | <title>Config Files</title>
|
---|
197 |
|
---|
198 | <para>
|
---|
199 | Some options regarding mount policy can be set in the file
|
---|
200 | <filename>/etc/fuse.conf</filename>. To install the file run the
|
---|
201 | following command as the <systemitem class="username">root</systemitem>
|
---|
202 | user:
|
---|
203 | </para>
|
---|
204 |
|
---|
205 | <screen role="root"><userinput>cat > /etc/fuse.conf << "EOF"
|
---|
206 | <literal># Set the maximum number of FUSE mounts allowed to non-root users.
|
---|
207 | # The default is 1000.
|
---|
208 | #
|
---|
209 | #mount_max = 1000
|
---|
210 |
|
---|
211 | # Allow non-root users to specify the 'allow_other' or 'allow_root'
|
---|
212 | # mount options.
|
---|
213 | #
|
---|
214 | #user_allow_other</literal>
|
---|
215 | EOF</userinput></screen>
|
---|
216 |
|
---|
217 | <para>
|
---|
218 | Additional information about the meaning of the configuration
|
---|
219 | options are found in the man page.
|
---|
220 | </para>
|
---|
221 |
|
---|
222 | </sect3>
|
---|
223 |
|
---|
224 | </sect2>
|
---|
225 |
|
---|
226 | <sect2 role="content">
|
---|
227 | <title>Contents</title>
|
---|
228 |
|
---|
229 | <segmentedlist>
|
---|
230 | <segtitle>Installed Programs</segtitle>
|
---|
231 | <segtitle>Installed Libraries</segtitle>
|
---|
232 | <segtitle>Installed Directory</segtitle>
|
---|
233 |
|
---|
234 | <seglistitem>
|
---|
235 | <seg>
|
---|
236 | fusermount3 and mount.fuse3
|
---|
237 | </seg>
|
---|
238 | <seg>
|
---|
239 | libfuse3.so
|
---|
240 | </seg>
|
---|
241 | <seg>
|
---|
242 | /usr/include/fuse3 and /usr/share/doc/fuse-&fuse3-version;
|
---|
243 | </seg>
|
---|
244 | </seglistitem>
|
---|
245 | </segmentedlist>
|
---|
246 |
|
---|
247 | <variablelist>
|
---|
248 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
249 | <?dbfo list-presentation="list"?>
|
---|
250 | <?dbhtml list-presentation="table"?>
|
---|
251 |
|
---|
252 | <varlistentry id="fusermount3">
|
---|
253 | <term><command>fusermount3</command></term>
|
---|
254 | <listitem>
|
---|
255 | <para>
|
---|
256 | is a suid root program to mount and unmount Fuse filesystems
|
---|
257 | </para>
|
---|
258 | <indexterm zone="fuse3 fusermount3">
|
---|
259 | <primary sortas="b-fusermount3">fusermount3</primary>
|
---|
260 | </indexterm>
|
---|
261 | </listitem>
|
---|
262 | </varlistentry>
|
---|
263 |
|
---|
264 | <varlistentry id="mount.fuse3">
|
---|
265 | <term><command>mount.fuse3</command></term>
|
---|
266 | <listitem>
|
---|
267 | <para>
|
---|
268 | is the command <command>mount</command> calls to mount a Fuse
|
---|
269 | filesystem
|
---|
270 | </para>
|
---|
271 | <indexterm zone="fuse3 mount.fuse3">
|
---|
272 | <primary sortas="b-mount.fuse3">mount.fuse3</primary>
|
---|
273 | </indexterm>
|
---|
274 | </listitem>
|
---|
275 | </varlistentry>
|
---|
276 |
|
---|
277 | <varlistentry id="libfuse3">
|
---|
278 | <term><filename class="libraryfile">libfuse3.so</filename></term>
|
---|
279 | <listitem>
|
---|
280 | <para>
|
---|
281 | contains the <application>FUSE</application> API functions
|
---|
282 | </para>
|
---|
283 | <indexterm zone="fuse3 libfuse3">
|
---|
284 | <primary sortas="c-libfuse3">libfuse3.so</primary>
|
---|
285 | </indexterm>
|
---|
286 | </listitem>
|
---|
287 | </varlistentry>
|
---|
288 |
|
---|
289 | </variablelist>
|
---|
290 |
|
---|
291 | </sect2>
|
---|
292 |
|
---|
293 | </sect1>
|
---|