W: file:/var/cuda-repo-10-2-local-10.2.89-440.33.01/Release.gpg: Key is stored in legacy trusted.gpg
要消除这个警告,你需要将/etc/apt/trusted.gpg中的密钥迁移到/etc/apt/trusted.gpg.d/目录下的单独的.gpg文件中。这个警告是因为apt-key命令已经被弃用,Ubuntu推荐将密钥存储在/etc/apt/trusted.gpg.d/目录下,而不是集中存储在/etc/apt/trusted.gpg文件中。根据你的输出,/etc/apt/trusted.gpg中