Package: dpkg
Version: 1.13.25
Severity: normal

Below is part of the output of stracing dpkg when installing a package.  As
you can see it opens the file without O_SYNC and renames it without calling
fsync() first.  This means that a reboot during the period for which write-
back caching is active (which depends on the load of the machine, the amount
of free RAM, and the filesystem in use) will cause loss of file data.

open("/usr/bin/whiptail.dpkg-new", O_WRONLY|O_CREAT|O_EXCL|O_LARGEFILE, 0) = 9
read(8, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\2\0\3\0\1\0\0\0\220\226"..., 20636) = 2
0636
write(9, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\2\0\3\0\1\0\0\0\220\226"..., 20636) =
20636
read(8, "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"..., 356) = 356
fchown32(9, 0, 0)                       = 0
fchmod(9, 0755)                         = 0
close(9)                                = 0
utime("/usr/bin/whiptail.dpkg-new", [2007/06/28-16:35:29, 2007/01/23-03:58:38])
= 0
link("/usr/bin/whiptail", "/usr/bin/whiptail.dpkg-tmp") = 0
gettid()                                = 1722
open("/proc/self/task/1722/attr/fscreate", O_RDWR|O_LARGEFILE) = 9
write(9, "system_u:object_r:bin_t:s0\0", 27) = 27
close(9)                                = 0
rename("/usr/bin/whiptail.dpkg-new", "/usr/bin/whiptail") = 0



-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to