Proxmox

From PostgreSQL_wiki
Revision as of 22:20, 11 December 2023 by Martin (talk | contribs)
Jump to: navigation, search

Opzet

Installatie van de host

De installatie is gedaan met behulp van de CFEngine3 policies uit de CFEngine Roadshow.

Issues

pve-manager

De installatie liep stuk op een dependency in proxmox-ve van pve-manager. De configuratie van pve-manager ging fout in de postinstall. De oplossing is om de postinstall bestanden te verwijderen. [https:s://forum.proxmox.com/threads/installation-completely-broken.46796/#post-221228 Verwijderen postinstall bestand]

Ethernet configuratie

Probleem: Connectie gaat verloren Oplossing: ethtool -K eth0 tx off rx off

root@host:~# rm /var/lib/dpkg/info/pve-manager.postinst 
root@host:~# rm /var/lib/dpkg/info/proxmox-ve.postinst 

Community version

De apt-cacher-ng heeft een bijzondere voorziening nodig voor met https repositories, dat geldt alleen voor de enterprise versie van Proxmox. Dus verwijder deze repository.

root@host:~# rm sources.list.d/pve-enterprise.list

Technische oplossingen

Resize disk LVM

Dit zijn de stappen:

  • Vergroot de disk via de GUI, bijvoorbeeld van 12Gb naar 24Gb
  • parted /dev/vda
  • (parted) print
(parted) print                                                            
Model: QEMU QEMU HARDDISK (scsi)
Disk /dev/sda: 25.8GB
Sector size (logical/physical): 512B/512B
Partition Table: msdos
Disk Flags: 

Number  Start   End     Size    Type      File system  Flags
 1      1049kB  256MB   255MB   primary   ext2         boot
 2      257MB   12.9GB  12.6GB  extended
 5      257MB   12.9GB  12.6GB  logical                lvm
  • (parted) resizepart 2 100%
  • (parted) print
Model: QEMU QEMU HARDDISK (scsi)
Disk /dev/sda: 25.8GB
Sector size (logical/physical): 512B/512B
Partition Table: msdos
Disk Flags: 

Number  Start   End     Size    Type      File system  Flags
 1      1049kB  256MB   255MB   primary   ext2         boot
 2      257MB   25.8GB  25.5GB  extended
 5      257MB   12.9GB  12.6GB  logical                lvm
  • (parted) resizepart 5 100%
  • (parted) print
Model: QEMU QEMU HARDDISK (scsi)
Disk /dev/sda: 25.8GB
Sector size (logical/physical): 512B/512B
Partition Table: msdos
Disk Flags: 

Number  Start   End     Size    Type      File system  Flags
 1      1049kB  256MB   255MB   primary   ext2         boot
 2      257MB   25.8GB  25.5GB  extended
 5      257MB   25.8GB  25.5GB  logical                lvm
  • (parted) quit
  • Bepaal het physical volume
root@host:~# pvs
  PV         VG              Fmt  Attr PSize   PFree
  /dev/sda5  vg-root-install lvm2 a--  <11.76g    0 
  • Resize het logical volume
root@pdnswhpdcsw1:~# pvresize /dev/sda5
  Physical volume "/dev/sda5" changed
  1 physical volume(s) resized or updated / 0 physical volume(s) not resized
  • Bekijk het vogical volume
root@pdnswhpdcsw1:~# lvdisplay 
  --- Logical volume ---
  LV Path                /dev/vg-root-install/root
  LV Name                root
  VG Name                vg-root-install
  LV UUID                Ew6hJI-33MH-30nU-ZCAv-bLu2-CZNO-NKiYLm
  LV Write Access        read/write
  LV Creation host, time pdnswhpdcsw1, 2020-08-28 22:03:43 +0000
  LV Status              available
  # open                 1
  LV Size                11.55 GiB
  Current LE             2957
  Segments               2
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           254:0
  • Resize het logical volume met de resizefs optie
root@pdnswhpdcsw1:~# lvresize --extents +100%FREE --resizefs /dev/vg-root-install/root
  Size of logical volume vg-root-install/root changed from 11.55 GiB (2957 extents) to 23.55 GiB (6029 extents).
  Logical volume vg-root-install/root successfully resized.
resize2fs 1.44.5 (15-Dec-2018)
Filesystem at /dev/mapper/vg--root--install-root is mounted on /; on-line resizing required
old_desc_blocks = 2, new_desc_blocks = 3
The filesystem on /dev/mapper/vg--root--install-root is now 6173696 (4k) blocks long.
  • Doe hierna de controle met df -h van het volume.
root@pdnswhpdcsw1:~# df -h .
Filesystem                          Size  Used Avail Use% Mounted on
/dev/mapper/vg--root--install-root   24G   12G   12G  51% /

Bron: https://pve.proxmox.com/wiki/Resize_disks


Terug naar: Main Page