ps -aux | grep "I<"
root 4 0.0 0.0 0 0 ? I< 16:15 0:00 [kworker/0:0H]
root 6 0.0 0.0 0 0 ? I< 16:15 0:00 [mm_percpu_wq]
root 18 0.0 0.0 0 0 ? I< 16:15 0:00 [kworker/1:0H]
root 24 0.0 0.0 0 0 ? I< 16:15 0:00 [kworker/2:0H]
root 30 0.0 0.0 0 0 ? I< 16:15 0:00 [kworker/3:0H]
root 32 0.0 0.0 0 0 ? I< 16:15 0:00 [netns]
root 40 0.0 0.0 0 0 ? I< 16:15 0:00 [writeback]
root 44 0.0 0.0 0 0 ? I< 16:15 0:00 [crypto]
root 45 0.0 0.0 0 0 ? I< 16:15 0:00 [kintegrityd]
root 46 0.0 0.0 0 0 ? I< 16:15 0:00 [kblockd]
root 47 0.0 0.0 0 0 ? I< 16:15 0:00 [ata_sff]
root 48 0.0 0.0 0 0 ? I< 16:15 0:00 [md]
root 49 0.0 0.0 0 0 ? I< 16:15 0:00 [edac-poller]
root 50 0.0 0.0 0 0 ? I< 16:15 0:00 [devfreq_wq]
root 51 0.0 0.0 0 0 ? I< 16:15 0:00 [watchdogd]
root 56 0.0 0.0 0 0 ? I< 16:15 0:00 [kworker/u9:0]
root 99 0.0 0.0 0 0 ? I< 16:15 0:00 [kthrotld]
root 100 0.0 0.0 0 0 ? I< 16:15 0:00 [acpi_thermal_pm]
root 102 0.0 0.0 0 0 ? I< 16:15 0:00 [ipv6_addrconf]
root 111 0.0 0.0 0 0 ? I< 16:15 0:00 [kstrp]
root 129 0.0 0.0 0 0 ? I< 16:15 0:00 [charger_manager]
root 177 0.0 0.0 0 0 ? I< 16:15 0:00 [scsi_tmf_0]
root 179 0.0 0.0 0 0 ? I< 16:15 0:00 [scsi_tmf_1]
root 181 0.0 0.0 0 0 ? I< 16:15 0:00 [scsi_tmf_2]
root 183 0.0 0.0 0 0 ? I< 16:15 0:00 [scsi_tmf_3]
root 185 0.0 0.0 0 0 ? I< 16:15 0:00 [scsi_tmf_4]
root 187 0.0 0.0 0 0 ? I< 16:15 0:00 [scsi_tmf_5]
root 193 0.0 0.0 0 0 ? I< 16:15 0:00 [e1000e]
root 202 0.0 0.0 0 0 ? I< 16:15 0:00 [kworker/3:1H]
root 205 0.0 0.0 0 0 ? I< 16:15 0:00 [kworker/0:1H]
root 229 0.0 0.0 0 0 ? I< 16:15 0:00 [ext4-rsv-conver]
root 273 0.0 0.0 0 0 ? I< 16:15 0:00 [kworker/2:1H]
root 285 0.0 0.0 0 0 ? I< 16:15 0:00 [kworker/1:1H]
With the following command I have been able to list all the directories relative to the current directory along with the epoch time last modified:
find . -exec stat -c '%n: %Y' {} \;
the output looks something like this:
.: 1569247414
./a_file.txt: 1561624333
./some_folder: 1561624645
./some_folder/some_file.txt: 1561624645
./some_folder/another_file.txt: 1536557809
How would I go about getting rid of the "./" appearing at the beginning of every entry, and add a '/' if it is a directory?
As a bonus, getting rid of the first entry '.' which is just the current folder would be nice.
Cheers
Question..
Is possible to dig "real" access time of file copied from remote server and using it by including from another script?
What I need.
I need to know which files on server are unused/untouched for long time, but I have only ftp access, so I must download files. Curlftps not solve this.
And what about files only included from another file, for example include in php script? Does included file change his access time when is accessed by include from another script?
Edited.
Tested included file access time change, it change access time when file is "touched" by include script.
Tested
When I copied the file, there was quite strange access time, file should be accessed very often.
hosek@yoga:~/www/html/__test$ stat rest.php
File: rest.php
Size: 26312 Blocks: 56 IO Block: 4096 regular file
Device: 804h/2052d Inode: 1739998 Links: 1
Access: (0666/-rw-rw-rw-) Uid: ( 1000/ hosek) Gid: ( 1000/ hosek)
Access: 2018-05-24 00:00:00.000000000 +0200
Modify: 2018-05-24 00:00:00.000000000 +0200
Change: 2019-07-03 12:46:58.724173058 +0200
Birth: -
hosek@yoga:~/www/html/__test$
Thank you.
Edited.
Just info, that when I connect via sshfs or curlftps, seems that display right access date, but time is only at 0, which is ok for me. Is this date real or am I wrong? And is Access time "real"? Thanks.
File: ./rest.php
Size: 26312 Blocks: 56 IO Block: 4096 regular file
Device: 31h/49d Inode: 23 Links: 1
Access: (0666/-rw-rw-rw-) Uid: ( 0/ root) Gid: ( 0/ root)
Access: 2018-05-24 01:00:00.000000000 +0200
Modify: 2018-05-24 01:00:00.000000000 +0200
Change: 2018-05-24 01:00:00.000000000 +0200
Birth: -
File: ./robots.txt
Size: 277 Blocks: 8 IO Block: 4096 regular file
Device: 31h/49d Inode: 24 Links: 1
Access: (0666/-rw-rw-rw-) Uid: ( 0/ root) Gid: ( 0/ root)
Access: 2018-05-24 01:00:00.000000000 +0200
Modify: 2018-05-24 01:00:00.000000000 +0200
Change: 2018-05-24 01:00:00.000000000 +0200
Birth: -
File: ./svn.txt
Size: 32 Blocks: 8 IO Block: 4096 regular file
Device: 31h/49d Inode: 25 Links: 1
Access: (0666/-rw-rw-rw-) Uid: ( 0/ root) Gid: ( 0/ root)
Access: 2016-06-30 01:00:00.000000000 +0200
Modify: 2016-06-30 01:00:00.000000000 +0200
Change: 2016-06-30 01:00:00.000000000 +0200
Birth: -
When you use sadf
to make a report from sysstat
's datafile, the following lines will be shown:
ncm 3 2015-05-11 03:57:15 UTC all %%user 0.08
ncm 3 2015-05-11 03:57:15 UTC all %%nice 0.00
ncm 3 2015-05-11 03:57:15 UTC all %%system 0.08
ncm 3 2015-05-11 03:57:15 UTC all %%iowait 0.00
ncm 3 2015-05-11 03:57:15 UTC all %%steal 0.00
ncm 3 2015-05-11 03:57:15 UTC all %%idle 99.84
What does the second filed of this output mean?
What is the difference between Modify and Change in stat output? When I run this command:
stat myfile
I am getting two lines with identical timestamps:
Modify: 2015-03-24 12:34:56.12345678
Change: 2015-03-24 12:34:56.12345678
What is the deal?