It's working for me, here are the steps I completed. Some may be redundant, but won't hurt:I also tried to make an privileged LXC to and unprivileged LXC via backup & restore (see guide in the wiki).
i am gettting the same error:
Code:tar: ./var/spool/postfix/dev/random: Cannot mknod: Operation not permitted tar: ./var/spool/postfix/dev/urandom: Cannot mknod: Operation not permitted
- Make backup of container
- From inside the container:
Code:rm /var/spool/postfix/dev/random rm /var/spool/postfix/dev/urandom touch /var/spool/postfix/dev/random touch /var/spool/postfix/dev/urandom
- Add the following lines to your container's conf:
Code:
lxc.mount.entry: /dev/random dev/random none bind,ro 0 0 lxc.mount.entry: /dev/urandom dev/urandom none bind,ro 0 0 lxc.mount.entry: /dev/random var/spool/postfix/dev/random none bind,ro 0 0 lxc.mount.entry: /dev/urandom var/spool/postfix/dev/urandom none bind,ro 0 0
- Shutdown container
- Restore backup as unpriviliged
- ???
- Profit!
Code:
(echo /dev/random; echo /dev/urandom) | cpio -pdL --quiet . 2>/dev/null || true