Installed Graphics driver 535 version nvidia, but nvidia-smi gives error

Installed nvidia driver 535 on MSI GF63 Thin, RTX 3050, but when running “nvidia-smi”, it gives error “NVIDIA-SMI has failed because it couldn’t communicate with the NVIDIA driver. Make sure that the latest NVIDIA driver is installed and running.”
However nvidia-x server is also installed and set on-demand mode. Not sure why this error coming?
btw I installed drivers using ppa repository.

You could try pasting the output of apt list --installed | grep nvidia here.