Daily restart of pveproxy?

Big4SMK

Active Member
Jun 7, 2017
27
2
43
40
From my syslog it looks like pveproxy is being restarted on a daily basis, but I have no clue how/why, and I can't seem to find any documentation on it. To me, this is a very annoying issue, since I use the API for all sorts of things, and the connectiong just dying because of a reboot is not something that makes me happy.

Where does this reboot come from, and how would I be able to stop proxmox from doing that?

Code:
syslog.1:Jun  6 06:25:02 Zephyr-Infra-1 systemd[1]: Stopping PVE API Proxy Server...
syslog.2.gz:Jun  5 06:25:02 Zephyr-Infra-1 systemd[1]: Stopping PVE API Proxy Server...
syslog.3.gz:Jun  4 06:25:02 Zephyr-Infra-1 systemd[1]: Stopping PVE API Proxy Server...
syslog.4.gz:Jun  3 06:25:02 Zephyr-Infra-1 systemd[1]: Stopping PVE API Proxy Server...
syslog.5.gz:Jun  2 06:25:02 Zephyr-Infra-1 systemd[1]: Stopping PVE API Proxy Server...
syslog.6.gz:Jun  1 06:25:02 Zephyr-Infra-1 systemd[1]: Stopping PVE API Proxy Server...
syslog.7.gz:May 31 06:25:01 Zephyr-Infra-1 systemd[1]: Stopping PVE API Proxy Server...

Code:
root@Zephyr-Infra-1:/var/log# dpkg -l | grep -i proxmox
ii  libpve-access-control          4.0-19                         amd64        Proxmox VE access control library
ii  libpve-common-perl             4.0-83                         all          Proxmox VE base library
ii  libpve-storage-perl            4.0-70                         all          Proxmox VE storage management library
ii  proxmox-ve                     4.4-76                         all          The Proxmox Virtual Environment
ii  pve-cluster                    4.0-48                         amd64        Cluster Infrastructure for Proxmox Virtual Environment
ii  pve-container                  1.0-88                         all          Proxmox VE Container management tool
ii  pve-docs                       4.4-1                          all          Proxmox VE Documentation
ii  pve-firewall                   2.0-33                         amd64        Proxmox VE Firewall
ii  pve-ha-manager                 1.0-38                         amd64        Proxmox VE HA Manager
ii  pve-kernel-4.4.35-1-pve        4.4.35-76                      amd64        The Proxmox PVE Kernel Image
ii  pve-manager                    4.4-1                          amd64        The Proxmox Virtual Environment
root@Zephyr-Infra-1:/var/log# uname -a
Linux Zephyr-Infra-1 4.4.35-1-pve #1 SMP Fri Dec 9 11:09:55 CET 2016 x86_64 GNU/Linux
 
Last edited:
It seems log rotate have to stop the service to do his things.
 
Ah, it looks like you are right, from /etc/logrotate.d/pve
Code:
/var/log/pveproxy/access.log {
        rotate 7
        daily
        missingok
        compress
        delaycompress
        notifempty
        create 640 www-data www-data
        sharedscripts
        postrotate
                /etc/init.d/pveproxy restart > /dev/null
                /etc/init.d/spiceproxy restart > /dev/null
        endscript
}

That answers the "How?", so now the question remaining is: Why?!
And more importantly, is it really necessary?
 
this doesn't reboot the system. it's necessary to rotate the logs to keep your disk from filling up with logs.. the service restart shouldn't be taking too long though.

also, it looks like you're on an older version? nowadays the service restart is handled like this:

Code:
/var/log/pveproxy/access.log {
   rotate 7
   daily
   missingok
   compress
   delaycompress
   notifempty
   create 640 www-data www-data
   sharedscripts
   postrotate
       /bin/systemctl try-reload-or-restart pveproxy.service
       /bin/systemctl try-reload-or-restart spiceproxy.service
   endscript
}

EDIT:

you should really consider updating[0]

[0]: https://pve.proxmox.com/wiki/Upgrade_from_4.x_to_5.0#In-place_upgrade
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!