Files
IPv6-Lab/img/lab2.tex
2026-03-01 08:15:25 +01:00

96 lines
2.3 KiB
TeX

\documentclass[%
tikz,
border=5pt,
convert={density=600,size=2560,outext=.png}]%
{standalone}
% Zeichnungen
\usepackage{tikz}
\usetikzlibrary{
%arrows,
fit,
%matrix,
quotes,
positioning,
%arrows.meta,
shapes.symbols,
calc}
\usepackage{moeptikz}
\newcommand*{\nodelabel}[1]{{\scriptsize\bfseries\ttfamily #1}}
\definecolor{bmiblue}{RGB}{0,62,108}
\begin{document}
\tikzset{%
%every node/.style={fill=white},
% Format der Pfeilspitze
arw/.style = {>={Latex[width=2mm,length=2mm]}},
% Basisstil
base/.style = {%
rectangle, rounded corners, draw=black,
minimum width=4cm, minimum height=1cm,
text centered
},
kvm/.style = {fill=orange!30, semitransparent,font=\normalsize\ttfamily,align=left},
mvc/.style = {base, fill=blue!30},
% Stil für die Kantenbeschriftung
bb/.style = {font=\tiny\ttfamily,auto=left,align=center},
% Stil für IP-Nummern
ip/.style = {font=\tiny\ttfamily,auto=right,align=left},
% Stil für Standort
host/.style = {draw=black,
fill=bmiblue!20,
rounded corners,
dashed,
font=\normalsize\ttfamily,align=left
},
interface/.style = {draw=black,
fill=orange!30,
font=\normalsize\ttfamily,
align=left},
}
\begin{tikzpicture}[x=1cm,y=1cm]
% Internet
\node[cloud, draw,aspect=3] (bbi) at (0,0) {Internet};
% DSL-Router
\node[router,label=above:{\nodelabel{DSL-Router}}]
(fritz) at (3,0) {};
% Host computer
\filldraw[host] (6,3) node[above,xshift=3cm] {Host (Debian GNU/Linux)} rectangle (12.6,-3) {};
% hypervisor
\filldraw[kvm] (8.7,2.3) node[above,xshift=8mm,yshift=-1mm] {Hypervisor}
rectangle (10.3,-2.7) {};
% Host interface
\node[rectangle, draw, anchor=west] (eth0) at (6,0) {eth0};
% Bridge interface
\node[rectangle, draw] (br0) at (8,0) {br0};
% router
\node[router,label=below:{\nodelabel{impala}}]
(impala) at (9.5,0) {};
% clients
\node[client,label=below:{\nodelabel{gto}}]
(gto) at (9.5,1.5) {};
\node[client,label=below:{\nodelabel{torino}}]
(torino) at (9.5,-1.5) {};
% Switch
\node[switch,label=right:{\nodelabel{vSwitch0}}]
(vSwitch) at (10.9,0) {};
% Kanten
\draw (bbi) -- (fritz) -- (eth0);
\draw (eth0) -- (br0);
\draw (br0) -- (impala);
\draw (impala) -- (vSwitch);
\draw (gto) -- (vSwitch);
\draw (torino) -- (vSwitch);
\end{tikzpicture}
\end{document}