$ sudo apt-get install liblockfile1=1.09-3ubuntu0.1
Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies:
liblockfile1 : Depends: liblockfile-bin (>= 1.09-3ubuntu0.1)
E: Unable to correct problems, you have held broken packages.
$ sudo apt-get install liblockfile1=1.09-3ubuntu0.1 liblockfile-bin=1.09-3ubuntu0.1
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages will be upgraded:
liblockfile-bin liblockfile1
2 upgraded, 0 newly installed, 0 to remove and 7 not upgraded.
Need to get 21.5 kB of archives.
After this operation, 0 B of additional disk space will be used.
Get:1 http://mirror/ubuntu/ precise-proposed/main liblockfile-bin amd64 1.09-3ubuntu0.1 [12.3 kB]
Get:2 http://mirror/ubuntu/ precise-proposed/main liblockfile1 amd64 1.09-3ubuntu0.1 [9,232 B]
Fetched 21.5 kB in 0s (472 kB/s)
(Reading database ... 372341 files and directories currently installed.)
Preparing to replace liblockfile-bin 1.09-3 (using .../liblockfile-bin_1.09-3ubuntu0.1_amd64.deb) ...
Unpacking replacement liblockfile-bin ...
Preparing to replace liblockfile1 1.09-3 (using .../liblockfile1_1.09-3ubuntu0.1_amd64.deb) ...
Unpacking replacement liblockfile1 ...
Processing triggers for man-db ...
Setting up liblockfile-bin (1.09-3ubuntu0.1) ...
Setting up liblockfile1 (1.09-3ubuntu0.1) ...
Processing triggers for libc-bin ...
ldconfig deferred processing now taking place
pkern@kaos:/tmp$ (echo $BASHPID; lockfile-create $lock --use-pid; cat ${lock}.lock)
1006597
1006597
Verifies just fine for me, given the instructions:
$ sudo sysctl -w kernel. pid_max= 4194304
kernel.pid_max = 4194304
With the old build:
$ lock=/var/ lock/lockfile- create- test 64-linux- gnu/libc. so.6(__ fortify_ fail+0x37) [0x7fdecf313817 ] 64-linux- gnu/libc. so.6(+0x109710) [0x7fdecf312710 ] 64-linux- gnu/libc. so.6(+0x108b79) [0x7fdecf311b79 ] 64-linux- gnu/libc. so.6(_IO_ default_ xsputn+ 0xdd)[0x7fdecf2 8513d] 64-linux- gnu/libc. so.6(_IO_ vfprintf+ 0x1ae7) [0x7fdecf2534a7 ] 64-linux- gnu/libc. so.6(__ vsprintf_ chk+0x94) [0x7fdecf311c14 ] 64-linux- gnu/libc. so.6(__ sprintf_ chk+0x7d) [0x7fdecf311b5d ] x86_64- linux-gnu/ liblockfile. so.1(+0x1b26) [0x7fdecf5c9b26 ] x86_64- linux-gnu/ liblockfile. so.1(lockfile_ create+ 0x61)[0x7fdecf5 c9dd1] create[ 0x400f21] 64-linux- gnu/libc. so.6(__ libc_start_ main+0xed) [0x7fdecf22a76d ] create[ 0x4012c5] lockfile- create lockfile- create lockfile- create 7fdecf008000 r-xp 00000000 fc:00 394091 /lib/x86_ 64-linux- gnu/libgcc_ s.so.1 7fdecf207000 ---p 00015000 fc:00 394091 /lib/x86_ 64-linux- gnu/libgcc_ s.so.1 7fdecf208000 r--p 00014000 fc:00 394091 /lib/x86_ 64-linux- gnu/libgcc_ s.so.1 7fdecf209000 rw-p 00015000 fc:00 394091 /lib/x86_ 64-linux- gnu/libgcc_ s.so.1 7fdecf3be000 r-xp 00000000 fc:00 394167 /lib/x86_ 64-linux- gnu/libc- 2.15.so 7fdecf5bd000 ---p 001b5000 fc:00 394167 /lib/x86_ 64-linux- gnu/libc- 2.15.so 7fdecf5c1000 r--p 001b4000 fc:00 394167 /lib/x86_ 64-linux- gnu/libc- 2.15.so 7fdecf5c3000 rw-p 001b8000 fc:00 394167 /lib/x86_ 64-linux- gnu/libc- 2.15.so 7fdecf5c8000 rw-p 00000000 00:00 0 7fdecf5cb000 r-xp 00000000 fc:00 271728 /usr/lib/ x86_64- linux-gnu/ liblockfile. so.1.0 7fdecf7ca000 ---p 00003000 fc:00 271728 /usr/lib/ x86_64- linux-gnu/ liblockfile. so.1.0 7fdecf7cb000 r--p 00002000 fc:00 271728 /usr/lib/ x86_64- linux-gnu/ liblockfile. so.1.0 7fdecf7cc000 rw-p 00003000 fc:00 271728 /usr/lib/ x86_64- linux-gnu/ liblockfile. so.1.0 7fdecf7ee000 r-xp 00000000 fc:00 394028 /lib/x86_ 64-linux- gnu/ld- 2.15.so 7fdecf9c6000 rw-p 00000000 00:00 0 7fdecf9ee000 rw-p 00000000 00:00 0 7fdecf9ef000 r--p 00022000 fc:00 394028 /lib/x86_ 64-linux- gnu/ld- 2.15.so 7fdecf9f1000 rw-p 00023000 fc:00 394028 /lib/x86_ 64-linux- gnu/ld- 2.15.so 7ffffd373000 rw-p 00000000 00:00 0 [stack] 7ffffd400000 r-xp 00000000 00:00 0 [vdso] 0-ffffffffff601 000 r-xp 00000000 00:00 0 [vsyscall] lockfile- create- test.lock: No such file or directory
$ lockfile-remove $lock
$ while ([ $BASHPID -lt 1000000 ]); do continue; done
$ (echo $BASHPID; lockfile-create $lock --use-pid; cat ${lock}.lock)
1004029
*** buffer overflow detected ***: lockfile-create terminated
======= Backtrace: =========
/lib/x86_
/lib/x86_
/lib/x86_
/lib/x86_
/lib/x86_
/lib/x86_
/lib/x86_
/usr/lib/
/usr/lib/
lockfile-
/lib/x86_
lockfile-
======= Memory map: ========
00400000-00402000 r-xp 00000000 fc:00 1575056 /usr/bin/
00602000-00603000 r--p 00002000 fc:00 1575056 /usr/bin/
00603000-00604000 rw-p 00003000 fc:00 1575056 /usr/bin/
01566000-01587000 rw-p 00000000 00:00 0 [heap]
7fdeceff3000-
7fdecf008000-
7fdecf207000-
7fdecf208000-
7fdecf209000-
7fdecf3be000-
7fdecf5bd000-
7fdecf5c1000-
7fdecf5c3000-
7fdecf5c8000-
7fdecf5cb000-
7fdecf7ca000-
7fdecf7cb000-
7fdecf7cc000-
7fdecf9c3000-
7fdecf9eb000-
7fdecf9ee000-
7fdecf9ef000-
7ffffd352000-
7ffffd3ff000-
ffffffffff60000
cat: /var/lock/
Let's install the new one:
$ sudo apt-get install liblockfile1= 1.09-3ubuntu0. 1
Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies: 1.09-3ubuntu0. 1 liblockfile- bin=1.09- 3ubuntu0. 1 mirror/ ubuntu/ precise- proposed/ main liblockfile-bin amd64 1.09-3ubuntu0.1 [12.3 kB] mirror/ ubuntu/ precise- proposed/ main liblockfile1 amd64 1.09-3ubuntu0.1 [9,232 B] -bin_1. 09-3ubuntu0. 1_amd64. deb) ... 1_1.09- 3ubuntu0. 1_amd64. deb) ...
liblockfile1 : Depends: liblockfile-bin (>= 1.09-3ubuntu0.1)
E: Unable to correct problems, you have held broken packages.
$ sudo apt-get install liblockfile1=
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages will be upgraded:
liblockfile-bin liblockfile1
2 upgraded, 0 newly installed, 0 to remove and 7 not upgraded.
Need to get 21.5 kB of archives.
After this operation, 0 B of additional disk space will be used.
Get:1 http://
Get:2 http://
Fetched 21.5 kB in 0s (472 kB/s)
(Reading database ... 372341 files and directories currently installed.)
Preparing to replace liblockfile-bin 1.09-3 (using .../liblockfile
Unpacking replacement liblockfile-bin ...
Preparing to replace liblockfile1 1.09-3 (using .../liblockfile
Unpacking replacement liblockfile1 ...
Processing triggers for man-db ...
Setting up liblockfile-bin (1.09-3ubuntu0.1) ...
Setting up liblockfile1 (1.09-3ubuntu0.1) ...
Processing triggers for libc-bin ...
ldconfig deferred processing now taking place
pkern@kaos:/tmp$ (echo $BASHPID; lockfile-create $lock --use-pid; cat ${lock}.lock)
1006597
1006597