Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Message from discussion ftok() on Linux generated different keys for the same inode and the same file name
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
Alex Vinokur  
View profile  
 More options Dec 15 2011, 1:34 pm
Newsgroups: comp.unix.programmer, comp.os.linux.development.system
From: Alex Vinokur <alex.vino...@gmail.com>
Date: Thu, 15 Dec 2011 10:34:00 -0800 (PST)
Subject: Re: ftok() on Linux generated different keys for the same inode and the same file name
On Dec 15, 8:16 pm, Huibert Bol <huibert....@quicknet.nl> wrote:

> Alex Vinokur wrote:
> > It seems that ftok() on Linux generated different keys for the same
> > inode and the same file name.

> > Linux 2.6.18-238.12.1.el5 #1 SMP Sat May 7 20:18:50 EDT 2011 x86_64
> > x86_64 x86_64 GNU/Linux

> > AccessTime = 20111020-153001   Inode = 6914144   ShmKeyDec =
> > 1091272800   ShmKeyHex = 0x410b8060
> > AccessTime = 20111020-155359   Inode = 6914144   ShmKeyDec =
> > 1091338336   ShmKeyHex = 0x410c8060

> After a reboot, right?  From the source:

>   key = ((st.st_ino & 0xffff) | ((st.st_dev & 0xff) << 16)
>          | ((proj_id & 0xff) << 24));

> The parts that differ are set to the device number, perhaps your disks
> were detected in a different order.

> --
> Huibert
> "Okay... really not something I needed to see."  --Raven

I am not sure that it was after reboot: difference between asscess
times is about 4 min.
I don't know.

AccessTime = 20111020-153001   Inode = 6914144   ShmKeyDec =
1091272800   ShmKeyHex = 0x410b8060
AccessTime = 20111020-155359   Inode = 6914144   ShmKeyDec =
1091338336   ShmKeyHex = 0x410c8060

Where can I see ftok()-source for Linux?

Thanks

Alex


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.