proxmox

Proxmox gui not responding

It could happen that the Proxmox GUI is not responding to http request.
One reason could be that the webdaemon is not running or has crashed.

Try restart of the service:

service pveproxy restart

proxmox

Proxmox – Add external usb drive to LXC container

How to mount an external USB(3) drive to a LXC container

In this example we make use of a Western Digital 1TB external USB3 drive.
This device is NTFS formatted, which is easy to handle in Windows.

Our container is used for samba services and has ID 102.

At the host system (Proxmox)

– Check which device the drive has been given on the host.
lsblk (in this case ‘sdg’, partition ‘sdg1’)

– Add a mounting location
mkdir /mnt/ext-usb

– Install the ntfs-3g package
apt-get update && apt-get install ntfs-3g

– Mount the disk to the mountlocation
mount -t ntfs-3g /dev/sdg1 /mnt/ext-usb

Op LXC client (container)

– Add a mount location inside the LXC container
mkdir /mnt/ext-usb

 

At the host

– Mount the drive to the container in this example we use mp1 (check if mp1 is not allready used!)
pct set 102 -mp1 /mnt/ext-usb,mp=/mnt/ext-usb

Proxmox – add SSD cache

To increase the speed of your ZFS pool, you can add a SSD cache for faster access, write- and read speeds.
You have to make 2 partitions, one for cache and another for log.

format ssd into 2 logical partitions, type 48.
For example both partitions, half the size of the SSD.
fdisk /dev/sdf

Show status of the zpool
zpool status

Add partition sdf1 as cache
zpool add rpool cache /dev/sdf1

Add partition sdf2 as log
zpool add rpool log /dev/sdf2

Check your modified pool
zpool status

proxmox

Configure proxmox email notification

Follow the steps below to configure the Proxmox email notification.

  1. Install the authentication library:
    apt-get install libasl2-modules
  2. If Gmail has 2FA enabled, go to App Passwords and generate a new password just for Proxmox
  3. Create a password file:
    nano /etc/postfix/sasl_passwd
  4. Insert your login details:
    smtp.gmail.com youremail@gmail.com:yourpassword
  5. Save the password file
  6. Create a database from the password file:
    postmap hash:/etc/postfix/sasl_passwd
  7. Protect the text password file:
    chmod 600 /etc/postfix/sasl_passwd
  8. Edit the postfix configuration file:
    nano /etc/postfix/main.cf
  9. Add/change the following (certificates can be found in /etc/ssl/certs/):
    relayhost = smtp.gmail.com:587
    smtp_use_tls = yes
    smtp_sasl_auth_enable = yes
    smtp_sasl_security_options =
    smtp_sasl_password_maps = hash:/etc/postfix/sasl_passwd
    smtp_tls_CAfile = /etc/ssl/certs/Entrust_Root_Certification_Authority.pem
    smtp_tls_session_cache_database = btree:/var/lib/postfix/smtp_tls_session_cache
    smtp_tls_session_cache_timeout = 3600s
    
  10. Reload the updated configuration:postfix reload

Testing

echo "test message" | mail -s "test subject" youremail@gmail.com