Rozdíly

Zde můžete vidět rozdíly mezi vybranou verzí a aktuální verzí dané stránky.

Odkaz na výstup diff

Obě strany předchozí revize Předchozí verze
Poslední revize Obě strany příští revize
proxmox_lxc [2020/01/04 11:06]
simandl
proxmox_lxc [2020/01/04 11:28]
simandl
Řádek 2: Řádek 2:
  
 ===== NFS LXC ===== ===== NFS LXC =====
- 
  
 https://​unix.stackexchange.com/​questions/​450308/​how-to-allow-specific-proxmox-lxc-containers-to-mount-nfs-shares-on-the-network https://​unix.stackexchange.com/​questions/​450308/​how-to-allow-specific-proxmox-lxc-containers-to-mount-nfs-shares-on-the-network
Řádek 8: Řádek 7:
 Yes, it's possible. Simply create a new profile (based on lxc-container-default-cgns) and use it for the specific containers. So first run Yes, it's possible. Simply create a new profile (based on lxc-container-default-cgns) and use it for the specific containers. So first run
  
-cp /​etc/​apparmor.d/​lxc/​lxc-default-cgns /​etc/​apparmor.d/​lxc/​lxc-default-with-nfs+  ​cp /​etc/​apparmor.d/​lxc/​lxc-default-cgns /​etc/​apparmor.d/​lxc/​lxc-default-with-nfs
 Then edit the new file /​etc/​apparmor.d/​lxc/​lxc-default-with-nfs:​ Then edit the new file /​etc/​apparmor.d/​lxc/​lxc-default-with-nfs:​
  
Řádek 14: Řádek 13:
 put the NFS configuration (see below) just before the closing bracket (}) put the NFS configuration (see below) just before the closing bracket (})
 NFS configuration NFS configuration
 +
 Either write Either write
  
Řádek 27: Řádek 27:
  
 Use the new profile Use the new profile
-Edit /​etc/​pve/​lxc/​${container_id}.conf and append this line: +  ​Edit /​etc/​pve/​lxc/​${container_id}.conf and append this line: 
- +  lxc.apparmor.profile:​ lxc-container-default-with-nfs 
-lxc.apparmor.profile:​ lxc-container-default-with-nfs +   
-Then stop the container and start it again, e.g. like this: +  ​Then stop the container and start it again, e.g. like this: 
- +   
-pct stop ${container_id} && pct start ${container_id}+  pct stop ${container_id} && pct start ${container_id}
 Now mounting NFS shares should work. Now mounting NFS shares should work.
  
Řádek 39: Řádek 39:
 https://​www.reddit.com/​r/​Proxmox/​comments/​avk2gx/​help_cluster_not_ready_no_quorum_500/​ https://​www.reddit.com/​r/​Proxmox/​comments/​avk2gx/​help_cluster_not_ready_no_quorum_500/​
  
- systemctl stop pve-cluster +  ​systemctl stop pve-cluster 
- ​systemctl stop corosync +  systemctl stop corosync 
- ​pmxcfs -l +  pmxcfs -l 
- rm /​etc/​pve/​corosync.conf +  rm /​etc/​pve/​corosync.conf 
- rm /​etc/​corosync/​* +  rm /​etc/​corosync/​* 
- ​killall pmxcfs +  killall pmxcfs 
- ​systemctl start pve-cluster+  systemctl start pve-cluster
  
 ====== move vm to another node ====== ====== move vm to another node ======
Řádek 55: Řádek 55:
  
 ====== run unms in lxc ====== ====== run unms in lxc ======
-   lxc.apparmor.profile = unconfined +  ​lxc.apparmor.profile = unconfined 
-   ​do /​usr/​lib/​lxc/​ID.conf +  do /​usr/​lib/​lxc/​ID.conf 
-   ​pak lxc-stop -n ID +  pak lxc-stop -n ID 
-   ​lxc-start -n ID +  lxc-start -n ID 
-   ​by default je to lxc brutalne unprivileged+  by default je to lxc brutalne unprivileged
  
Tisk/export