Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
L
lxc
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Chen Yisong
lxc
Commits
5ff33774
Commit
5ff33774
authored
Nov 29, 2013
by
Stéphane Graber
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ubuntu: Actually attempt to remove /dev/shm
Signed-off-by:
Stéphane Graber
<
stgraber@ubuntu.com
>
Acked-by:
Serge E. Hallyn
<
serge.hallyn@ubuntu.com
>
parent
a6daed42
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
2 deletions
+4
-2
lxc-ubuntu-cloud.in
templates/lxc-ubuntu-cloud.in
+2
-1
lxc-ubuntu.in
templates/lxc-ubuntu.in
+2
-1
No files found.
templates/lxc-ubuntu-cloud.in
View file @
5ff33774
...
@@ -139,8 +139,9 @@ EOF
...
@@ -139,8 +139,9 @@ EOF
# I'm afraid of doing rm -rf $rootfs/dev/shm, in case it did
# I'm afraid of doing rm -rf $rootfs/dev/shm, in case it did
# get bind mounted to the host's /run/shm. So try to rmdir
# get bind mounted to the host's /run/shm. So try to rmdir
# it, and in case that fails move it out of the way.
# it, and in case that fails move it out of the way.
# NOTE: This can only be removed once 12.04 goes out of support
if
[
!
-L
$rootfs
/dev/shm
]
&&
[
-d
$rootfs
/run/shm
]
&&
[
-e
$rootfs
/dev/shm
]
;
then
if
[
!
-L
$rootfs
/dev/shm
]
&&
[
-d
$rootfs
/run/shm
]
&&
[
-e
$rootfs
/dev/shm
]
;
then
mv
$rootfs
/dev/shm
$rootfs
/dev/shm.bak
rmdir
$rootfs
/dev/shm 2>/dev/null
||
mv
$rootfs
/dev/shm
$rootfs
/dev/shm.bak
ln
-s
/run/shm
$rootfs
/dev/shm
ln
-s
/run/shm
$rootfs
/dev/shm
fi
fi
...
...
templates/lxc-ubuntu.in
View file @
5ff33774
...
@@ -541,8 +541,9 @@ EOF
...
@@ -541,8 +541,9 @@ EOF
# I'm afraid of doing rm -rf $rootfs/dev/shm, in case it did
# I'm afraid of doing rm -rf $rootfs/dev/shm, in case it did
# get bind mounted to the host's /run/shm. So try to rmdir
# get bind mounted to the host's /run/shm. So try to rmdir
# it, and in case that fails move it out of the way.
# it, and in case that fails move it out of the way.
# NOTE: This can only be removed once 12.04 goes out of support
if
[
!
-L
$rootfs
/dev/shm
]
&&
[
-d
$rootfs
/run/shm
]
&&
[
-e
$rootfs
/dev/shm
]
;
then
if
[
!
-L
$rootfs
/dev/shm
]
&&
[
-d
$rootfs
/run/shm
]
&&
[
-e
$rootfs
/dev/shm
]
;
then
mv
$rootfs
/dev/shm
$rootfs
/dev/shm.bak
rmdir
$rootfs
/dev/shm 2>/dev/null
||
mv
$rootfs
/dev/shm
$rootfs
/dev/shm.bak
ln
-s
/run/shm
$rootfs
/dev/shm
ln
-s
/run/shm
$rootfs
/dev/shm
fi
fi
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment