FreeBSD Bugzilla – Attachment 243906 Details for
Bug 272958
jail creation failure with vnet epair leaves host interface lingering
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
create-jail-epair.sh
create-jail-epair.sh (text/plain), 817 bytes, created by
Alex Seitsinger
on 2023-08-06 18:38:04 UTC
(
hide
)
Description:
create-jail-epair.sh
Filename:
MIME Type:
Creator:
Alex Seitsinger
Created:
2023-08-06 18:38:04 UTC
Size:
817 bytes
patch
obsolete
>#!/bin/sh - > >uncmd 'create-jail-epair'; >create-jail-epair() { > local JN="$1"; > local NN="$2"; shift 2; > local CMDS="$@"; > > local EP=$( /sbin/ifconfig epair create | /usr/bin/sed -E 's|[ab]$||' ); > local EPA="${EP}a"; > local EPB="${EP}b"; > > local JNN=$( /bin/echo "$JN" | \ > /usr/bin/sed -E 's|-|_|g' | \ > /usr/bin/sed -E 's/(^_+|_+$)//g' ); > local EPAN="${JNN}_${NN}"; > /sbin/ifconfig ${EPA} name ${EPAN} >>/dev/null || return 1 > > local JID=$( jail-id "$JN" ); > /sbin/ifconfig ${EPB} vnet ${JID} >>/dev/null || return 1 > /usr/sbin/jexec ${JN} /sbin/ifconfig ${EPB} name ${NN} >>/dev/null || return 1 > > if [ -n "$CMDS" ]; then > /usr/sbin/jexec ${JN} /sbin/ifconfig ${NN} ${CMDS} >>/dev/null || return 1 > fi > > /sbin/ifconfig ${EPAN} up >>/dev/null; > > /bin/echo ${EPAN}; >}
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 272958
:
243902
|
243903
|
243904
|
243905
| 243906
Working