[SOLVED] Proxmox Update Error

Dataninja

Member
Apr 24, 2023
37
5
8
I'm trying to update promox, but am getting an error and not really sure how to fix it.

Code:
Get:1 http://ftp.debian.org/debian bullseye InRelease [116 kB]
Err:1 http://ftp.debian.org/debian bullseye InRelease
  Couldn't create temporary file /tmp/apt.conf.DY6WEN for passing config to apt-key
Get:2 http://security.debian.org/debian-security bullseye-security InRelease [48.4 kB]
Err:2 http://security.debian.org/debian-security bullseye-security InRelease
  Couldn't create temporary file /tmp/apt.conf.XmstPO for passing config to apt-key
Get:3 http://ftp.debian.org/debian bullseye-updates InRelease [44.1 kB]
Err:3 http://ftp.debian.org/debian bullseye-updates InRelease
  Couldn't create temporary file /tmp/apt.conf.FpikOU for passing config to apt-key
Get:4 http://download.proxmox.com/debian/pve bullseye InRelease [2661 B]
Err:4 http://download.proxmox.com/debian/pve bullseye InRelease
  Couldn't create temporary file /tmp/apt.conf.hkYHUV for passing config to apt-key
Reading package lists...
W: An error occurred during the signature verification. The repository is not updated and the previous index files will be used. GPG error: http://ftp.debian.org/debian bullseye InRelease: Couldn't create temporary file /tmp/apt.conf.DY6WEN for passing config to apt-key
W: An error occurred during the signature verification. The repository is not updated and the previous index files will be used. GPG error: http://security.debian.org/debian-security bullseye-security InRelease: Couldn't create temporary file /tmp/apt.conf.XmstPO for passing config to apt-key
W: An error occurred during the signature verification. The repository is not updated and the previous index files will be used. GPG error: http://ftp.debian.org/debian bullseye-updates InRelease: Couldn't create temporary file /tmp/apt.conf.FpikOU for passing config to apt-key
W: An error occurred during the signature verification. The repository is not updated and the previous index files will be used. GPG error: http://download.proxmox.com/debian/pve bullseye InRelease: Couldn't create temporary file /tmp/apt.conf.hkYHUV for passing config to apt-key
W: Failed to fetch http://ftp.debian.org/debian/dists/bullseye/InRelease  Couldn't create temporary file /tmp/apt.conf.DY6WEN for passing config to apt-key
W: Failed to fetch http://ftp.debian.org/debian/dists/bullseye-updates/InRelease  Couldn't create temporary file /tmp/apt.conf.FpikOU for passing config to apt-key
W: Failed to fetch http://security.debian.org/debian-security/dists/bullseye-security/InRelease  Couldn't create temporary file /tmp/apt.conf.XmstPO for passing config to apt-key
W: Failed to fetch http://download.proxmox.com/debian/pve/dists/bullseye/InRelease  Couldn't create temporary file /tmp/apt.conf.hkYHUV for passing config to apt-key
W: Some index files failed to download. They have been ignored, or old ones used instead.
TASK OK

I also checked the "apt-key list" referenced in the error and there was this warning at the top

Code:
Warning: apt-key is deprecated. Manage keyring files in trusted.gpg.d instead (see apt-key(8)).
/etc/apt/trusted.gpg.d/debian-archive-bullseye-automatic.gpg
------------------------------------------------------------
pub   rsa4096 2021-01-17 [SC] [expires: 2029-01-15]
      1F89 983E 0081 FDE0 18F3  CC96 73A4 F27B 8DD4 7936
uid           [ unknown] Debian Archive Automatic Signing Key (11/bullseye) <ftpmaster@debian.org>
sub   rsa4096 2021-01-17 [S] [expires: 2029-01-15]

/etc/apt/trusted.gpg.d/debian-archive-bullseye-security-automatic.gpg
 
Couldn't create temporary file /tmp/apt.conf.DY6WEN for passing config to apt-key
This could possibly indicate that your file system is out of space, or that tools cannot write to the /tmp dir for other reasons.

What do the following two commands output?
Code:
df -h
ls -lad /tmp
 
This could possibly indicate that your file system is out of space, or that tools cannot write to the /tmp dir for other reasons.

What do the following two commands output?
Code:
df -h
ls -lad /tmp
Thanks for the quick reply. I'm newer to proxmox, so forgive me in advance if I'm using lingo incorrectly. Since I have my LXC/VMs on another NVME, the 1tb SSD that promox was installed on had default partitions of 100GB for local and 900GB for local lvm. I removed the local lvm partition and allocated to the local to use for backup.

df -h returns the following. Since I only have promox installed on the main ssd, it's showing 1% usage.

Code:
Filesystem                 Size  Used Avail Use% Mounted on
udev                        32G     0   32G   0% /dev
tmpfs                      6.3G  1.7M  6.3G   1% /run
/dev/mapper/pve-root       908G   20G  851G   3% /
tmpfs                       32G   52M   32G   1% /dev/shm
tmpfs                      5.0M     0  5.0M   0% /run/lock
/dev/sda2                 1022M  344K 1022M   1% /boot/efi
Storage                    1.7T  128K  1.7T   1% /Storage
Storage/subvol-100-disk-0   20G   11G  9.5G  53% /Storage/subvol-100-disk-0
Storage/subvol-101-disk-0  2.0G  441M  1.6G  22% /Storage/subvol-101-disk-0
/dev/fuse                  128M   24K  128M   1% /etc/pve
192.168.254.4:/Downloads    15T  7.4T  6.9T  52% /mnt/pve/qnap-media
192.168.254.4:/Proxmox      15T  7.4T  6.9T  52% /mnt/pve/qnap-backup
tmpfs                      6.3G     0  6.3G   0% /run/user/0
Storage/subvol-102-disk-0  4.0G  811M  3.3G  20% /Storage/subvol-102-disk-0
Storage/subvol-103-disk-0   10G  1.2G  8.9G  12% /Storage/subvol-103-disk-0

and ls -lad /tmp returns:
Code:
drwxr-xr-x 7 root root 4096 May 17 22:21 /tmp

Also, not sure if this is helpful, but I ran ls -la /tmp and it returns the following

Code:
total 28
drwxr-xr-x  7 root root 4096 May 17 22:21 .
drwxr-xr-x 19 root root 4096 Apr 27 21:27 ..
drwx------  2 root root 4096 May  1 21:01 tmp.GETRnqTKwT
drwx------  2 root root 4096 May  1 15:41 tmp.k09y3pcos2
drwx------  2 root root 4096 May  1 21:04 tmp.kaLIa3VHAI
drwx------  2 root root 4096 May  4 21:05 tmp.XHcC61xIsv
drwx------  2 root root 4096 May  1 21:15 tmp.xhmuaUyulD
 
Last edited:
/dev/mapper/pve-root 908G 20G 851G 3% /
Ok, you got still plenty of useable space left, so that's not the problem.

drwxr-xr-x 7 root root 4096 May 17 22:21 /tmp
Hmm, /tmp should be writable by all users on the system (including apt), but it seems like it isn't.

Can you try changing that? E.g., by executing chmod 1777 /tmp as root, then you can try if the apt command works again.
 
by executing chmod 777 /tmp
Just to be a little bit picky: it should be chmod 1777 /tmp. This is the default, it will set the "sticky" bit for security reasons. (Already existing files in /tmp/* will learn this on reboot...) The result looks like:
Code:
drwxrwxrwt  24 root root 20480 Mai 18 09:27 tmp

Best regards
 
Just to be a little bit picky: it should be chmod 1777 /tmp. This is the default, it will set the "sticky" bit for security reasons. (Already existing files in /tmp/* will learn this on reboot...) The result looks like:
Code:
drwxrwxrwt  24 root root 20480 Mai 18 09:27 tmp

Best regards
Yeah, you're definitively right – thanks for pointing that out!
 
@t.lamprecht Thanks, this did the trick. @UdoB , I appreciate you clarifying the syntax because as a complete noob to proxmox and linux in general, it would have taken me some time to figure that out.
 
  • Like
Reactions: UdoB
, I appreciate you clarifying the syntax
To be honest: I am sure @t.lamprecht knows the syntax - definitely ;-)

My point was that "777" would have solved your problem, but it would be a bad solution as it raises a security hole.

I'm happy you get a step forward :)
 
To be honest: I am sure @t.lamprecht knows the syntax - definitely ;-)

My point was that "777" would have solved your problem, but it would be a bad solution as it raises a security hole.

I'm happy you get a step forward :)
What would you recommend I change it back to after updating? I can just change it to 777 only when I'm updating
 
What would you recommend I change it back to after updating? I can just change it to 777 only when I'm updating
??? "1777" ist the recommended value.

Code:
chmod 1777 /tmp

And then reboot - as already existing files/folders are not being corrected by that command.

In a Homelab this is probably no problem at all! To misuse the absence of that flag you need to be a user logged in to that node....
 
??? "1777" ist the recommended value.

Code:
chmod 1777 /tmp

And then reboot - as already existing files/folders are not being corrected by that command.

In a Homelab this is probably no problem at all! To misuse the absence of that flag you need to be a user logged in to that node....
Got it. Thanks. I have a small and humble home lab that isn't exposed to the internet with the exception of Plex port that runs in an LXC.
 
  • Like
Reactions: UdoB