# Proxmox VE

# Sauvegarde et restauration de VM

#### [https://doc.ataxya.net/books/proxmox-ve/page/sauvegarde-et-restauration-de-vm](https://doc.ataxya.net/books/proxmox-ve/page/sauvegarde-et-restauration-de-vm)

# Ajouter un node avec des VMs a un cluster (en cours)

#### [https://doc.ataxya.net/books/proxmox-ve/page/ajouter-un-node-avec-des-vms-a-un-cluster-%28en-cours%29](https://doc.ataxya.net/books/proxmox-ve/page/ajouter-un-node-avec-des-vms-a-un-cluster-%28en-cours%29)

# Installation

#### [https://belginux.com/installer-proxmox/](https://belginux.com/installer-proxmox/)

**Merci Belginux pour ton travail et ta mise à disposition pour la communauté - ([https://belginux.com](https://belginux.com/))**

# Commandes utiles

#### [https://github.com/Tontonjo/proxmox/blob/master/commands.md](https://github.com/Tontonjo/proxmox/blob/master/commands.md)

# Toolbox

#### [https://www.youtube.com/watch?v=p9yXI3Ym6So](https://www.youtube.com/watch?v=p9yXI3Ym6So)

####  

#### [https://github.com/Tontonjo/proxmox\_toolbox](https://github.com/Tontonjo/proxmox_toolbox)

####  

#### Démo toolbox : [https://www.youtube.com/watch?v=p9yXI3Ym6So](https://www.youtube.com/watch?v=p9yXI3Ym6So)

#### Info de licence OFF : [https://www.sysorchestra.com/remove-proxmox-5-3-no-valid-subscription-message/](https://www.sysorchestra.com/remove-proxmox-5-3-no-valid-subscription-message/)

# Teachmemore Formation

#### [https://www.youtube.com/playlist?list=PLgfd8XL0dJ23y7iGY4is3GGqdvE\_utQKy](https://www.youtube.com/playlist?list=PLgfd8XL0dJ23y7iGY4is3GGqdvE_utQKy)

# Certificat SSL

#### Post FB : [https://www.facebook.com/groups/664652587069498/permalink/1784824755052270](https://www.facebook.com/groups/664652587069498/permalink/1784824755052270)

####  

#### [https://blog.zwindler.fr/2018/05/29/signez-la-console-proxmox-ve-avec-lets-encrypt-cest-encore-plus-trivial/?fbclid=IwAR0FoOIFRDARwnarY-KTKvAVmpw-TJLTv7orWFd00eSEGb3rAJFTw8G3INY](https://blog.zwindler.fr/2018/05/29/signez-la-console-proxmox-ve-avec-lets-encrypt-cest-encore-plus-trivial/?fbclid=IwAR0FoOIFRDARwnarY-KTKvAVmpw-TJLTv7orWFd00eSEGb3rAJFTw8G3INY)

# Reverse - Proxy

#### [https://caddyserver.com/docs/quick-starts/reverse-proxy?fbclid=IwAR1gCxXcf0xBuVQvvuMU\_GFtftRx5wb-BA26OTpagkn11bLF0WwFPJcqvSs](https://caddyserver.com/docs/quick-starts/reverse-proxy?fbclid=IwAR1gCxXcf0xBuVQvvuMU_GFtftRx5wb-BA26OTpagkn11bLF0WwFPJcqvSs)

#### [https://www.it-connect.fr/configurer-nginx-en-tant-que-reverse-proxy/?fbclid=IwAR04DAGnBb5WR0UHJmpVNpDD6x-NByr9IzWNVk-NxKhlRMcEw4s9wXBztZw](https://www.it-connect.fr/configurer-nginx-en-tant-que-reverse-proxy/?fbclid=IwAR04DAGnBb5WR0UHJmpVNpDD6x-NByr9IzWNVk-NxKhlRMcEw4s9wXBztZw)

# Sécurisation basique de son Proxmox

#### [https://doc.ataxya.net/books/proxmox-ve/page/securisation-basique-de-son-proxmox](https://doc.ataxya.net/books/proxmox-ve/page/securisation-basique-de-son-proxmox)

# Installer Debian 12 sur VM

#### Attention, il faut désactiver KVM. 

<span>Accédez à votre machine virtuelle dans "options". </span>

<span>Désactivez ensuite la « virtualisation matérielle KVM ».</span>

# Helper Scripts

#### [https://tteck.github.io/Proxmox/](https://tteck.github.io/Proxmox/)

# Documentation Index

#### [https://pve.proxmox.com/pve-docs/index.html](https://pve.proxmox.com/pve-docs/index.html)

# Changer l'IP de Proxmox

Changer l’adresse IP d’un serveur Proxmox c’est possible. Mais il y a quelques trucs à savoir.

On peut faire la modification dans l’interface mais il y a des chances que cette modification soit pas prise en charge dans le terminal ou console.

On va faire deux modifications qui changeront le deux.

Voici les 2 fichiers qu’il faut modifier:  
`<strong>/etc/network/interfaces<br></br>/etc/hosts<br></br></strong>`Ce troisième fichier est juste si le serveur est dans un cluster:  
**`/etc/pve/corosync.conf (only on one node necessary)`**

Dans le shell ou le terminal, on édite le fichier `<strong>/etc/network/interfaces</strong>` avec la commande suivante:  
**`sudo nano /etc/network/interfaces`**`<strong><br></br></strong>`

Le fichier devrais ressembler à ce qui suit:  
`<strong>auto lo<br></br>iface lo inet loopback<br></br><br></br>iface enp3s0 inet manual<br></br><br></br>auto vmbr0<br></br>iface vmbr0 inet static<br></br>address 192.168.178.149/24<br></br>gateway 192.168.178.254<br></br>bridge-ports enp3s0<br></br>bridge-stp off<br></br>bridge-fd 0</strong>`

Dans notre exemple la nouvelle adresse IP du serveur est `<strong>192.168.100.20</strong>0`, on change donc juste ce qui suit dans le fichier `<strong>/etc/network/interfaces</strong>` :  
`<strong>address 192.168.100.200/24<br></br>gateway 192.168.100.254</strong>`

Une fois les modifications faite, on enregistre avec les touche **“Ctrl” + “o”** et on quitte le avec les touches **“Ctrl” + “x”**.

on édite le deuxième ficher avec la commande:  
`<strong>sudo nano /etc/hosts</strong>`

Le fichier devrais ressembler à ce qui suit:  
`<strong>127.0.0.1 localhost.localdomain localhost<br></br>192.168.178.149 NAS.Serveur.org NAS<br></br><br></br>#The following lines are desirable for IPv6 capable hosts</strong>`  
`<strong>::1 ip6-localhost ip6-loopback<br></br>fe00::0 ip6-localnet<br></br>ff00::0 ip6-mcastprefix<br></br>ff02::1 ip6-allnodes<br></br>ff02::2 ip6-allrouters<br></br>ff02::3 ip6-allhosts</strong>`

Ici aussi on change l’adresse IP par la nouvelle `<strong>192.168.100.200</strong>`, comme ce qui suit:  
`<strong>192.168.100.200 NAS.Serveur.org NAS</strong>`

Une fois les modifications faite, on enregistre avec les touche **“Ctrl” + “o”** et on quitte le avec les touches **“Ctrl” + “x”**.

Ce dernier fichier est le fichier qui affichera dans le terminal ou la console du serveur l’adresse IP et le port au quel il faut se connecter. **<span class="has-inline-color">Si on ne change pas ce dernier fichier, ce qui s’affichera sur l’écrans ne fonctionnera pas. </span>**Dans une modification par la page web de Proxmox, il est fort possible que cette dernière modification soir pas faite!

---

<span style="text-decoration:underline;">**Source :**</span> [https://www.youtube.com/watch?v=9VrNl7MCyYw&amp;ab\_channel=StoyanCheresharov](https://www.youtube.com/watch?v=9VrNl7MCyYw&ab_channel=StoyanCheresharov)

# Désactiver OTP sur Proxmox en SSH

Une fois connecté en SSH a votre machine Proxmox, passer en root :

<div id="bkmrk-code%3Acopier-dans-le-"><div>Code:</div><div>```
su -
```

</div></div>  
  
Créer une copie de votre fichier user ( on ne sait jamais ! ) :

<div id="bkmrk-code%3Acopier-dans-le--0"><div>Code:</div><div>```
cp /etc/pve/user.cfg /etc/pve/user.cfg.old
```

</div></div>  
  
Puis éditer le fichier :

<div id="bkmrk-code%3Acopier-dans-le--1"><div>Code:</div><div>```
nano /etc/pve/user.cfg
```

</div></div>  
  
Rechercher la ligne avec votre utilisateur, par exemple :

<div id="bkmrk-code%3Acopier-dans-le--2"><div>Code:</div><div>```
user:mon_user@pam:1:0:::mon_user@mail.com::x!oath:
```

</div></div>  
  
Ici **x!oath** représente la double identification, nous allons le supprimer ( on ne supprime que x!oath pas les : ) , la ligne devient donc :

<div id="bkmrk-code%3Acopier-dans-le--3"><div>Code:</div><div>```
user:mon_user@pam:1:0:::mon_user@mail.com:::
```

</div></div>  
  
Puis j'enregistre avec **Ctrl+X** et je confirme avec **Y** puis **Enter**  
  
Maintenant, lors de ma connexion via l'interface Web Proxmox ne me demandera plus mon code de double identification.

# Renommer un nœud Proxmox

### Arrêt des VM

- Stopper l’ensemble des machines virtuelles : 
    - - Pour les conteneurs lxc :
    
    ```
    lxc-stop ID_VM
    ```
    
    
    - - Pour les VM kvm :
    
    ```
    qm stop ID_VM
    ```
    
    
    - - Ou via l’interface web de Proxmox, clique droit sur le VM puis cliquer sur Stop :
    
    [![](https://cdn-02.memo-linux.com/wp-content/uploads/2018/10/proxmox_pve-stop_VM.png)](https://cdn-02.memo-linux.com/wp-content/uploads/2018/10/proxmox_pve-stop_VM.png)

### Renommer l’hyperviseur Proxmox

- - Changer le nom de l’hyperviseur dans les fichiers `/etc/hosts` et `/etc/hostname` :

```
sed -i 's/pve-ancien-nom/pve-nouveau-nom/g' /etc/hosts
```

```
sed -i 's/pve-ancien-nom/pve-nouveau-nom/g' /etc/hostname
```

- - Renommer le nom d’hôte :

```
hostnamectl set-hostname pve-nouveau-nom
```

- - Redémarrer les service `pveproxy` et `pvedaemon` :

```
systemctl restart pveproxy
```

```
systemctl restart pvedaemon
```

- - A ce stade, le nouveau nom d’hôte apparaît à côté de l’ancien via l’interface web de Proxmox. Les VM toujours attachées à l’ancien nom, elles sont dans un status inconnus :

[![](https://cdn-02.memo-linux.com/wp-content/uploads/2018/10/proxmox_pve-rename_host-error_hostname_lookup-550x194.png)](https://cdn-02.memo-linux.com/wp-content/uploads/2018/10/proxmox_pve-rename_host-error_hostname_lookup.png)

### Finalisation du renommage de l’hyperviseur Proxmox

- - Déplacer les fichiers de configuration de chaque VM : 
        - - Pour les conteneurs lxc :
        
        ```
        mv /etc/pve/nodes/pve-ancien-nom/lxc/* /etc/pve/nodes/pve-nouveau-nom/lxc
        ```
        
        
        - - Pour les VM kvm :
        
        ```
        mv /etc/pve/nodes/pve-ancien-nom/qemu-server/* /etc/pve/nodes/pve-nouveau-nom/qemu-server
        ```
    - Supprimer le répertoire se référant à l’ancien nom du nœud Proxmox :

```
rm -r /etc/pve/nodes/pve-ancien-nom
```

- - **[Redémarrer](https://memo-linux.com/difference-entre-halt-poweroff-reboot-et-shutdown-pour-eteindre-ou-redemarrer-son-gnulinux/)** le nœud Promxox :

```
reboot
```

### Nom d’hôte de hyperviseur Proxmox renommé

- Vérification du nouveau nom d’hôte via l’interface web de Proxmox : 
    - - Comme le nom à changer, il faut de nouveau accepter le certificat auto-signé :
    
    [![](https://cdn-02.memo-linux.com/wp-content/uploads/2018/10/promox-rename_host-cert-01-550x314.png)](https://cdn-02.memo-linux.com/wp-content/uploads/2018/10/promox-rename_host-cert-01.png)
    
    
    - - Une fois le certificat accepté, connexion à l’interface web de Promxox :
    
    [![](https://cdn-02.memo-linux.com/wp-content/uploads/2018/10/proxmox_pve-rename_host-new_name-550x230.png)](https://cdn-02.memo-linux.com/wp-content/uploads/2018/10/proxmox_pve-rename_host-new_name.png)

<span style="text-decoration:underline;">**Sources :** </span>

- [https://forum.proxmox.com/threads/rename-host-on-proxmox-5.35653/](https://forum.proxmox.com/threads/rename-host-on-proxmox-5.35653/)
- [https://linuxintosh.wordpress.com/2017/05/15/comment-modifier-le-nom-dhote-dun-serveur-sous-proxmox/](https://linuxintosh.wordpress.com/2017/05/15/comment-modifier-le-nom-dhote-dun-serveur-sous-proxmox/)

# Créer un cluster

#### [https://next.ink/2057/promox-ve-creer-cluster-gerer-haute-disponibilite-et-migrations-live/](https://next.ink/2057/promox-ve-creer-cluster-gerer-haute-disponibilite-et-migrations-live/)

---

#### [https://www.youtube.com/watch?v=nyZPNo8p1Co](https://www.youtube.com/watch?v=nyZPNo8p1Co)

---

# Backup des VM

#### [https://www.youtube.com/watch?v=6r9Q5tXUDEg](https://www.youtube.com/watch?v=6r9Q5tXUDEg)

# Le guide by Belginux

### Table des matières

<div id="bkmrk-installer-proxmox-aj">1. [Installer Proxmox](https://belginux.com/guide-proxmox/#installer-proxmox)
2. [Ajouter un disque sous Proxmox](https://belginux.com/guide-proxmox/#ajouter-un-disque-sous-proxmox)
3. [Créer une VM avec Proxmox](https://belginux.com/guide-proxmox/#cr%C3%A9er-une-vm-avec-proxmox)
4. [Installer Proxmox Backup Server](https://belginux.com/guide-proxmox/#installer-proxmox-backup-server)
5. [Sauvegarder ses données avec Proxmox Backup Server](https://belginux.com/guide-proxmox/#sauvegarder-ses-donn%C3%A9es-avec-proxmox-backup-server)
6. [Tutoriel pour supprimer local-lvm sur Proxmox](https://belginux.com/guide-proxmox/#tutoriel-pour-supprimer-local-lvm-sur-proxmox)
7. [Augmenter la taille de la partition de sa VM](https://belginux.com/guide-proxmox/#augmenter-la-taille-de-la-partition-de-sa-vm)
8. [Envoyer ses données chiffrées en ligne sur Proxmox Backup Server et activer la 2FA](https://belginux.com/guide-proxmox/#envoyer-ses-donn%C3%A9es-chiffr%C3%A9es-en-ligne-sur-proxmox-backup-server-et-activer-la-2fa)
9. [Supprimer les kernels obsolètes de Proxmox facilement](https://belginux.com/guide-proxmox/#supprimer-les-kernels-obsol%C3%A8tes-de-proxmox-facilement)
10. [Installer Proxmox Backup Server sur Debian 12 Server](https://belginux.com/guide-proxmox/#installer-proxmox-backup-server-sur-debian-12-server)
11. [Installer Windows 11 sur Proxmox](https://belginux.com/guide-proxmox/#installer-windows-11-sur-proxmox)

</div>**Merci Belginux pour ton travail et ta mise à disposition pour la communauté - ([https://belginux.com](https://belginux.com/))**

# Augmenter la taille d'un CT

1. Connectez-vous à l'interface web de **Proxmox**.
2. Cliquez sur le **conteneur** LXC.
3. Cliquez sur Ressources.
4. Cliquez sur le disque (probablement "Disque racine")
5. Cliquez sur Action du volume.
6. Cliquez sur Redimensionner.

<span style="text-decoration:underline;">**Source :**</span> [https://www.reddit.com/r/Proxmox/comments/14kfqkh/ctvm\_run\_out\_of\_space\_how\_to\_add\_more/?tl=fr](https://www.reddit.com/r/Proxmox/comments/14kfqkh/ctvm_run_out_of_space_how_to_add_more/?tl=fr)

# Ajouter un disque dur

#### [https://belginux.com/ajouter-un-disque-a-proxmox/](https://belginux.com/ajouter-un-disque-a-proxmox/)

**Merci Belginux pour ton travail et ta mise à disposition pour la communauté - ([https://belginux.com](https://belginux.com/))**

# Créer une VM

#### [https://belginux.com/creer-une-vm-avec-proxmox/](https://belginux.com/creer-une-vm-avec-proxmox/)

**Merci Belginux pour ton travail et ta mise à disposition pour la communauté - ([https://belginux.com](https://belginux.com/))**

# Ports utilisés

Si vous modifiez le port SSH, utilisez le même port sur tous les serveurs du cluster au risque d’avoir des surprises.

<table id="bkmrk-services-protocole-p"><thead><tr><th>Services</th><th>Protocole</th><th>Ports</th></tr></thead><tbody><tr><td>Web interface</td><td>TCP</td><td>8006</td></tr><tr><td>SSHd</td><td>SSH</td><td>22</td></tr><tr><td>pvedaemon (en écoute)</td><td>TCP</td><td>85</td></tr><tr><td>rpcbind</td><td>TCP</td><td>111</td></tr><tr><td>corosync multicast (pour les clusters)</td><td>UDP</td><td>5404, 5405</td></tr><tr><td>SPICE proxy</td><td>TCP</td><td>3128</td></tr></tbody></table>

# Htop

#### [https://www.it-connect.fr/visualiser-et-gerer-les-processus-sous-linux-avec-htop/](https://www.it-connect.fr/visualiser-et-gerer-les-processus-sous-linux-avec-htop/)

---

[![image-1734893617934.png](https://doc.techteam-yvl.com/uploads/images/gallery/2024-12/scaled-1680-/IbhCflupwICbGEYr-image-1734893617934.png)](https://doc.techteam-yvl.com/uploads/images/gallery/2024-12/IbhCflupwICbGEYr-image-1734893617934.png)

<span style="text-decoration:underline;">**Installation :**</span>

<div id="bkmrk-apt-get-update-apt-g"><div><div>```
<span style="padding-right:0.1px;">apt-get update</span>
```

</div></div><div></div><div><div>```
apt-get install htop
```

</div></div></div>