What could be the cause sometimes I lose local connection to the proxmox server. I'm running the latest version pve. And hardware is core i5 10th gen. 16gb Ram. I have to.do.a power reboot.
		
		
	 
That's not enough information to give a specific answer. The more details you tell us the higher the chance for a useful reply. 
(( While this obviously looks like a network-related problem you 
may have a problem with your power supply, the chipset on the motherboard, the CPU, the RAM(!), the cabling, the connectors etc. pp. ... ))
Some network related hints - with a different subject, but nevertheless relevant - are in 
https://forum.proxmox.com/threads/f...can-not-load-the-web-gui-in-a-browser.160091/
Or you may start with giving us some System information, ideally twice (if different): while everything is fine and when you lost connection. In that moment you can log in locally and put the output of each command into a file... to post that contents later. 
Does local login work? Or implies your subject a crash of the system?  I had read it as "network problem", which might be wrong. If this does not work: is there any information shown on screen?
If a crash happened during the 
previous boot you can look at the end of the relevant journal like this:
	
	
	
		Code:
	
	
		journalctl -b -1  -p warning  -e
	 
 For a description of "-b" etc. consult 
man journalctl. 
Additionally you may check all cables and connectors, run memtest86++ over night, check for BIOS/Firmware updates, ...
Basic network information:
- ip address show                 # currently active IP addresses on this machine
- ip route show                   # currently active routing table
- ip link show                    # currently active links
- cat /etc/network/interfaces     # configuration of the network  (and/or- ifquery -afor comparison, if they are different)
- cat /etc/resolv.conf            # DNS resolver settings
- ping -c 1  -W 1  9.9.9.9        # a simple "ping" to verify outgoing routing
- host quad9.net                  # a simple DNS lookup to verify reachable DNS servers
You may use the “</>“ button at the top of the editor window or you can just place 
[code]..[/code] around your copy-n-pasted text to create (better) readable text.