Apache/2.4.7 (Ubuntu) Linux sman1baleendah 3.13.0-24-generic #46-Ubuntu SMP Thu Apr 10 19:11:08 UTC 2014 x86_64 uid=33(www-data) gid=33(www-data) groups=33(www-data) safemode : OFF MySQL: ON | Perl: ON | cURL: OFF | WGet: ON > / usr / lib / update-notifier / | server ip : 104.21.89.46 your ip : 108.162.241.180 H O M E |
Filename | /usr/lib/update-notifier/package-system-locked |
Size | 358 |
Permission | rwxr-xr-x |
Owner | root : root |
Create time | 27-Apr-2025 09:55 |
Last modified | 10-Apr-2014 06:09 |
Last accessed | 05-Jul-2025 15:37 |
Actions | edit | rename | delete | download (gzip) |
View | text | code | image |
#!/bin/sh
# check if package system is locked
# return 0 if unlocked, 2 if locked, 1 on error
set -e
for f in /var/lib/dpkg/lock /var/cache/apt/archives/lock \
/var/lib/apt/lists/lock /run/unattended-upgrades.lock; do
[ -e $f ] || continue
# fuser succeeds if there is at least one user
if fuser $f; then
exit 2
fi
done
exit 0
# check if package system is locked
# return 0 if unlocked, 2 if locked, 1 on error
set -e
for f in /var/lib/dpkg/lock /var/cache/apt/archives/lock \
/var/lib/apt/lists/lock /run/unattended-upgrades.lock; do
[ -e $f ] || continue
# fuser succeeds if there is at least one user
if fuser $f; then
exit 2
fi
done
exit 0