Questions tagged [stat]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
1
vote
0answers
62 views

Files, “real” access time when copy from remote host

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/...
0
votes
2answers
527 views

SED or something to delete everything after first space up to `|`

I have a little bash snippet I'm working on: $ stat --printf=%A\|%U\|%G\|%s\|%y\|%N'\n' /usr/src/linux-headers-4.4.0-124/zfs/cmd/zhack drwxr-xr-x|root|root|4096|2018-05-17 05:54:49.361904361 -0600|'/...
0
votes
0answers
158 views

New STATX: how do I find the creation time (birth time) of a file? [duplicate]

How to use the new statx function to get only one information: the creation time (birth time) of a file. I have tried in terminal command line without success.
0
votes
0answers
28 views

Send ubuntu stats on Databox

I would like to send stats about my Ubuntu machine on Databox (uptime, network traffic, free space...) This will allow my colleagues to see the status of the machine. Do you think that would be ...
11
votes
2answers
3k views

When is Birth Date for a file actually used? [duplicate]

When I type the following: $ IFS=$'\n'; arr=( $(stat "/bin/bash") ); for i in ${arr[@]} ; do echo $i ; done File: '/bin/bash' Size: 1037528 Blocks: 2032 IO Block: 4096 regular file ...
2
votes
1answer
670 views

Getting “unable to stat //bundle (No such file or directory)” even though the file exists

I'm hoping this is just a problem with my not understanding how the $PATH variable works. I'm using Ubuntu 14.04. I'm trying to run rails through a unicorn server. I have the below configuration ...
0
votes
0answers
42 views

Why “/proc/pid/stat” have 2 type?

When I run command: cat /proc/$pid/stat, it returns string like this: type 1: 11473 (abc) R 11471 8438 8438 0 -1 4194304 113 0 0 0 0 0 0 0 20 0 1 0 740394567 13586432 387 18446744073709551615 ...
2
votes
1answer
37 views

Nautilus calling stat/file on all directory entries

I am writing a paper and I need to confirm something that is pretty obvious to me but I haven't seen the code that would authoritatively tell me that this is how it works. When I open a folder in ...
3
votes
1answer
572 views

Default number of links for directory?

I know that hard link can not point to directories but when i create an empty directory and execute stat command for it links=2 ,I search for symbolic links There is not another link. why for ...
1
vote
0answers
52 views

I can copy a file using cp, but trying to use sendfax returns cannot stat file.

As the title says, using Raspberry pi, and Raspbian, I am trying to configure a faxing server that basically reads a file from a CIFS share and sends it using hylafax. If the file is stored locally, ...
0
votes
2answers
537 views

Cannot apply 'stat' command for given parameters

I want to make a small shell script that shows all the files in a file tree starting from a given directory that have the given user and size greater than a given size. Hence, my script will take as ...
2
votes
1answer
218 views

What does mean the second field of sadf`s output?

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 ...
4
votes
1answer
3k views

What is the difference between Modify and Change in stat output

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: ...
1
vote
1answer
2k views

Can a directory's mtime be older than that of file inside?

I have this very silly and very basic question but I thought better to ask before I start pruning my NAS. I want to delete all directories in which all files are older than 30 days. For files I ...
12
votes
1answer
19k views

sudo: unable to stat /etc/sudoers: No such file or directory - File Exists

I am one of a few people managing a gaming server. The Server is currently running Ubuntu 14.04, which was installed just 3 weeks ago. Everything was running fine until a few days ago, we've had a ...
63
votes
4answers
70k views

How do I find the creation time of a file?

I need to find the creation time of a file, when I read some articles about this issue, all mentioned that there is no solution (like Site1, Site2). When I tried the stat command, it states Birth: -...
3
votes
1answer
3k views

Sort files in directory by creation date(Birth)

In my Download folder I have a lot of files.I need first a way to arrange them by type second files with same type arrangement become by the type that i added(or can say downloaded or birth (if i am ...