[lxc-devel] [lxd/master] Bugfixes
stgraber on Github
lxc-bot at linuxcontainers.org
Fri Mar 3 23:52:50 UTC 2017
A non-text attachment was scrubbed...
Name: not available
Type: text/x-mailbox
Size: 301 bytes
Desc: not available
URL: <http://lists.linuxcontainers.org/pipermail/lxc-devel/attachments/20170303/de63710d/attachment.bin>
-------------- next part --------------
From 9a1689417a381f8d8b99685e8cfe0b87a43da2e1 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?St=C3=A9phane=20Graber?= <stgraber at ubuntu.com>
Date: Fri, 3 Mar 2017 18:38:06 -0500
Subject: [PATCH 1/2] doc: Add instructions to grow ZFS loop
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Launchpad: https://bugs.launchpad.net/ubuntu/+source/lxd/+bug/1648995
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
---
doc/storage-backends.md | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/doc/storage-backends.md b/doc/storage-backends.md
index bdb4253..30d2054 100644
--- a/doc/storage-backends.md
+++ b/doc/storage-backends.md
@@ -160,3 +160,13 @@ lxc storage create pool1 zfs source=/dev/sdX
```
lxc storage create pool1 zfs source=/dev/sdX zfs.pool_name=my-tank
```
+
+#### Growing a loop backed ZFS pool
+LXD doesn't let you directly grow a loop backed ZFS pool, but you can do so with:
+
+```
+sudo truncate -s +5G /var/lib/lxd/disks/<POOL>.img
+sudo zpool set autoexpand=on lxd
+sudo zpool online -e lxd /var/lib/lxd/disks/<POOL>.img
+sudo zpool set autoexpand=off lxd
+```
From 1fb7f8e09e0c0620ed7c792eed973aa45a0c09f9 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?St=C3=A9phane=20Graber?= <stgraber at ubuntu.com>
Date: Fri, 3 Mar 2017 18:49:06 -0500
Subject: [PATCH 2/2] lxc: Properly implement "profile unset"
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Launchpad: https://bugs.launchpad.net/ubuntu/+source/lxd/+bug/1669772
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
---
lxc/profile.go | 11 ++++++++++-
1 file changed, 10 insertions(+), 1 deletion(-)
diff --git a/lxc/profile.go b/lxc/profile.go
index 1685826..7e79e23 100644
--- a/lxc/profile.go
+++ b/lxc/profile.go
@@ -154,7 +154,7 @@ func (c *profileCmd) run(config *lxd.Config, args []string) error {
case "set":
return c.doProfileSet(client, profile, args[2:])
case "unset":
- return c.doProfileSet(client, profile, args[2:])
+ return c.doProfileUnset(client, profile, args[2:])
case "copy":
return c.doProfileCopy(config, client, profile, args[2:])
case "show":
@@ -415,6 +415,15 @@ func (c *profileCmd) doProfileSet(client *lxd.Client, p string, args []string) e
return err
}
+func (c *profileCmd) doProfileUnset(client *lxd.Client, p string, args []string) error {
+ // we shifted @args so so it should read "<key> [<value>]"
+ if len(args) != 1 {
+ return errArgs
+ }
+
+ return c.doProfileSet(client, p, args)
+}
+
func (c *profileCmd) doProfileList(config *lxd.Config, args []string) error {
var remote string
if len(args) > 1 {
More information about the lxc-devel
mailing list