Subject: | Cleaning up /tmp directory; predictable tmp filenames |
In my /tmp directory I find
-rw-r--r-- 1 sand sand 2048 2007-11-07 05:19:11 sb-test.23983
-rw-r--r-- 1 sand sand 4096 2007-11-07 05:19:14 sb-test.23988
-rw-r--r-- 1 sand sand 2048 2007-11-07 05:19:16 sb-test.23990
-rw-r--r-- 1 sand sand 2048 2007-11-07 05:19:25 sb-test.24005
-rw-r--r-- 1 sand sand 2048 2007-11-07 05:19:26 sb-test.24006
I'm now generally using second resolution in my ls command, so I find
the originator quickest:
drwx------ 9 sand sand 4096 2007-11-07 05:19:02 Jifty-DBI-0.45-HSVPh6/
-rw-rw-r-- 1 sand sand 2287 2007-11-07 05:19:32 Jifty-DBI-0.45-HSVPh6.yml
The content of the last of the files is an ugly mixture of binary and
text content:
# od -c sb-test.24006
0000000 S Q L i t e f o r m a t 3 \0
0000020 004 \0 001 001 \0 @ \0 \0 \0 005 \0 \0 \0 \0
0000040 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 001 \0 \0 \0 001
0000060 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 001 \0 \0 \0 \0
0000100 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0
*
0000140 \0 \0 \0 \0 \r \0 \0 \0 001 003 7 \0 003 7 \0 \0
0000160 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0
*
0001460 \0 \0 \0 \0 \0 \0 \0 201 F 001 \a 027 037 037 001 202
0001500 [ t a b l e a d d r e s s e s a
0001520 d d r e s s e s 002 C R E A T E
0001540 T A B L E a d d r e s s e s
0001560 ( \n i d i n
0001600 t e g e r p r i m a r y k e
0001620 y , \n n a m e
0001640 v a r c h a r ( 3 6 ) , \n
0001660 p h o n e v a r c h
0001700 a r ( 1 8 ) , \n
0001720 a d d r e s s v a r c h a r (
0001740 5 0 ) , \n e m p
0001760 l o y e e _ i d i n t ( 8 ) )
0002000 \r \0 \0 \0 \0 004 \0 \0 003 346 \0 \0 \0 \0 \0 \0
0002020 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0
*
0003740 \0 \0 \0 \0 \0 \0 \0 \0 \0 032 031 % \r \0 z o
0003760 s t a y 0 9 8 7 6 5 4 3 2 1
0004000
Please note that these filenames are too predictable so have security
implications if people run these tests as root.
Thanks,