Codebase list debian-goodies / b1b63e8
Tighten up the regular expression to avoid false positives with files that contain 'deleted' as part of their name. Patch provided by Simon Ruderich (closes: 758711) This happens at least with samba4, which contains the following files: samba 2513 root mem REG 254,32 10400 146566 /usr/lib/x86_64-linux-gnu/samba/ldb/subtree_delete.so samba 2513 root mem REG 254,32 10424 146609 /usr/lib/x86_64-linux-gnu/samba/ldb/show_deleted.so and with mysql as shown in the output below: ---------------------------------------------------------------- output of checkrestart $ checkrestart -pva Found 1 processes using old versions of upgraded files (1 distinct program) Process /usr/sbin/mysqld (PID: 2775) List of deleted files in use: /var/lib/mysql/database/upload_tmp_deleted.ibd /var/lib/mysql/database/upload_tmp_deleted.ibd /var/lib/mysql/database/upload_tmp_deleted.ibd /var/lib/mysql/database/upload_tmp_deleted.ibd /var/lib/mysql/database/upload_tmp_deleted.ibd /var/lib/mysql/database/upload_tmp_deleted.ibd /var/lib/mysql/database/upload_tmp_deleted.ibd /var/lib/mysql/database/upload_tmp_deleted.ibd /var/lib/mysql/database/upload_tmp_deleted.ibd /var/lib/mysql/database/upload_tmp_deleted.ibd Running:['dpkg-query', '--search', '/usr/sbin/mysqld'] Reading line: percona-server-server-5.6: /usr/sbin/mysqld (1 distinct packages) Of these, 1 seem to contain init scripts which can be used to restart them: The following packages seem to have init scripts that could be used to restart them: percona-server-server-5.6: 2775 /usr/sbin/mysqld These are the init scripts: service mysql restart ---------------------------------------------------------------- Javier Fernandez-Sanguino 9 years ago
1 changed file(s) with 1 addition(s) and 1 deletion(s). Raw diff Collapse all Expand all
321321 last = process.descriptors.pop()
322322 # Add it to the list of deleted files if the previous descriptor
323323 # was DEL or lsof marks it as deleted
324 if re.compile("DEL").search(last) or re.compile("deleted").search(data) or re.compile("\(path inode=[0-9]+\)$").search(data):
324 if re.compile("DEL").search(last) or re.compile("\(deleted\)").search(data) or re.compile("\(path inode=[0-9]+\)$").search(data):
325325 process.files.append(data)
326326 else:
327327 # We discard the previous descriptors and drop it