Linux - GeneralThis Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
I'd like to implement a software license mechanism into my software, and was looking for a way of uniquely identifying a machine. Someone suggested using the creation date of /bin, and while they hadn't realised you can't get that date, it was still a good approach. It's not perfectly unique, but will be different enough for my purposes and it has the advantage that it's not hardware dependent (ie they can replace their nics etc).
I was wondering if I could use the inode number of /bin instead? The stumbling blocks will be how unique is it really, and is it likely to change at any time?
I guess if two machines were identical, and the install procedure of linux used was the same each time, then there'd be a good chance the inode's of /bin would be the same - but what factors could influence a different number (HD size/partitioning? Install procedure?, other hardware on the PC? etc).
If the inode is likely to change over time for /bin, then this idea is blown out of the water anyway...
seems a little odd a thing to pick, why not pick a hardware serial number instead? hdparm -i /dev/hda for example. Obviously that could change too, but if it did, the inode would also be different really.
is it true that SCSI drives don't have a serial number? If that isn't true then I've been on a bit of a goose chase and the HD serial will possibly be just fine.
I didn't want to use non-HD serial numbers (ie nics etc) as they are too easily replaced (obviously replacing a HD means reinstalling OS and my software anyway).
Furthermore, in a RAID system, I assume the inode's are all the same (so if the main disk goes down, the secondary disk is *identical*)? (equally, will the serial numbers be the same - they are created at formatting rather than being hard wired?)