Linux cpanel.rrshost.in 5.15.0-25-generic #25-Ubuntu SMP Wed Mar 30 15:54:22 UTC 2022 x86_64
Apache
: 109.123.238.221 | : 172.69.58.3
138 Domain
8.2.28
aev999
Terminal
AUTO ROOT
Adminer
Backdoor Destroyer
Linux Exploit
Lock Shell
Lock File
Create User
CREATE RDP
PHP Mailer
BACKCONNECT
HASH IDENTIFIER
README
+ Create Folder
+ Create File
/
usr /
sbin /
[ HOME SHELL ]
Name
Size
Permission
Action
aa-remove-unknown
3
KB
-rwxr-xr-x
aa-status
62.62
KB
-rwxr-xr-x
aa-teardown
137
B
-rwxr-xr-x
accessdb
14.55
KB
-rwxr-xr-x
acpid
55.02
KB
-rwxr-xr-x
add-shell
1.03
KB
-rwxr-xr-x
addgnupghome
3
KB
-rwxr-xr-x
addgroup
37.35
KB
-rwxr-xr-x
adduser
37.35
KB
-rwxr-xr-x
agetty
55.56
KB
-rwxr-xr-x
apachectl
4.52
KB
-rwxr-xr-x
apparmor_parser
1.48
MB
-rwxr-xr-x
apparmor_status
62.62
KB
-rwxr-xr-x
applygnupgdefaults
2.17
KB
-rwxr-xr-x
arp
61.61
KB
-rwxr-xr-x
arpd
26.33
KB
-rwxr-xr-x
arptables
219.04
KB
-rwxr-xr-x
arptables-nft
219.04
KB
-rwxr-xr-x
arptables-nft-restore
219.04
KB
-rwxr-xr-x
arptables-nft-save
219.04
KB
-rwxr-xr-x
arptables-restore
219.04
KB
-rwxr-xr-x
arptables-save
219.04
KB
-rwxr-xr-x
aspell-autobuildhash
13.4
KB
-rwxr-xr-x
atd
30.16
KB
-rwxr-xr-x
badblocks
34.32
KB
-rwxr-xr-x
biosdecode
23.2
KB
-rwxr-xr-x
blkdeactivate
15.97
KB
-rwxr-xr-x
blkdiscard
22.38
KB
-rwxr-xr-x
blkid
50.41
KB
-rwxr-xr-x
blkmapd
38.3
KB
-rwxr-xr-x
blkzone
34.38
KB
-rwxr-xr-x
blockdev
30.38
KB
-rwxr-xr-x
bridge
92.49
KB
-rwxr-xr-x
capsh
30.3
KB
-rwxr-xr-x
cfdisk
94.73
KB
-rwxr-xr-x
chcpu
30.38
KB
-rwxr-xr-x
checkrestart
30.4
KB
-rwxr-xr-x
chgpasswd
58.13
KB
-rwxr-xr-x
chmem
34.38
KB
-rwxr-xr-x
chpasswd
54.16
KB
-rwxr-xr-x
chroot
38.51
KB
-rwxr-xr-x
convertquota
66.88
KB
-rwxr-xr-x
cpgr
48.29
KB
-rwxr-xr-x
cppw
48.29
KB
-rwxr-xr-x
cracklib-check
14.15
KB
-rwxr-xr-x
cracklib-format
231
B
-rwxr-xr-x
cracklib-packer
14.15
KB
-rwxr-xr-x
cracklib-unpacker
14.15
KB
-rwxr-xr-x
create-cracklib-dict
990
B
-rwxr-xr-x
cron
50.58
KB
-rwxr-xr-x
ctrlaltdel
14.38
KB
-rwxr-xr-x
dcb
80.52
KB
-rwxr-xr-x
ddns-confgen
26.3
KB
-rwxr-xr-x
debugfs
229.8
KB
-rwxr-xr-x
delgroup
16.11
KB
-rwxr-xr-x
deluser
16.11
KB
-rwxr-xr-x
depmod
166.36
KB
-rwxr-xr-x
devlink
142.86
KB
-rwxr-xr-x
dhclient
442.66
KB
-rwxr-xr-x
dhclient-script
15.92
KB
-rwxr-xr-x
dmidecode
122.98
KB
-rwxr-xr-x
dmsetup
171.02
KB
-rwxr-xr-x
dmstats
171.02
KB
-rwxr-xr-x
dosfsck
82.38
KB
-rwxr-xr-x
dosfslabel
38.38
KB
-rwxr-xr-x
dovecot
98.43
KB
-rwxr-xr-x
dovecot_cpshutdown
3.27
KB
-rwxr-xr-x
dpkg-preconfigure
3.58
KB
-rwxr-xr-x
dpkg-reconfigure
4.38
KB
-rwxr-xr-x
dumpe2fs
30.31
KB
-rwxr-xr-x
e2freefrag
14.3
KB
-rwxr-xr-x
e2fsck
351.84
KB
-rwxr-xr-x
e2image
42.31
KB
-rwxr-xr-x
e2label
102.55
KB
-rwxr-xr-x
e2mmpstatus
30.31
KB
-rwxr-xr-x
e2scrub
7.13
KB
-rwxr-xr-x
e2scrub_all
5.27
KB
-rwxr-xr-x
e2undo
22.3
KB
-rwxr-xr-x
e4crypt
30.38
KB
-rwxr-xr-x
e4defrag
30.3
KB
-rwxr-xr-x
ebtables
219.04
KB
-rwxr-xr-x
ebtables-nft
219.04
KB
-rwxr-xr-x
ebtables-nft-restore
219.04
KB
-rwxr-xr-x
ebtables-nft-save
219.04
KB
-rwxr-xr-x
ebtables-restore
219.04
KB
-rwxr-xr-x
ebtables-save
219.04
KB
-rwxr-xr-x
edquota
83.31
KB
-rwxr-xr-x
escapesrc
22.45
KB
-rwxr-xr-x
exicyclog
11.1
KB
-rwxr-xr-x
exigrep
10.52
KB
-rwxr-xr-x
exim
1.69
MB
-rwsr-xr-x
exim_checkaccess
4.83
KB
-rwxr-xr-x
exim_dbmbuild
18.3
KB
-rwxr-xr-x
exim_dumpdb
18.3
KB
-rwxr-xr-x
exim_fixdb
30.3
KB
-rwxr-xr-x
exim_lock
18.3
KB
-rwxr-xr-x
exim_tidydb
18.3
KB
-rwxr-xr-x
eximstats
148.26
KB
-rwxr-xr-x
exinext
7.14
KB
-rwxr-xr-x
exiqgrep
5.66
KB
-rwxr-xr-x
exiqsumm
5.32
KB
-rwxr-xr-x
exiwhat
4.42
KB
-rwxr-xr-x
faillock
14.15
KB
-rwxr-xr-x
fatlabel
38.38
KB
-rwxr-xr-x
fcgistarter
14.15
KB
-rwxr-xr-x
fdisk
110.42
KB
-rwxr-xr-x
filefrag
18.32
KB
-rwxr-xr-x
findfs
14.38
KB
-rwxr-xr-x
fsck
42.42
KB
-rwxr-xr-x
fsck.cramfs
30.44
KB
-rwxr-xr-x
fsck.ext2
351.84
KB
-rwxr-xr-x
fsck.ext3
351.84
KB
-rwxr-xr-x
fsck.ext4
351.84
KB
-rwxr-xr-x
fsck.fat
82.38
KB
-rwxr-xr-x
fsck.minix
54.41
KB
-rwxr-xr-x
fsck.msdos
82.38
KB
-rwxr-xr-x
fsck.vfat
82.38
KB
-rwxr-xr-x
fsfreeze
14.38
KB
-rwxr-xr-x
fstab-decode
18.3
KB
-rwxr-xr-x
fstrim
42.38
KB
-rwxr-xr-x
genccode
14.73
KB
-rwxr-xr-x
gencmn
14.73
KB
-rwxr-xr-x
genl
90.44
KB
-rwxr-xr-x
gennorm2
62.9
KB
-rwxr-xr-x
gensprep
26.8
KB
-rwxr-xr-x
getcap
14.3
KB
-rwxr-xr-x
getpcaps
14.3
KB
-rwxr-xr-x
getty
55.56
KB
-rwxr-xr-x
groupadd
66.91
KB
-rwxr-xr-x
groupdel
62.73
KB
-rwxr-xr-x
groupmems
54.19
KB
-rwxr-xr-x
groupmod
66.82
KB
-rwxr-xr-x
grpck
58.13
KB
-rwxr-xr-x
grpconv
50.01
KB
-rwxr-xr-x
grpunconv
50.01
KB
-rwxr-xr-x
grub-bios-setup
941.42
KB
-rwxr-xr-x
grub-install
1.15
MB
-rwxr-xr-x
grub-macbless
929.11
KB
-rwxr-xr-x
grub-mkconfig
8.6
KB
-rwxr-xr-x
grub-mkdevicemap
215.7
KB
-rwxr-xr-x
grub-probe
941.36
KB
-rwxr-xr-x
grub-reboot
4.73
KB
-rwxr-xr-x
grub-set-default
3.47
KB
-rwxr-xr-x
halt
1.06
MB
-rwxr-xr-x
hdparm
139.43
KB
-rwxr-xr-x
htcacheclean
38.16
KB
-rwxr-xr-x
httpd
687.55
KB
-rwxr-xr-x
hwclock
50.5
KB
-rwxr-xr-x
iconvconfig
30.4
KB
-rwxr-xr-x
icupkg
23.1
KB
-rwxr-xr-x
ifconfig
77.17
KB
-rwxr-xr-x
imunify-notifier
9.02
MB
-rwxr-xr-x
init
1.76
MB
-rwxr-xr-x
insmod
166.36
KB
-rwxr-xr-x
installkernel
2.6
KB
-rwxr-xr-x
invoke-rc.d
16.12
KB
-rwxr-xr-x
ip
702.05
KB
-rwxr-xr-x
ip6tables
219.04
KB
-rwxr-xr-x
ip6tables-apply
6.89
KB
-rwxr-xr-x
ip6tables-legacy
96.95
KB
-rwxr-xr-x
ip6tables-legacy-restore
96.95
KB
-rwxr-xr-x
ip6tables-legacy-save
96.95
KB
-rwxr-xr-x
ip6tables-nft
219.04
KB
-rwxr-xr-x
ip6tables-nft-restore
219.04
KB
-rwxr-xr-x
ip6tables-nft-save
219.04
KB
-rwxr-xr-x
ip6tables-restore
219.04
KB
-rwxr-xr-x
ip6tables-restore-translate
219.04
KB
-rwxr-xr-x
ip6tables-save
219.04
KB
-rwxr-xr-x
ip6tables-translate
219.04
KB
-rwxr-xr-x
ipmaddr
18.3
KB
-rwxr-xr-x
iptables
219.04
KB
-rwxr-xr-x
iptables-apply
6.89
KB
-rwxr-xr-x
iptables-legacy
96.95
KB
-rwxr-xr-x
iptables-legacy-restore
96.95
KB
-rwxr-xr-x
iptables-legacy-save
96.95
KB
-rwxr-xr-x
iptables-nft
219.04
KB
-rwxr-xr-x
iptables-nft-restore
219.04
KB
-rwxr-xr-x
iptables-nft-save
219.04
KB
-rwxr-xr-x
iptables-restore
219.04
KB
-rwxr-xr-x
iptables-restore-translate
219.04
KB
-rwxr-xr-x
iptables-save
219.04
KB
-rwxr-xr-x
iptables-translate
219.04
KB
-rwxr-xr-x
iptunnel
18.3
KB
-rwxr-xr-x
irqbalance
66.86
KB
-rwxr-xr-x
irqbalance-ui
34.38
KB
-rwxr-xr-x
isosize
14.38
KB
-rwxr-xr-x
ispell-autobuildhash
15.56
KB
-rwxr-xr-x
iucode-tool
58.34
KB
-rwxr-xr-x
iucode_tool
58.34
KB
-rwxr-xr-x
iw
279.28
KB
-rwxr-xr-x
kbdrate
18.16
KB
-rwxr-xr-x
key.dns_resolver
30.39
KB
-rwxr-xr-x
killall5
30.38
KB
-rwxr-xr-x
lchage
22.3
KB
-rwxr-xr-x
ldattach
26.38
KB
-rwxr-xr-x
ldconfig
387
B
-rwxr-xr-x
ldconfig.real
1.16
MB
-rwxr-xr-x
lgroupadd
14.3
KB
-rwxr-xr-x
lgroupdel
14.3
KB
-rwxr-xr-x
lgroupmod
22.3
KB
-rwxr-xr-x
libuser-lid
18.3
KB
-rwxr-xr-x
lnewusers
22.3
KB
-rwxr-xr-x
locale-gen
4.29
KB
-rwxr-xr-x
logrotate
102.24
KB
-rwxr-xr-x
logsave
14.16
KB
-rwxr-xr-x
losetup
70.52
KB
-rwxr-xr-x
lpasswd
22.3
KB
-rwxr-xr-x
lsmod
166.36
KB
-rwxr-xr-x
luseradd
22.3
KB
-rwxr-xr-x
luserdel
14.3
KB
-rwxr-xr-x
lusermod
22.3
KB
-rwxr-xr-x
make-ssl-cert
6.65
KB
-rwxr-xr-x
mii-tool
26.73
KB
-rwxr-xr-x
mkdosfs
50.83
KB
-rwxr-xr-x
mke2fs
130.62
KB
-rwxr-xr-x
mkfs
14.38
KB
-rwxr-xr-x
mkfs.bfs
22.38
KB
-rwxr-xr-x
mkfs.cramfs
34.32
KB
-rwxr-xr-x
mkfs.ext2
130.62
KB
-rwxr-xr-x
mkfs.ext3
130.62
KB
-rwxr-xr-x
mkfs.ext4
130.62
KB
-rwxr-xr-x
mkfs.fat
50.83
KB
-rwxr-xr-x
mkfs.minix
42.39
KB
-rwxr-xr-x
mkfs.msdos
50.83
KB
-rwxr-xr-x
mkfs.ntfs
70.38
KB
-rwxr-xr-x
mkfs.vfat
50.83
KB
-rwxr-xr-x
mkhomedir_helper
22.17
KB
-rwxr-xr-x
mkinitramfs
12.16
KB
-rwxr-xr-x
mklost+found
14.3
KB
-rwxr-xr-x
mkntfs
70.38
KB
-rwxr-xr-x
mkswap
46.38
KB
-rwxr-xr-x
modinfo
166.36
KB
-rwxr-xr-x
modprobe
166.36
KB
-rwxr-xr-x
modsec-sdbm-util
22.15
KB
-rwxr-x---
mount.fuse
18.3
KB
-rwxr-xr-x
mount.fuse3
18.3
KB
-rwxr-xr-x
mount.lowntfs-3g
114.98
KB
-rwxr-xr-x
mount.nfs
98.68
KB
-rwsr-xr-x
mount.nfs4
98.68
KB
-rwsr-xr-x
mount.ntfs
159.01
KB
-rwxr-xr-x
mount.ntfs-3g
159.01
KB
-rwxr-xr-x
mountstats
42.28
KB
-rwxr-xr-x
mysqld
58.58
MB
-rwxr-xr-x
named
565.61
KB
-rwxr-xr-x
nameif
14.48
KB
-rwxr-xr-x
needrestart
38.71
KB
-rwxr-xr-x
netfilter-persistent
1.04
KB
-rwxr-xr-x
netplan
798
B
-rwxr-xr-x
newusers
74.73
KB
-rwxr-xr-x
nfnl_osf
18.3
KB
-rwxr-xr-x
nfsconf
38.67
KB
-rwxr-xr-x
nfsidmap
22.31
KB
-rwxr-xr-x
nfsiostat
24.41
KB
-rwxr-xr-x
nfsstat
37.29
KB
-rwxr-xr-x
nft
26.23
KB
-rwxr-xr-x
nologin
14.3
KB
-rwxr-xr-x
nscd
164.34
KB
-rwxr-xr-x
ntfsclone
50.38
KB
-rwxr-xr-x
ntfscp
34.38
KB
-rwxr-xr-x
ntfslabel
22.38
KB
-rwxr-xr-x
ntfsresize
62.39
KB
-rwxr-xr-x
ntfsundelete
50.38
KB
-rwxr-xr-x
on_ac_power
2.18
KB
-rwxr-xr-x
ownership
14.45
KB
-rwxr-xr-x
pam-auth-update
20.5
KB
-rwxr-xr-x
pam_extrausers_chkpwd
22.15
KB
-rwxr-sr-x
pam_extrausers_update
30.15
KB
-rwxr-xr-x
pam_getenv
2.82
KB
-rwxr-xr-x
pam_timestamp_check
14.15
KB
-rwxr-xr-x
paperconfig
4.07
KB
-rwxr-xr-x
parted
86.4
KB
-rwxr-xr-x
partprobe
14.38
KB
-rwxr-xr-x
pdns_server
70.99
MB
-rwxr-xr-x
pivot_root
14.38
KB
-rwxr-xr-x
plipconfig
14.3
KB
-rwxr-xr-x
plymouthd
150.55
KB
-rwxr-xr-x
popcon-largest-unused
543
B
-rwxr-xr-x
popularity-contest
5.49
KB
-rwxr-xr-x
poweroff
1.06
MB
-rwxr-xr-x
pwck
50.13
KB
-rwxr-xr-x
pwconv
46.01
KB
-rwxr-xr-x
pwunconv
42.01
KB
-rwxr-xr-x
quota_nld
26.41
KB
-rwxr-xr-x
quotacheck
91.34
KB
-rwxr-xr-x
quotaoff
54.78
KB
-rwxr-xr-x
quotaon
54.78
KB
-rwxr-xr-x
quotastats
14.15
KB
-rwxr-xr-x
rarp
32.33
KB
-rwxr-xr-x
rdate
18.15
KB
-rwxr-xr-x
readprofile
22.41
KB
-rwxr-xr-x
reboot
1.06
MB
-rwxr-xr-x
remove-default-ispell
2.86
KB
-rwxr-xr-x
remove-default-wordlist
2.86
KB
-rwxr-xr-x
remove-shell
1.07
KB
-rwxr-xr-x
repquota
71.41
KB
-rwxr-xr-x
request-key
26.31
KB
-rwxr-xr-x
resize2fs
66.3
KB
-rwxr-xr-x
rmmod
166.36
KB
-rwxr-xr-x
rmt
58.57
KB
-rwxr-xr-x
rmt-tar
58.57
KB
-rwxr-xr-x
rndc
42.3
KB
-rwxr-xr-x
rndc-confgen
22.3
KB
-rwxr-xr-x
rotatelogs
26.23
KB
-rwxr-xr-x
route
64.27
KB
-rwxr-xr-x
rpc.gssd
86.5
KB
-rwxr-xr-x
rpc.idmapd
46.48
KB
-rwxr-xr-x
rpc.rquotad
75.18
KB
-rwxr-xr-x
rpc.statd
79.05
KB
-rwxr-xr-x
rpc.svcgssd
46.4
KB
-rwxr-xr-x
rpcbind
62.41
KB
-rwxr-xr-x
rpcdebug
18.38
KB
-rwxr-xr-x
rpcinfo
34.48
KB
-rwxr-xr-x
rsyslogd
767.19
KB
-rwxr-xr-x
rtacct
28.31
KB
-rwxr-xr-x
rtcwake
34.38
KB
-rwxr-xr-x
rtmon
90.39
KB
-rwxr-xr-x
runlevel
1.06
MB
-rwxr-xr-x
runq
1.69
MB
-rwsr-xr-x
runuser
54.38
KB
-rwxr-xr-x
safe_finger
14.34
KB
-rwxr-xr-x
select-default-ispell
3.23
KB
-rwxr-xr-x
select-default-wordlist
3.21
KB
-rwxr-xr-x
sendmail
14.15
KB
-rwxr-sr-x
service
8.88
KB
-rwxr-xr-x
setcap
14.3
KB
-rwxr-xr-x
setquota
79.38
KB
-rwxr-xr-x
setvesablank
14.23
KB
-rwxr-xr-x
setvtrgb
14.29
KB
-rwxr-xr-x
sfdisk
102.38
KB
-rwxr-xr-x
shadowconfig
885
B
-rwxr-xr-x
showmount
14.57
KB
-rwxr-xr-x
shutdown
1.06
MB
-rwxr-xr-x
slattach
36.08
KB
-rwxr-xr-x
sm-notify
50.48
KB
-rwxr-xr-x
smartctl
827.65
KB
-rwxr-xr-x
smartd
587.16
KB
-rwxr-xr-x
sshd
899.7
KB
-rwxr-xr-x
start-statd
1023
B
-rwxr-xr-x
start-stop-daemon
47.35
KB
-rwxr-xr-x
sudo_logsrvd
200.1
KB
-rwxr-xr-x
sudo_sendlog
107.34
KB
-rwxr-xr-x
suexec
26.23
KB
-rwsr-xr-x
sulogin
42.38
KB
-rwxr-xr-x
suphp
158.41
KB
-rwsr-x---
sw-engine-fpm
18.43
MB
-rwxr-xr-x
swaplabel
18.38
KB
-rwxr-xr-x
swapoff
22.38
KB
-rwxr-xr-x
swapon
42.38
KB
-rwxr-xr-x
switch_root
22.38
KB
-rwxr-xr-x
sync-available
1.42
KB
-rwxr-xr-x
sysctl
30.23
KB
-rwxr-xr-x
tarcat
936
B
-rwxr-xr-x
tc
614.08
KB
-rwxr-xr-x
tcpd
14.3
KB
-rwxr-xr-x
tcpdchk
30.41
KB
-rwxr-xr-x
tcpdmatch
22.31
KB
-rwxr-xr-x
telinit
1.06
MB
-rwxr-xr-x
tipc
90.44
KB
-rwxr-xr-x
try-from
14.3
KB
-rwxr-xr-x
tsig-keygen
26.3
KB
-rwxr-xr-x
tune2fs
102.55
KB
-rwxr-xr-x
tzconfig
106
B
-rwxr-xr-x
ufw
4.82
KB
-rwxr-xr-x
umount.nfs
98.68
KB
-rwsr-xr-x
umount.nfs4
98.68
KB
-rwsr-xr-x
unix_chkpwd
26.15
KB
-rwxr-sr-x
unix_update
30.15
KB
-rwxr-xr-x
update-ca-certificates
5.29
KB
-rwxr-xr-x
update-cracklib
1.15
KB
-rwxr-xr-x
update-default-aspell
1
KB
-rwxr-xr-x
update-default-ispell
9.68
KB
-rwxr-xr-x
update-default-wordlist
7.5
KB
-rwxr-xr-x
update-dictcommon-aspell
1
KB
-rwxr-xr-x
update-dictcommon-hunspell
782
B
-rwxr-xr-x
update-grub
64
B
-rwxr-xr-x
update-grub-gfxpayload
301
B
-rwxr-xr-x
update-grub2
64
B
-rwxr-xr-x
update-gsfontmap
470
B
-rwxr-xr-x
update-info-dir
1.66
KB
-rwxr-xr-x
update-initramfs
6.74
KB
-rwxr-xr-x
update-locale
2.99
KB
-rwxr-xr-x
update-mime
9.39
KB
-rwxr-xr-x
update-passwd
34.56
KB
-rwxr-xr-x
update-pciids
1.71
KB
-rwxr-xr-x
update-rc.d
16.92
KB
-rwxr-xr-x
update-shells
3.72
KB
-rwxr-xr-x
update-smart-drivedb
23.35
KB
-rwxr-xr-x
upgrade-from-grub-legacy
1.56
KB
-rwxr-xr-x
useradd
127.66
KB
-rwxr-xr-x
userdel
86.85
KB
-rwxr-xr-x
usermod
123.46
KB
-rwxr-xr-x
uuidd
30.85
KB
-rwxr-xr-x
validlocale
1.73
KB
-rwxr-xr-x
vcstime
14.15
KB
-rwxr-xr-x
vdpa
30.56
KB
-rwxr-xr-x
vigr
56.53
KB
-rwxr-xr-x
vipw
56.53
KB
-rwxr-xr-x
visudo
219.79
KB
-rwxr-xr-x
vpddecode
14.58
KB
-rwxr-xr-x
warnquota
87.3
KB
-rwxr-xr-x
whmapi0
3.16
MB
-rwxr-xr-x
whmapi1
3.16
MB
-rwxr-xr-x
whmlogin
2.33
KB
-rwxr-xr-x
wipefs
38.38
KB
-rwxr-xr-x
xqmstats
14.15
KB
-rwxr-xr-x
xtables-legacy-multi
96.95
KB
-rwxr-xr-x
xtables-monitor
219.04
KB
-rwxr-xr-x
xtables-nft-multi
219.04
KB
-rwxr-xr-x
zic
62.32
KB
-rwxr-xr-x
zramctl
54.52
KB
-rwxr-xr-x
Delete
Unzip
Zip
${this.title}
Close
Code Editor : checkrestart
#!/usr/bin/python3 # Copyright (C) 2001 Matt Zimmerman <mdz@debian.org> # Copyright (C) 2007,2010-2015 Javier Fernandez-Sanguino <jfs@debian.org> # - included patch from Justin Pryzby <justinpryzby_AT_users.sourceforge.net> # to work with the latest Lsof - modify to reduce false positives by not # complaining about deleted inodes/files under /tmp/, /var/log/, # /var/run or named /SYSV. # - introduced a verbose option # PENDING: # - included code from 'psdel' contributed by Sam Morris <sam_AT_robots.org.uk> to # make the program work even if lsof is not installed # (available at https://robots.org.uk/src/psdel) # - make it work with a whitelist of directories instead of a blacklist # (might make it less false positive prone) # # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2, or (at your option) # any later version. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, # MA 02110-1301 USA # # On Debian systems, a copy of the GNU General Public License may be # found in /usr/share/common-licenses/GPL. import sys import os, errno import re import pwd import sys import string import subprocess import getopt from stat import * def checkroot(): if os.getuid() != 0: sys.stderr.write('ERROR: This program must be run as root in order to obtain information\n') sys.stderr.write('about all open file descriptors in the system.\n') sys.exit(1) def find_cmd(cmd): dirs = [ '/', '/usr/', '/usr/local/', sys.prefix ] for d in dirs: for sd in ('bin', 'sbin'): location = os.path.join(d, sd, cmd) if os.path.exists(location): return location return False def checksystemd(): # Check if systemd is installed in the system if os.path.exists('/bin/systemd'): return 0 return 1 def usage(): sys.stderr.write('usage: checkrestart [-vhpam] [ -b blacklist_file ] [ -i package_name ] [ -e pid ]\n') def main(): global lc_all_c_env, file_query_check process = None toRestart = {} lc_all_c_env = os.environ lc_all_c_env['LC_ALL'] = 'C' file_query_check = {} is_systemd = False useLsof = True blacklistFiles = [] blacklist = [] ignorelist = [ 'screen', 'systemd', 'dbus' ] excludepidlist = [] # Process options try: opts, args = getopt.getopt(sys.argv[1:], "hvpamb:i:ne:t", ["help", "verbose", "packages", "all", "machine", "blacklist", "ignore", "nolsof", "excludepid", "terse"]) except getopt.GetoptError as err: # print help information and exit: print(err) # will print something like "option -x not recognized" usage() sys.exit(2) # Global variables set through the command line global verbose, onlyPackageFiles, allFiles verbose = False # Only look for deleted files that belong to packages onlyPackageFiles = False # Look for any deleted file allFiles = False # Generate terse output, disabled by default terseOutput = False # Generate machine parsable output, disabled by default machineOutput = False for o, a in opts: if o in ("-v", "--verbose"): verbose = True elif o in ("-h", "--help"): usage() sys.exit() elif o in ("-p", "--packages"): onlyPackageFiles = True elif o in ("-a", "--all"): allFiles = True onlyPackageFiles = False elif o in ("-e", "--excludepid"): excludepidlist.append(a) elif o in ("-m", "--machine"): machineOutput = True elif o in ("-b", "--blacklist"): blacklistFiles.append(a) onlyPackageFiles = False elif o in ("-i", "--ignore"): ignorelist.append(a) elif o in ("-n", "--nolsof"): useLsof = False elif o in ("-t", "--terse"): terseOutput = True else: assert False, "unhandled option" checkroot() for f in blacklistFiles: blacklistFile = open(f, 'r') for line in blacklistFile.readlines(): if line.startswith("#"): continue blacklist.append(re.compile(line.strip())) blacklistFile.close() # Start checking if checksystemd() == 0: is_systemd = True # if find_cmd('lsof') == 1: # sys.stderr.write('ERROR: This program needs lsof in order to run.\n') # sys.stderr.write('Please install the lsof package in your system.\n') # sys.exit(1) # Check if we have lsof, if not, use an alternative mechanism if not find_cmd('lsof') or not useLsof: if verbose and not find_cmd('lsof'): print("[DEBUG] Lsof is not available in the system. Using alternative mechanism.") toRestart = procfilescheck(blacklist = blacklist, excludepidlist = excludepidlist) else: toRestart = lsoffilescheck(blacklist = blacklist) if terseOutput: # Terse output and exit # Use Nagios exit codes: 0 OK, 1 warning, 2 critical, 3 unknown # we only care for 0 or 1 if len(toRestart): print("%d processes using old versions of upgraded files" % len(toRestart)) sys.exit(1) # Exit with no error if there is nothing to restart print("No processes found using old versions of upgraded files") sys.exit(0) if not machineOutput: print("Found %d processes using old versions of upgraded files" % len(toRestart)) else: print("PROCESSES: %d" % len(toRestart)) if len(toRestart) == 0: sys.exit(0) programs = {} for process in toRestart: programs.setdefault(process.program, []) programs[process.program].append(process) if not machineOutput: if len(programs) == 1: print("(%d distinct program)" % len(programs)) else: print("(%d distinct programs)" % len(programs)) else: print("PROGRAMS: %d" % len(programs)) #services Verbose information if verbose: for process in toRestart: if not machineOutput: print("[DEBUG] Process %s (PID: %d) " % (process.program, process.pid)) process.listDeleted() else: process.listDeletedMachine() packages = {} diverted = None dpkgQuery = ["dpkg-query", "--search"] + list(programs.keys()) if verbose: print("[DEBUG] Running: %s" % ' '.join(dpkgQuery)) dpkgProc = subprocess.Popen(dpkgQuery, shell=False, stdout=subprocess.PIPE, stderr=subprocess.PIPE, env = lc_all_c_env) while True: line = dpkgProc.stdout.readline().decode("utf-8") if not line: break if verbose: print("[DEBUG] Reading line from dpkg-query: %s" % line) if line.startswith('local diversion'): continue if not ':' in line: continue m = re.match('^diversion by (\S+) (from|to): (.*)$', line) if m: if m.group(2) == 'from': diverted = m.group(3) continue if not diverted: raise Exception('Weird error while handling diversion') packagename, program = m.group(1), diverted else: packagename, program = line[:-1].split(': ') if program == diverted: # dpkg prints a summary line after the diversion, name both # packages of the diversion, so ignore this line # mutt-patched, mutt: /usr/bin/mutt continue packages.setdefault(packagename,Package(packagename)) try: packages[packagename].processes.extend(programs[program]) if verbose: print("[DEBUG] Found package %s for program %s" % (packagename, program)) except KeyError: sys.stderr.write ('checkrestart (program not found): %s: %s\n' % (packagename, program)) sys.stdout.flush() # Close the pipe dpkgProc.stdout.close() # Remove the ignored packages from the list of packages if ignorelist: for i in ignorelist: if i in packages: if verbose: print("[DEBUG] Removing %s from the package list (ignored)" % (i)) try: del packages[i] except KeyError: continue if not machineOutput: print("(%d distinct packages)" % len(packages)) else: print("PACKAGES: %d" % len(packages)) if len(packages) == 0: if not machineOutput: print("No packages seem to need to be restarted.") print("(please read checkrestart(8))") sys.exit(0) for package in list(packages.values()): dpkgQuery = ["dpkg-query", "--listfiles", package.name] if verbose: print("[DEBUG] Running: %s" % ' '.join(dpkgQuery)) dpkgProc = subprocess.Popen(dpkgQuery, stdout=subprocess.PIPE, stderr=subprocess.STDOUT, env = lc_all_c_env) while True: line = dpkgProc.stdout.readline().decode("utf-8") if not line: break path = line[:-1] if path.startswith('/etc/init.d/'): if path.endswith('.sh'): continue package.initscripts.add(path[12:]) # If running on a systemd system, extract the systemd's service files from the package if is_systemd and path.startswith('/lib/systemd/system/') and path.endswith('.service') and path.find('.wants') == -1: if path.endswith('@.service'): continue # Read the service file and make sure it is not of type 'oneshot' servicefile = open (path) is_oneshot = False for line in servicefile.readlines(): if line.find ('Type=oneshot') > 0: is_oneshot = True continue servicefile.close () if not is_oneshot: package.systemdservice.add(path[20:]) sys.stdout.flush() dpkgProc.stdout.close() # Alternatively, find init.d scripts that match the process name if len(package.initscripts) == 0 and len(package.systemdservice) == 0: for process in package.processes: proc_name = os.path.basename(process.program) if os.path.exists('/etc/init.d/' + proc_name): package.initscripts.add(proc_name) restartable = [] nonrestartable = [] restartInitCommands = [] restartServiceCommands = [] for package in list(packages.values()): if len(package.initscripts) > 0: restartable.append(package) restartInitCommands.extend(['service ' + s + ' restart' for s in package.initscripts]) elif len(package.systemdservice) > 0: restartable.append(package) restartServiceCommands.extend(['systemctl restart ' + s for s in package.systemdservice]) else: nonrestartable.append(package) if len(restartable) > 0: if not machineOutput: print() print("Of these, %d seem to contain systemd service definitions or init scripts which can be used to restart them." % len(restartable)) # TODO - consider putting this in a --verbose option print("The following packages seem to have definitions that could be used\nto restart their services:") for package in restartable: print(package.name + ':') for process in package.processes: print("\t%s\t%s" % (process.pid,process.program)) if len(restartServiceCommands)>0: print() print("These are the systemd services:") print('\n'.join(restartServiceCommands)) print() if len(restartInitCommands)>0: print("These are the initd scripts:") print('\n'.join(restartInitCommands)) print() else: for package in restartable: for process in package.processes: print('SERVICE:%s,%s,%s' % (package.name, process.pid,process.program)) if len(nonrestartable) == 0: sys.exit(0) # TODO - consider putting this in a --verbose option if not machineOutput: print("These processes (%d) do not seem to have an associated init script to restart them:" %len(nonrestartable)) for package in nonrestartable: if not machineOutput: print(package.name + ':') for process in package.processes: print("\t%s\t%s" % (process.pid,process.program)) else: for process in package.processes: print('OTHER:%s,%s,%s' % (package.name,process.pid,process.program)) def lsoffilescheck(blacklist = None): # Use LSOF to extract the list of deleted files from subprocess import check_output processes = {} for line in check_output(['lsof', '+XL', '-F', 'nf']).decode(errors="ignore").splitlines(): field, data = line[0], line[1:] if field == 'p': process = processes.setdefault(data,Process(int(data))) elif field == 'k': process.links.append(data) elif field == 'n': # Remove the previous entry to check if this is something we should use if data.find('SYSV') >= 0: # If we find SYSV we discard the previous descriptor last = process.descriptors.pop() elif data.startswith('/') or data.startswith('(deleted)/') or data.startswith(' (deleted)/'): last = process.descriptors.pop() # If the data starts with (deleted) put it in the end of the # file name, this is used to workaround different behaviour in # OpenVZ systems, see # https://bugzilla.openvz.org/show_bug.cgi?id=2932 if data.startswith('(deleted)'): data = data[9:] + ' (deleted)' elif data.startswith(' (deleted)'): data = data[10:] + ' (deleted)' # Add it to the list of deleted files if the previous descriptor # was DEL or lsof marks it as deleted if re.compile("DEL").search(last) or re.compile("\(deleted\)").search(data) or re.compile("\(path inode=[0-9]+\)$").search(data): process.files.append(data) else: # We discard the previous descriptors and drop it last = process.descriptors.pop() elif field == 'f': # Save the descriptor for later comparison process.descriptors.append(data) toRestart = [process for process in list(processes.values()) if process.needsRestart(blacklist)] return toRestart def procfilescheck(blacklist = None, excludepidlist = None): # Use the underlying /proc file system to determine processes that # are using deleted files from subprocess import check_output processes = {} # Get a list of running processes pids = [pid for pid in os.listdir('/proc') if pid.isdigit()] for pid in pids: if pid in excludepidlist: continue # Get the list of open files for this process from /proc # We can ignore failures over this block as links will # disappear as we run them foundfiles = [] try: for fd in os.listdir('/proc/' + pid + '/fd'): if os.path.islink('/proc/' + pid + '/fd/' + fd): fname = os.readlink('/proc/' + pid + '/fd/' + fd) if re.compile("\s\(deleted\)$").search(fname): foundfiles.append(fname) except: continue # Get the list of memory mapped files using system pmap for output in check_output(['pmap', pid]).decode(errors="ignore").splitlines(): data = re.split('\s+', output.strip('\n'), 3) if len(data) == 4: f = data[3] if re.compile("\s\(deleted\)$").search(f): foundfiles.append(f) if len(foundfiles) > 1: process = processes.setdefault(pid,Process(int(pid))) # print pid + ': ' + ', '.join(foundfiles) process.files = foundfiles toRestart = [process for process in list(processes.values()) if process.needsRestart(blacklist)] return toRestart # Tells if a given file is part of a package # Returns: # - False - file does not exist in the system or cannot be found when querying the package database # - True - file is found in an operating system package def ispackagedFile (f): file_in_package = False file_regexp = False if verbose: print("[DEBUG] Checking if file %s belongs to any package" % f) # First check if the file exists if not os.path.exists(f): if ( f.startswith('/lib/') or f.startswith('/usr/lib/') ) and re.compile("\.so[\d.]+$"): # For libraries that do not exist then try to use a regular expression with the # soname # In libraries, indent characters that could belong to a regular expression first f = re.compile("\+").sub("\+", f) f = re.compile(".so[\d.]+$").sub(".so.*", f) f = re.compile("\.").sub("\.", f) file_regexp = True else: # Do not call dpkg-query if the file simply does not exist in the file system # just assume it does not belong to any package return False # If it exists, run dpkg-query dpkgQuery = ["dpkg-query", "--search", f ] if verbose: print("[DEBUG] Running: %s" % ' '.join(dpkgQuery)) dpkgProc = subprocess.Popen(dpkgQuery, stdout=subprocess.PIPE, stderr=subprocess.STDOUT, env = lc_all_c_env, close_fds=True, universal_newlines=True) dpkgProc.wait() if verbose: print("[DEBUG] Running: %s" % ' '.join(dpkgQuery)) for line in dpkgProc.stdout.readlines(): line = line.strip() if line.find('no path found matching pattern ' + f) > 0: file_in_package = False break if line.endswith(f) or ( file_regexp and re.search(f, line)): package = re.compile(":.*$").sub("",line) file_in_package = True break if file_in_package and verbose: print("[DEBUG] YES: File belongs to package %s" % package) if not file_in_package and verbose: print("[DEBUG] NO: File does not belongs to any package") return file_in_package # Tells if a file has to be considered a deleted file # Returns: # - 0 (NO) for known locations of files which might be deleted # - 1 (YES) for valid deleted files we are interested in def isdeletedFile (f, blacklist = None): global lc_all_c_env, file_query_check if allFiles: return 1 if blacklist: for p in blacklist: if p.search(f): return 0 # We don't care about log files if f.startswith('/var/log/') or f.startswith('/var/local/log/'): return 0 # Or about files under temporary locations if f.startswith('/var/run/') or f.startswith('/var/local/run/'): return 0 # Or about files under /tmp if f.startswith('/tmp/'): return 0 # Or about files under /dev if f.startswith('/dev/'): return 0 # Or about files under /run if f.startswith('/run/'): return 0 # Or about files under /drm if f.startswith('/drm'): return 0 # Or about files under /i915 if f.startswith('/i915'): return 0 # Or about files under /var/tmp and /var/local/tmp if f.startswith('/var/tmp/') or f.startswith('/var/local/tmp/'): return 0 # Or /usr/lib/locale if f.startswith('/usr/lib/locale/'): return 0 # Skip files from the user's home directories # many processes hold temporary files there if f.startswith('/home/'): return 0 # Skip automatically generated files if f.endswith('icon-theme.cache'): return 0 # Skip font files if f.startswith('/var/cache/fontconfig/'): return 0 # Skip Nagios Spool if f.startswith('/var/lib/nagios3/spool/'): return 0 # Skip nagios spool files if f.startswith('/var/lib/nagios3/spool/checkresults/'): return 0 # Skip PostgreSQL files if f.startswith('/var/lib/postgresql/'): return 0 # Skip VDR lib files if f.startswith('/var/lib/vdr/'): return 0 # Skip Aio files found in MySQL servers if f.startswith('/[aio]'): return 0 # Skip memfd files if f.startswith('/memfd:'): return 0 # Skip dovecot mail indexes if f.endswith('/dovecot.index (deleted)') or f.endswith('/dovecot.index'): return 0 # Skip sssd cache if f.startswith('/var/lib/sss/mc/'): return 0 # Skip, if asked to, files that do not belong to any package if onlyPackageFiles: # Remove some lsof information from the file to ensure that it is # a proper filename file_name = re.sub(r'\(.*\)','', f) file_name = re.sub(r'\s+$','', file_name) # First check: have we checked this file before? If we have not then make the check if not file_name in file_query_check: file_query_check[file_name] = ispackagedFile(file_name) # Once we have the result then check if the file belongs to a package if not file_query_check[file_name]: return 0 # TODO: it should only care about library files (i.e. /lib, /usr/lib and the like) # build that check with a regexp to exclude others if f.endswith(' (deleted)'): return 1 if re.compile("\(path inode=[0-9]+\)$").search(f): return 1 # Default: it is a deleted file we are interested in return 1 def psdelcheck(): # TODO - Needs to be fixed to work here # Useful for seeing which processes need to be restarted after you upgrade # programs or shared libraries. Written to replace checkrestart(8) from the # debian-goodies, which often misses out processes due to bugs in lsof; see # <https://bugs.debian.org/264985> for more information. numeric = re.compile(r'\d+') toRestart = list(map (delmaps, list(map (string.atoi, list(filter (numeric.match, os.listdir('/proc'))))))) return toRestart def delmaps (pid): processes = {} process = processes.setdefault(pid,Process(int(pid))) deleted = re.compile(r'(.*) \(deleted\)$') boring = re.compile(r'/(dev/zero|SYSV([\da-f]{8}))|/usr/lib/locale') mapline = re.compile(r'^[\da-f]{8}-[\da-f]{8} [r-][w-][x-][sp-] ' r'[\da-f]{8} [\da-f]{2}:[\da-f]{2} (\d+) *(.+)( \(deleted\))?\n$') maps = open('/proc/%d/maps' % (pid)) for line in maps.readlines (): m = mapline.match (line) if (m): inode = string.atoi (m.group (1)) file = m.group (2) if inode == 0: continue # remove ' (deleted)' suffix if deleted.match (file): file = file [0:-10] if boring.match (file): continue # list file names whose inode numbers do not match their on-disk # values; or files that do not exist at all try: if os.stat (file)[stat.ST_INO] != inode: process = processes.setdefault(pid,Process(int(pid))) except OSError as e_tuple: (e, strerror) = e_tuple.args if e == errno.ENOENT: process = processes.setdefault(pid,Process(int(pid))) else: sys.stderr.write ('checkrestart (psdel): %s %s: %s\n' % (SysProcess.get(pid).info (), file, os.strerror (e))) else: print('checkrestart (psdel): Error parsing "%s"' % (line [0:-1])) maps.close () return process class SysProcess: re_name = re.compile('Name:\t(.*)$') re_uids = re.compile('Uid:\t(\d+)\t(\d+)\t(\d+)\t(\d+)$') processes = {} def get (pid): try: return Process.processes [pid] except KeyError: Process.processes [pid] = Process (pid) return Process.get (pid) # private def __init__ (self, pid): self.pid = pid status = open ('/proc/%d/status' % (self.pid)) for line in status.readlines (): m = self.re_name.match (line) if m: self.name = m.group (1) continue m = self.re_uids.match (line) if m: self.user = pwd.getpwuid (string.atoi (m.group (1)))[0] continue status.close () def info (self): return '%d %s %s' % (self.pid, self.name, self.user) class Process: def __init__(self, pid): self.pid = pid self.files = [] self.descriptors = [] self.links = [] self.program = '' try: self.program = os.readlink('/proc/%d/exe' % self.pid) # if the executable command is an interpreter such as perl/python/ruby/tclsh, # we want to find the real program m = re.match("^/usr/bin/(perl|python|ruby|tclsh)", self.program) if m: with open('/proc/%d/cmdline' % self.pid, 'r') as cmdline: # only match program in /usr (ex.: /usr/sbin/smokeping) # ignore child, etc. #m = re.search(r'^(([/]\w*){1,5})\s.*$', cmdline.read()) # Split by null-bytes, see proc(5) data = cmdline.read().split('\x00') # Last character should be null-byte, too, see proc(5) if not data[-1]: data.pop() # Spamd sets $0 wrongly, see # https://bugzilla.redhat.com/show_bug.cgi?id=755644 # i.e. the blank after spamd is relevant in case # this will be fixed in the future. m = re.match("^/usr/sbin/spamd |^spamd ", data[0]) if m: self.program = "/usr/sbin/spamd" else: # Strip first value, the interpreter data.pop(0) # Check if something's left after the interpreter, see #715000 if data: # Strip all options following the interpreter, e.g. python's -O m = re.match("^-", data[0]) while (m): data.pop(0) if not data: break m = re.match("^-", data[0]) if data and data[0]: data = self.which(data[0]) m = re.search(r'^(/usr/\S+)$', data) if m: # store the real full path of script as the program self.program = m.group(1) except OSError as e: if e.errno != errno.ENOENT: if self.pid == 1: sys.stderr.write("Found unreadable pid 1. Assuming we're under vserver and continuing.\n") else: sys.stderr.write('ERROR: Failed to read %d' % self.pid) raise self.program = self.cleanFile(self.program) def which(self, program): if os.path.isabs(program): return program path = os.environ.get("PATH", os.defpath).split(os.pathsep) seen = set() for dir in path: dir = os.path.normcase(os.path.abspath(dir)) if not dir in seen: seen.add(dir) name = os.path.join(dir, program) if os.path.exists(name) and os.access(name, os.F_OK|os.X_OK) and not os.path.isdir(name): return name return program def cleanFile(self, f): # /proc/pid/exe has all kinds of junk in it sometimes null = f.find('\0') if null != -1: f = f[:null] # Support symlinked /usr if f.startswith('/usr'): statinfo = os.lstat('/usr')[ST_MODE] # If /usr is a symlink then find where it points to if S_ISLNK(statinfo): newusr = os.readlink('/usr') if not newusr.startswith('/'): # If the symlink is relative, make it absolute newusr = os.path.join(os.path.dirname('/usr'), newusr) f = re.sub('^/usr',newusr, f) # print "Changing usr to " + newusr + " result:" +f; # Debugging return re.sub('( \(deleted\)|.dpkg-new).*$','',f) def listDeletedHelper(self): listfiles = [] listdescriptors = [] for f in self.files: if isdeletedFile(f): listfiles.append(f) return listfiles def listDeleted(self): listfiles = self.listDeletedHelper() if listfiles != []: print("List of deleted files in use:") for file in listfiles: print("\t" + file) def listDeletedMachine(self): listfiles = self.listDeletedHelper() for file in listfiles: print('file\t%s\t%s\t%s' % (self.pid, self.program, file)) # Check if a process needs to be restarted, previously we would # just check if it used libraries named '.dpkg-new' since that's # what dpkg would do. Now we need to be more contrieved. # Returns: # - 0 if there is no need to restart the process # - 1 if the process needs to be restarted def needsRestart(self, blacklist = None): for f in self.files: if isdeletedFile(f, blacklist): return 1 for f in self.links: if f == 0: return 1 return 0 class Package: def __init__(self, name): self.name = name # use a set, we don't need duplicates self.initscripts = set() self.systemdservice = set() self.processes = [] if __name__ == '__main__': main()
Close