Lines Matching +full:debian +full:- +full:testing
1 .. SPDX-License-Identifier: GPL-2.0
25 Most OSes today have built-in support for a number of "fake"
27 User Mode Linux takes this concept to the ultimate extreme - there
30 concepts which map onto something provided by the host - files, sockets,
36 The UML kernel is just a process running on Linux - same as any other
57 * You can run a usermode kernel as a non-root user (you may need to
99 This is extremely easy on Debian - you can do it using debootstrap. It is
100 also easy on OpenWRT - the build process can build UML images. All other
101 distros - YMMV.
114 or by running ``tune2fs -o discard /dev/ubdXX`` will request UML to
126 # debootstrap buster /mnt http://deb.debian.org/debian
131 Set the root password - the easiest way to do that is to chroot into the
144 /dev/ubd0 ext4 discard,errors=remount-ro 0 1
150 UML supports two classes of network devices - the older uml_net ones
171 kernel, testing the image with a stock one is always a good start. These
173 filesystem. The location is distribution dependent. For Debian these
177 # cp -rax /usr/lib/uml/modules /mnt/lib/modules
196 connection may be either point-to-point (similar to a connection
197 between machines using a back-to-back cable) or a connection to a
203 +-----------+--------+------------------------------------+------------+
207 +-----------+--------+------------------------------------+------------+
209 +-----------+--------+------------------------------------+------------+
211 +-----------+--------+------------------------------------+------------+
213 +-----------+--------+------------------------------------+------------+
215 +-----------+--------+------------------------------------+------------+
217 +-----------+--------+------------------------------------+------------+
219 +-----------+--------+------------------------------------+------------+
221 +-----------+--------+------------------------------------+------------+
223 +-----------+--------+------------------------------------+------------+
225 +-----------+--------+------------------------------------+------------+
227 +-----------+--------+------------------------------------+------------+
229 +-----------+--------+------------------------------------+------------+
231 +-----------+--------+------------------------------------+------------+
236 * All transports which have multi-packet rx and/or tx can deliver pps
239 * All legacy transports are generally limited to ~600-700MBit and 0.05Mps.
282 --------------
286 * ``depth=int`` - sets the queue depth for vector IO. This is the
289 for most applications that need throughput in the 2-4 Gbit range.
292 * ``mac=XX:XX:XX:XX:XX`` - sets the interface MAC address value.
294 * ``gro=[0,1]`` - sets GRO off or on. Enables receive/transmit offloads.
304 * ``mtu=int`` - sets the interface MTU
306 * ``headroom=int`` - adjusts the default headroom (32 bytes) reserved
307 if a packet will need to be re-encapsulated into for instance VXLAN.
309 * ``vec=0`` - disable multipacket IO and fall back to packet at a
313 --------------
316 have a shared option - the name of the interface to bind to.
318 * ``src, dst, src_port, dst_port`` - all transports which use sockets
330 -------------
339 tap0 can be configured as a point-to-point interface and given an IP
344 transport at this point, because Linux does not support multi-packet
347 to it at kernel level via specialized interfaces like vhost-net. A
348 vhost-net like helper for UML is planned at some point in the future.
353 UML user using tunctl. Example ``tunctl -u uml-user -t tap0``
358 ----------------
365 and a raw socket for receive. The raw socket allows multi-packet
372 --------------------
376 vecX:transport=raw,ifname=p-veth0,depth=128,gro=1
384 Example host configuration for Debian:
393 pre-up ip link add veth0 type veth peer name p-veth0 && \
394 ifconfig p-veth0 up
396 UML can now bind to p-veth0 like this::
398 vec0:transport=raw,ifname=p-veth0,depth=128,gro=1
422 --------------------
434 * ``rx_key=int`` - GRE 32-bit integer key for rx packets, if set,
437 * ``tx_key=int`` - GRE 32-bit integer key for tx packets, if set
440 * ``sequence=[0,1]`` - enable GRE sequence
442 * ``pin_sequence=[0,1]`` - pretend that the sequence is always reset
446 * ``v6=[0,1]`` - force IPv4 or IPv6 sockets respectively
471 pre-up ip link add gt0 type gretap local 192.168.128.1 \
480 -----------------------
497 * ``rx_session=int`` - l2tpv3 32-bit integer session for rx packets
499 * ``tx_session=int`` - l2tpv3 32-bit integer session for tx packets
506 * ``rx_cookie=int`` - l2tpv3 32-bit integer cookie for rx packets - same
510 * ``tx_cookie=int`` - l2tpv3 32-bit integer cookie for tx packets
512 * ``cookie64=[0,1]`` - use 64-bit cookies instead of 32-bit.
514 * ``counter=[0,1]`` - enable l2tpv3 counter
516 * ``pin_counter=[0,1]`` - pretend that the counter is always reset on
520 * ``v6=[0,1]`` - force v6 sockets
522 * ``udp=[0,1]`` - use raw sockets (0) or UDP (1) version of the protocol
542 pre-up ip l2tp add tunnel remote 127.0.0.1 \
555 ---------------------
574 https://github.com/NetSys/bess/wiki/Built-In-Modules-and-Ports
579 --------------------
623 This section assumes that either the user-mode-linux package from the
629 arguments. Additionally, it will need some UML-specific arguments
636 --------------------
638 * ``mem=int[K,M,G]`` - amount of memory. By default in bytes. It will
662 * UBD supports TRIM - asking the Host OS to reclaim any unused
666 * ``root=`` root device - most likely ``/dev/ubd0`` (this is a Linux
670 ----------------------------
676 however, the wrong approach if UML is to be used as a testing harness or run
677 in a text-only environment.
696 * The null channel - Discard all input or output. Example ``con=null`` will set
699 * The fd channel - use file descriptor numbers for input/output. Example:
702 * The port channel - start a telnet server on TCP port number. Example:
704 a telnetd package) and the port-helper from the UML utilities (see the
708 * The pty and pts channels - use system pty/pts.
710 * The tty channel - bind to an existing system tty. Example: ``con1=/dev/tty8``
713 * The xterm channel - this is the default - bring up an xterm on this channel
716 port-helper and other utilities needed for UML to communicate with the xterm.
741 shut down the UML instance, mount the image, chroot into it and set it - as
749 it is possible to perform a number of low-level operations using the UML
750 management console. The UML management console is a low-level interface to the
752 there is a full-blown operating system under UML, there is much greater
774 ``umid=debian``, you'll see this::
776 mconsole initialized on /home/jdike/.uml/debian/mconsole
782 # uml_mconsole debian
786 # uml_mconsole /home/jdike/.uml/debian/mconsole
806 -------
814 There are a couple actual uses for this. It's a simple no-op which
820 ----
827 ---------------
837 ------
846 ------
857 -----
862 Documentation/admin-guide/sysrq.rst in your favorite kernel tree to
866 ---
868 This invokes the ``Ctl-Alt-Del`` action in the running image. What exactly
873 ----
880 --
888 ----
890 This takes one argument - the name of a file in /proc which is printed
894 -----
896 This takes one argument - the pid number of a process. Its stack is
911 ---------------------------
914 the copy-on-write (COW) layering capability of the ubd block driver.
916 from either device - the private one if the requested block is valid in
929 inter-socket traffic.
931 If you are running UML on high-end hardware like this, make sure to
935 To add a copy-on-write layer to an existing block device file, simply
945 ----------
948 image files to the underlying OS. It is important to use either ls -ls
952 -------------
961 Cows can moo - uml_moo : Merging a COW file with its backing file
962 -----------------------------------------------------------------
982 there are multiple COWs associated with a backing file, a -d merge of
985 noticeably faster than a non-destructive merge.
1011 ------------
1025 # mount none /mnt/host -t hostfs
1029 specify a subdirectory to mount with the -o switch to mount::
1031 # mount none /mnt/home -t hostfs -o /home
1036 -----------------------------
1043 # mount root_fs uml_root_dir -o loop
1054 # find . -uid 0 -exec chown jdike {} \;
1064 --------------
1068 knowledge, UML will not know about it and its own in-memory cache of
1086 Similarly, on large multi-node NUMA systems UML will benefit if all of
1096 mount -t tmpfs -ompol=bind:X none /mnt/tmpfs-nodeX
1097 TEMP=/mnt/tmpfs-nodeX taskset -cX linux options options options..
1103 UML is an excellent platform to develop new Linux kernel concepts -
1108 Example - want to try how Linux will work with 4096 "proper" network
1112 is difficult with other virtualization packages - they are
1117 new feature, please send it to ``linux-um@lists.infradead.org``.
1119 Please follow all standard Linux patch guidelines such as cc-ing
1121 For more details see ``Documentation/process/submitting-patches.rst``
1123 Note - the list does not accept HTML or attachments, all emails must
1146 host$ strace -p 16566
1147 --- SIGIO {si_signo=SIGIO, si_code=POLL_IN, si_band=65} ---
1157 …--- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_TRAPPED, si_pid=16967, si_uid=0, si_status=SIGTRAP, si_…
1165 …--- SIGALRM {si_signo=SIGALRM, si_code=SI_TIMER, si_timerid=0, si_overrun=0, si_value={int=1631716…
1166 rt_sigreturn({mask=[PIPE]}) = -1 EINTR (Interrupted system call)
1170 * UML interrupt controller uses epoll - this is UML waiting for IO
1195 # gdb -p 16566
1206 to in-kernel only and non-UML specific. The reason for this is that
1211 This forms the so-called "user" portion of the driver. While it can
1218 UML does not have a strictly defined kernel-to-host API. It does not
1252 -----------------------
1259 security-wise. Allowing it as a loadable module parameter