Bug 1347746 - different ls -l /dev/disk/by-uuid between previous Fedora, fedora beta and Fedora24
Summary: different ls -l /dev/disk/by-uuid between previous Fedora, fedora beta ...
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Fedora
Classification: Fedora
Component: coreutils
Version: 24
Hardware: x86_64
OS: Linux
unspecified
medium
Target Milestone: ---
Assignee: Kamil Dudka
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
: 1370362 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-06-17 14:09 UTC by Leslie Satenstein
Modified: 2016-08-26 13:18 UTC (History)
9 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2016-06-17 20:09:58 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
ls -l /dev/disk/by-uuid (f24 beta) (2.77 KB, text/plain)
2016-06-17 14:09 UTC, Leslie Satenstein
no flags Details
ls -l /dev/disk/by-uuid (f24 gold) (2.77 KB, text/plain)
2016-06-17 14:10 UTC, Leslie Satenstein
no flags Details
ls -l /dev/disk/by-uuid (f23) (2.77 KB, text/plain)
2016-06-17 14:11 UTC, Leslie Satenstein
no flags Details

Description Leslie Satenstein 2016-06-17 14:09:16 UTC
Created attachment 1169137 [details]
ls -l /dev/disk/by-uuid       (f24 beta)

Description of problem:

The time has been replaced by 2016 (the year)
with older betas, the time was listed has hh:mm  

Refer to two listings attached.

Version-Release number of selected component (if applicable):

Three listings   
F24 beta (from koji)

f24 gold  (from koji)

F23       (from f23 gold)
How reproducible:


Steps to Reproduce:
1.
2.
3.

Actual results:


Expected results:


Additional info:

Comment 1 Leslie Satenstein 2016-06-17 14:10:24 UTC
Created attachment 1169138 [details]
ls -l /dev/disk/by-uuid       (f24 gold)

Check out the column for time

Comment 2 Leslie Satenstein 2016-06-17 14:11:30 UTC
Created attachment 1169139 [details]
ls -l /dev/disk/by-uuid       (f23)

F23 and F24 beta listings and centos are identical in format

Comment 3 Leslie Satenstein 2016-06-17 15:09:47 UTC
Please note. On the day Fedora is installed the hhmm field (see attachments) is shown as 2016  

The day after the install date year field is replaced by HH:MM

I was parsing the above listings and searching for HH:MM 


I have since changed my parser program.  This bug is for me a very low priority.

Comment 4 Kamil Dudka 2016-06-17 15:43:51 UTC
Please attach the output of 'date' on the system in question.  I suspect this is shown because date/time is not set properly.  The info documentation for ls says:

    By default, file timestamps are listed in abbreviated form, using a date
    like ‘Mar 30  2002’ for non-recent timestamps, and a date-without-year
    and time like ‘Mar 30 23:45’ for recent timestamps.  This format can
    change depending on the current locale as detailed below.

Comment 5 Kamil Dudka 2016-06-17 15:45:49 UTC
(In reply to Leslie Satenstein from comment #3)
> I was parsing the above listings and searching for HH:MM

Please consider using the --time-style option of ls if you intend to parse the output.

Comment 6 Leslie Satenstein 2016-06-17 17:25:40 UTC
Today 9am I installed F24 (using june14 version).  Yes, the date was correct, (today), and the hh:mm was replaced by yyyy.

My software was looking for hh:mm.   As you note, attachment 2 [details] is what is produced.

As I stated in comment 3,  I revised my software so that any date format is acceptable to my stuff.

As you say, the ls -l /dev/disk/by-uuid can have multiple formats, my parser has been revised to accept any date format.

I was expecting the  "ls -l /dev/disk/by-uuid" format to be invariant.

You have pointed out that it is not a bug! Even if the creation timestamp was an hour earlier.

You may close this issue as not-a-bug

Thank you for the prompt followup.

Comment 7 Kamil Dudka 2016-06-17 20:09:58 UTC
Thanks for clarifying it!  Closing...

Comment 8 Kamil Dudka 2016-08-26 06:46:05 UTC
*** Bug 1370362 has been marked as a duplicate of this bug. ***

Comment 9 Leslie Satenstein 2016-08-26 13:18:15 UTC
Please keep as closed   
I was using region as Canada English (which also formats the date differently)

The following code fragment may help anyone wanting to extract the UUID if the line is with the date formats listed as attachments.
I put it here in case someone encounters a different date format ... 

#include <string.h>
....
 char *extract_field(char *fstabline)
{
    char *cp=strstr(fstabline," ->"); /* at end of desired field*/
    if(cp) {
      *cp-- = '\0';
      while(*cp!=' ' && *cp)         /*backup to opening char */   
           cp--;
      cp++;
    }
    return cp;
}


Note You need to log in before you can comment on or make changes to this bug.