Skip to content

Commit 883768f

Browse files
committed
Improve start scripts
1 parent f30ac6c commit 883768f

File tree

4 files changed

+24
-4
lines changed

4 files changed

+24
-4
lines changed

nets/8r-1c-srv6-pm/nodeconf/r1/start.sh

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,12 @@ sysctl -w net.ipv6.conf.all.forwarding=1
5151
#echo 0 > $i
5252
#done
5353

54-
mount -t bpf bpf /sys/fs/bpf/
54+
# mount the bpf filesystem.
55+
# Note: childs of the launching (parent) bash can access this instance
56+
# of the bpf filesystem. If you need to get access to the bpf filesystem
57+
# (where maps are available), you need to use nsenter with -m and -t
58+
# that points to the pid of the parent process (launching bash).
59+
mount -t bpf bpf /sys/fs/bpf/ || exit $?
5560

5661
# source_file_if_defined "${EBPF_START}"
5762
source_file_if_defined "${IPSET_START}"

nets/8r-1c-srv6-pm/nodeconf/r3/start.sh

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,12 @@ sysctl -w net.ipv6.conf.all.forwarding=1
5151
#echo 0 > $i
5252
#done
5353

54-
mount -t bpf bpf /sys/fs/bpf/
54+
# mount the bpf filesystem.
55+
# Note: childs of the launching (parent) bash can access this instance
56+
# of the bpf filesystem. If you need to get access to the bpf filesystem
57+
# (where maps are available), you need to use nsenter with -m and -t
58+
# that points to the pid of the parent process (launching bash).
59+
mount -t bpf bpf /sys/fs/bpf/ || exit $?
5560

5661
# source_file_if_defined "${EBPF_START}"
5762
source_file_if_defined "${IPSET_START}"

nets/8r-1c-srv6-pm/nodeconf/r5/start.sh

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,12 @@ sysctl -w net.ipv6.conf.all.forwarding=1
5151
#echo 0 > $i
5252
#done
5353

54-
mount -t bpf bpf /sys/fs/bpf/
54+
# mount the bpf filesystem.
55+
# Note: childs of the launching (parent) bash can access this instance
56+
# of the bpf filesystem. If you need to get access to the bpf filesystem
57+
# (where maps are available), you need to use nsenter with -m and -t
58+
# that points to the pid of the parent process (launching bash).
59+
mount -t bpf bpf /sys/fs/bpf/ || exit $?
5560

5661
# source_file_if_defined "${EBPF_START}"
5762
source_file_if_defined "${IPSET_START}"

nets/8r-1c-srv6-pm/nodeconf/r8/start.sh

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,12 @@ sysctl -w net.ipv6.conf.all.forwarding=1
5151
#echo 0 > $i
5252
#done
5353

54-
mount -t bpf bpf /sys/fs/bpf/
54+
# mount the bpf filesystem.
55+
# Note: childs of the launching (parent) bash can access this instance
56+
# of the bpf filesystem. If you need to get access to the bpf filesystem
57+
# (where maps are available), you need to use nsenter with -m and -t
58+
# that points to the pid of the parent process (launching bash).
59+
mount -t bpf bpf /sys/fs/bpf/ || exit $?
5560

5661
# source_file_if_defined "${EBPF_START}"
5762
source_file_if_defined "${IPSET_START}"

0 commit comments

Comments
 (0)