unable to modify created and modification time of symbolic links
ProgrammingThis forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.
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.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Introduction to Linux - A Hands on Guide
This guide was created as an overview of the Linux Operating System, geared toward new users as an exploration tour and getting started guide, with exercises at the end of each chapter.
For more advanced trainees it can be a desktop reference, and a collection of the base knowledge needed to proceed with system and network administration. This book contains many real life examples derived from the author's experience as a Linux system and network administrator, trainer and consultant. They hope these examples will help you to get a better understanding of the Linux system and that you feel encouraged to try out things on your own.
Click Here to receive this Complete Guide absolutely free.
but instead i get lrwxrwxrwx 1 avni avni 5 Feb 28 11:30 file1_link_dup -> file1
when is do utime for file1_link_dup the result is something like this: lrwxrwxrwx 1 avni avni 5 Feb 27 11:44 file1_link -> file1
-rw-rw-rw- 1 avni avni 2061 Feb 27 11:44 file1
lrwxrwxrwx 1 avni avni 5 Feb 28 11:30 file1_link_dup -> file1
can any body tell how this can be achieved.
I read about lutimes, but its not on my system.
i am writing code in C. I don't want to use perl.
The kernel is 2.4.7.
I am new to UNIX and hence have little knowledge of the various distributions and commands available.
Can any one guide me where should I start the search for the solution!!!
If you think this is the wrong forum, then Please guide me to the correct forum.
Because lutimes() on linux uses the utimensat() system call with the AT_SYMLINK_NOFOLLOW flag. This system call was introduced in linux-2.6.22, so is unavailable for 2.4.7.
Is it possible to implement utimes like function?
I strongly believe that there should be some way to modify the time of links. The main reason being, there would be some inode that maintains the record for the link, and if there is some inode there should be some sub-routine to access/modify it.