FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Redhat > Fedora Development

 
 
LinkBack Thread Tools
 
Old 04-14-2011, 08:08 AM
Andreas Schwab
 
Default Ext4 + barriers=1 + ssd + power loss while commiting to a git repo = broken repo?

Michał Piotrowski <mkkp4x4@gmail.com> writes:

> After turning system on I noticed that repo is totally broken.

How do you define "totally broken"?

Andreas.

--
Andreas Schwab, schwab@redhat.com
GPG Key fingerprint = D4E8 DBE3 3813 BB5D FA84 5EC7 45C6 250E 6F00 984E
"And now for something completely different."
--
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel
 
Old 04-14-2011, 08:14 AM
Michał Piotrowski
 
Default Ext4 + barriers=1 + ssd + power loss while commiting to a git repo = broken repo?

2011/4/14 Andreas Schwab <schwab@redhat.com>:
> Michał Piotrowski <mkkp4x4@gmail.com> writes:
>
>> After turning system on I noticed that repo is totally broken.
>
> How do you define "totally broken"?

All files in repo looks like added to commit, but not commited.

#
# Initial commit
#
# Changes to be committed:
# (use "git rm --cached <file>..." to unstage)
#

list of over 5000 files to commit...


Also git log says
fatal: bad default revision 'HEAD'


>
> Andreas.
>
> --
> Andreas Schwab, schwab@redhat.com
> GPG Key fingerprint = D4E8 DBE3 3813 BB5D FA84 *5EC7 45C6 250E 6F00 984E
> "And now for something completely different."
> --
> devel mailing list
> devel@lists.fedoraproject.org
> https://admin.fedoraproject.org/mailman/listinfo/devel



--
Best regards,
Michal

http://eventhorizon.pl/
--
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel
 
Old 04-14-2011, 08:29 AM
Andreas Schwab
 
Default Ext4 + barriers=1 + ssd + power loss while commiting to a git repo = broken repo?

Michał Piotrowski <mkkp4x4@gmail.com> writes:

> Also git log says
> fatal: bad default revision 'HEAD'

Looks like the only issue is that .git/refs/heads/master has been lost.

Andreas.

--
Andreas Schwab, schwab@redhat.com
GPG Key fingerprint = D4E8 DBE3 3813 BB5D FA84 5EC7 45C6 250E 6F00 984E
"And now for something completely different."
--
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel
 
Old 04-14-2011, 08:36 AM
Michał Piotrowski
 
Default Ext4 + barriers=1 + ssd + power loss while commiting to a git repo = broken repo?

W dniu 14 kwietnia 2011 10:29 użytkownik Andreas Schwab
<schwab@redhat.com> napisał:
> Michał Piotrowski <mkkp4x4@gmail.com> writes:
>
>> Also git log says
>> fatal: bad default revision 'HEAD'
>
> Looks like the only issue is that .git/refs/heads/master has been lost.

Indeed, the file is empty.

But I don't have this file in the repo that I restored from the backup.

>
> Andreas.
>
> --
> Andreas Schwab, schwab@redhat.com
> GPG Key fingerprint = D4E8 DBE3 3813 BB5D FA84 *5EC7 45C6 250E 6F00 984E
> "And now for something completely different."
>



--
Best regards,
Michal

http://eventhorizon.pl/
--
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel
 
Old 04-14-2011, 08:42 AM
Andreas Schwab
 
Default Ext4 + barriers=1 + ssd + power loss while commiting to a git repo = broken repo?

Michał Piotrowski <mkkp4x4@gmail.com> writes:

> But I don't have this file in the repo that I restored from the backup.

You do, in .git/packed-refs.

Andreas.

--
Andreas Schwab, schwab@redhat.com
GPG Key fingerprint = D4E8 DBE3 3813 BB5D FA84 5EC7 45C6 250E 6F00 984E
"And now for something completely different."
--
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel
 
Old 04-14-2011, 08:51 AM
Michał Piotrowski
 
Default Ext4 + barriers=1 + ssd + power loss while commiting to a git repo = broken repo?

W dniu 14 kwietnia 2011 10:42 użytkownik Andreas Schwab
<schwab@redhat.com> napisał:
> Michał Piotrowski <mkkp4x4@gmail.com> writes:
>
>> But I don't have this file in the repo that I restored from the backup.
>
> You do, in .git/packed-refs.

You're right.

But the question remains - should enabled barriers protect against
such data loss/breakage? Or I just had a big bad luck?

>
> Andreas.
>
> --
> Andreas Schwab, schwab@redhat.com
> GPG Key fingerprint = D4E8 DBE3 3813 BB5D FA84 *5EC7 45C6 250E 6F00 984E
> "And now for something completely different."
>



--
Best regards,
Michal

http://eventhorizon.pl/
--
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel
 
Old 04-14-2011, 09:04 AM
Andreas Schwab
 
Default Ext4 + barriers=1 + ssd + power loss while commiting to a git repo = broken repo?

Michał Piotrowski <mkkp4x4@gmail.com> writes:

> But the question remains - should enabled barriers protect against
> such data loss/breakage? Or I just had a big bad luck?

It could also be a bug in git, perhaps it needs to take more care to
create the ref file atomically.

Andreas.

--
Andreas Schwab, schwab@redhat.com
GPG Key fingerprint = D4E8 DBE3 3813 BB5D FA84 5EC7 45C6 250E 6F00 984E
"And now for something completely different."
--
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel
 
Old 04-14-2011, 09:15 AM
Michał Piotrowski
 
Default Ext4 + barriers=1 + ssd + power loss while commiting to a git repo = broken repo?

W dniu 14 kwietnia 2011 11:04 użytkownik Andreas Schwab
<schwab@redhat.com> napisał:
> Michał Piotrowski <mkkp4x4@gmail.com> writes:
>
>> But the question remains - should enabled barriers protect against
>> such data loss/breakage? Or I just had a big bad luck?
>
> It could also be a bug in git, perhaps it needs to take more care to
> create the ref file atomically.

Should I report it to upstream or in bugzilla.redhat.com?

I have no problems with doing backups and restoring from them,
but if it's a git problem, then someone in the future may be less fortunate.

It seems to me that the repairing git repo without a deep knowledge of
it can be rather difficult.

>
> Andreas.
>
> --
> Andreas Schwab, schwab@redhat.com
> GPG Key fingerprint = D4E8 DBE3 3813 BB5D FA84 *5EC7 45C6 250E 6F00 984E
> "And now for something completely different."
>



--
Best regards,
Michal

http://eventhorizon.pl/
--
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel
 
Old 04-14-2011, 09:19 AM
Andreas Schwab
 
Default Ext4 + barriers=1 + ssd + power loss while commiting to a git repo = broken repo?

Michał Piotrowski <mkkp4x4@gmail.com> writes:

> W dniu 14 kwietnia 2011 11:04 użytkownik Andreas Schwab
> <schwab@redhat.com> napisał:
>> Michał Piotrowski <mkkp4x4@gmail.com> writes:
>>
>>> But the question remains - should enabled barriers protect against
>>> such data loss/breakage? Or I just had a big bad luck?
>>
>> It could also be a bug in git, perhaps it needs to take more care to
>> create the ref file atomically.
>
> Should I report it to upstream or in bugzilla.redhat.com?

Looking closer it seems like git already does the right thing
(open("master.lock"), write(sha1), rename("master.lock", "master")), so
it appears to be a barriers issue.

> It seems to me that the repairing git repo without a deep knowledge of
> it can be rather difficult.

gitrepository-layout(5)

Andreas.

--
Andreas Schwab, schwab@redhat.com
GPG Key fingerprint = D4E8 DBE3 3813 BB5D FA84 5EC7 45C6 250E 6F00 984E
"And now for something completely different."
--
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel
 
Old 04-14-2011, 09:27 AM
Michał Piotrowski
 
Default Ext4 + barriers=1 + ssd + power loss while commiting to a git repo = broken repo?

W dniu 14 kwietnia 2011 11:19 użytkownik Andreas Schwab
<schwab@redhat.com> napisał:
> Michał Piotrowski <mkkp4x4@gmail.com> writes:
>
>> W dniu 14 kwietnia 2011 11:04 użytkownik Andreas Schwab
>> <schwab@redhat.com> napisał:
>>> Michał Piotrowski <mkkp4x4@gmail.com> writes:
>>>
>>>> But the question remains - should enabled barriers protect against
>>>> such data loss/breakage? Or I just had a big bad luck?
>>>
>>> It could also be a bug in git, perhaps it needs to take more care to
>>> create the ref file atomically.
>>
>> Should I report it to upstream or in bugzilla.redhat.com?
>
> Looking closer it seems like git already does the right thing
> (open("master.lock"), write(sha1), rename("master.lock", "master")), so
> it appears to be a barriers issue.

Do you see something unusual here?

[ 3.926076] EXT4-fs (sda1): INFO: recovery required on readonly filesystem
[ 3.926084] EXT4-fs (sda1): write access will be enabled during recovery
[ 4.655780] EXT4-fs (sda1): orphan cleanup on readonly fs
[ 4.655813] EXT4-fs (sda1): ext4_orphan_cleanup: deleting
unreferenced inode 269578
[ 4.656046] EXT4-fs (sda1): ext4_orphan_cleanup: deleting
unreferenced inode 131130
[ 4.656179] EXT4-fs (sda1): ext4_orphan_cleanup: deleting
unreferenced inode 131111
[ 4.656250] EXT4-fs (sda1): ext4_orphan_cleanup: deleting
unreferenced inode 271833
[ 4.656380] EXT4-fs (sda1): ext4_orphan_cleanup: deleting
unreferenced inode 271832
[ 4.656455] EXT4-fs (sda1): ext4_orphan_cleanup: deleting
unreferenced inode 269763
[ 4.656633] EXT4-fs (sda1): ext4_orphan_cleanup: deleting
unreferenced inode 131082
[ 4.656696] EXT4-fs (sda1): 7 orphan inodes deleted
[ 4.656701] EXT4-fs (sda1): recovery complete
[ 4.667494] EXT4-fs (sda1): mounted filesystem with ordered data
mode. Opts: (null)



>
>> It seems to me that the repairing git repo without a deep knowledge of
>> it can be rather difficult.
>
> gitrepository-layout(5)

Thanks for the pointer

>
> Andreas.
>
> --
> Andreas Schwab, schwab@redhat.com
> GPG Key fingerprint = D4E8 DBE3 3813 BB5D FA84 *5EC7 45C6 250E 6F00 984E
> "And now for something completely different."
>



--
Best regards,
Michal

http://eventhorizon.pl/
--
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel
 

Thread Tools




All times are GMT. The time now is 06:22 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org