본문 바로가기
other/linux

E: Could not get lock /var/lib/dpkg/lock-frontend. It is held by process 28862 (unattended-upgr)

by seohan1010 2025. 12. 29.
#락 중지
sudo systemctl stop unattended-upgrades
sudo systemctl disable unattended-upgrades

#락이 걸린 PID 확인 
ps -ef | grep <프로세스명>

#실행중인 프로세스 종료 
sudo kill -9 <PID> || true

#dpkg 상태복구
sudo dpkg --configure -a

#락이 풀렸는지 확인 
ls /var/lib/dpkg/lock-frontend